public abstract class GetGroupsBase extends Configured implements Tool
Modifier | Constructor and Description |
---|---|
protected |
GetGroupsBase(Configuration conf)
Create an instance of this tool using the given configuration.
|
protected |
GetGroupsBase(Configuration conf,
PrintStream out)
Used exclusively for testing.
|
Modifier and Type | Method and Description |
---|---|
protected abstract InetSocketAddress |
getProtocolAddress(Configuration conf)
Must be overridden by subclasses to get the address where the
GetUserMappingsProtocol implementation is running. |
protected org.apache.hadoop.tools.GetUserMappingsProtocol |
getUgmProtocol()
Get a client of the
GetUserMappingsProtocol . |
int |
run(String[] args)
Get the groups for the users given and print formatted output to the
PrintStream configured earlier. |
getConf, setConf
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getConf, setConf
protected GetGroupsBase(Configuration conf)
conf
- protected GetGroupsBase(Configuration conf, PrintStream out)
conf
- The configuration to use.out
- The PrintStream to write to, instead of System.outpublic int run(String[] args) throws Exception
PrintStream
configured earlier.protected abstract InetSocketAddress getProtocolAddress(Configuration conf) throws IOException
GetUserMappingsProtocol
implementation is running.conf
- The configuration to use.IOException
protected org.apache.hadoop.tools.GetUserMappingsProtocol getUgmProtocol() throws IOException
GetUserMappingsProtocol
.GetUserMappingsProtocol
client proxy.IOException
Copyright © 2017 Apache Software Foundation. All Rights Reserved.