[ https://issues.apache.org/jira/browse/HDFS-8901?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15459053#comment-15459053 ]
Zhe Zhang commented on HDFS-8901: --------------------------------- Thanks Sammi. I think all my previous comments have been addressed. But I see some issues / questions in the changes from v17 to v18/19: # Why do we need to flip? In the previous code, {{arraycopy}} just starts copying from the current position of {{result}}. {code} - System.arraycopy(result.array(), result.position(), buf, offset, - len); + result.flip(); {code} # Could you also explain why {{TestPread}} and {{TestSnapshotFileLength}} failed for v17 and v18 patches respectively? # Need to be removed: {code} + //buffer.position(buffer.position() + bytesToRead); {code} Thanks for adding the ByteBuffer version of readAll. Due to the size of the current patch, can we create a separate JIRA just to add this API? It will go through quickly and we can focus on the main logic on this JIRA. Thanks for the great effort here. > Use ByteBuffer in striping positional read > ------------------------------------------ > > Key: HDFS-8901 > URL: https://issues.apache.org/jira/browse/HDFS-8901 > Project: Hadoop HDFS > Issue Type: Sub-task > Reporter: Kai Zheng > Assignee: SammiChen > Attachments: HDFS-8901-v10.patch, HDFS-8901-v17.patch, > HDFS-8901-v18.patch, HDFS-8901-v19.patch, HDFS-8901-v2.patch, > HDFS-8901-v3.patch, HDFS-8901-v4.patch, HDFS-8901-v5.patch, > HDFS-8901-v6.patch, HDFS-8901-v7.patch, HDFS-8901-v8.patch, > HDFS-8901-v9.patch, HDFS-8901.v11.patch, HDFS-8901.v12.patch, > HDFS-8901.v13.patch, HDFS-8901.v14.patch, HDFS-8901.v15.patch, > HDFS-8901.v16.patch, initial-poc.patch > > > Native erasure coder prefers to direct ByteBuffer for performance > consideration. To prepare for it, this change uses ByteBuffer through the > codes in implementing striping position read. It will also fix avoiding > unnecessary data copying between striping read chunk buffers and decode input > buffers. -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: hdfs-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: hdfs-issues-h...@hadoop.apache.org