Skip to content

Commit

Permalink
Clarify what happens if an error and result are returned (#1203)
Browse files Browse the repository at this point in the history
  • Loading branch information
Quinn-With-Two-Ns authored Aug 22, 2023
1 parent 9bd67dd commit 27895a9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions workflow/doc.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ The following sections describe what is going on in the above code.
# Declaration
In the Temporal programing model a workflow is implemented with a function. The function declaration specifies the
In the Temporal programming model a workflow is implemented with a function. The function declaration specifies the
parameters the workflow accepts as well as any values it might return.
func SimpleWorkflow(ctx workflow.Context, value string) error
Expand Down Expand Up @@ -140,7 +140,8 @@ Time related functions:
# Failing a Workflow
To mark a workflow as failed all that needs to happen is for the workflow function to return an error via the err
return value.
return value. Returning an error and a result from a workflow are mutually exclusive. If an error is returned from a
workflow then any results returned are ignored.
# Execute Activity
Expand Down

0 comments on commit 27895a9

Please sign in to comment.