sodonnel commented on code in PR #3345:
URL: https://github.com/apache/ozone/pull/3345#discussion_r861678220


##########
hadoop-hdds/interface-server/src/main/proto/ScmServerDatanodeHeartbeatProtocol.proto:
##########
@@ -407,6 +409,20 @@ message ReplicateContainerCommandProto {
   required int64 cmdId = 3;
 }
 
+/**
+* This command asks the datanode to reconstruct the missing EC containers by
+* using remaining containers from sources.
+*/
+message ReconstructECContainersCommandProto {
+  required int64 containerID = 1;
+  repeated DatanodeDetailsProto sources = 2;

Review Comment:
   I think it could be worth creating a simple type to pass datanodeDetails and 
replicaIndex together, eg:
   
   ```
   message DatanodeDetailsAndReplicaIndexProto {
       required DatanodeDetailsProto datanodeDetails = 1;
       required int32 replicaIndex = 2;
   }
   ```
   
   Then have `repeated DatanodeDetailsAndReplicaIndexProto sources = 2`.
   
   That way, we always send the two as a pair, and its less likely a mistake 
can be made serializing or de-serializing with order or one missing etc.



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