[
https://issues.apache.org/jira/browse/HDDS-17111?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Siyao Meng reassigned HDDS-17111:
---------------------------------
Assignee: Siyao Meng
> OFS and O3FS getFileBlockLocations ignore start and len
> -------------------------------------------------------
>
> Key: HDDS-17111
> URL: https://issues.apache.org/jira/browse/HDDS-17111
> Project: Apache Ozone
> Issue Type: Bug
> Reporter: Siyao Meng
> Assignee: Siyao Meng
> Priority: Major
>
> {{BasicOzoneFileSystem#getFileBlockLocations(FileStatus, long, long)}} and
> the same method in {{BasicRootedOzoneFileSystem}} return every block of the
> file when given a {{LocatedFileStatus}}, whatever {{start}} and {{len}} are.
> HDFS, and the default {{FileSystem}} implementation, return only the blocks
> that overlap the requested range.
> Callers that ask about part of a file see blocks outside that range. For
> example, HBase computes block locality for a split reference file from the
> half of the HFile it covers, so it overstates locality on Ozone. Split
> planning in MapReduce or Spark can be affected the same way.
> Proposed fix: return only the blocks that overlap {{[start, start + len)}},
> or the block containing {{start}} when {{len}} is 0, matching HDFS. Reject a
> negative {{start}} or {{len}} with {{IllegalArgumentException}}, as
> {{FileSystem}} does.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]