application.yml 966 字节
Newer Older
M
ManongJu 已提交
1 2 3 4
server:
  port: 9021
spring:
  application:
M
ManongJu 已提交
5
    name: user-service
M
ManongJu 已提交
6 7
  zipkin:
      base-url: http://10.10.8.2:9050
M
ManongJu 已提交
8 9 10 11
  cloud:
    loadbalancer:
      retry:
        enabled: true
M
ManongJu 已提交
12 13
eureka:
  instance:
M
ManongJu 已提交
14 15
    prefer-ip-address: true #使用IP注册
    instance-id: ${spring.cloud.client.ipAddress}:${server.port}
M
ManongJu 已提交
16 17
  client:
      service-url:
M
ManongJu 已提交
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
        defaultZone: http://register1:9010/eureka/,http://register2:9011/eureka/

###actuator监控点 start####
endpoints:
  health:
    sensitive: false
    enabled: true
##默认情况下很多端点是不允许访问的,会返回401:Unauthorized
management:
  security:
    enabled: false
###actuator监控点 end####

ribbon:
  ConnectTimeout: 3000
  ReadTimeout: 3000
  #同一实例最大重试次数,不包括首次调用
  maxAutoRetries: 1
  # 重试其他实例的最大重试次数,不包括首次所选的server
  MaxAutoRetriesNextServer: 2
  # 是否所有操作都进行重试
  OkToRetryOnAllOperations: true