General Question: How to decide with which task to continue?

Hi All

I’ve got a receive task with three possible valid outcomes.

What is good practice to model such a case?
Should I use a process variable in combination with sequence flow conditions?
Or should I make two Message Boundary Events and one ‘default’ task?
(as far as I understand boundary events are there for something like an exceptional case, so I don’t think that’s a good solution)
Is there a more elegant solution?

Thank you very much

Hi @chiffshinz,
would a conditional event (1) be suitable for your case?

Cheers,
Mat

1 Like

Hi @chiffshinz,
if the outcome of the receive task determines how the process should process, you are in exactly the case what gateways are for :wink:
Hence, yes: place a exclusive gateway behind the receive task and use the outgoing sequence flows of that gateway to control the process flow in respect to the result of the receive task. Transport the result of the receive task via process variable.

Hope that helps,
Ragnar

1 Like