| 
 | Apache Tomcat 6.0.53 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.catalina.core.StandardThreadExecutor
public class StandardThreadExecutor
| Field Summary | |
|---|---|
| protected  boolean | daemonRun threads in daemon or non-daemon state | 
| protected  java.util.concurrent.ThreadPoolExecutor | executorThe executor we use for this component | 
| protected  int | maxIdleTimeidle time in milliseconds | 
| protected  int | maxQueueSizeThe maximum number of elements that can queue up before we reject them | 
| protected  int | maxThreadsmax number of threads | 
| protected  int | minSpareThreadsmin number of threads | 
| protected  java.lang.String | namethe name of this thread pool | 
| protected  java.lang.String | namePrefixDefault name prefix for the thread name | 
| protected  java.util.concurrent.atomic.AtomicInteger | submittedTasksCountNumber of tasks submitted and not yet completed. | 
| protected  int | threadPriorityDefault thread priority | 
| Fields inherited from interface org.apache.catalina.Lifecycle | 
|---|
| AFTER_START_EVENT, AFTER_STOP_EVENT, BEFORE_START_EVENT, BEFORE_STOP_EVENT, DESTROY_EVENT, INIT_EVENT, PERIODIC_EVENT, START_EVENT, STOP_EVENT | 
| Constructor Summary | |
|---|---|
| StandardThreadExecutor() | |
| Method Summary | |
|---|---|
|  void | addLifecycleListener(LifecycleListener listener)Add a LifecycleEvent listener to this component. | 
|  void | execute(java.lang.Runnable command) | 
|  void | execute(java.lang.Runnable command,
        long timeout,
        java.util.concurrent.TimeUnit unit) | 
|  LifecycleListener[] | findLifecycleListeners()Get the lifecycle listeners associated with this lifecycle. | 
|  int | getActiveCount() | 
|  long | getCompletedTaskCount() | 
|  int | getCorePoolSize() | 
|  int | getLargestPoolSize() | 
|  int | getMaxIdleTime() | 
|  int | getMaxQueueSize() | 
|  int | getMaxThreads() | 
|  int | getMinSpareThreads() | 
|  java.lang.String | getName() | 
|  java.lang.String | getNamePrefix() | 
|  int | getPoolSize() | 
|  int | getQueueSize() | 
|  int | getThreadPriority() | 
|  boolean | isDaemon() | 
|  void | removeLifecycleListener(LifecycleListener listener)Remove a LifecycleEvent listener from this component. | 
|  void | setDaemon(boolean daemon) | 
|  void | setMaxIdleTime(int maxIdleTime) | 
|  void | setMaxQueueSize(int size) | 
|  void | setMaxThreads(int maxThreads) | 
|  void | setMinSpareThreads(int minSpareThreads) | 
|  void | setName(java.lang.String name) | 
|  void | setNamePrefix(java.lang.String namePrefix) | 
|  void | setThreadPriority(int threadPriority) | 
|  void | start()Prepare for the beginning of active use of the public methods of this component. | 
|  void | stop()Gracefully terminate the active use of the public methods of this component. | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
protected int threadPriority
protected boolean daemon
protected java.lang.String namePrefix
protected int maxThreads
protected int minSpareThreads
protected int maxIdleTime
protected java.util.concurrent.ThreadPoolExecutor executor
protected java.lang.String name
protected java.util.concurrent.atomic.AtomicInteger submittedTasksCount
protected int maxQueueSize
| Constructor Detail | 
|---|
public StandardThreadExecutor()
| Method Detail | 
|---|
public void start()
           throws LifecycleException
Lifecycle
start in interface LifecycleLifecycleException - if this component detects a fatal error
  that prevents this component from being used
public void stop()
          throws LifecycleException
Lifecycle
stop in interface LifecycleLifecycleException - if this component detects a fatal error
  that needs to be reported
public void execute(java.lang.Runnable command,
                    long timeout,
                    java.util.concurrent.TimeUnit unit)
public void execute(java.lang.Runnable command)
execute in interface java.util.concurrent.Executorpublic int getThreadPriority()
public boolean isDaemon()
public java.lang.String getNamePrefix()
public int getMaxIdleTime()
public int getMaxThreads()
public int getMinSpareThreads()
public java.lang.String getName()
public void setThreadPriority(int threadPriority)
public void setDaemon(boolean daemon)
public void setNamePrefix(java.lang.String namePrefix)
public void setMaxIdleTime(int maxIdleTime)
public void setMaxThreads(int maxThreads)
public void setMinSpareThreads(int minSpareThreads)
public void setName(java.lang.String name)
public void setMaxQueueSize(int size)
public int getMaxQueueSize()
public void addLifecycleListener(LifecycleListener listener)
addLifecycleListener in interface Lifecyclelistener - The listener to addpublic LifecycleListener[] findLifecycleListeners()
findLifecycleListeners in interface Lifecyclepublic void removeLifecycleListener(LifecycleListener listener)
removeLifecycleListener in interface Lifecyclelistener - The listener to removepublic int getActiveCount()
public long getCompletedTaskCount()
public int getCorePoolSize()
public int getLargestPoolSize()
public int getPoolSize()
public int getQueueSize()
| 
 | Apache Tomcat 6.0.53 | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||