-
public final class ConcurrencyExtKt
-
-
Method Summary
Modifier and Type Method Description final static UnitexecuteSafe(Executor $self, String operationName, InternalLogger internalLogger, Runnable runnable)Executes runnable without throwing RejectedExecutionException if it cannot be accepted for execution. final static ScheduledFuture<?>scheduleSafe(ScheduledExecutorService $self, String operationName, Long delay, TimeUnit unit, InternalLogger internalLogger, Runnable runnable)Executes runnable without throwing RejectedExecutionException if it cannot be accepted for execution. final static Future<?>submitSafe(ExecutorService $self, String operationName, InternalLogger internalLogger, Runnable runnable)Submit runnable without throwing RejectedExecutionException if it cannot be accepted for execution. -
-
Method Detail
-
executeSafe
final static Unit executeSafe(Executor $self, String operationName, InternalLogger internalLogger, Runnable runnable)
Executes runnable without throwing RejectedExecutionException if it cannot be accepted for execution.
- Parameters:
operationName- Name of the task.internalLogger- Internal logger.runnable- Task to run.
-
scheduleSafe
final static ScheduledFuture<?> scheduleSafe(ScheduledExecutorService $self, String operationName, Long delay, TimeUnit unit, InternalLogger internalLogger, Runnable runnable)
Executes runnable without throwing RejectedExecutionException if it cannot be accepted for execution.
- Parameters:
operationName- Name of the task.delay- Task scheduling delay.unit- Delay unit.internalLogger- Internal logger.runnable- Task to run.
-
submitSafe
final static Future<?> submitSafe(ExecutorService $self, String operationName, InternalLogger internalLogger, Runnable runnable)
Submit runnable without throwing RejectedExecutionException if it cannot be accepted for execution.
- Parameters:
operationName- Name of the task.internalLogger- Internal logger.runnable- Task to run.
-
-
-
-