st2
st2 copied to clipboard
workflow doesn't go ahead next item in case of concurrency: 1
Discussed in https://github.com/StackStorm/st2/discussions/6232
Originally posted by freeyssu September 3, 2024
I usually use with - items
statement for parallel process.
I found out that a failed job with concurrency: 1
config causes that task is termiated immediately even though uncompleted items in loop still remains.
This is my sampe code.
When svr1
is failed with concurrency: 1
, the workflow doesn 't run the action for the remained 2 items svr2
and svr3
. My expectation is that the task completes all 3 items in loop and then mark FAIL result as the first item is failed.
In case of concurrency: 2
or having bigger value, the workflow executes all 3 items and then marks task FAIL result. This is what I expected.
vars
- servers: ["svr1", "svr2", "svr3"]
task:
with:
items: target_server in <% ctx(servers) %>
concurrency: 1
action: pack.action
next:
....
```</div>