You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by GitBox <gi...@apache.org> on 2020/02/01 22:44:11 UTC

[GitHub] [hadoop] goiri commented on a change in pull request #1825: HDFS-15151 Use TransmitFile for file to socket data transfer

goiri commented on a change in pull request #1825: HDFS-15151 Use TransmitFile for file to socket data transfer
URL: https://github.com/apache/hadoop/pull/1825#discussion_r373806607
 
 

 ##########
 File path: hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/net/SocketOutputStream.java
 ##########
 @@ -219,7 +226,9 @@ public void transferToFully(FileChannel fileCh, long position, int count,
       waitForWritable();
       long wait = System.nanoTime();
 
-      int nTransfered = (int) fileCh.transferTo(position, count, getChannel());
+      int nTransfered = (int) NativeIO.transferTo(fileCh,
+          fileInputStream.getFD(), getChannel(),
+          ((SelChImpl) getChannel()).getFD(), position, count);
 
 Review comment:
   I cannot find an easy way out but can you see if we can remove:
   SelChImpl is internal proprietary API and may be removed in a future release

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-issues-help@hadoop.apache.org