public class MonitoringThreadPoolExecutor extends ThreadPoolExecutor
ThreadPoolExecutor.AbortPolicy, ThreadPoolExecutor.CallerRunsPolicy, ThreadPoolExecutor.DiscardOldestPolicy, ThreadPoolExecutor.DiscardPolicy
Constructor and Description |
---|
MonitoringThreadPoolExecutor(int maximumPoolSize,
long keepAliveTime,
TimeUnit unit) |
MonitoringThreadPoolExecutor(int maximumPoolSize,
long keepAliveTime,
TimeUnit unit,
RejectedExecutionHandler handler) |
Modifier and Type | Method and Description |
---|---|
void |
execute(Runnable task) |
long |
getAverageQueueLatency() |
long |
getAverageTaskLatency() |
int |
getMaxActiveThreads() |
long |
getMaxQueueLatency() |
int |
getMaxQueueSize() |
long |
getMaxTaskLatency() |
long |
getTasks() |
void |
reset() |
afterExecute, allowCoreThreadTimeOut, allowsCoreThreadTimeOut, awaitTermination, beforeExecute, 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, toString
invokeAll, invokeAll, invokeAny, invokeAny, newTaskFor, newTaskFor, submit, submit, submit
public MonitoringThreadPoolExecutor(int maximumPoolSize, long keepAliveTime, TimeUnit unit)
public MonitoringThreadPoolExecutor(int maximumPoolSize, long keepAliveTime, TimeUnit unit, RejectedExecutionHandler handler)
public void reset()
public long getTasks()
public long getMaxTaskLatency()
public long getAverageTaskLatency()
public long getMaxQueueLatency()
public long getAverageQueueLatency()
public int getMaxQueueSize()
public int getMaxActiveThreads()
public void execute(Runnable task)
execute
in interface Executor
execute
in class ThreadPoolExecutor
Copyright © 2008–2024 The CometD Project. All rights reserved.