Commit 0cc47f777252643748a879c6d155f7a6eccb0e38

Authored by luotong
1 parent 30f2b41b

添加服务消费负载均衡配置ribbon

Showing 1 changed file with 19 additions and 0 deletions
class-service.yml
@@ -96,6 +96,25 @@ eureka: @@ -96,6 +96,25 @@ eureka:
96 defaultZone: http://discovery:15200/eureka/ 96 defaultZone: http://discovery:15200/eureka/
97 healthcheck: 97 healthcheck:
98 enabled: true 98 enabled: true
  99 +
  100 +hystrix:
  101 + command:
  102 + default:
  103 + execution:
  104 + timeout:
  105 + enabled: true
  106 + isolation:
  107 + thread:
  108 + timeoutInMilliseconds: 60000
  109 +
  110 +#这个配置为true则取发现服务的注册地址(服务地址存储在DomainExtractingServerList,由EurekaRibbonClientConfiguration.ribbonServerList()创建)
  111 +#为false取本地配置文件的配置地址(服务地址存储在ConfigurationBasedServerList中,由RibbonClientConfiguration.ribbonServerList()创建)
  112 +ribbon:
  113 + eureka:
  114 + enabled: true
  115 + UseIPAddrForServer: true
  116 + ReadTimeout: 5000
  117 + ConnectTimeout: 10000
99 118
100 # 一些公共的常量配置 119 # 一些公共的常量配置
101 apiConfig: 120 apiConfig: