|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.springframework.data.hadoop.mapreduce.ToolRunner
public class ToolRunner
Wrapper around ToolRunner allowing for an easier configuration and execution
of Tool instances inside Spring.
Optionally returns the execution result (as an int per Tool.run(String[])).
| Constructor Summary | |
|---|---|
ToolRunner()
|
|
| Method Summary | |
|---|---|
void |
afterPropertiesSet()
|
Integer |
getObject()
|
Class<?> |
getObjectType()
|
boolean |
isSingleton()
|
void |
setArchives(Resource... archives)
Sets the archives to be unarchive to the map reduce cluster. |
void |
setArguments(String... arguments)
Sets the arguments. |
void |
setBeanClassLoader(ClassLoader classLoader)
|
void |
setConfiguration(Configuration configuration)
Sets the configuration. |
void |
setFiles(Resource... files)
Sets the files to be copied to the map reduce cluster. |
void |
setJar(Resource jar)
|
void |
setLibs(Resource... libJars)
Sets the jar files to include in the classpath. |
void |
setProperties(Properties properties)
Sets the properties. |
void |
setRunAtStartup(boolean runAtStartup)
Sets the run at startup. |
void |
setTool(Tool tool)
Sets the tool. |
void |
setToolClass(String toolClassName)
Sets the tool class by name. |
void |
setUser(String user)
Sets the user impersonation (optional) for running this job. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ToolRunner()
| Method Detail |
|---|
public Integer getObject()
throws Exception
getObject in interface FactoryBean<Integer>Exceptionpublic Class<?> getObjectType()
getObjectType in interface FactoryBean<Integer>public boolean isSingleton()
isSingleton in interface FactoryBean<Integer>
public void afterPropertiesSet()
throws Exception
afterPropertiesSet in interface InitializingBeanExceptionpublic void setRunAtStartup(boolean runAtStartup)
runAtStartup - The runAtStartup to set.public void setTool(Tool tool)
tool - The tool to set.public void setToolClass(String toolClassName)
toolClassName - the new tool classpublic void setJar(Resource jar)
public void setArguments(String... arguments)
arguments - The arguments to set.public void setConfiguration(Configuration configuration)
configuration - The configuration to set.public void setProperties(Properties properties)
properties - The properties to set.public void setBeanClassLoader(ClassLoader classLoader)
setBeanClassLoader in interface BeanClassLoaderAwarepublic void setLibs(Resource... libJars)
mydir/*.jar), which the
Spring container will automatically resolve.
libJars - The jar files to include in the classpath.public void setFiles(Resource... files)
mydir/*.txt), which the
Spring container will automatically resolve.
files - The files to copy.public void setArchives(Resource... archives)
mydir/*.zip), which the
Spring container will automatically resolve.
archives - The archives to unarchive on the compute machines.public void setUser(String user)
user - user/group information
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||