HADOOP-10280. Make Schedulables return a configurable identity of user or group. (Contributed by Chris Li)

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1581532 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Arpit Agarwal 2014-03-25 21:34:21 +00:00
parent d14eff7d38
commit c64974a863
3 changed files with 11 additions and 1 deletions

View File

@ -390,6 +390,9 @@ Release 2.4.0 - UNRELEASED
HADOOP-10423. Clarify compatibility policy document for combination of
new client and old server. (Chris Nauroth via kasha)
HADOOP-10280. Make Schedulables return a configurable identity of user
or group. (Chris Li via Arpit Agarwal)
OPTIMIZATIONS
BUG FIXES

View File

@ -89,6 +89,7 @@ public class CommonConfigurationKeys extends CommonConfigurationKeysPublic {
*/
public static final String IPC_CALLQUEUE_NAMESPACE = "ipc";
public static final String IPC_CALLQUEUE_IMPL_KEY = "callqueue.impl";
public static final String IPC_CALLQUEUE_IDENTITY_PROVIDER_KEY = "identity-provider.impl";
/** Internal buffer size for Lzo compressor/decompressors */
public static final String IO_COMPRESSION_CODEC_LZO_BUFFERSIZE_KEY =

View File

@ -496,7 +496,7 @@ public abstract class Server {
}
/** A call queued for handling. */
public static class Call {
public static class Call implements Schedulable {
private final int callId; // the client's call id
private final int retryCount; // the retry count of the call
private final Writable rpcRequest; // Serialized Rpc request from client
@ -534,6 +534,12 @@ public abstract class Server {
public void setResponse(ByteBuffer response) {
this.rpcResponse = response;
}
// For Schedulable
@Override
public UserGroupInformation getUserGroupInformation() {
return connection.user;
}
}
/** Listens on the socket. Creates jobs for the handler threads*/