I have a series of pipelines and sub-pipelines, and I wanted to guarantee that the last item in the flow only gets executed after the first ones are done. Something like:
- PipelineA
- Pipeline B, with pipeline.After(future_from_pipeline_a)
- Pipeline C, with pipeline.After(future_from_pipeline_a_and_b)
- Pipeline D (spawned from within PipelineC multiple times in a for loop)
- Pipeline E (want to run this after A-D are in a done or finalizing state)
I'm noticing that Pipeline D (above) sometimes runs in parallel to E, even though we use pipeline.After and pipeline.InOrder statements. All of our pipelines are generator pipelines (yield) but I'm thinking of converting them to just return (synchronous) since the order of execution is critical here and we don't actually use the future values for the next pipeline (each pipeline and sub-pipeline is responsible for fetching it's own state and data to run).
Happy to attach code if needed for further clarification, didn't want to create a large post my first time. Thank you in advance!