Class SupervisorStateManager
java.lang.Object
org.apache.druid.indexing.overlord.supervisor.SupervisorStateManager
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic classstatic interface -
Constructor Summary
ConstructorsConstructorDescriptionSupervisorStateManager(SupervisorStateManagerConfig supervisorStateManagerConfig, boolean suspended) -
Method Summary
Modifier and TypeMethodDescriptionprotected SupervisorStateManager.ExceptionEventprotected Deque<SupervisorStateManager.ExceptionEvent>protected SupervisorStateManager.StatebooleanbooleanbooleanisIdle()booleanprotected booleanvoidvoidmaybeSetState(SupervisorStateManager.State proposedState) Certain states are only valid if the supervisor hasn't had a successful iteration.voidvoid
-
Constructor Details
-
SupervisorStateManager
public SupervisorStateManager(SupervisorStateManagerConfig supervisorStateManagerConfig, boolean suspended)
-
-
Method Details
-
maybeSetState
Certain states are only valid if the supervisor hasn't had a successful iteration. This method checks if there's been at least one successful iteration, and if applicable, sets supervisor state to an appropriate new state. A STOPPING supervisor cannot transition to any other state as this state is final. This method must be thread-safe as multiple threads trying to update may lead to an invalid state. -
recordThrowableEvent
-
recordCompletedTaskState
-
markRunFinished
public void markRunFinished() -
getExceptionEvents
-
getSupervisorState
-
isHealthy
public boolean isHealthy() -
isSteadyState
public boolean isSteadyState() -
isAtLeastOneSuccessfulRun
public boolean isAtLeastOneSuccessfulRun() -
isIdle
public boolean isIdle() -
getRecentEventsQueue
-
isStoreStackTrace
protected boolean isStoreStackTrace() -
getSpecificUnhealthySupervisorState
-
buildExceptionEvent
-