类 ExecutorFactory.Managed

java.lang.Object
com.alibaba.nacos.common.executor.ExecutorFactory.Managed
封闭类:
ExecutorFactory

public static final class ExecutorFactory.Managed extends Object
  • 构造器详细资料

    • Managed

      public Managed()
  • 方法详细资料

    • newSingleExecutorService

      public static ExecutorService newSingleExecutorService(String group)
      Create a new single executor service with default thread factory and register to manager.
      参数:
      group - group name
      返回:
      new single executor service
    • newSingleExecutorService

      public static ExecutorService newSingleExecutorService(String group, ThreadFactory threadFactory)
      Create a new single executor service with input thread factory and register to manager.
      参数:
      group - group name
      threadFactory - thread factory
      返回:
      new single executor service
    • newFixedExecutorService

      public static ExecutorService newFixedExecutorService(String group, int nThreads)
      Create a new fixed executor service with default thread factory and register to manager.
      参数:
      group - group name
      nThreads - thread number
      返回:
      new fixed executor service
    • newFixedExecutorService

      public static ExecutorService newFixedExecutorService(String group, int nThreads, ThreadFactory threadFactory)
      Create a new fixed executor service with input thread factory and register to manager.
      参数:
      group - group name
      nThreads - thread number
      threadFactory - thread factory
      返回:
      new fixed executor service
    • newSingleScheduledExecutorService

      public static ScheduledExecutorService newSingleScheduledExecutorService(String group, ThreadFactory threadFactory)
      Create a new single scheduled executor service with input thread factory and register to manager.
      参数:
      group - group name
      threadFactory - thread factory
      返回:
      new single scheduled executor service
    • newScheduledExecutorService

      public static ScheduledExecutorService newScheduledExecutorService(String group, int nThreads, ThreadFactory threadFactory)
      Create a new scheduled executor service with input thread factory and register to manager.
      参数:
      group - group name
      nThreads - thread number
      threadFactory - thread factory
      返回:
      new scheduled executor service
    • newCustomerThreadExecutor

      public static ThreadPoolExecutor newCustomerThreadExecutor(String group, int coreThreads, int maxThreads, long keepAliveTimeMs, ThreadFactory threadFactory)
      Create a new custom executor service and register to manager.
      参数:
      group - group name
      coreThreads - core thread number
      maxThreads - max thread number
      keepAliveTimeMs - keep alive time milliseconds
      threadFactory - thread facotry
      返回:
      new custom executor service