Olve Heitmann
09/20/2025, 10:18 PMMarvin
09/20/2025, 10:18 PMMarvin
09/20/2025, 10:20 PMchild_flow()
inside parent_flow()
), the subflow runs in the same process and the same container as the parent. It creates a nested flow run in the UI but does not provision new infrastructure.
- If you trigger a child via a deployment (e.g., run_deployment("child/deploy-name", ...)
), it creates a separate flow run that is picked up by a worker. With a Docker work pool, that means a new container will be started for the child run. By default it appears as a subflow in the UI (as_subflow=True
), but it’s still a separate container.
Helpful links:
- Run deployments from a flow (run_deployment)
- Serving flows with Docker workers
- Workflow design patterns and subflows
If you want everything to stay in one container, call the child flow directly. If you want isolation/parallelism or different infra for children, use run_deployment
. Happy to share a small example if helpful.