HADOOP-10833. Remove unused cache in UserProvider. (Benoy Antony)

This commit is contained in:
Benoy Antony 2014-08-30 12:49:19 -07:00
parent 0f34e6f387
commit 258c7d0f53
2 changed files with 2 additions and 5 deletions

View File

@ -537,6 +537,8 @@ Release 2.6.0 - UNRELEASED
schedules incoming calls and multiplexes outgoing calls. (Chris Li via schedules incoming calls and multiplexes outgoing calls. (Chris Li via
Arpit Agarwal) Arpit Agarwal)
HADOOP-10833. Remove unused cache in UserProvider. (Benoy Antony)
BUG FIXES BUG FIXES
HADOOP-10781. Unportable getgrouplist() usage breaks FreeBSD (Dmitry HADOOP-10781. Unportable getgrouplist() usage breaks FreeBSD (Dmitry

View File

@ -21,9 +21,7 @@
import java.io.IOException; import java.io.IOException;
import java.net.URI; import java.net.URI;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map;
import org.apache.hadoop.classification.InterfaceAudience; import org.apache.hadoop.classification.InterfaceAudience;
import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.conf.Configuration;
@ -41,8 +39,6 @@ public class UserProvider extends CredentialProvider {
public static final String SCHEME_NAME = "user"; public static final String SCHEME_NAME = "user";
private final UserGroupInformation user; private final UserGroupInformation user;
private final Credentials credentials; private final Credentials credentials;
private final Map<String, CredentialEntry> cache = new HashMap<String,
CredentialEntry>();
private UserProvider() throws IOException { private UserProvider() throws IOException {
user = UserGroupInformation.getCurrentUser(); user = UserGroupInformation.getCurrentUser();
@ -86,7 +82,6 @@ public synchronized void deleteCredentialEntry(String name) throws IOException {
throw new IOException("Credential " + name + throw new IOException("Credential " + name +
" does not exist in " + this); " does not exist in " + this);
} }
cache.remove(name);
} }
@Override @Override