[
https://issues.apache.org/jira/browse/HADOOP-15423?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16522834#comment-16522834
]
Hudson commented on HADOOP-15423:
---------------------------------
SUCCESS: Integrated in Jenkins build Hadoop-trunk-Commit #14478 (See
[https://builds.apache.org/job/Hadoop-trunk-Commit/14478/])
HADOOP-15423. Merge fileCache and dirCache into ine single cache in
(mackrorysd: rev c687a6617d73293019d8d91ac48bbfd2ccca3b40)
* (edit)
hadoop-tools/hadoop-aws/src/test/java/org/apache/hadoop/fs/s3a/s3guard/MetadataStoreTestBase.java
* (add)
hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/s3guard/LocalMetadataEntry.java
* (edit)
hadoop-tools/hadoop-aws/src/test/java/org/apache/hadoop/fs/s3a/s3guard/TestLocalMetadataStore.java
* (edit)
hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/s3guard/LocalMetadataStore.java
> Merge fileCache and dirCache into one single cache in LocalMetadataStore
> ------------------------------------------------------------------------
>
> Key: HADOOP-15423
> URL: https://issues.apache.org/jira/browse/HADOOP-15423
> Project: Hadoop Common
> Issue Type: Sub-task
> Reporter: Gabor Bota
> Assignee: Gabor Bota
> Priority: Minor
> Fix For: 3.2.0
>
> Attachments: HADOOP-15423.001.patch
>
>
> Right now the s3guard.LocalMetadataStore uses two HashMap in the
> implementation - one for the file and one for the dir hash.
> {code:java}
> /** Contains directories and files. */
> private Cache<Path, PathMetadata> fileCache;
> /** Contains directory listings. */
> private Cache<Path, DirListingMetadata> dirCache;
> {code}
> It would be nice to have only one hash instead of these two for storing the
> values. An idea for the implementation would be to have a class with nullable
> fields:
> {code:java}
> static class LocalMetaEntry {
> @Nullable
> public PathMetadata pathMetadata;
> @Nullable
> public DirListingMetadata dirListingMetadata;
> }
> {code}
> or a Pair (tuple):
> {code:java}
> Pair<PathMetadata, DirListingMetadata> metaEntry;
> {code}
> And only one hash/cache for these elements.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]