Class ScheduledThreadPoolSupplier.Builder

    • Method Detail

      • daemon

        public ScheduledThreadPoolSupplier.Builder daemon​(boolean daemon)
        Is daemon of the thread pool executor.
        Parameters:
        daemon - whether the threads are daemon threads
        Returns:
        updated builder instance
      • threadNamePrefix

        public ScheduledThreadPoolSupplier.Builder threadNamePrefix​(String threadNamePrefix)
        Name prefix for threads in this thread pool executor.
        Parameters:
        threadNamePrefix - prefix of a thread name
        Returns:
        updated builder instance
      • prestart

        public ScheduledThreadPoolSupplier.Builder prestart​(boolean prestart)
        Whether to prestart core threads in this thread pool executor.
        Parameters:
        prestart - whether to prestart the threads
        Returns:
        updated builder instance
      • config

        public ScheduledThreadPoolSupplier.Builder config​(Config config)
        Load all properties for this thread pool executor from configuration. Expected keys:
        • core-pool-size
        • is-daemon
        • thread-name-prefix
        • should-prestart
        Parameters:
        config - config located on the key of executor-service
        Returns:
        updated builder instance