1
0
mirror of https://gitee.com/mirrors/Spring-Cloud-Alibaba.git synced 2021-06-26 13:25:11 +08:00

sentinel示例,添加sentinel配置,实现sentinel示例功能,以及运行说明。

This commit is contained in:
yangying 2020-12-15 15:18:06 +08:00
parent bd3d1681cb
commit 1ecf526b5c
2 changed files with 7 additions and 0 deletions

View File

@ -114,6 +114,8 @@ public class EchoController {
- 启动nacos 注册中心
- 启动sentinel
- 启动服务提供方:
1. IDE直接启动找到主类 `ProviderApplication`,执行 main 方法启动应用。
@ -123,3 +125,5 @@ public class EchoController {
1. IDE直接启动找到主类 `ConsumerApplication`,执行 main 方法启动应用。
2. 打包编译后启动:首先执行 `mvn clean package` 将工程编译打包,然后执行 `java -jar sentinel-feign-consumer-example.jar`启动应用。
- 启动之后Sentinel Dashboard可能看不见service-consumer服务的详细信息多请求几次接口即可。

View File

@ -8,6 +8,9 @@ spring:
nacos:
discovery:
server-addr: 127.0.0.1:8848
sentinel:
transport:
dashboard: 127.0.0.1:8081
feign:
sentinel: