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
d39f55cc
Commit
d39f55cc
authored
Jul 19, 2018
by
Nepxion
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加图形化灰度发布功能
parent
f16621b0
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
26 additions
and
2 deletions
+26
-2
discovery-console-desktop/src/main/java/com/nepxion/discovery/console/desktop/workspace/RouterTopology.java
+23
-1
discovery-console-desktop/src/main/java/com/nepxion/discovery/console/desktop/workspace/ServiceTopology.java
+1
-1
discovery-console-desktop/src/main/resources/com/nepxion/discovery/console/desktop/locale/Locale.properties
+1
-0
discovery-console-desktop/src/main/resources/com/nepxion/discovery/console/desktop/locale/Locale_zh_CN.properties
+1
-0
No files found.
discovery-console-desktop/src/main/java/com/nepxion/discovery/console/desktop/workspace/RouterTopology.java
View file @
d39f55cc
...
...
@@ -90,6 +90,7 @@ public class RouterTopology extends AbstractTopology {
toolBar
.
add
(
Box
.
createHorizontalStrut
(
5
));
toolBar
.
add
(
comboBox
);
toolBar
.
add
(
new
JClassicButton
(
createAddServiceAction
()));
toolBar
.
add
(
new
JClassicButton
(
createDeleteServiceAction
()));
toolBar
.
add
(
textField
);
toolBar
.
add
(
new
JClassicButton
(
createExecuteRouterAction
()));
toolBar
.
add
(
new
JClassicButton
(
createClearRouterAction
()));
...
...
@@ -144,6 +145,8 @@ public class RouterTopology extends AbstractTopology {
graph
.
getLayoutInternalFrame
().
setLocation
(
3000
,
3000
);
// graph.adjustComponentPosition(graph.getLayoutInternalFrame());
RouterTopology
.
this
.
setPreferredSize
(
new
Dimension
(
RouterTopology
.
this
.
getPreferredSize
().
width
-
82
,
900
));
removeHierarchyListener
(
this
);
}
});
...
...
@@ -225,7 +228,26 @@ public class RouterTopology extends AbstractTopology {
}
private
JSecurityAction
createAddServiceAction
()
{
JSecurityAction
action
=
new
JSecurityAction
(
ConsoleIconFactory
.
getSwingIcon
(
"direction_east.png"
),
ConsoleLocale
.
getString
(
"add_service"
))
{
JSecurityAction
action
=
new
JSecurityAction
(
ConsoleIconFactory
.
getSwingIcon
(
"add.png"
),
ConsoleLocale
.
getString
(
"add_service"
))
{
private
static
final
long
serialVersionUID
=
1L
;
public
void
execute
(
ActionEvent
e
)
{
String
routerPath
=
textField
.
getText
();
String
serviceId
=
comboBox
.
getSelectedItem
().
toString
();
if
(
StringUtils
.
isNotEmpty
(
routerPath
))
{
routerPath
=
routerPath
+
";"
+
serviceId
;
}
else
{
routerPath
=
serviceId
;
}
textField
.
setText
(
routerPath
);
}
};
return
action
;
}
private
JSecurityAction
createDeleteServiceAction
()
{
JSecurityAction
action
=
new
JSecurityAction
(
ConsoleIconFactory
.
getSwingIcon
(
"delete.png"
),
ConsoleLocale
.
getString
(
"delete_service"
))
{
private
static
final
long
serialVersionUID
=
1L
;
public
void
execute
(
ActionEvent
e
)
{
...
...
discovery-console-desktop/src/main/java/com/nepxion/discovery/console/desktop/workspace/ServiceTopology.java
View file @
d39f55cc
...
...
@@ -505,7 +505,7 @@ public class ServiceTopology extends AbstractTopology {
if
(
routerTopology
==
null
)
{
routerTopology
=
new
RouterTopology
();
routerTopology
.
setPreferredSize
(
new
Dimension
(
1280
,
900
));
//
routerTopology.setPreferredSize(new Dimension(1280, 900));
}
Object
[]
filterServices
=
filterServices
(
node
);
...
...
discovery-console-desktop/src/main/resources/com/nepxion/discovery/console/desktop/locale/Locale.properties
View file @
d39f55cc
...
...
@@ -12,6 +12,7 @@ refresh_gray_state=刷新灰度状态
service_list
=
服务列表
add_service
=
添加服务
delete_service
=
添加服务
execute_router
=
执行路由
clear_router
=
清除路由
router_path_invalid
=
路由路径不能为空
...
...
discovery-console-desktop/src/main/resources/com/nepxion/discovery/console/desktop/locale/Locale_zh_CN.properties
View file @
d39f55cc
...
...
@@ -12,6 +12,7 @@ refresh_gray_state=\u5237\u65b0\u7070\u5ea6\u72b6\u6001
service_list
=
\u
670d
\u
52a1
\u5217\u8868
add_service
=
\u
6dfb
\u
52a0
\u
670d
\u
52a1
delete_service
=
\u
6dfb
\u
52a0
\u
670d
\u
52a1
execute_router
=
\u6267\u
884c
\u
8def
\u7531
clear_router
=
\u
6e05
\u9664\u
8def
\u7531
router_path_invalid
=
\u
8def
\u7531\u
8def
\u
5f84
\u
4e0d
\u
80fd
\u
4e3a
\u
7a7a
...
...
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