Package org.infinispan.util.concurrent
Class NonBlockingManagerImpl
- java.lang.Object
-
- org.infinispan.util.concurrent.NonBlockingManagerImpl
-
- All Implemented Interfaces:
NonBlockingManager
public class NonBlockingManagerImpl extends Object implements NonBlockingManager
-
-
Constructor Summary
Constructors Constructor Description NonBlockingManagerImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AutoCloseablescheduleWithFixedDelay(Supplier<CompletionStage<?>> supplier, long initialDelay, long delay, TimeUnit unit)Schedules the supplier that is executed after the initialDelay period and subsequently runs delay after the previous stage completes.
-
-
-
Method Detail
-
scheduleWithFixedDelay
public AutoCloseable scheduleWithFixedDelay(Supplier<CompletionStage<?>> supplier, long initialDelay, long delay, TimeUnit unit)
Description copied from interface:NonBlockingManagerSchedules the supplier that is executed after the initialDelay period and subsequently runs delay after the previous stage completes. The supplier must not block the thread in which it runs and should immediately return to avoid blocking the scheduling thread.- Specified by:
scheduleWithFixedDelayin interfaceNonBlockingManager- Parameters:
supplier- non-blocking operation supplier.initialDelay- period of time before the supplier is invoked.delay- delay between subsequent supplier invocations.unit- time unit for delays.- Returns:
- an AutoCloseable that cancels the scheduled task.
-
-