Skip to content

Update Set task to support direct runtime expression #1086

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
6e99bae
Fix #1076 - Make detail and title a runtime expression in the schema
ricardozanini Feb 5, 2025
947c368
Add string as anyOf
ricardozanini Feb 5, 2025
a035fee
feat(schema): allow expressions in HTTP query and headers (#1080)
toxik Feb 10, 2025
deef55a
update DSL version from alpha1, alpha2, alpha5 to 1.0.0 across multip…
geomagilles Feb 18, 2025
f3ebd9a
Fix the description of flow directives and addressed few issues in ds…
geomagilles Feb 24, 2025
f2d0501
Fix broken link in README.md (#1084)
mbroz2 Mar 3, 2025
d73165a
Set task to support direct runtime expression
nyamathshaik Mar 9, 2025
cfc7e75
updated workflow schema along with table fix
nyamathshaik Mar 9, 2025
dbc4529
updating the schema
nyamathshaik Mar 9, 2025
86fc361
addressing PR comment reviews
nyamathshaik Mar 10, 2025
3a05358
removing unwanted set example
nyamathshaik Mar 10, 2025
7a0e4aa
Update dsl-reference.md
nyamathshaik Mar 10, 2025
83778e5
Update dsl-reference.md
nyamathshaik Mar 10, 2025
7c05b93
Update dsl-reference.md
nyamathshaik Mar 10, 2025
052c34f
reverting back original set example change
nyamathshaik Mar 10, 2025
33ec5e1
Update dsl-reference.md
nyamathshaik Mar 10, 2025
d25ca39
passing the set example as object
nyamathshaik Mar 10, 2025
5f69853
reverting to original
nyamathshaik Mar 15, 2025
25a7d30
Add a new file that compares the Serverless Workflow to other popular…
cdavernas Mar 10, 2025
3951cd0
Fix a the `catalog` link in the `use` section table (#1088)
cdavernas Mar 10, 2025
6b85537
Merge branch 'main' into feat/set-task-support-direct-runtime-expression
nyamathshaik Mar 19, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions dsl-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -962,8 +962,8 @@ A task used to set data.
##### Properties

| Name | Type | Required | Description |
|:--|:---:|:---:|:---|
| set | `object` | `yes` | A name/value mapping of the data to set. |
|:-------|:------:|:----------:|:-------------|
| set | `map` <br> `string` | `yes` | The data to set.<br>*Can be an object or a direct runtime expression.* |

##### Examples

Expand All @@ -979,6 +979,8 @@ do:
shape: circle
size: ${ .configuration.size }
fill: ${ .configuration.fill }
- setColor:
set: ${ .configuration.color }
```

#### Switch
Expand Down
13 changes: 13 additions & 0 deletions examples/set-expression.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
document:
dsl: '1.0.0'
namespace: test
name: set
version: '0.1.0'
schedule:
on:
one:
with:
type: io.serverlessworkflow.samples.events.trigger.v1
do:
- initialize:
set: ${ $workflow.input[0] }
2 changes: 1 addition & 1 deletion examples/set.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ schedule:
one:
with:
type: io.serverlessworkflow.samples.events.trigger.v1
do:
do:
- initialize:
set:
startEvent: ${ $workflow.input[0] }
8 changes: 5 additions & 3 deletions schema/workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -767,11 +767,13 @@ $defs:
unevaluatedProperties: false
properties:
set:
type: object
oneOf:
- type: object
minProperties: 1
additionalProperties: true
- type: string
title: SetTaskConfiguration
description: The data to set.
minProperties: 1
additionalProperties: true
switchTask:
type: object
$ref: '#/$defs/taskBase'
Expand Down