Class 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
      • Nested classes/interfaces inherited from interface org.eclipse.jetty.util.thread.ThreadPool

        org.eclipse.jetty.util.thread.ThreadPool.SizedThreadPool
      • Nested classes/interfaces inherited from interface org.eclipse.jetty.util.thread.TryExecutor

        org.eclipse.jetty.util.thread.TryExecutor.NoTryExecutor
    • Field Summary

      • Fields inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle

        FAILED, RUNNING, STARTED, STARTING, STOPPED, STOPPING
      • Fields inherited from interface org.eclipse.jetty.util.component.Dumpable

        KEY
      • Fields inherited from interface org.eclipse.jetty.util.thread.TryExecutor

        NO_TRY
    • 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
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface org.eclipse.jetty.util.component.Dumpable

        dumpSelf
    • Constructor Detail

      • DelegatingThreadPool

        public DelegatingThreadPool​(java.util.concurrent.Executor executor)
    • 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 interface java.util.concurrent.Executor
        Specified by:
        execute in interface org.eclipse.jetty.util.thread.TryExecutor
      • tryExecute

        public boolean tryExecute​(java.lang.Runnable task)
        Specified by:
        tryExecute in interface org.eclipse.jetty.util.thread.TryExecutor
      • getIdleThreads

        public int getIdleThreads()
        Specified by:
        getIdleThreads in interface org.eclipse.jetty.util.thread.ThreadPool
      • getThreads

        public int getThreads()
        Specified by:
        getThreads in interface org.eclipse.jetty.util.thread.ThreadPool
      • isLowOnThreads

        public boolean isLowOnThreads()
        Specified by:
        isLowOnThreads in interface org.eclipse.jetty.util.thread.ThreadPool
      • join

        public void join()
                  throws java.lang.InterruptedException
        Specified by:
        join in interface org.eclipse.jetty.util.thread.ThreadPool
        Throws:
        java.lang.InterruptedException
      • doStop

        protected void doStop()
                       throws java.lang.Exception
        Overrides:
        doStop in class org.eclipse.jetty.util.component.ContainerLifeCycle
        Throws:
        java.lang.Exception