Would there be a way for an activity to trigger multiple async child workflows and also allow the parent workflow to wait for all these child workflows to complete?
I know that if I trigger the child workflows directly from the parent workflow - without an activity - I can do something like
Promise.allOf(promises).get() to get it to wait, but I’m not sure about the approach when there is an activity triggering the child workflows
For some background:
I have a potentially a large amount of items to process. Thus to avoid potentially overloading the workflow’s state/history size, I’m using an activity to read in each of the items to process from a file (rather than an object of the parent workflow).
I need to wait for all these child workflows to complete first before the parent workflow can continue on with its other tasks.
I’d also be good if there is a way to enforce a limit to the number of concurrently running child workflows running at a time.
Interested to hear any advice or suggestions!