Package org.eclipse.jetty.http.spi
Class DelegatingThreadPool
- java.lang.Object
-
- org.eclipse.jetty.util.component.AbstractLifeCycle
-
- org.eclipse.jetty.util.component.ContainerLifeCycle
-
- org.eclipse.jetty.http.spi.DelegatingThreadPool
-
- All Implemented Interfaces:
java.util.concurrent.Executor
,org.eclipse.jetty.util.component.Container
,org.eclipse.jetty.util.component.Destroyable
,org.eclipse.jetty.util.component.Dumpable
,org.eclipse.jetty.util.component.LifeCycle
,org.eclipse.jetty.util.thread.ThreadPool
,org.eclipse.jetty.util.thread.TryExecutor
public class DelegatingThreadPool extends org.eclipse.jetty.util.component.ContainerLifeCycle implements org.eclipse.jetty.util.thread.ThreadPool, org.eclipse.jetty.util.thread.TryExecutor
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
org.eclipse.jetty.util.component.AbstractLifeCycle.AbstractLifeCycleListener
-
Nested classes/interfaces inherited from interface org.eclipse.jetty.util.component.Container
org.eclipse.jetty.util.component.Container.InheritedListener, org.eclipse.jetty.util.component.Container.Listener
-
Nested classes/interfaces inherited from interface org.eclipse.jetty.util.component.LifeCycle
org.eclipse.jetty.util.component.LifeCycle.Listener
-
-
Constructor Summary
Constructors Constructor Description DelegatingThreadPool(java.util.concurrent.Executor executor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
doStop()
void
execute(java.lang.Runnable job)
java.util.concurrent.Executor
getExecutor()
int
getIdleThreads()
int
getThreads()
boolean
isLowOnThreads()
void
join()
void
setExecutor(java.util.concurrent.Executor executor)
boolean
tryExecute(java.lang.Runnable task)
-
Methods inherited from class org.eclipse.jetty.util.component.ContainerLifeCycle
addBean, addBean, addBean, addEventListener, addManaged, contains, destroy, doStart, dump, dump, dump, dump, dump, dumpBeans, dumpObject, dumpObjects, dumpStdErr, dumpThis, getBean, getBeans, getBeans, getContainedBeans, getContainedBeans, isAuto, isManaged, isUnmanaged, manage, removeBean, removeBeans, removeEventListener, setBeans, setStopTimeout, start, stop, unmanage, updateBean, updateBean, updateBeans
-
Methods inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
addLifeCycleListener, getState, getState, getStopTimeout, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop, toString
-
-
-
-
Method Detail
-
getExecutor
public java.util.concurrent.Executor getExecutor()
-
setExecutor
public void setExecutor(java.util.concurrent.Executor executor)
-
execute
public void execute(java.lang.Runnable job)
- Specified by:
execute
in interfacejava.util.concurrent.Executor
- Specified by:
execute
in interfaceorg.eclipse.jetty.util.thread.TryExecutor
-
tryExecute
public boolean tryExecute(java.lang.Runnable task)
- Specified by:
tryExecute
in interfaceorg.eclipse.jetty.util.thread.TryExecutor
-
getIdleThreads
public int getIdleThreads()
- Specified by:
getIdleThreads
in interfaceorg.eclipse.jetty.util.thread.ThreadPool
-
getThreads
public int getThreads()
- Specified by:
getThreads
in interfaceorg.eclipse.jetty.util.thread.ThreadPool
-
isLowOnThreads
public boolean isLowOnThreads()
- Specified by:
isLowOnThreads
in interfaceorg.eclipse.jetty.util.thread.ThreadPool
-
join
public void join() throws java.lang.InterruptedException
- Specified by:
join
in interfaceorg.eclipse.jetty.util.thread.ThreadPool
- Throws:
java.lang.InterruptedException
-
doStop
protected void doStop() throws java.lang.Exception
- Overrides:
doStop
in classorg.eclipse.jetty.util.component.ContainerLifeCycle
- Throws:
java.lang.Exception
-
-