(1)方法一:version 2.0.0.
management.endpoints.web.exposure.include=hystrix.stream" adding in bootstrap.properties;
and the url was change to "http://host:port/actuator/hystrix.stream", it is ok.
also,"management.endpoints.web.base-path=/ " can make "http://host:port/hystrix.stream" work.
(2)方法二:version 2.0.0.
@configuration
public class HystrixServletDefinitions {
@Bean(name = "hystrixRegistrationBean")
public ServletRegistrationBean servletRegistrationBean() {
ServletRegistrationBean registration = new ServletRegistrationBean(
new HystrixMetricsStreamServlet(), "/hystrix.stream");
registration.setName("hystrixServlet");
registration.setLoadOnStartup(1);
return registration;
}
}
解决链接:https://github.com/Netflix/Hystrix/issues/1566
解决链接:https://blog.youkuaiyun.com/qq_22772259/article/details/79812026
本文介绍两种在Spring Boot 2.0.0版本中配置Hystrix监控流的方法。第一种是在bootstrap.properties文件中设置暴露Hystrix.stream端点;第二种是通过自定义配置类实现。这些方法使开发人员能够有效监控服务熔断状态。
4719

被折叠的 条评论
为什么被折叠?



