【SpringBoot學習筆記】turbine界面不顯示監控信息——unable to connect to command metric stream


[[錯誤現象:]]

界面沒有監控信息,只有一行字:unable to connect to command metric stream ,如下圖:

 

 

[[可能原因]]:

 1)stream地址輸入錯誤,一定要輸入:ip:port/turbine.stream,可能會誤寫成:ip:port/turbine.stream,這樣一來,反復檢查都不容易檢查出問題,因為本身后者在使用hystrix時是沒錯的,但用turbine時就不對了;

2)缺少pom依賴或注解

  依賴項如下:

<dependency>
    <groupId>org.springframework.cloud</groupId>
    <artifactId>spring-cloud-starter-turbine</artifactId>
</dependency>
<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-actuator</artifactId>
</dependency>

 

  注解如下:

@SpringBootApplication @EnableHystrixDashboard @EnableTurbine

public class EurekaMonitorClientApplication {
    public static void main(String[] args) {
SpringApplication.run(EurekaMonitorClientApplication.class, args);
}
}
 

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM