szetszwo commented on a change in pull request #2682:
URL: https://github.com/apache/ozone/pull/2682#discussion_r717292689



##########
File path: 
hadoop-hdds/client/src/main/java/org/apache/hadoop/hdds/scm/storage/BlockDataStreamOutput.java
##########
@@ -184,7 +186,47 @@ private DataStreamOutput setupStream() throws IOException {
         ContainerCommandRequestMessage.toMessage(builder.build(), null);
 
     return Preconditions.checkNotNull(xceiverClient.getDataStreamApi())
-        .stream(message.getContent().asReadOnlyByteBuffer());
+//        .stream(message.getContent().asReadOnlyByteBuffer());
+    
.stream(message.getContent().asReadOnlyByteBuffer(),getRoutingTable(pipeline));
+  }
+
+  public RoutingTable getRoutingTable(Pipeline pipeline) {
+    RaftPeer primary = null;
+    List<RaftPeer> raftPeers = new ArrayList();

Review comment:
       RoutingTable only needs RaftPeerId.  So we can have List<RaftPeerId> 
instead of List<RaftPeer>.

##########
File path: 
hadoop-hdds/client/src/main/java/org/apache/hadoop/hdds/scm/storage/BlockDataStreamOutput.java
##########
@@ -184,7 +186,47 @@ private DataStreamOutput setupStream() throws IOException {
         ContainerCommandRequestMessage.toMessage(builder.build(), null);
 
     return Preconditions.checkNotNull(xceiverClient.getDataStreamApi())
-        .stream(message.getContent().asReadOnlyByteBuffer());
+//        .stream(message.getContent().asReadOnlyByteBuffer());
+    
.stream(message.getContent().asReadOnlyByteBuffer(),getRoutingTable(pipeline));
+  }
+
+  public RoutingTable getRoutingTable(Pipeline pipeline) {
+    RaftPeer primary = null;
+    List<RaftPeer> raftPeers = new ArrayList();

Review comment:
       RoutingTable only needs RaftPeerId.  So we can have `List<RaftPeerId>` 
instead of `List<RaftPeer>`.




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