BPM 2.0 Parallel Waiting Gateway / Exclusive Gateway new iteration

Picture of the problem

Here is my problem: all three streams of the sequence after the fork have to be tested separately, and if they are negative, I want to start another P2 process. After P2 completes, I want to go back to the process starting at P1 and I want to check all three thread sequences again after they have been forked.

Maybe an example helps to understand: we assume that C1 and C2 are positive, C3 is negative in the first iteration, so the system waits at the federated gateway for C3, and another procedure starts after P2 process. Now, in the second test, C1 and C3 are positive and C2 is negative. Here's the problem: the exclusive gateway will join the streams of the sequence as if all checks were positive, even though C2 was negative in the second iteration. I want it to just join them when all checks were positive in HAVING PLAY.

+3


source to share


1 answer


Join the parallel branches using gateway merge, then check the state with only one exclusive gateway. This is easier to understand and maintain as it uses fewer gateways.

join branches


If C1, C2, and C3 need to be terminated as soon as possible, you can checkout three branches into one subprocess. The subprocess issues a signal if one branch fails and the surrounding process catches it.

sub process




Without subprocesses, you will need an additional exclusive gateway and connections to merging gateways for each activity in each branch. This adds quickly if C1, C2, and C3 are not simple steps but sequences, but might be fine for simple workflows.

The merge of the lock after P2 prevents race conditions. For example if P2 ends before C3 and so the second iteration will start before the first ends.

(Eventually, you will need an additional parallel gateway after each branch action to separate paths.)

without sub process

+1


source







All Articles