Class DecoratedScheduledExecutorService
java.lang.Object
org.apache.druid.java.util.common.concurrent.DecoratedExecutorService
org.apache.druid.java.util.common.concurrent.DecoratedScheduledExecutorService
- All Implemented Interfaces:
Executor,ExecutorService,ScheduledExecutorService
- Direct Known Subclasses:
DelayMetricEmittingScheduledExecutorService
public class DecoratedScheduledExecutorService
extends DecoratedExecutorService
implements ScheduledExecutorService
A
ScheduledExecutorService where all tasks are automatically decorated before being submitted to a
delegate executor service. Extends DecoratedExecutorService to handle the
ExecutorService methods.
The JDK scheduleAtFixedRate(java.lang.Runnable, long, long, java.util.concurrent.TimeUnit) and scheduleWithFixedDelay(java.lang.Runnable, long, long, java.util.concurrent.TimeUnit) methods are not supported;
use ScheduledExecutors instead.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.druid.java.util.common.concurrent.DecoratedExecutorService
DecoratedExecutorService.Decorator -
Field Summary
Fields inherited from class org.apache.druid.java.util.common.concurrent.DecoratedExecutorService
decorator, exec -
Constructor Summary
ConstructorsConstructorDescriptionDecoratedScheduledExecutorService(ScheduledExecutorService delegate, DecoratedExecutorService.Decorator decorator) -
Method Summary
Modifier and TypeMethodDescription<V> ScheduledFuture<V>scheduleAtFixedRate(Runnable command, long initialDelay, long period, TimeUnit unit) scheduleWithFixedDelay(Runnable command, long initialDelay, long delay, TimeUnit unit) Methods inherited from class org.apache.druid.java.util.common.concurrent.DecoratedExecutorService
awaitTermination, execute, invokeAll, invokeAll, invokeAny, invokeAny, isShutdown, isTerminated, shutdown, shutdownNow, submit, submit, submitMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.concurrent.ExecutorService
awaitTermination, invokeAll, invokeAll, invokeAny, invokeAny, isShutdown, isTerminated, shutdown, shutdownNow, submit, submit, submit
-
Constructor Details
-
DecoratedScheduledExecutorService
public DecoratedScheduledExecutorService(ScheduledExecutorService delegate, DecoratedExecutorService.Decorator decorator)
-
-
Method Details
-
schedule
- Specified by:
schedulein interfaceScheduledExecutorService
-
schedule
- Specified by:
schedulein interfaceScheduledExecutorService
-
scheduleAtFixedRate
public ScheduledFuture<?> scheduleAtFixedRate(Runnable command, long initialDelay, long period, TimeUnit unit) - Specified by:
scheduleAtFixedRatein interfaceScheduledExecutorService
-
scheduleWithFixedDelay
public ScheduledFuture<?> scheduleWithFixedDelay(Runnable command, long initialDelay, long delay, TimeUnit unit) - Specified by:
scheduleWithFixedDelayin interfaceScheduledExecutorService
-