Hi community/<@U021J8TU753> I’ve been struggling w...
# ask-community
m
Hi community/@Prefect I’ve been struggling with parallel subflow runs. Using asyncio trick is allowing them to run in parallel, but still on the same agent that picked up the main flow. Is there a way to add the subflows to a work queue, so they can be picked up by several agents?
1
t
I use a submit-flow task with
run_deployment
to achieve this 🙂
gratitude thank you 2
2
m
Thanks! Is it possible to run it from another deployment? For example:
Copy code
@flow 
def submit-flow():
    run_deployment(name="a")
    run_deployment(name="b")

deployment = Deployment.build_from_flow(
    flow=submit-flow,
    name="submit-flow", 
    work_queue_name="demo",
)
deployment.apply()
It works, thanks!
1
🚀 1