sentinel使用控制台实现

1、添加依赖

<!-- 整合控制台 -->
<dependency >
<groupId >com.alibaba.csp</groupId >
<artifactId >sentinel-transport-simple-http</artifactId >
<version >1.8.0</version >
</dependency >

此项方法,只是单独的添加整合sentinel控制台

SpringCloudAlibaba整合了的,只需要添加:

<!--sentinel 依赖 -->
<dependency >
<groupId >com.alibaba.cloud</groupId >
<artifactId >spring-cloud-starter-alibaba-sentinel</artifactId >
</dependency >

2、下载控制台jar包

Releases · alibaba/Sentinel · GitHub 此处选择使用1.8.0

3、启动

java -jar sentinel-dashboard-1.8.0.jar

用户可以通过如下参数进行配置:

###用于定指控制台的端口,默认为8080

-Dserver.port=8080

###用于指定控制台的登录用户名为 sentinel

-Dsentinel.dashboard.auth.username=sentinel

###用于指定控制台的登录密码为 123456

-Dsentinel.dashboard.auth.password=123456

###用于指定 Spring Boot 服务端 session 的过期时间,如 7200 表示 7200 秒;60m 表示 60 分钟, 默认为 30 分钟

-Dserver.servlet.session.timeout=7200

4、访问地址

默认地址:http://localhost:8080/#/login

默认用户名/密码:sentinel/sentinel

5、项目整合sentinel

初始化登录以后,无任何的菜单数据,因为没有服务整合使用了这个控制台。需要调用了项目相关的接口才会有对应数据。

相关推荐
没有bug.的程序员1 天前
Redis Sentinel:高可用架构的守护者
java·redis·架构·sentinel
波波烤鸭1 天前
Sentinel 原理与源码解析:流控、熔断、降级到热点限流的一体化方案
sentinel
曾经的三心草2 天前
springcloud二-Sentinel
spring·spring cloud·sentinel
T_Ghost5 天前
SpringCloud微服务服务容错机制Sentinel熔断器
spring cloud·微服务·sentinel
你是人间五月天6 天前
sentinel实现控制台与nacos数据双向绑定
windows·sentinel
无名客06 天前
sentinel限流常见的几种算法以及优缺点
算法·sentinel·限流
tsxchen6 天前
centos9安装sentinel
sentinel
寒士obj6 天前
Sentinel服务治理:服务降级、熔断与线程隔离
sentinel
iiYcyk6 天前
Hystrix与Sentinel-熔断限流
hystrix·sentinel·springcloud
勇往直前plus6 天前
Sentinel微服务保护
java·spring boot·微服务·sentinel