Spring for Apache Hadoop

org.springframework.yarn.am.container
Class DefaultContainerLauncher

java.lang.Object
  extended by org.springframework.yarn.support.LifecycleObjectSupport
      extended by org.springframework.yarn.am.container.AbstractLauncher
          extended by org.springframework.yarn.am.container.DefaultContainerLauncher
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.InitializingBean, org.springframework.context.Lifecycle, org.springframework.context.Phased, org.springframework.context.SmartLifecycle, ContainerLauncher

public class DefaultContainerLauncher
extends AbstractLauncher
implements ContainerLauncher

Default container launcher.

Author:
Janne Valkealahti

Nested Class Summary
 
Nested classes/interfaces inherited from class org.springframework.yarn.am.container.AbstractLauncher
AbstractLauncher.ContainerLauncherInterceptorList
 
Constructor Summary
DefaultContainerLauncher()
           
 
Method Summary
protected  void doStart()
          Subclasses may implement this method with the start behavior.
protected  void doStop()
          Subclasses may implement this method with the stop behavior.
 void launchContainer(org.apache.hadoop.yarn.api.records.Container container, java.util.List<java.lang.String> commands)
          Launch container Container using given list of commands.
protected  void onInit()
          Subclasses may implement this for initialization logic.
 
Methods inherited from class org.springframework.yarn.am.container.AbstractLauncher
addInterceptor, getCmTemplate, getConfiguration, getEnvironment, getInterceptors, getResourceLocalizer, getUsername, setConfiguration, setEnvironment, setInterceptors, setResourceLocalizer, setUsername
 
Methods inherited from class org.springframework.yarn.support.LifecycleObjectSupport
afterPropertiesSet, getBeanFactory, getPhase, getTaskExecutor, getTaskScheduler, getYarnEventPublisher, isAutoStartup, isRunning, setAutoStartup, setBeanFactory, setPhase, setTaskExecutor, setTaskScheduler, setYarnEventPublisher, start, stop, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultContainerLauncher

public DefaultContainerLauncher()
Method Detail

onInit

protected void onInit()
               throws java.lang.Exception
Description copied from class: LifecycleObjectSupport
Subclasses may implement this for initialization logic. Called during the InitializingBean phase. Implementor should always call super method not to break initialization chain.

Overrides:
onInit in class AbstractLauncher
Throws:
java.lang.Exception

doStart

protected void doStart()
Description copied from class: LifecycleObjectSupport
Subclasses may implement this method with the start behavior. This method will be invoked while holding the LifecycleObjectSupport.lifecycleLock.

Overrides:
doStart in class LifecycleObjectSupport

doStop

protected void doStop()
Description copied from class: LifecycleObjectSupport
Subclasses may implement this method with the stop behavior. This method will be invoked while holding the LifecycleObjectSupport.lifecycleLock.

Overrides:
doStop in class LifecycleObjectSupport

launchContainer

public void launchContainer(org.apache.hadoop.yarn.api.records.Container container,
                            java.util.List<java.lang.String> commands)
Description copied from interface: ContainerLauncher
Launch container Container using given list of commands.

Specified by:
launchContainer in interface ContainerLauncher
Parameters:
container - the Container
commands - the list of commands

Spring for Apache Hadoop