dcapwell commented on code in PR #108:
URL: https://github.com/apache/cassandra-accord/pull/108#discussion_r1702230147


##########
accord-core/src/main/java/accord/topology/Topologies.java:
##########
@@ -64,6 +64,11 @@ default boolean isEmpty()
 
     Set<Node.Id> nodes();
 
+    default Set<Node.Id> nonStaleNodes()
+    {
+        throw new UnsupportedOperationException();

Review Comment:
   why?  this can't be accepted for any impl so by not defining it makes it 
clear to know where to add; no?



##########
accord-core/src/main/java/accord/topology/Topologies.java:
##########
@@ -64,6 +64,11 @@ default boolean isEmpty()
 
     Set<Node.Id> nodes();
 
+    default Set<Node.Id> nonStaleNodes()
+    {
+        throw new UnsupportedOperationException();

Review Comment:
   if you want to block in `Multi` then we should be more explicit about 
that... and the callers of this should enforce we don't have multi (which is 
allowed for RX transactions)



##########
accord-core/src/main/java/accord/topology/Topology.java:
##########
@@ -60,8 +61,10 @@ public class Topology
 {
     public static final long EMPTY_EPOCH = 0;
     private static final int[] EMPTY_SUBSET = new int[0];
-    public static final Topology EMPTY = new Topology(null, EMPTY_EPOCH, new 
Shard[0], Ranges.EMPTY, Collections.emptyMap(), Ranges.EMPTY, EMPTY_SUBSET);
+    public static final Topology EMPTY = new Topology(null, EMPTY_EPOCH, 
Collections.emptySet(), new Shard[0], Ranges.EMPTY, Collections.emptyMap(), 
Ranges.EMPTY, EMPTY_SUBSET);
+
     final long epoch;
+    final Set<Id> staleIds;

Review Comment:
   to keep the pattern shouldn't this be in `Shard`?  In C* we cache things, so 
we won't have a ton of duplicates. 



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