Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
discovery
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
谢捷峰
discovery
Commits
3635799e
Commit
3635799e
authored
Jul 05, 2018
by
Nepxion
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改介绍
parent
2c211bb9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
README.md
+4
-4
No files found.
README.md
View file @
3635799e
...
...
@@ -348,11 +348,11 @@ http://IP:[server.port]/route/{routeServiceId}/{routeHost}/{routePort}
routeServiceIds按调用服务名的前后次序排列,起始节点的服务名不能加上去。如果多个用“;”分隔,不允许出现空格
```
java
Java:
@RequestMapping
(
path
=
"/route
All
"
,
method
=
RequestMethod
.
POST
)
public
RouterEntity
route
All
(
@RequestBody
String
routeServiceIds
)
@RequestMapping
(
path
=
"/route
s
"
,
method
=
RequestMethod
.
POST
)
public
RouterEntity
route
s
(
@RequestBody
String
routeServiceIds
)
Url:
http:
//IP:[server.port]/route
All
http:
//IP:[server.port]/route
s
```
## 扩展和自定义更多规则或者监听
...
...
@@ -435,7 +435,7 @@ spring-cloud-consul的2.0.0.RELEASE(目前最新的稳定版)支持consul-ap
-
通过Postman或者浏览器,执行GET
[
http://localhost:1200/instances/discovery-springcloud-example-c
](
http://localhost:1200/instances/discovery-springcloud-example-c
)
,查看当前B1服务可访问C服务的列表
-
通过Postman或者浏览器,执行GET
[
http://localhost:1201/instances/discovery-springcloud-example-c
](
http://localhost:1201/instances/discovery-springcloud-example-c
)
,查看当前B2服务可访问C服务的列表
-
灰度版本切换
-
通过Postman或者浏览器,执行POST
[
http://localhost:1100/route
All
](
http://localhost:1100/routeAll
)
,填入discovery-springcloud-example-b;discovery-springcloud-example-c,查看路由路径,如图3,可以看到符合图2的实线调用路径
-
通过Postman或者浏览器,执行POST
[
http://localhost:1100/route
s
](
http://localhost:1100/routes
)
,填入discovery-springcloud-example-b;discovery-springcloud-example-c,查看路由路径,如图3,可以看到符合图2的实线调用路径
-
通过Postman或者浏览器,执行POST
[
http://localhost:5100/version/send
](
http://localhost:5100/version/send
)
,填入1.1,动态把服务A的版本从1.0切换到1.1
-
再执行3.1步骤,如图4,可以看到符合图2的虚线调用路径,符合逻辑,灰度版本切换成功
-
灰度版本控制
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment