Enum Class TaskStatus

Object
Enum<TaskStatus>
akka.javasdk.agent.task.TaskStatus
All Implemented Interfaces:
Serializable, Comparable<TaskStatus>, Constable

public enum TaskStatus extends Enum<TaskStatus>
The lifecycle status of a Task.

PENDING, ASSIGNED, IN_PROGRESS, and RESULT_REJECTED are non-terminal. COMPLETED, FAILED, and CANCELLED are terminal.

  • Enum Constant Details

    • PENDING

      public static final TaskStatus PENDING
      Created but not yet assigned to an agent.
    • ASSIGNED

      public static final TaskStatus ASSIGNED
      Assigned to an agent but not yet started.
    • IN_PROGRESS

      public static final TaskStatus IN_PROGRESS
      An agent is actively working on it.
    • RESULT_REJECTED

      public static final TaskStatus RESULT_REJECTED
      A TaskRule rejected the result. The agent retries on the next iteration.
    • COMPLETED

      public static final TaskStatus COMPLETED
      Finished successfully with a typed result.
    • FAILED

      public static final TaskStatus FAILED
      Failed during execution, either by the model's decision or because the iteration limit was reached.
    • CANCELLED

      public static final TaskStatus CANCELLED
      Terminated before execution began, for example by a dependency failure.
  • Method Details

    • values

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

      public static TaskStatus valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified name
      NullPointerException - if the argument is null