Hi @Niall- I assume the call to child process is going to be asynchronous. I have tried a similar implementation where parent process runs a loop to trigger multiple child processes via send message event.
The purpose of using this over call activity was to have multiple instances triggered asynchronously, however each instance of the child process is waiting for completion before the next instances begins.
By default it will start them async. to create transaction boundaries for each instance use the asynchronous before tick box on the start event of the process you’re calling.
Thank @Niall, basically I do not want the child process instance to wait for completion before next one triggers. If parent process has triggered 30 send messages via a loop I would like all the 30 instances to be triggered parallely. How can that be achieved?
YES!!! this is exactly what I needed. Was pulling my hair out trying to figure out how to make this work using the job executor and job priority and some weird hacks with bpm.
Does Camunda consider it bad practice to start a process instance from another process instance with Java code vs. an explicit call activity or embedded sub-process?
The reason I do it is because if one or two of the process instances in the child process definition (prcs def that is triggered with java api from a delegate) creates an incident I don’t want to lock up the calling parent process. I also don’t want to loose any of the nested child process instances if they aren’t successful right away. My understanding is that with call activities and nested sub-process (that are multi instance) if any instances fail or don’t complete they will be deleted when the parent process moves on to the next token.
The parent would not move on to the next activity until all call activity of embedded sub processes were completed. They are just extensions of the parent process. But using messages is non blocking and not connected like how call activities are.