Track execution origin

Registered by Winson Chan on 2015-02-10

If workflow contains several nested levels of subflows, it is really hard to query for all related tasks under the original workflow execution. Can we add a field in the execution and task DB to track the original workflow execution ID? And then add appropriate API/CLI query to filter by origin?

Blueprint information

Renat Akhmerov
Winson Chan
ali abdelal
Series goal:
Accepted for ussuri
Milestone target:
milestone icon ussuri-2
Started by
Renat Akhmerov on 2020-01-15
Completed by
Renat Akhmerov on 2020-01-28

Related branches



rakhmerov: Seems like a very needed BP, I came across the same inconvenience and was trying to come up with a solution for that.

melisha: I agree with this concept but I don't think all sub-executions should be linked to the origin.

I suggest to add the "task_execution_id" to WF execution-list/get API response - this already exists in the DB and only need to be exposed in the API/UI.
This will allow building the execution graph from the execution list.

Another API that can be helpful for ease and performance is to add an "executions/{id}/executions" API which will list all the sub-workflow executions.
This API can also have a "nested_depth" query to get more than one level.

rakhmerov: melisha, I agree with those API additions. Great idea. As far as 'task_execution_id' also yes, it's easy to do.

12/23/2019, rakhmerov: so we now have "root_execution_id" that can be used to filter executions by the parent most execution. We need to make sure all it works well and exists in the API/CLI. And also implement other mentioned capabilities, if needed.

Gerrit topic:

Addressed by:
    Added a new API to fetch sub-execution of an execution or a task

Addressed by:
    Add new CLI commands for sub-executions new API endpoints


Work Items

This blueprint contains Public information 
Everyone can see this information.