Table of Contents

Enum WorkflowTaskFailedCause

Namespace
Temporalio.Api.Enums.V1
Assembly
Temporalio.dll

Workflow tasks can fail for various reasons. Note that some of these reasons can only originate from the server, and some of them can only originate from the SDK/worker.

public enum WorkflowTaskFailedCause

Fields

[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_BINARY")] BadBinary = 21
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_CANCEL_TIMER_ATTRIBUTES")] BadCancelTimerAttributes = 5
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_CANCEL_WORKFLOW_EXECUTION_ATTRIBUTES")] BadCancelWorkflowExecutionAttributes = 9
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_COMPLETE_WORKFLOW_EXECUTION_ATTRIBUTES")] BadCompleteWorkflowExecutionAttributes = 7
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_CONTINUE_AS_NEW_ATTRIBUTES")] BadContinueAsNewAttributes = 11
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_FAIL_WORKFLOW_EXECUTION_ATTRIBUTES")] BadFailWorkflowExecutionAttributes = 8
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_MODIFY_WORKFLOW_PROPERTIES_ATTRIBUTES")] BadModifyWorkflowPropertiesAttributes = 25
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_RECORD_MARKER_ATTRIBUTES")] BadRecordMarkerAttributes = 6
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_REQUEST_CANCEL_ACTIVITY_ATTRIBUTES")] BadRequestCancelActivityAttributes = 3
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_REQUEST_CANCEL_EXTERNAL_WORKFLOW_EXECUTION_ATTRIBUTES")] BadRequestCancelExternalWorkflowExecutionAttributes = 10
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_SCHEDULE_ACTIVITY_ATTRIBUTES")] BadScheduleActivityAttributes = 2
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_SEARCH_ATTRIBUTES")] BadSearchAttributes = 23
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_SIGNAL_INPUT_SIZE")] BadSignalInputSize = 19
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_SIGNAL_WORKFLOW_EXECUTION_ATTRIBUTES")] BadSignalWorkflowExecutionAttributes = 15
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_START_CHILD_EXECUTION_ATTRIBUTES")] BadStartChildExecutionAttributes = 16
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_START_TIMER_ATTRIBUTES")] BadStartTimerAttributes = 4
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_BAD_UPDATE_WORKFLOW_EXECUTION_MESSAGE")] BadUpdateWorkflowExecutionMessage = 30

Workflow execution update message (update.Acceptance, update.Rejection, or update.Response) has wrong format, or missing required fields.

[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_FAILOVER_CLOSE_COMMAND")] FailoverCloseCommand = 18
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_FORCE_CLOSE_COMMAND")] ForceCloseCommand = 17
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_NON_DETERMINISTIC_ERROR")] NonDeterministicError = 24

The worker encountered a mismatch while replaying history between what was expected, and what the workflow code actually did.

[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_PENDING_ACTIVITIES_LIMIT_EXCEEDED")] PendingActivitiesLimitExceeded = 27

Starting a new activity would cause this workflow to exceed its limit of pending activities that we track.

[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_PENDING_CHILD_WORKFLOWS_LIMIT_EXCEEDED")] PendingChildWorkflowsLimitExceeded = 26

We send the below error codes to users when their requests would violate a size constraint of their workflow. We do this to ensure that the state of their workflow does not become too large because that can cause severe performance degradation. You can modify the thresholds for each of these errors within your dynamic config.

Spawning a new child workflow would cause this workflow to exceed its limit of pending child workflows.

[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_PENDING_REQUEST_CANCEL_LIMIT_EXCEEDED")] PendingRequestCancelLimitExceeded = 29

Similarly, we have a buffer of pending requests to cancel other workflows. We return this error when our capacity for pending cancel requests is already reached.

[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_PENDING_SIGNALS_LIMIT_EXCEEDED")] PendingSignalsLimitExceeded = 28

A workflow has a buffer of signals that have not yet reached their destination. We return this error when sending a new signal would exceed the capacity of this buffer.

[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_RESET_STICKY_TASK_QUEUE")] ResetStickyTaskQueue = 13

The worker wishes to fail the task and have the next one be generated on a normal, not sticky queue. Generally workers should prefer to use the explicit ResetStickyTaskQueue RPC call.

[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_RESET_WORKFLOW")] ResetWorkflow = 20
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_SCHEDULE_ACTIVITY_DUPLICATE_ID")] ScheduleActivityDuplicateId = 22
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_START_TIMER_DUPLICATE_ID")] StartTimerDuplicateId = 12
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_UNHANDLED_COMMAND")] UnhandledCommand = 1

Between starting and completing the workflow task (with a workflow completion command), some new command (like a signal) was processed into workflow history. The outstanding task will be failed with this reason, and a worker must pick up a new task.

[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_UNHANDLED_UPDATE")] UnhandledUpdate = 31

Similar to WORKFLOW_TASK_FAILED_CAUSE_UNHANDLED_COMMAND, but for updates.

[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_UNSPECIFIED")] Unspecified = 0
[OriginalName("WORKFLOW_TASK_FAILED_CAUSE_WORKFLOW_WORKER_UNHANDLED_FAILURE")] WorkflowWorkerUnhandledFailure = 14