我的技术堆栈包括以下内容
Hystrix仪表板运行良好,因为我能够使用从服务中公开的hystrics.stream流。
但是,每当我试图将涡轮机添加到这个堆栈时,/turbine.stream只在浏览器上重复返回data: {"type":"Ping"},因此Hystrix仪表板显示Unable to connect to Command Metric Stream。
有人能帮我找出我哪里出了问题吗?
这是我的涡轮机的关键配置。TurbineAppliation类只是一个带有@EnableTurbineStream的listing引导应用程序,所以不要在下面列出它。
pom依赖关系:
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>1.5.1.RELEASE</version>
</parent>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-dependencies</artifactId>
<version>Camden.SR5</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-config-client</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-turbine-stream</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-stream-rabbit</artifactId>
</dependency>
</dependencies>bootstrap.yml:(如果不重要的话,请忽略eureka特定的配置,因为我没有亲自对它们进行调优)。配置服务器和eureka设置对于工作正常的所有其他组件都是相同的。
spring:
application:
name: Turbine
cloud:
config:
enabled: true
discovery:
enabled: true
serviceId: ConfigServer
management:
security:
enabled: false
eureka:
instance:
leaseRenewalIntervalInSeconds: 10
# leaseExpirationDurationInSeconds: 2
preferIpAddress: true
ipAddress: 127.0.0.1
client:
serviceUrl:
defaultZone: http://localhost:8761/discovery/eureka/ ---discovery is my eureka context root required for my appapplication.yml
server:
port: 7980
info:
component: Turbine App
turbine:
aggregator:
clusterConfig: MY-SERVICE
appConfig: MY-SERVICE
clusterNameExpression: new String('default')
InstanceMonitor:
eventStream:
skipLineLogic:
enabled: false发布于 2017-04-21 12:53:34
嗨,我正在用Camden.SR6处理同样的问题。
在透平服务pom.xml中添加以下内容之后,我能够在hystrix仪表板中使用透平流:
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-netflix-hystrix-amqp</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-bus-amqp</artifactId>
</dependency>我还添加了:Spring.rabbitmq.Address=兔子-mq:5672到bootstrap.properties文件。

发布于 2017-02-23 16:35:08
使用Spring SR5的新版本,将rabbitMQ队列从springCloudHystrixStream重命名为turbineStreamInput。作为一种解决办法,您可以指定spring-cloud-stream的前一个版本。
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-stream</artifactId>
<version>1.1.0.RELEASE</version>
</dependency>发布于 2017-03-22 13:24:49
在pom中使用涡轮机应用程序
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-netflix</artifactId>
<version>1.3.0.M1</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>https://stackoverflow.com/questions/42379802
复制相似问题