Enum ExecutionState

java.lang.Object
java.lang.Enum<ExecutionState>
org.apache.flink.runtime.execution.ExecutionState
All Implemented Interfaces:
Serializable, Comparable<ExecutionState>

public enum ExecutionState extends Enum<ExecutionState>
An enumeration of all states that a task can be in during its execution. Tasks usually start in the state CREATED and switch states according to this diagram:

  CREATED  -> SCHEDULED -> DEPLOYING -> INITIALIZING -> RUNNING -> FINISHED
     |            |            |          |              |
     |            |            |    +-----+--------------+
     |            |            V    V
     |            |         CANCELLING -----+----> CANCELED
     |            |                         |
     |            +-------------------------+
     |
     |                                   ... -> FAILED
     V
 RECONCILING  -> INITIALIZING | RUNNING | FINISHED | CANCELED | FAILED

 

It is possible to enter the RECONCILING state from CREATED state if job manager fail over, and the RECONCILING state can switch into any existing task state.

It is possible to enter the FAILED state from any other state.

The states FINISHED, CANCELED, and FAILED are considered terminal states.

  • Enum Constant Details

    • CREATED

      public static final ExecutionState CREATED
    • SCHEDULED

      public static final ExecutionState SCHEDULED
    • DEPLOYING

      public static final ExecutionState DEPLOYING
    • RUNNING

      public static final ExecutionState RUNNING
    • FINISHED

      public static final ExecutionState FINISHED
      This state marks "successfully completed". It can only be reached when a program reaches the "end of its input". The "end of input" can be reached when consuming a bounded input (fix set of files, bounded query, etc) or when stopping a program (not cancelling!) which make the input look like it reached its end at a specific point.
    • CANCELING

      public static final ExecutionState CANCELING
    • CANCELED

      public static final ExecutionState CANCELED
    • FAILED

      public static final ExecutionState FAILED
    • RECONCILING

      public static final ExecutionState RECONCILING
    • INITIALIZING

      public static final ExecutionState INITIALIZING
      Restoring last possible valid state of the task if it has it.
  • Method Details

    • values

      public static ExecutionState[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static ExecutionState valueOf(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:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null
    • isTerminal

      public boolean isTerminal()