Lee Mendelowitz
02/25/2024, 12:43 PMMarvin
02/25/2024, 12:43 PMasyncio.gather
. This means that while subflows generally block the execution of the parent flow until they complete, you can perform them asynchronously and concurrently if you structure your parent flow correctly.
For more detailed guidance on how to compose your flows in this manner, you can refer to the relevant section of the Prefect documentation here.Lee Mendelowitz
02/25/2024, 12:48 PMLee Mendelowitz
02/25/2024, 12:49 PMMarvin
02/25/2024, 12:49 PMasyncio.gather
. However, it doesn't mention any special treatment needed for subflows that are not asynchronous, which implies that they will simply block the parent flow until they complete. There is no indication that a subflow has to be asynchronous.
For more details, you can have a look at the Prefect documentation on composing flows: Prefect Flows.Marvin
02/25/2024, 12:49 PMasyncio.gather
. Unfortunately, it seems that the documentation does not explicitly provide a method for running non-async subflows in parallel.
However, it may be possible to work around this limitation by wrapping synchronous subflows