Package io.camunda.zeebe.util.sched
Class ActorTask
java.lang.Object
io.camunda.zeebe.util.sched.ActorTask
A task executed by the scheduler. For each actor (instance), exactly one task is created. Each
invocation of one of the actor's methods is an
ActorJob.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumAn actor task's lifecycle phasesstatic enumDescribes an actor's scheduling state -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddSubscription(ActorSubscription subscription) booleanclaim(long stateCount) booleanexecute(ActorThread runner) voidfail()getActor()getName()intgetState()longvoidbooleanvoidvoidonSubscriptionCancelled(ActorSubscription subscription) onTaskScheduled(ActorExecutor actorExecutor, ActorThreadGroup actorThreadGroup) called when the task is initially scheduled.voidvoidresubmit()voidsetPriority(int priority) voidsetUpdatedSchedulingHints(int hints) voidUsed to externally submit a job.toString()booleanvoid
-
Field Details
-
closeFuture
-
-
Constructor Details
-
ActorTask
-
-
Method Details
-
onTaskScheduled
public ActorFuture<Void> onTaskScheduled(ActorExecutor actorExecutor, ActorThreadGroup actorThreadGroup) called when the task is initially scheduled. -
submit
Used to externally submit a job. -
execute
-
requestClose
public void requestClose() -
onFailure
-
claim
public boolean claim(long stateCount) -
tryWakeup
public boolean tryWakeup() -
getState
-
toString
-
yieldThread
public void yieldThread() -
getStateCount
public long getStateCount() -
getActorThreadGroup
-
getName
-
getActor
-
isClosing
public boolean isClosing() -
getPriority
public int getPriority() -
setPriority
public void setPriority(int priority) -
getActorExecutor
-
getLifecyclePhase
-
getStartingFuture
-
addSubscription
-
onSubscriptionCancelled
-
setUpdatedSchedulingHints
public void setUpdatedSchedulingHints(int hints) -
resubmit
public void resubmit() -
insertJob
-
fail
public void fail()
-