dcapwell commented on code in PR #3656:
URL: https://github.com/apache/cassandra/pull/3656#discussion_r1830067882


##########
test/harry/main/org/apache/cassandra/harry/sut/TokenPlacementModel.java:
##########
@@ -237,6 +237,25 @@ public static List<Node> peerStateToNodes(Object[][] 
resultset)
         return nodes;
     }
 
+    private static <T> T get(Object[] row, int idx, String name)
+    {
+        T t = (T) row[idx];
+        if (t == null || ((t instanceof Collection<?>) && ((Collection<?>) 
t).isEmpty()))
+            throw new IncompletePeersStateException(name);
+        return t;
+    }
+
+    /**
+     * When the node sees the new epoch, the update of the peers table is 
async, so checking the table may yield partial results, so need some way to 
detect this to enable retries.

Review Comment:
   well, I think it depends on if we wish to just say "harry only works with 
the current branch", if so we have a better peers table which is a vtable 
showing the data in `ClusterMetadata`.
   
   > and instead construct real view of ring every time.
   
   what do you mean here?  would we need to tell harry that we started a token 
move or would it still query?



-- 
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]

Reply via email to