smiklosovic commented on code in PR #4394:
URL: https://github.com/apache/cassandra/pull/4394#discussion_r2377828769
##########
src/java/org/apache/cassandra/gms/Gossiper.java:
##########
@@ -2070,6 +2071,74 @@ public void setLooseEmptyEnabled(boolean enabled)
EndpointState.LOOSE_DEF_OF_EMPTY_ENABLED = enabled;
}
+ @Override
+ public Map<String, Map<String, Object>> echoAllNodesWithTiming()
+ {
+ Map<String, Map<String, Object>> results = new HashMap<>();
+ Set<InetAddressAndPort> liveMembers = getLiveMembers();
+
+ for (InetAddressAndPort endpoint : liveMembers)
+ {
+ Map<String, Object> nodeResult = new HashMap<>();
+
+ // Skip self - no need to echo to ourselves
+ if (endpoint.equals(getBroadcastAddressAndPort()))
+ {
+ nodeResult.put("status", "SELF");
+ nodeResult.put("responseTimeMs", 0);
+ nodeResult.put("timestamp", System.currentTimeMillis());
Review Comment:
Please use `Clock.Global.nanoTime() / Clock.Global.currentTimeMillis()`
instead.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]