public class SafeScheduledThreadPoolExecutor extends ScheduledThreadPoolExecutor
Wrapper to provide standard exception handling
ThreadPoolExecutor.AbortPolicy, ThreadPoolExecutor.CallerRunsPolicy, ThreadPoolExecutor.DiscardOldestPolicy, ThreadPoolExecutor.DiscardPolicy
Constructor and Description |
---|
SafeScheduledThreadPoolExecutor(int corePoolSize) |
SafeScheduledThreadPoolExecutor(int corePoolSize,
RejectedExecutionHandler handler) |
SafeScheduledThreadPoolExecutor(int corePoolSize,
ThreadFactory threadFactory) |
SafeScheduledThreadPoolExecutor(int corePoolSize,
ThreadFactory threadFactory,
RejectedExecutionHandler handler) |
Modifier and Type | Method and Description |
---|---|
protected void |
afterExecute(Runnable r,
Throwable t) |
decorateTask, decorateTask, execute, getContinueExistingPeriodicTasksAfterShutdownPolicy, getExecuteExistingDelayedTasksAfterShutdownPolicy, getQueue, getRemoveOnCancelPolicy, schedule, schedule, scheduleAtFixedRate, scheduleWithFixedDelay, setContinueExistingPeriodicTasksAfterShutdownPolicy, setExecuteExistingDelayedTasksAfterShutdownPolicy, setRemoveOnCancelPolicy, shutdown, shutdownNow, submit, submit, submit
allowCoreThreadTimeOut, allowsCoreThreadTimeOut, awaitTermination, beforeExecute, finalize, getActiveCount, getCompletedTaskCount, getCorePoolSize, getKeepAliveTime, getLargestPoolSize, getMaximumPoolSize, getPoolSize, getRejectedExecutionHandler, getTaskCount, getThreadFactory, isShutdown, isTerminated, isTerminating, prestartAllCoreThreads, prestartCoreThread, purge, remove, setCorePoolSize, setKeepAliveTime, setMaximumPoolSize, setRejectedExecutionHandler, setThreadFactory, terminated, toString
invokeAll, invokeAll, invokeAny, invokeAny, newTaskFor, newTaskFor
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
awaitTermination, invokeAll, invokeAll, invokeAny, invokeAny, isShutdown, isTerminated
public SafeScheduledThreadPoolExecutor(int corePoolSize)
public SafeScheduledThreadPoolExecutor(int corePoolSize, RejectedExecutionHandler handler)
public SafeScheduledThreadPoolExecutor(int corePoolSize, ThreadFactory threadFactory)
public SafeScheduledThreadPoolExecutor(int corePoolSize, ThreadFactory threadFactory, RejectedExecutionHandler handler)
protected void afterExecute(Runnable r, Throwable t)
afterExecute
in class ThreadPoolExecutor
Copyright © 2015–2017. All rights reserved.