Package org.apache.cassandra.concurrent
Interface SequentialExecutorPlus
- All Superinterfaces:
Executor,ExecutorPlus,ExecutorService,ResizableThreadPool
- All Known Subinterfaces:
LocalAwareSequentialExecutorPlus
- All Known Implementing Classes:
LocalAwareSingleThreadExecutorPlus,SingleThreadExecutorPlus
An
ExecutorPlus that guarantees the order of execution matches the order of task submission,
and provides a simple mechanism for the recurring pattern of ensuring a job is executed at least once
after some point in time (i.e. ensures that at most one copy of the task is queued, with up to one
copy running as well)-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface org.apache.cassandra.concurrent.ExecutorPlus
ExecutorPlus.MaximumPoolSizeListener -
Method Summary
Modifier and TypeMethodDescriptionatLeastOnceTrigger(Runnable runnable) Return an object for orchestrating the execution of this task at least once (in its entirety) after the trigger is invoked, i.e.Methods inherited from interface org.apache.cassandra.concurrent.ExecutorPlus
execute, inExecutor, invokeAll, invokeAll, invokeAny, invokeAny, maybeExecuteImmediately, submit, submit, submit, submit, submit, submitMethods inherited from interface java.util.concurrent.ExecutorService
awaitTermination, isShutdown, isTerminated, shutdown, shutdownNowMethods inherited from interface org.apache.cassandra.concurrent.ResizableThreadPool
getActiveTaskCount, getCompletedTaskCount, getCorePoolSize, getMaximumPoolSize, getMaxTasksQueued, getPendingTaskCount, oldestTaskQueueTime, setCorePoolSize, setMaximumPoolSize
-
Method Details
-
atLeastOnceTrigger
Return an object for orchestrating the execution of this task at least once (in its entirety) after the trigger is invoked, i.e. saturating the number of pending tasks at 1 (2 including any possibly executing at the time of invocation)
-