Interface IExecutorFactory


  • @Deprecated
    public interface IExecutorFactory
    Deprecated.
    - This interface stands deprecated as of TestNG v7.9.0.
    Represents the capabilities to be possessed by any implementation that can be plugged into TestNG to execute nodes from a IDynamicGraph object.
    • Method Detail

      • newSuiteExecutor

        ITestNGThreadPoolExecutor newSuiteExecutor​(java.lang.String name,
                                                   IDynamicGraph<ISuite> graph,
                                                   IThreadWorkerFactory<ISuite> factory,
                                                   int corePoolSize,
                                                   int maximumPoolSize,
                                                   long keepAliveTime,
                                                   java.util.concurrent.TimeUnit unit,
                                                   java.util.concurrent.BlockingQueue<java.lang.Runnable> workQueue,
                                                   java.util.Comparator<ISuite> comparator)
        Deprecated.
        Parameters:
        name - - The name to be used as a prefix for all created threads.
        graph - - A IDynamicGraph object that represents the graph of methods and the hierarchy of execution.
        factory - - A IThreadWorkerFactory factory to create threads.
        corePoolSize - the number of threads to keep in the pool, even if they are idle, unless allowCoreThreadTimeOut is set
        maximumPoolSize - the maximum number of threads to allow in the pool
        keepAliveTime - when the number of threads is greater than the core, this is the maximum time that excess idle threads will wait for new tasks before terminating.
        unit - the time unit for the keepAliveTime argument
        workQueue - the queue to use for holding tasks before they are executed. This queue will hold only the Runnable tasks submitted by the execute method.
        comparator - - A Comparator to order nodes internally.
        Returns:
        - A new ITestNGThreadPoolExecutor that is capable of running suites in parallel.
      • newTestMethodExecutor

        ITestNGThreadPoolExecutor newTestMethodExecutor​(java.lang.String name,
                                                        IDynamicGraph<ITestNGMethod> graph,
                                                        IThreadWorkerFactory<ITestNGMethod> factory,
                                                        int corePoolSize,
                                                        int maximumPoolSize,
                                                        long keepAliveTime,
                                                        java.util.concurrent.TimeUnit unit,
                                                        java.util.concurrent.BlockingQueue<java.lang.Runnable> workQueue,
                                                        java.util.Comparator<ITestNGMethod> comparator)
        Deprecated.
        Parameters:
        name - - The name to be used as a prefix for all created threads.
        graph - - A IDynamicGraph object that represents the graph of methods and the hierarchy of execution.
        factory - - A IThreadWorkerFactory factory to create threads.
        corePoolSize - the number of threads to keep in the pool, even if they are idle, unless allowCoreThreadTimeOut is set
        maximumPoolSize - the maximum number of threads to allow in the pool
        keepAliveTime - when the number of threads is greater than the core, this is the maximum time that excess idle threads will wait for new tasks before terminating.
        unit - the time unit for the keepAliveTime argument
        workQueue - the queue to use for holding tasks before they are executed. This queue will hold only the Runnable tasks submitted by the execute method.
        comparator - - A Comparator to order nodes internally.
        Returns:
        - A new ITestNGThreadPoolExecutor that is capable of running test methods in parallel.