Modeling a process that can reset itself

Hi :slight_smile:

I have a process definition with a transaction. During the flow, the user can decide to stop, compensate what he has done so far and start all over as often as he wishes to.

diagram_1.bpmn (9.6 KB)

I used signals to model “starting all over”, but I just noticed that Camunda sends its signals globally to all process instances.

Could someone please give me a hint how to handle this in a way that my processes can run independently from each other?
Do I have to use messages? To me it seems to be kind of an overhead, but I could not find any other solution so far.

Thanks a lot

Are you set on using compensation events?

Have not tested (there might be a compensation limitation that prevents the event sub-process from working as i would expect), but try this:

Hi Stephen,

thanks a lot! :slight_smile:

In my real process, the transaction contains more than one task and I have to make sure that the transaction is interrupted and left as soon as the user wants to reset the process. I guess this is not possible when using an embedded process?

I came up with a flow using messages and pools. This works fine except that the compensation task does not come up:

iceCreamPools.bpmn (14.2 KB)

When I complete “eat ice cream” and, after that, reset the process with “reject ice cream flavour” , I get “report message receival” as next task, so sending and receiving the message works fine :slight_smile:
But after that I get “eat ice cream” again and no compensation task.

Do you know why it does not come up?

Thanks in advance!