Alper
Alper13mo ago

Flow loop

i currently have a flow with a single step. it's a python script that does some parallel processing: 1. fetch n entries from a database 2. in parallel process a long running task for each of the n entries i'd like to split the script into multiple smaller parts and use the flow loops or branches for that, but i'm not sure how that works with a dynamic number of parallel branches. any ideas?
4 Replies
Sindre
Sindre13mo ago
Use the flow loop. What have you tried so far?
Alper
Alper13mo ago
I didn't try anything yet. From reading the documentation, the flow loops seems to run all steps sequentially though, not in parallel
Tiago Serafim
Tiago Serafim13mo ago
https://www.windmill.dev/docs/flows/flow_loops check the section below the video, and the image following this section. You can control the parallelism
For loops | Windmill
For loops is a special type of steps that allows you to iterate over a list of items, given by an iterator expression.
Alper
Alper13mo ago
Oh that's great actually, thanks!