Sentinel实时监控不展示问题

问题

官方插件

Endpoint 支持,可以实时统计出SpringBoot的健康状况和请求的调用信息

在使用 Endpoint 特性之前需要在 Maven 中添加 **spring-boot-starter-actuator**依赖,并在配置中允许 Endpoints 的访问。

  • Spring Boot 1.x 中添加配置 management.security.enabled=false。暴露的 endpoint 路径为 /sentinel

  • Spring Boot 2.x 中添加配置 management.endpoints.web.exposure.include=*。暴露的 endpoint 路径为 /actuator/sentinel

Sentinel Endpoint 里暴露的信息非常有用。包括当前应用的所有规则信息、日志目录、当前实例的 IP,Sentinel Dashboard 地址,Block Page,应用与 Sentinel Dashboard 的心跳频率等等信息。

解决问题

1.项目添加依赖

复制代码
<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-actuator</artifactId>
</dependency>

2.增加配置:

根据自己的SpringBoot版本添加配置:

  • Spring Boot 1.x 中添加配置 management.security.enabled=false。暴露的 endpoint 路径为 /sentinel

  • Spring Boot 2.x 中添加配置 management.endpoints.web.exposure.include=*。暴露的 endpoint 路径为 /actuator/sentinel

重新启动项目查看结果:

相关推荐
Volunteer Technology1 天前
sentinel基本操作
spring cloud·sentinel
程序员泠零澪回家种桔子1 天前
Sentinel核心能力解析:限流与集群方案
后端·架构·sentinel
团子的二进制世界3 天前
Sentinel-服务保护(限流、熔断降级)
java·开发语言·sentinel·异常处理
团子的二进制世界3 天前
Sentinel 的核心规则体系
sentinel·熔断·热点·流控
小马爱打代码4 天前
Sentinel:入门到实战详细教程
sentinel
小马爱打代码5 天前
Spring Boot:Sentinel 企业级熔断、降级与限流实战
spring boot·后端·sentinel
没有bug.的程序员5 天前
Spring Cloud Sentinel:熔断降级规则配置与分布式流量防线实战终极指南
java·分布式·后端·spring cloud·sentinel·熔断规则·分布式流量防线
u0104058368 天前
Java中的服务熔断机制:Hystrix与Sentinel的比较
java·hystrix·sentinel
what丶k8 天前
微服务稳定性守护者:Sentinel 全面使用指南(从入门到企业级落地)
微服务·架构·sentinel
鸽鸽程序猿8 天前
【JavaEE】【SpringCloud】 熔断和限流 Alibaba Sentinel
spring cloud·java-ee·sentinel