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

重新启动项目查看结果:

相关推荐
sevevty-seven11 天前
Sentinel
linux·服务器·sentinel
秋恬意11 天前
什么是Sentinel?以及优缺点
sentinel
liang899911 天前
Sentinel(一):Sentinel 介绍和安装
sentinel
述雾学java12 天前
Sentinel 服务限流机制
sentinel
2401_8532757313 天前
Sentinel实现原理
服务器·网络·sentinel
苏格拉没有底_coder15 天前
【Redis】Sentinel哨兵
redis·sentinel
苏格拉没有底_coder20 天前
基于 Spring Cloud Gateway + Sentinel 实现高并发限流保护机制
sentinel
未来并未来21 天前
Sentinel 流量控制安装与使用
开发语言·python·sentinel
·云扬·21 天前
【PmHub面试篇】集成 Sentinel+OpenFeign实现网关流量控制与服务降级相关面试题解答
面试·职场和发展·sentinel
ℳ₯㎕ddzོꦿ࿐22 天前
Ubuntu 24.04 上安装与 Docker 部署 Sentinel
ubuntu·docker·sentinel