Package dev.failsafe.spi
Interface Scheduler
-
- All Known Implementing Classes:
DelegatingScheduler
public interface SchedulerSchedules executions.- See Also:
DefaultScheduledFuture
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description static Schedulerof(java.util.concurrent.ExecutorService executorService)Returns a Scheduler adapted from theexecutorService.static Schedulerof(java.util.concurrent.ScheduledExecutorService scheduledExecutorService)Returns a Scheduler adapted from thescheduledExecutorService.java.util.concurrent.ScheduledFuture<?>schedule(java.util.concurrent.Callable<?> callable, long delay, java.util.concurrent.TimeUnit unit)Schedules thecallableto be called after thedelayfor theunit.
-
-
-
Field Detail
-
DEFAULT
static final Scheduler DEFAULT
The default scheduler used by Failsafe if no other scheduler orScheduledExecutorServiceis configured for an execution.
-
-
Method Detail
-
schedule
java.util.concurrent.ScheduledFuture<?> schedule(java.util.concurrent.Callable<?> callable, long delay, java.util.concurrent.TimeUnit unit)Schedules thecallableto be called after thedelayfor theunit.
-
of
static Scheduler of(java.util.concurrent.ScheduledExecutorService scheduledExecutorService)
Returns a Scheduler adapted from thescheduledExecutorService.
-
of
static Scheduler of(java.util.concurrent.ExecutorService executorService)
Returns a Scheduler adapted from theexecutorService.
-
-