Interface StateTransitionManager.Context
- Enclosing interface:
- StateTransitionManager
public static interface StateTransitionManager.Context
The interface that can be used by the
StateTransitionManager to communicate with the
underlying system.-
Method Summary
Modifier and TypeMethodDescriptionorg.apache.flink.api.common.JobIDgetJobId()Gets theJobIDof the job.booleanReturnstrueif the available resources meet the desired resources for the job; otherwisefalse.booleanReturnstrueif the available resources are sufficient enough for a state transition; otherwisefalse.scheduleOperation(Runnable callback, Duration delay) Runs operation with a given delay in the underlying main thread.voidTriggers the transition to the subsequent state of theAdaptiveScheduler.
-
Method Details
-
hasSufficientResources
boolean hasSufficientResources()Returnstrueif the available resources are sufficient enough for a state transition; otherwisefalse. -
hasDesiredResources
boolean hasDesiredResources()Returnstrueif the available resources meet the desired resources for the job; otherwisefalse. -
transitionToSubsequentState
void transitionToSubsequentState()Triggers the transition to the subsequent state of theAdaptiveScheduler. -
scheduleOperation
Runs operation with a given delay in the underlying main thread.- Returns:
- a ScheduledFuture representing pending completion of the operation.
-
getJobId
org.apache.flink.api.common.JobID getJobId()Gets theJobIDof the job.- Returns:
- the
JobIDof the job
-