I haven't dug into the API reference docs, but just looking at the high level docs for Flow-of-Flows, is it possible to have a flow-of-flows where FlowA is running on a schedule, and then FlowB only runs after FlowA, whenever that happens to be? edit: and these are in two different environments and two different agents so I can't make them one flow
✅ 1
k
Kevin Kho
01/18/2022, 5:43 PM
Yes. Call FlowB at the end of FlowA with the
create_flow_run
task.
y
Yusuf Khan
01/18/2022, 5:45 PM
Okay, and then when I register FlowA I register it with a schedule as normal right? and then I register FlowB without a schedule?
k
Kevin Kho
01/18/2022, 5:47 PM
Yes exactly
y
Yusuf Khan
01/18/2022, 5:48 PM
you are the best, Kevin. thank you!
👍 1
Yusuf Khan
01/24/2022, 12:47 AM
@Kevin Kho Hey I tried the above, it doesn't seem to work? I have FlowA registered with a schedule, FlowB registered without a schedule, and then a parent flow registered without a schedule.
Yusuf Khan
01/24/2022, 12:47 AM
Do I need to remove the schedule from FlowA and add it to the parent flow?
Yusuf Khan
01/24/2022, 12:48 AM
This is what my main function looks like :
Copy code
def main():
with Flow("parent-flow") as flow:
flow_0 = create_flow_run(flow_name="PiCaptureLoad", project_name="PiProject")
wait_for_flow_0 = wait_for_flow_run(flow_0, raise_final_state=True)
flow_1 = create_flow_run(flow_name="EnvironmentalConditions", project_name="PiProject")
flow_1.set_upstream(wait_for_flow_0)
flow.register(project_name="PiProject")
Bring your towel and join one of the fastest growing data communities. Welcome to our second-generation open source orchestration platform, a completely rethought approach to dataflow automation.