Package org.jboss.as.ee.concurrent
Class ManagedExecutorServiceImpl
- java.lang.Object
-
- java.util.concurrent.AbstractExecutorService
-
- org.glassfish.enterprise.concurrent.AbstractManagedExecutorService
-
- org.glassfish.enterprise.concurrent.ManagedExecutorServiceImpl
-
- org.jboss.as.ee.concurrent.ManagedExecutorServiceImpl
-
- All Implemented Interfaces:
jakarta.enterprise.concurrent.ManagedExecutorService,Executor,ExecutorService,ManagedExecutorWithHungThreads
public class ManagedExecutorServiceImpl extends org.glassfish.enterprise.concurrent.ManagedExecutorServiceImpl implements ManagedExecutorWithHungThreads
- Author:
- Stuart Douglas, emmartins
-
-
Constructor Summary
Constructors Constructor Description ManagedExecutorServiceImpl(String name, org.glassfish.enterprise.concurrent.ManagedThreadFactoryImpl managedThreadFactory, long hungTaskThreshold, boolean longRunningTasks, int corePoolSize, int maxPoolSize, long keepAliveTime, TimeUnit keepAliveTimeUnit, long threadLifeTime, int queueCapacity, org.glassfish.enterprise.concurrent.ContextServiceImpl contextService, org.glassfish.enterprise.concurrent.AbstractManagedExecutorService.RejectPolicy rejectPolicy, org.wildfly.extension.requestcontroller.ControlPoint controlPoint)ManagedExecutorServiceImpl(String name, org.glassfish.enterprise.concurrent.ManagedThreadFactoryImpl managedThreadFactory, long hungTaskThreshold, boolean longRunningTasks, int corePoolSize, int maxPoolSize, long keepAliveTime, TimeUnit keepAliveTimeUnit, long threadLifeTime, org.glassfish.enterprise.concurrent.ContextServiceImpl contextService, org.glassfish.enterprise.concurrent.AbstractManagedExecutorService.RejectPolicy rejectPolicy, BlockingQueue<Runnable> queue, org.wildfly.extension.requestcontroller.ControlPoint controlPoint)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidexecute(Runnable command)ManagedExecutorRuntimeStatsgetRuntimeStats()protected ThreadPoolExecutorgetThreadPoolExecutor()Future<?>submit(Runnable task)<T> Future<T>submit(Runnable task, T result)<T> Future<T>submit(Callable<T> task)-
Methods inherited from class org.glassfish.enterprise.concurrent.ManagedExecutorServiceImpl
getAdapter, getCompletedTaskCount, getExecutorForTaskListener, getNewTaskFor, getNewTaskFor, getTaskCount
-
Methods inherited from class org.glassfish.enterprise.concurrent.AbstractManagedExecutorService
awaitTermination, completedFuture, completedStage, copy, copy, doInvokeAny, executeManagedFutureTask, failedFuture, failedStage, getContextService, getContextSetupProvider, getHungThreads, getManagedThreadFactory, getName, getObjectName, getRejectPolicy, getThreads, invokeAll, invokeAll, invokeAny, invokeAny, isContextualCallback, isEventProvider, isLongRunningTasks, isShutdown, isStateManageable, isStatisticsProvider, isTerminated, newIncompleteFuture, newTaskFor, newTaskFor, runAsync, shutdown, shutdownNow, supplyAsync
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.jboss.as.ee.concurrent.ManagedExecutorWithHungThreads
getHungThreads, getName, terminateHungTasks
-
-
-
-
Constructor Detail
-
ManagedExecutorServiceImpl
public ManagedExecutorServiceImpl(String name, org.glassfish.enterprise.concurrent.ManagedThreadFactoryImpl managedThreadFactory, long hungTaskThreshold, boolean longRunningTasks, int corePoolSize, int maxPoolSize, long keepAliveTime, TimeUnit keepAliveTimeUnit, long threadLifeTime, org.glassfish.enterprise.concurrent.ContextServiceImpl contextService, org.glassfish.enterprise.concurrent.AbstractManagedExecutorService.RejectPolicy rejectPolicy, BlockingQueue<Runnable> queue, org.wildfly.extension.requestcontroller.ControlPoint controlPoint)
-
ManagedExecutorServiceImpl
public ManagedExecutorServiceImpl(String name, org.glassfish.enterprise.concurrent.ManagedThreadFactoryImpl managedThreadFactory, long hungTaskThreshold, boolean longRunningTasks, int corePoolSize, int maxPoolSize, long keepAliveTime, TimeUnit keepAliveTimeUnit, long threadLifeTime, int queueCapacity, org.glassfish.enterprise.concurrent.ContextServiceImpl contextService, org.glassfish.enterprise.concurrent.AbstractManagedExecutorService.RejectPolicy rejectPolicy, org.wildfly.extension.requestcontroller.ControlPoint controlPoint)
-
-
Method Detail
-
submit
public <T> Future<T> submit(Callable<T> task)
- Specified by:
submitin interfaceExecutorService- Overrides:
submitin classorg.glassfish.enterprise.concurrent.AbstractManagedExecutorService
-
submit
public <T> Future<T> submit(Runnable task, T result)
- Specified by:
submitin interfaceExecutorService- Overrides:
submitin classorg.glassfish.enterprise.concurrent.AbstractManagedExecutorService
-
submit
public Future<?> submit(Runnable task)
- Specified by:
submitin interfaceExecutorService- Overrides:
submitin classorg.glassfish.enterprise.concurrent.AbstractManagedExecutorService
-
execute
public void execute(Runnable command)
-
getThreadPoolExecutor
protected ThreadPoolExecutor getThreadPoolExecutor()
- Overrides:
getThreadPoolExecutorin classorg.glassfish.enterprise.concurrent.ManagedExecutorServiceImpl
-
getRuntimeStats
public ManagedExecutorRuntimeStats getRuntimeStats()
- Returns:
- the executor's runtime stats
-
-