public class BonitaThreadPoolExecutor extends ThreadPoolExecutor implements BonitaExecutorService
ThreadPoolExecutor.AbortPolicy, ThreadPoolExecutor.CallerRunsPolicy, ThreadPoolExecutor.DiscardOldestPolicy, ThreadPoolExecutor.DiscardPolicy| Constructor and Description |
|---|
BonitaThreadPoolExecutor(int corePoolSize,
int maximumPoolSize,
long keepAliveTime,
TimeUnit unit,
BlockingQueue<Runnable> workQueue,
ThreadFactory threadFactory,
RejectedExecutionHandler handler,
WorkFactory workFactory,
TechnicalLoggerService logger,
org.bonitasoft.engine.commons.time.EngineClock engineClock,
WorkExecutionCallback workExecutionCallback) |
| Modifier and Type | Method and Description |
|---|---|
void |
clearAllQueues()
clear the queue of work
|
long |
getExecuted() |
long |
getPendings() |
long |
getRunnings() |
void |
shutdownAndEmptyQueue()
shutdown and handle the queue properly
|
Future<?> |
submit(Runnable task) |
void |
submit(WorkDescriptor work)
Execute the work described by the work descriptor
|
afterExecute, allowCoreThreadTimeOut, allowsCoreThreadTimeOut, awaitTermination, beforeExecute, execute, finalize, getActiveCount, getCompletedTaskCount, getCorePoolSize, getKeepAliveTime, getLargestPoolSize, getMaximumPoolSize, getPoolSize, getQueue, getRejectedExecutionHandler, getTaskCount, getThreadFactory, isShutdown, isTerminated, isTerminating, prestartAllCoreThreads, prestartCoreThread, purge, remove, setCorePoolSize, setKeepAliveTime, setMaximumPoolSize, setRejectedExecutionHandler, setThreadFactory, shutdown, shutdownNow, terminated, toStringinvokeAll, invokeAll, invokeAny, invokeAny, newTaskFor, newTaskFor, submit, submitclone, equals, getClass, hashCode, notify, notifyAll, wait, wait, waitawaitTerminationpublic BonitaThreadPoolExecutor(int corePoolSize,
int maximumPoolSize,
long keepAliveTime,
TimeUnit unit,
BlockingQueue<Runnable> workQueue,
ThreadFactory threadFactory,
RejectedExecutionHandler handler,
WorkFactory workFactory,
TechnicalLoggerService logger,
org.bonitasoft.engine.commons.time.EngineClock engineClock,
WorkExecutionCallback workExecutionCallback)
public void clearAllQueues()
BonitaExecutorServiceclearAllQueues in interface BonitaExecutorServicepublic Future<?> submit(Runnable task)
submit in interface ExecutorServicesubmit in class AbstractExecutorServicepublic void shutdownAndEmptyQueue()
BonitaExecutorServiceshutdownAndEmptyQueue in interface BonitaExecutorServicepublic void submit(WorkDescriptor work)
BonitaExecutorServicesubmit in interface BonitaExecutorServicepublic long getPendings()
getPendings in interface org.bonitasoft.engine.monitoring.ObservableExecutorpublic long getRunnings()
getRunnings in interface org.bonitasoft.engine.monitoring.ObservableExecutorpublic long getExecuted()
getExecuted in interface org.bonitasoft.engine.monitoring.ObservableExecutorCopyright © 2019 Bonitasoft S.A.. All rights reserved.