com.netflix.hystrix.exception.HystrixRuntimeException: service-feign timed-out a

错误: com.netflix.hystrix.exception.HystrixRuntimeException: service-feign timed-out and no fallback available.

原因:
Hystrix缺省超时判断为1秒钟,由于网络问题,有些请求超过1秒钟之后才接收到。
解决:
配置修改请求超时时长(application.yml):

hystrix:  
  command:  
    default:  
      execution:  
        isolation:  
          thread:  
            timeoutInMilliseconds: 30000 #缺省为1000  

 application.properties 文件

 

hystrix.command.default.execution.isolation.thread.timeoutInMilliseconds=30000

 

猜你喜欢

转载自chuichuige.iteye.com/blog/2394473
今日推荐