StackStorm / StackStorm/st2

re-run a failed action didn't inherit parent execution id

Open
#3,568 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

complexity:medium enhancement
Dominant language
Python
Stars
6.5k
Forks
787
PR merge metrics
No merged PRs in 30d

Description

Dear support,

If we re-run failed actions in workflow, the new separated action execution didn't inherit parent execution id, means we can't find "parent" element in the new action execution which is a lot trouble for us, since we want the new one show up in the same workflow chain.
if we use api:
/api/v1/executions/{id}/children
the new one is not able to get since it doesn't has parent.

so, my question is:

  1. Is it possible to re-run current action instead create a separated one, in some scenario like, external system fix problem, and then we need re-run the failed one to get it through.
  2. Is it possible to post an new API to get children by trace_context id? (seems the new actions hold the same trace id, so we can get all actions relate to trace id)

"context": {
"trace_context": {
"id_": "5966f6ff570e014c3431c471"
},
"re-run": {
"ref": "5967015f570e014771c04345"
},
"user": "st2admin"
}

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the rerun behavior described for failed workflow actions and the /api/v1/executions/{id}/children endpoint. Compare the proposed options: preserving the parent execution relationship or querying related actions by trace_context id. Done should include a decided API or execution-model change that keeps rerun actions discoverable in the workflow chain.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
api, backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.