本文介绍了Hystrix.stream 和 management.context的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

设置

management.context-path = /admin

并使用

@EnableCircuitBreaker

使 Hystrix 端点/admin/hystrix.stream

makes Hystrix endpoint /admin/hystrix.stream

当使用 Turbine 来聚合指标时,这会成为一个问题

This becomes an issue when using Turbine to aggregate metrics as its looking for

 instanceserver:port/hystrix.stream

通过 Eureka 发现实例时

when discovering instances via Eureka

有什么建议吗?

推荐答案

涡轮机的完整配置:

server.port=8082
spring.application.name=turbine
management.endpoint.health.enabled=true
management.endpoints.jmx.exposure.include=*
management.endpoints.web.exposure.include=*
management.endpoints.web.base-path=/actuator
management.endpoints.web.cors.allowed-origins=true
management.endpoint.health.show-details=always
eureka.client.serviceUrl.defaultZone=${EUREKA_URI:http://localhost:8761/eureka}
eureka.instance.lease-expiration-duration-in-seconds=5
eureka.instance.lease-renewal-interval-in-seconds=5
turbine.aggregator.cluster-config=default
turbine.app-config=google
turbine.cluster-name-expression= new String("default")
turbine.combine-host-port=true
turbine.instanceUrlSuffix.default: actuator/hystrix.stream

这篇关于Hystrix.stream 和 management.context的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-15 10:37