[
https://issues.apache.org/jira/browse/HADOOP-14020?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15874037#comment-15874037
]
Aaron Fabbri commented on HADOOP-14020:
---------------------------------------
Shoot, I just noticed a bug this patch introduced.. The offending portion is
here:
{noformat}
- if (dirMeta.get(s.getPath()) == null) {
- dirMeta.put(s);
- }
+ changed = changed || dirMeta.put(s);
+ }
+
{noformat}
hint: Logical OR is a short-circuit operator.
Sorry I didn't catch this in original review.. I'll file a JIRA now. Easy fix,
but should probably come with a unit test for dirListingUnion().
> Optimize dirListingUnion
> ------------------------
>
> Key: HADOOP-14020
> URL: https://issues.apache.org/jira/browse/HADOOP-14020
> Project: Hadoop Common
> Issue Type: Sub-task
> Components: fs/s3
> Reporter: Sean Mackrory
> Assignee: Sean Mackrory
> Fix For: HADOOP-13345
>
> Attachments: HADOOP-14020-HADOOP-13345.001.patch,
> HADOOP-14020-HADOOP-13345.002.patch, HADOOP-14020-HADOOP-13345.003.patch,
> HADOOP-14020-HADOOP-13345.004.patch
>
>
> There's a TODO in dirListingUnion:
> {quote}// TODO optimize for when allowAuthoritative = false{quote}
> There will be cases when we can intelligently avoid a round trip: if S3A
> results are a subset or the metadatastore results (including them being equal
> or empty) then writing back will do nothing (although perhaps that should set
> the authoritative flag if it isn't set already).
> There may also be cases where users want to just skip that altogether. It's
> wasted work if authoritative mode is disabled, so perhaps we want to trigger
> a skip if that's false, or perhaps it should be a separate property. First
> one makes for simpler config, second is more flexible...
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]