Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

修复移除TokenServer失败的问题 #2591

Merged
merged 1 commit into from
Mar 15, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,8 @@ public static List<ClusterGroupEntity> wrapToClusterGroup(List<ClusterUniversalS
if (mode == ClusterStateManager.CLUSTER_SERVER) {
String serverAddress = getIp(ip);
int port = stateVO.getState().getServer().getPort();
map.computeIfAbsent(serverAddress, v -> new ClusterGroupEntity()
String targetAddress = serverAddress + ":" + port;
map.computeIfAbsent(targetAddress, v -> new ClusterGroupEntity()
.setBelongToApp(true).setMachineId(ip + '@' + stateVO.getCommandPort())
.setIp(ip).setPort(port)
);
Expand All @@ -145,8 +146,8 @@ public static List<ClusterGroupEntity> wrapToClusterGroup(List<ClusterUniversalS
if (StringUtil.isBlank(targetServer) || targetPort == null || targetPort <= 0) {
continue;
}

ClusterGroupEntity group = map.computeIfAbsent(targetServer,
String targetAddress = targetServer + ":" + targetPort;
ClusterGroupEntity group = map.computeIfAbsent(targetAddress,
v -> new ClusterGroupEntity()
.setBelongToApp(true).setMachineId(targetServer)
.setIp(targetServer).setPort(targetPort)
Expand Down