Skip to main content

Completion Timeout Configuration

The CompletionTimeoutConfiguration class specifies how the system should respond when a step does not complete within a predefined timeframe. Unlike start timeouts, completion timeouts do not support retries, focusing instead on immediate actions such as failing the step or taking no action. This configuration ensures that long-running or stalled steps are handled appropriately, maintaining the integrity and efficiency of the overall process.

Data Model

CompletionTimeoutConfiguration

The CompletionTimeoutConfiguration class encapsulates the settings required to manage completion timeouts for a process step.

FieldTypeDescription
durationlongThe maximum duration (in milliseconds) to wait for a step to complete before triggering the timeout.
actionStepErrorActionThe action to perform when a timeout occurs. Options are FAIL, RETRY, or NONE.
runRequestProcessRequestThe request details to initiate a new process run if applicable.

StepErrorAction Enum

The StepErrorAction enum defines the possible actions to take when a step encounters an error or timeout during execution.

ActionDescription
FAILMarks the step as failed and stops the process execution.
NONETakes no action, allowing the process to continue despite the error or timeout.
RETRYNOT APPLICABLE
note

In the context of CompletionTimeoutConfiguration, the RETRY action is not supported. Only FAIL and NONE are applicable.

Process Request

The ProcessRequest class encapsulates the details required to initiate a new process run. It includes metadata and input parameters necessary for executing the process.

FieldTypeDescription
nameStringThe name of the process to be executed.
namespaceStringThe namespace under which the process is categorized.
versionIntegerThe version number of the process definition.
idStringA unique identifier for the process run.
correlationIdStringAn identifier used to correlate related process runs or events.
inputMap<String, Object>A map of input parameters provided to the process during initiation.

How does Completion Timeout work?

The completion timeout mechanism ensures that each step within a process completes within an expected timeframe. If a step does not complete within the specified duration, the system takes action based on the action defined in the CompletionTimeoutConfiguration.

Actions

  • FAIL:

    • Description: Marks the step as failed.
    • Effect: Stops the process execution and triggers any defined error handling mechanisms.
  • NONE:

    • Description: Takes no action.
    • Effect: Allows the process to continue without interruption, even if the step does not complete within the specified duration. (useful to just trigger a run request and continue)
note

In the context of CompletionTimeoutConfiguration, the RETRY action is not supported. Only FAIL and NONE are applicable.