Interface ExecutorServiceFactory

  • All Superinterfaces:
    VertxServiceProvider

    public interface ExecutorServiceFactory
    extends VertxServiceProvider
    The interface for a factory used to obtain an external ExecutorService.
    Author:
    Gordon Hutchison
    • Method Detail

      • init

        default void init​(io.vertx.core.internal.VertxBootstrap builder)
        Description copied from interface: VertxServiceProvider
        Let the provider initialize the Vert.x builder.
        Specified by:
        init in interface VertxServiceProvider
        Parameters:
        builder - the builder
      • createExecutor

        ExecutorService createExecutor​(ThreadFactory threadFactory,
                                       Integer concurrency,
                                       Integer maxConcurrency)
        Create an ExecutorService
        Parameters:
        threadFactory - A ThreadFactory which must be used by the created ExecutorService to create threads. Null indicates there is no requirement to use a specific factory.
        concurrency - The target level of concurrency or 0 which indicates unspecified
        maxConcurrency - A hard limit to the level of concurrency required, should be greater than concurrency or 0 which indicates unspecified.
        Returns:
        an ExecutorService that can be used to run tasks