Package org.jboss.as.threads
Class ManagedQueueExecutorService
- java.lang.Object
-
- org.jboss.as.threads.ManagedExecutorService
-
- org.jboss.as.threads.ManagedQueueExecutorService
-
- All Implemented Interfaces:
Executor
,ExecutorService
,org.jboss.threads.BlockingExecutor
public class ManagedQueueExecutorService extends ManagedExecutorService implements org.jboss.threads.BlockingExecutor
- Author:
- Alexey Loubyansky
-
-
Constructor Summary
Constructors Constructor Description ManagedQueueExecutorService(org.jboss.threads.QueueExecutor executor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
executeBlocking(Runnable task)
void
executeBlocking(Runnable task, long timeout, TimeUnit unit)
void
executeNonBlocking(Runnable task)
int
getCoreThreads()
int
getCurrentThreadCount()
long
getKeepAlive()
int
getLargestThreadCount()
int
getMaxThreads()
int
getQueueSize()
int
getRejectedCount()
boolean
isAllowCoreTimeout()
boolean
isBlocking()
protected ExecutorService
protectExecutor(ExecutorService executor)
-
Methods inherited from class org.jboss.as.threads.ManagedExecutorService
awaitTermination, execute, invokeAll, invokeAll, invokeAny, invokeAny, isShutdown, isTerminated, shutdown, shutdownNow, submit, submit, submit
-
-
-
-
Method Detail
-
protectExecutor
protected ExecutorService protectExecutor(ExecutorService executor)
- Overrides:
protectExecutor
in classManagedExecutorService
-
getCoreThreads
public int getCoreThreads()
-
isAllowCoreTimeout
public boolean isAllowCoreTimeout()
-
isBlocking
public boolean isBlocking()
-
getMaxThreads
public int getMaxThreads()
-
getKeepAlive
public long getKeepAlive()
-
getCurrentThreadCount
public int getCurrentThreadCount()
-
getLargestThreadCount
public int getLargestThreadCount()
-
getRejectedCount
public int getRejectedCount()
-
getQueueSize
public int getQueueSize()
-
executeBlocking
public void executeBlocking(Runnable task) throws RejectedExecutionException, InterruptedException
- Specified by:
executeBlocking
in interfaceorg.jboss.threads.BlockingExecutor
- Throws:
RejectedExecutionException
InterruptedException
-
executeBlocking
public void executeBlocking(Runnable task, long timeout, TimeUnit unit) throws RejectedExecutionException, InterruptedException
- Specified by:
executeBlocking
in interfaceorg.jboss.threads.BlockingExecutor
- Throws:
RejectedExecutionException
InterruptedException
-
executeNonBlocking
public void executeNonBlocking(Runnable task) throws RejectedExecutionException
- Specified by:
executeNonBlocking
in interfaceorg.jboss.threads.BlockingExecutor
- Throws:
RejectedExecutionException
-
-