Enum PoolType

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<PoolType>

    public enum PoolType
    extends java.lang.Enum<PoolType>
    An enum for the different thread-pools available within PGX.
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      ANALYSIS_POOL
      - multi-threaded - executed concurrent to server thread - sequential to each other (new tasks are only submitted if thread pool idling to exploit full parallelism)
      FAST_TRACK_ANALYSIS_POOL
      - single-threaded - executed concurrent to server thread - concurrent to each other
      IO_POOL
      - multi-threaded - executed concurrent to server thread - sequential to each other (new tasks are only submitted if thread pool idling to exploit full parallelism)
      SERVER_THREAD
      - single-threaded - executed sequentially on server thread
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getName()  
      java.lang.String toString()
      Alias for getName()
      static PoolType valueOf​(java.lang.String name)
      Returns the enum constant of this type with the specified name.
      static PoolType[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      • Methods inherited from class java.lang.Enum

        compareTo, equals, getDeclaringClass, hashCode, name, ordinal, valueOf
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Enum Constant Detail

      • SERVER_THREAD

        public static final PoolType SERVER_THREAD
        - single-threaded - executed sequentially on server thread

        SERVER_THREAD tasks should be really quick, as they block the server thread.

      • FAST_TRACK_ANALYSIS_POOL

        public static final PoolType FAST_TRACK_ANALYSIS_POOL
        - single-threaded - executed concurrent to server thread - concurrent to each other

        Make sure there are no side-effects to global state.

        Side-effects to session state are fine, as there will never be two tasks of the same session be executed concurrently.

      • ANALYSIS_POOL

        public static final PoolType ANALYSIS_POOL
        - multi-threaded - executed concurrent to server thread - sequential to each other (new tasks are only submitted if thread pool idling to exploit full parallelism)

        Make sure there are no side-effects to global state.

        Side-effects to session state are fine, as there will never be two tasks of the same session be executed concurrently.

      • IO_POOL

        public static final PoolType IO_POOL
        - multi-threaded - executed concurrent to server thread - sequential to each other (new tasks are only submitted if thread pool idling to exploit full parallelism)

        Make sure there are no side-effects to the state.

        Side-effects to session state are fine, as there will never be two tasks of the same session be executed concurrently.

    • Method Detail

      • values

        public static PoolType[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (PoolType c : PoolType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static PoolType valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getName

        public java.lang.String getName()
        Returns:
        the name of this thread pool
      • toString

        public java.lang.String toString()
        Alias for getName()
        Overrides:
        toString in class java.lang.Enum<PoolType>
        Returns:
        the name of this thread pool