How do I properly model a process where I have 1 input and the process forks into processes that are unrelated with each other

I’m looking for any input on how I should approach this properly, or even someone to tell me that what I’m doing is wrong.

I have this process below, all conditions could pass and all call activity could be executed and call another process. Currently everything is executed in the same app as the camunda engine using java delegates.

image

My problem is the 3 processes don’t really have anything to do with each other, but if for example an exception is thrown in process 1 and an incident is created then the other 2 process will no longer be executed. Is there anyway around that? or is what I’m doing just really wrong?

This is due to how the process engine deals with transactions on a fundamental level.

Short answer: Go to the start events of each process being called by the call activities and tick the async-before box.

Long answer
Unlike Camunad 8, Camunda 7 is transactional. To ensure consistency of state only one thread will be acting on the state of the process at one given time. So while you’ve modeled a parallel execution the reality is that each branch happens one at a time - in memory - until a wait state is reached. Which means if any single branch fails it will roll back to the last wait state. You should read this for more details.

But - you’re using Call Activities - that makes things interesting. It means that if you create a wait state on the start event of each of the processes being called by the call activities it means that the tread will activate each of processes before committing it’s state. then each of the processes called will continue independently on their own threads before returning.