[
https://issues.apache.org/jira/browse/HDFS-8203?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14531770#comment-14531770
]
Jing Zhao commented on HDFS-8203:
---------------------------------
Thanks Yi! The patch looks pretty good to me. Some minor comments:
# In the seek function, do we also want to do a special handling for the
scenario that the targetPos is before pos but still locates inside of the
curStripeRange?
# Nitty-pick: we can rename the local variable "pos" to something else in order
to avoid the confusion with {{DFSInputStream#pos}}.
{code}
for (int i = startCell; i < numCell; i++) {
int pos = i == startCell ? bufOffset : cellSize * i;
curStripeBuf.position(pos);
{code}
# Maybe we can also add some simple tests to cover cases seeking to
cell/stripe/block boundaries?
> Erasure Coding: Seek and other Ops in DFSStripedInputStream.
> ------------------------------------------------------------
>
> Key: HDFS-8203
> URL: https://issues.apache.org/jira/browse/HDFS-8203
> Project: Hadoop HDFS
> Issue Type: Sub-task
> Reporter: Yi Liu
> Assignee: Yi Liu
> Attachments: HDFS-8203.001.patch, HDFS-8203.002.patch
>
>
> In HDFS-7782 and HDFS-8033, we handle pread and stateful read for
> {{DFSStripedInputStream}}, we also need handle other operations, such as
> {{seek}}, zerocopy read ...
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)