Class JobExecutionStateMachineImpl
- java.lang.Object
-
- com.netflix.genie.agent.execution.statemachine.JobExecutionStateMachineImpl
-
- All Implemented Interfaces:
JobExecutionStateMachine
public class JobExecutionStateMachineImpl extends java.lang.Object implements JobExecutionStateMachine
Implementation of the job execution state machine.- Since:
- 4.0.0
-
-
Constructor Summary
Constructors Constructor Description JobExecutionStateMachineImpl(java.util.List<ExecutionStage> executionStages, com.netflix.genie.agent.execution.statemachine.ExecutionContext executionContext, java.util.Collection<JobExecutionListener> listeners, JobProcessManager jobProcessManager)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidkill(KillService.KillSource killSource)Abort execution, if necessary by stopping the running job process.voidrun()Runs the state machine until completion.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.netflix.genie.agent.execution.statemachine.JobExecutionStateMachine
getExecutionContext, getExecutionStages
-
-
-
-
Constructor Detail
-
JobExecutionStateMachineImpl
public JobExecutionStateMachineImpl(java.util.List<ExecutionStage> executionStages, com.netflix.genie.agent.execution.statemachine.ExecutionContext executionContext, java.util.Collection<JobExecutionListener> listeners, JobProcessManager jobProcessManager)
Constructor.- Parameters:
executionStages- the (ordered) list of execution stagesexecutionContext- the execution context passed across stages during executionlisteners- the list of listenersjobProcessManager- the job process manager
-
-
Method Detail
-
run
public void run()
Runs the state machine until completion.- Specified by:
runin interfaceJobExecutionStateMachine
-
kill
public void kill(KillService.KillSource killSource)
Description copied from interface:JobExecutionStateMachineAbort execution, if necessary by stopping the running job process. The state machine still runs to termination, but may skip steps as appropriate.- Specified by:
killin interfaceJobExecutionStateMachine- Parameters:
killSource- a representation of who/what requested the kill
-
-