006hystrix.stream信息聚合Turbine
Posted TBBS
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了006hystrix.stream信息聚合Turbine相关的知识,希望对你有一定的参考价值。
1、POM配置
和普通Spring Boot工程相比,仅仅添加了Turbine和Spring Boot Starter Actuator依赖
<dependencies>
<!--添加Turbine依赖--> <dependency> <groupId>org.springframework.cloud</groupId> <artifactId>spring-cloud-starter-turbine</artifactId> </dependency>
<!--添加Turbine依赖--> <dependency> <groupId>org.springframework.cloud</groupId> <artifactId>spring-cloud-netflix-turbine</artifactId> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-actuator</artifactId> </dependency> </dependencies> <dependencyManagement> <dependencies> <dependency> <groupId>org.springframework.cloud</groupId> <artifactId>spring-cloud-dependencies</artifactId> <version>Dalston.SR2</version> <type>pom</type> <scope>import</scope> </dependency> </dependencies> </dependencyManagement>
02、使能Eureka Server
@SpringBootApplication
@EnableTurbine//使能Turbine
public class Application {
public static void main(String[] args) {
SpringApplication.run(Application.class, args);
}
}
03、src/main/resources工程配置文件application.yml内容如下
spring:
application.name: turbine-service-monitoring
server:
port: 4001
#security.basic.enabled: false
turbine:
aggregator:
clusterConfig: default # 指定聚合哪些集群,多个使用","分割,默认为default。
appConfig: ribbon-hello-service-consumer, feign-hello-service-consumer ### 配置Eureka中的serviceId列表,表明监控哪些服务
clusterNameExpression: new String("default")
eureka:
client:
serviceUrl:
defaultZone: http://discovery:1000/eureka/
以上是关于006hystrix.stream信息聚合Turbine的主要内容,如果未能解决你的问题,请参考以下文章
无法在 Spring Cloud 中获取 /hystrix.stream
hystrix.stream、management.port 和 Spring Cloud Turbine
Spring cloud Camden.SR1 hystrix.stream 挂起
spring cloud(Greenwich.M2) hystrix dashboard 报/actuator/hystrix.stream 404 Not Found的问题