-
Notifications
You must be signed in to change notification settings - Fork 79
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Wf-Diagnostics] add troubleshooting guide for activity failures in a…
… workflow (#199)
- Loading branch information
1 parent
2a30577
commit a1c85bd
Showing
2 changed files
with
28 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
src/docs/08-workflow-troubleshooting/02-activity-failures.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
--- | ||
layout: default | ||
title: Activity Failures | ||
permalink: /docs/workflow-troubleshooting/activity-failures | ||
--- | ||
# Activity failures | ||
An activity fails when it encounters an error during its execution. This results in ActivityTaskFailed event in the workflow execution with some details of the error. The different kinds of errors that can be seen in activity failures are listed here. | ||
|
||
## Panic errors | ||
Description: There is a issue in the activity code that is causing a panic. | ||
|
||
Mitigation: Panics are usually caused by nil pointer dereferences or out-of-range array access and should never be expected in a workflow. Check the stack trace provided in the error details to find where in the activity code, the panic is seen. Fix the rootcause of the panic. | ||
|
||
## Custom errors | ||
Description: This is a customised error returned by the activity. | ||
|
||
Mitigation: This is a way of facilitating error handling done within the activity code. Check your activity code to find where it returns a NewCustomError with some information. This is ideally an expected error scenario and should be handled within the workflow that executed the activity. | ||
|
||
Read more about [error handling](https://cadenceworkflow.io/docs/go-client/error-handling/) | ||
|
||
## Generic errors | ||
Description: This is an error returned by the activity. | ||
|
||
Mitigation: This error is caused by something unexpected within the activity code, typically due to a downstream service that your activity communicates with. Cadence does not know anything about it and just puts all unknown errors in this category. Check your activity code to find the potential error cases. This is ideally an unexpected error scenario and should be debugged further to fix the rootcause. | ||
|
||
Read more about [error handling](https://cadenceworkflow.io/docs/go-client/error-handling/) | ||
|