Skip to content

Commit

Permalink
Merge pull request #1005 from matthias-pichler/matthias-pichler/defin…
Browse files Browse the repository at this point in the history
…e-context-1001

Document context of `task.if`
  • Loading branch information
cdavernas committed Aug 30, 2024
2 parents a73a32b + 4567349 commit 62ff5e8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion dsl-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ The Serverless Workflow DSL defines a list of [tasks](#task) that **must be** su
| Name | Type | Required | Description|
|:--|:---:|:---:|:---|
| if | `string` | `no` | A [`runtime expression`](dsl.md#runtime-expressions), if any, used to determine whether or not the task should be run.<br>The task is considered skipped if not run. |
| if | `string` | `no` | A [`runtime expression`](dsl.md#runtime-expressions), if any, used to determine whether or not the task should be run.<br>The task is considered skipped if not run, and the *raw* task input becomes the task's output. The expression is evaluated against the *raw* task input before any other expression of the task. |
| input | [`input`](#input) | `no` | An object used to customize the task's input and to document its schema, if any. |
| output | [`output`](#output) | `no` | An object used to customize the task's output and to document its schema, if any. |
| export | [`export`](#export) | `no` | An object used to customize the content of the workflow context. |
Expand Down
4 changes: 3 additions & 1 deletion dsl.md
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,7 @@ flowchart TD
workflow_transformed_input{{Transformed Workflow Input}}
task_raw_input{{Raw Task Input}}
task_if[Task: <code>if</code>]
task_input_schema[\Task: <code>input.schema</code>/]
task_input_from[Task: <code>input.from</code>]
task_transformed_input{{Transformed Task Input}}
Expand All @@ -282,7 +283,8 @@ flowchart TD
subgraph Task
task_raw_input -- Validated by --> task_input_schema
task_raw_input -- Passed to --> task_if
task_if -- Validated by --> task_input_schema
task_input_schema -- Passed to --> task_input_from
task_input_from -- Produces --> task_transformed_input
task_transformed_input -- Set as --> input_arg
Expand Down

0 comments on commit 62ff5e8

Please sign in to comment.