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:
Executor, org.eclipse.jetty.util.component.Container, org.eclipse.jetty.util.component.Destroyable, org.eclipse.jetty.util.component.Dumpable, org.eclipse.jetty.util.component.Dumpable.DumpableContainer, org.eclipse.jetty.util.component.LifeCycle, org.eclipse.jetty.util.thread.ThreadPool, org.eclipse.jetty.util.thread.TryExecutor, org.eclipse.jetty.util.VirtualThreads.Configurable

public class DelegatingThreadPool extends org.eclipse.jetty.util.component.ContainerLifeCycle implements org.eclipse.jetty.util.thread.ThreadPool, org.eclipse.jetty.util.thread.TryExecutor, org.eclipse.jetty.util.VirtualThreads.Configurable
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle

    org.eclipse.jetty.util.component.AbstractLifeCycle.AbstractLifeCycleListener, org.eclipse.jetty.util.component.AbstractLifeCycle.StopException

    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.Dumpable

    org.eclipse.jetty.util.component.Dumpable.DumpableContainer

    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, 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
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
     
    void
     
     
    int
     
    int
     
     
    boolean
     
    void
     
    void
     
    void
     
    boolean
     

    Methods inherited from class org.eclipse.jetty.util.component.ContainerLifeCycle

    addBean, addBean, addEventListener, addManaged, contains, destroy, doStart, dump, dump, dump, dumpObjects, dumpStdErr, getBean, getBeans, getBeans, getContainedBeans, getContainedBeans, installBean, installBean, isAuto, isManaged, isUnmanaged, manage, removeBean, removeBeans, removeEventListener, setBeans, start, stop, unmanage, updateBean, updateBean, updateBeans, updateBeans

    Methods inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle

    getEventListeners, getState, getState, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, setEventListeners, 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.Container

    getCachedBeans, getEventListeners

    Methods inherited from interface org.eclipse.jetty.util.component.Dumpable

    dumpSelf

    Methods inherited from interface org.eclipse.jetty.util.component.Dumpable.DumpableContainer

    isDumpable

    Methods inherited from interface org.eclipse.jetty.util.VirtualThreads.Configurable

    isUseVirtualThreads, setUseVirtualThreads
  • Constructor Details

    • DelegatingThreadPool

      public DelegatingThreadPool(Executor executor)
  • Method Details

    • getExecutor

      public Executor getExecutor()
    • setExecutor

      public void setExecutor(Executor executor)
    • execute

      public void execute(Runnable job)
      Specified by:
      execute in interface Executor
      Specified by:
      execute in interface org.eclipse.jetty.util.thread.TryExecutor
    • tryExecute

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

      public Executor getVirtualThreadsExecutor()
      Specified by:
      getVirtualThreadsExecutor in interface org.eclipse.jetty.util.VirtualThreads.Configurable
    • setVirtualThreadsExecutor

      public void setVirtualThreadsExecutor(Executor executor)
      Specified by:
      setVirtualThreadsExecutor in interface org.eclipse.jetty.util.VirtualThreads.Configurable
    • 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 InterruptedException
      Specified by:
      join in interface org.eclipse.jetty.util.thread.ThreadPool
      Throws:
      InterruptedException
    • doStop

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