Class ThreadPoolUtils


  • public class ThreadPoolUtils
    extends java.lang.Object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void shutdownAndAwaitTermination​(java.util.concurrent.ExecutorService pool, int timeoutSeconds)
      Shutdown a ExecutorService.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • shutdownAndAwaitTermination

        public static void shutdownAndAwaitTermination​(java.util.concurrent.ExecutorService pool,
                                                       int timeoutSeconds)
        Shutdown a ExecutorService.

        Source: https://docs.oracle.com/javase/7/docs/api/java/util/concurrent/ExecutorService.html

        Parameters:
        executor - the ExecutorService
        timeoutSeconds - the applied timeout (is applied twice in the worst case)