HADOOP-10539. Merging change r1589884 from trunk to branch-2.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1589885 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Chris Nauroth 2014-04-24 21:26:09 +00:00
parent fa9fea80e2
commit 91aad1c7bd
2 changed files with 18 additions and 1 deletions

View File

@ -84,6 +84,9 @@ Release 2.5.0 - UNRELEASED
HADOOP-10531. hadoop-config.sh - bug in --hosts argument.
(Sebastien Barrier via wang)
HADOOP-10539. Provide backward compatibility for ProxyUsers.authorize()
call. (Benoy Antony via cnauroth)
Release 2.4.1 - UNRELEASED
INCOMPATIBLE CHANGES

View File

@ -34,7 +34,7 @@
import com.google.common.annotations.VisibleForTesting;
@InterfaceAudience.Private
@InterfaceAudience.LimitedPrivate({"HDFS", "MapReduce", "HBase", "Hive"})
public class ProxyUsers {
private static final String CONF_HOSTS = ".hosts";
@ -189,6 +189,20 @@ public static synchronized void authorize(UserGroupInformation user,
}
}
/**
* This function is kept to provide backward compatibility.
* @param user
* @param remoteAddress
* @param conf
* @throws AuthorizationException
* @deprecated use {@link #authorize(UserGroupInformation, String) instead.
*/
@Deprecated
public static synchronized void authorize(UserGroupInformation user,
String remoteAddress, Configuration conf) throws AuthorizationException {
authorize(user,remoteAddress);
}
/**
* Return true if the configuration specifies the special configuration value
* "*", indicating that any group or host list is allowed to use this configuration.