zuston commented on code in PR #1652:
URL: 
https://github.com/apache/incubator-uniffle/pull/1652#discussion_r1577494116


##########
client-spark/common/src/main/java/org/apache/spark/shuffle/ShuffleHandleInfo.java:
##########
@@ -247,4 +330,25 @@ public static ShuffleHandleInfo 
fromProto(RssProtos.ShuffleHandleInfo handleProt
     handle.remoteStorage = remoteStorageInfo;
     return handle;
   }
+
+  public Set<String> listFaultyServers() {
+    return faultyServerToReplacements.keySet();
+  }
+
+  public void checkPartitionReassignServerNum(
+      Set<Integer> partitionIds, int legalReassignServerNum) {
+    for (int partitionId : partitionIds) {
+      Map<Integer, List<ShuffleServerInfo>> replicas =
+          partitionReplicaAssignedServers.get(partitionId);
+      for (List<ShuffleServerInfo> servers : replicas.values()) {
+        if (servers.size() - 1 > legalReassignServerNum) {

Review Comment:
   Yes. The index 0 is the initial assignment server.



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