问题
Spring Boot Admin 1 has an integrated Hystrix Dashboard. After upgrading my stack from Spring Boot 1.x to 2.x; this dashboard seems to have disappeared. How can I re-enable it?
回答1:
The official support for Hystrix Dashboard was dropped in Spring Boot Admin 2.x. There now exists an unofficial plugin for Spring Boot Admin 2.x that brings Hystrix Dashboard back to live.
Add the following Maven dependency to your Spring Boot Admin application's pom.xml
, rebuild and deploy.
<dependency>
<groupId>nl.devillers</groupId>
<artifactId>spring-boot-admin-hystrix-dashboard</artifactId>
<version>1.0.1</version>
</dependency>
The instance view in Spring Boot Admin should now show a "Hystrix" tab with the dashboard, like in the screenshot below. If it doesn't show up, make sure your Spring Boot application (the client) is properly configured:
- The
management.endpoints.web.exposure.include
property includes thehystrix.stream
endpoint (or*
for all endpoints) - The application is annotated with the
org.springframework.cloud.netflix.hystrix.EnableHystrix
annotation from thespring-cloud-starter-netflix-hystrix
package
来源:https://stackoverflow.com/questions/58929693/how-to-get-hystrix-dashboard-working-again-in-spring-boot-admin-2-x