public final class ApplicationLauncher extends Object
Modifier and Type | Field and Description |
---|---|
static int |
CLIENT_ERROR
Exception occurred in the application.
|
static String |
KEY_LAUNCHER_USED
The configuration key of whether the application may be launched via
ApplicationLauncher . |
static int |
LAUNCH_ERROR
Failed to prepare the application.
|
Modifier and Type | Method and Description |
---|---|
static void |
disposeClassLoader(ClassLoader classLoader)
Disposes the target class loader.
|
static int |
exec(org.apache.hadoop.conf.Configuration configuration,
String... args)
Executes launcher.
|
static int |
exec(String... args)
Executes launcher with default configuration.
|
static void |
main(String... args)
The program entry.
|
static ClassLoader |
switchContextClassLoader(ClassLoader classLoader)
Sets the context class loader and returns the current one.
|
public static final String KEY_LAUNCHER_USED
ApplicationLauncher
.
This will be only set by this class.public static final int LAUNCH_ERROR
public static final int CLIENT_ERROR
public static void main(String... args)
args
- the launcher argumentspublic static int exec(String... args)
args
- the launcher argumentspublic static int exec(org.apache.hadoop.conf.Configuration configuration, String... args)
configuration
- the Hadoop configuration for the applicationargs
- the launcher argumentspublic static ClassLoader switchContextClassLoader(ClassLoader classLoader)
classLoader
- the new context class loaderpublic static void disposeClassLoader(ClassLoader classLoader)
classLoader
- the class loaderCopyright © 2011–2019 Asakusa Framework Team. All rights reserved.