原因:hystrix 熔断策略 慢调用默认是1秒,如果业务处理时长超过1秒,就会一直走降级
#熔断降级规则 hystrix: command: default: execution: isolation: thread: timeoutInMilliseconds: 5000 #默认是1秒,如果业务处理时长超过1秒,就会一直走降级 feign: hystrix: enabled: true #开启使用hystrix client: config: stock-service: #如果stock-service换成 default 表示所有服务 connectTimeout: 10000 readTimeout: 60000 requestInterceptors[0]: # 可以忽略 com.ldj.cloud.interceptor.CustomFeignInterceptor
使用Sentinel组件 作为熔断降级