hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From omal...@apache.org
Subject svn commit: r1077353 - /hadoop/common/branches/branch-0.20-security-patches/src/core/org/apache/hadoop/security/ShellBasedUnixGroupsMapping.java
Date Fri, 04 Mar 2011 04:06:26 GMT
Author: omalley
Date: Fri Mar  4 04:06:26 2011
New Revision: 1077353

URL: http://svn.apache.org/viewvc?rev=1077353&view=rev
Log:
commit 21feb1e46d60c45f8f60cf37933ece4d40d4a56d
Author: Devaraj Das <ddas@yahoo-inc.com>
Date:   Sat Mar 20 17:06:36 2010 -0700

    HADOOP:6652 from https://issues.apache.org/jira/secure/attachment/12439372/groups.patch
    
    +++ b/YAHOO-CHANGES.txt
    +    HADOOP-6652. ShellBasedUnixGroupsMapping shouldn't have a cache.
    +    (ddas)
    +

Modified:
    hadoop/common/branches/branch-0.20-security-patches/src/core/org/apache/hadoop/security/ShellBasedUnixGroupsMapping.java

Modified: hadoop/common/branches/branch-0.20-security-patches/src/core/org/apache/hadoop/security/ShellBasedUnixGroupsMapping.java
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-0.20-security-patches/src/core/org/apache/hadoop/security/ShellBasedUnixGroupsMapping.java?rev=1077353&r1=1077352&r2=1077353&view=diff
==============================================================================
--- hadoop/common/branches/branch-0.20-security-patches/src/core/org/apache/hadoop/security/ShellBasedUnixGroupsMapping.java
(original)
+++ hadoop/common/branches/branch-0.20-security-patches/src/core/org/apache/hadoop/security/ShellBasedUnixGroupsMapping.java
Fri Mar  4 04:06:26 2011
@@ -35,19 +35,12 @@ import org.apache.hadoop.util.Shell.Exit
  * memberships of a given user.
  */
 public class ShellBasedUnixGroupsMapping implements GroupMappingServiceProvider {
-  Map<String, List<String>> userGroups = 
-    new ConcurrentHashMap<String, List<String>>();
   
   private static final Log LOG = LogFactory.getLog(ShellBasedUnixGroupsMapping.class);
   
   @Override
   public List<String> getGroups(String user) throws IOException {
-    List<String> groups = userGroups.get(user);
-    if (groups == null) {
-      groups = getUnixGroups(user);
-      userGroups.put(user, groups);
-    }
-    return groups;
+    return getUnixGroups(user);
   }
 
   /** 



Mime
View raw message