配置集群服务可以向eureka通知应用是否可以使用
a、在eureka server的application.properties中加入:
# 设为false,关闭自我保护
eureka.server.enable-self-preservation=false
# 清理间隔(单位毫秒,默认是60*1000)
eureka.server.eviction-interval-timer-in-ms=20000

b、在个application的application.properties中加入:
# 开启健康检查(需要spring-boot-starter-actuator依赖)
eureka.client.healthcheck.enabled=true
# 续约更新时间间隔(默认30秒)
eureka.instance.lease-renewal-interval-in-seconds=30
# 续约到期时间(默认90秒)
eureka.instance.lease-expiration-duration-in-seconds=90

c、如果没有加过actuator的引用,在pom.xml中加入
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>

不然启动应用会有
“Initialization of bean failed; nested exception is java.lang.NoClassDefFoundError: org/springframework/boot/actuate/health/HealthAggregator“

最新文章

  1. oracle树形查询 start with connect by
  2. python :添加的内容具有之前的功能用delegate绑定事件
  3. Kolmogorov 的数学观与业绩
  4. VMWare发布ESXi 6.0
  5. Google Chrome: Make the Bookmarks Bar Display as Icons Only
  6. 继续寻找app开发的技术方案
  7. 【BZOJ】1452: [JSOI2009]Count
  8. 转:关于数据库压缩技术的Survey
  9. Paint the Grid Again ZOJ - 3780 拓扑
  10. [ZJOI 2010]Perm 排列计数
  11. mybatis延迟加载详解
  12. Java面试题之Forward和Redirect的区别
  13. package.json文件中dependencies和devDependencies的区别
  14. Android 测试入门之---Monkey test
  15. laravel DB 执行 mysql函数或者字段
  16. CMake Error: not providing &quot;FindEigen3.cmake&quot; in CMAKE_MODULE_PATH
  17. unity项目针对IOS及Android平台的音频压缩格式
  18. 直接插入排序实现(Java)
  19. c++11 List 容器
  20. MFC+WinPcap编写一个嗅探器之六(分析模块)

热门文章

  1. myapp——自动生成小学四则运算题目的命令行程序(侯国鑫 谢嘉帆)
  2. C++客户端访问WebService VS2008
  3. SQLServer之修改索引
  4. LeetCode算法题-Employee Importance(Java实现)
  5. WPF中在MVVM模式下,后台绑定ListCollectionView事件触发问题
  6. Java学习笔记记录(一)
  7. KERBEROS PROTOCOL TUTORIAL
  8. 单元测试(qunit)
  9. Linux学习笔记(一)----Ubuntu下的apt命令
  10. docker 常用命令和常用容器启动