public class JmxManagedThreadPool extends SeExecutorService implements JmxManagedThreadPoolMBean, PlatformService<JmxManagedThreadPool>
Modifier and Type | Field and Description |
---|---|
protected BlockingQueue<Runnable> |
threadPoolQueue |
threadPoolExecutor
Constructor and Description |
---|
JmxManagedThreadPool(BlockingQueue<Runnable> queue,
ThreadPoolExecutor executor) |
Modifier and Type | Method and Description |
---|---|
int |
getActiveCount() |
long |
getCompletedTaskCount() |
int |
getLargestPoolSize() |
int |
getMaximumPoolSize() |
int |
getPoolSize() |
int |
getQueueCount() |
long |
getTaskCount() |
ThreadPoolExecutor |
getThreadPoolExecutor() |
JmxManagedThreadPool |
getValue() |
void |
purgeThreadPool() |
void |
setCorePoolSize(int corePoolSize) |
void |
setKeepAliveTime(long time,
TimeUnit unit) |
void |
setMaximumPoolSize(int maximumPoolSize) |
void |
start(PlatformServiceContainer mBeanServiceContainer) |
void |
stop(PlatformServiceContainer mBeanServiceContainer) |
executeLongRunning, executeShortRunning, getExecuteJobsRunnable, schedule
protected final BlockingQueue<Runnable> threadPoolQueue
public JmxManagedThreadPool(BlockingQueue<Runnable> queue, ThreadPoolExecutor executor)
public void start(PlatformServiceContainer mBeanServiceContainer)
start
in interface PlatformService<JmxManagedThreadPool>
public void stop(PlatformServiceContainer mBeanServiceContainer)
stop
in interface PlatformService<JmxManagedThreadPool>
public JmxManagedThreadPool getValue()
getValue
in interface PlatformService<JmxManagedThreadPool>
public void setCorePoolSize(int corePoolSize)
setCorePoolSize
in interface JmxManagedThreadPoolMBean
public void setMaximumPoolSize(int maximumPoolSize)
setMaximumPoolSize
in interface JmxManagedThreadPoolMBean
public int getMaximumPoolSize()
getMaximumPoolSize
in interface JmxManagedThreadPoolMBean
public void setKeepAliveTime(long time, TimeUnit unit)
public void purgeThreadPool()
purgeThreadPool
in interface JmxManagedThreadPoolMBean
public int getPoolSize()
getPoolSize
in interface JmxManagedThreadPoolMBean
public int getActiveCount()
getActiveCount
in interface JmxManagedThreadPoolMBean
public int getLargestPoolSize()
getLargestPoolSize
in interface JmxManagedThreadPoolMBean
public long getTaskCount()
getTaskCount
in interface JmxManagedThreadPoolMBean
public long getCompletedTaskCount()
getCompletedTaskCount
in interface JmxManagedThreadPoolMBean
public int getQueueCount()
getQueueCount
in interface JmxManagedThreadPoolMBean
public ThreadPoolExecutor getThreadPoolExecutor()
Copyright © 2019. All rights reserved.