Skip to content

Commit

Permalink
[improve] update the node print info
Browse files Browse the repository at this point in the history
  • Loading branch information
liunaijie committed Dec 10, 2024
1 parent a24af69 commit 8d7115b
Showing 1 changed file with 7 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -286,21 +286,20 @@ public String toString() {
sb.append(":");
sb.append(address.getPort());
sb.append(" - ").append(uuid);
if (localMember()) {
sb.append(" this");
}

// update for seatunnel, add worker and master info
if (isLiteMember()) {
sb.append(" worker");
sb.append(" [worker node]");
} else {
sb.append(" [master node]");
}

if (instance != null
&& instance.node.getClusterService().getMasterAddress() != null
&& instance.node.getClusterService().getMasterAddress().equals(address)) {
sb.append(" master");
sb.append(" [active master]");
}
if (localMember()) {
sb.append(" this");
}

// update for seatunnel, add worker and master info end
return sb.toString();
}
Expand Down

0 comments on commit 8d7115b

Please sign in to comment.