You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by "Ted Yu (JIRA)" <ji...@apache.org> on 2018/10/24 03:12:00 UTC

[jira] [Created] (HADOOP-15876) Use keySet().removeAll() to remove multiple keys from Map in AzureBlobFileSystemStore

Ted Yu created HADOOP-15876:
-------------------------------

             Summary: Use keySet().removeAll() to remove multiple keys from Map in AzureBlobFileSystemStore
                 Key: HADOOP-15876
                 URL: https://issues.apache.org/jira/browse/HADOOP-15876
             Project: Hadoop Common
          Issue Type: Improvement
            Reporter: Ted Yu


Looking at hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/AzureBlobFileSystemStore.java , {{removeDefaultAcl}} in particular:
{code}
    for (Map.Entry<String, String> defaultAclEntry : defaultAclEntries.entrySet()) {
      aclEntries.remove(defaultAclEntry.getKey());
    }
{code}
The above operation can be written this way:
{code}
    aclEntries.keySet().removeAll(defaultAclEntries.keySet());
{code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-issues-help@hadoop.apache.org