bdeggleston commented on code in PR #4106:
URL: https://github.com/apache/cassandra/pull/4106#discussion_r2069091545


##########
src/java/org/apache/cassandra/replication/Shard.java:
##########
@@ -94,6 +109,42 @@ void addSummaryForRange(AbstractBounds<PartitionPosition> 
range, boolean include
         });
     }
 
+    List<InetAddressAndPort> remoteReplicas()
+    {
+        List<InetAddressAndPort> replicas = new 
ArrayList<>(participants.size() - 1);
+        for (int i = 0, size = participants.size(); i < size; ++i)
+        {
+            int hostId = participants.get(i);
+            if (hostId != localHostId)
+                replicas.add(ClusterMetadata.current().directory.endpoint(new 
NodeId(hostId)));
+        }
+        return replicas;
+    }
+
+    /**
+     * Collects replicated offsets for the logs owned by this coordinator on 
this shard.
+     */
+    ShardReplicatedOffsets collectReplicatedOffsets()
+    {
+        Long2ObjectHashMap<LogReplicatedOffsets> offsets = new 
Long2ObjectHashMap<>();
+        for (CoordinatorLogPrimary log : primaryLogs())

Review Comment:
   It seems like increasing the broadcast payload size by RF would _probably_ 
be negligible. It wouldn’t be optimally small of course, but it feels like 
getting to a payload size that’s problematic would be difficult. Even then, 
there are encoding tricks you could use that would be less work than adding a 
new replica state.
   
   Then regarding mutation transmission, I was thinking that replicas would 
fetch their own missing mutations. I’m not sure what’s to be gained by staging 
mutations on a reconciliation coordinator before transmitting them to the nodes 
that need them. I guess you could more easily balance load between the replicas 
you’re fetching mutations from.



-- 
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: pr-unsubscr...@cassandra.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscr...@cassandra.apache.org
For additional commands, e-mail: pr-h...@cassandra.apache.org

Reply via email to