BPMN inclusive gateway - one path always fires, other conditional. How to model?

1
+1
-1

Hi all,

I am using an inclusive gateway with two exit sequences. One sequence should always be executed, the other sequence only when an expression is true. It looks like this:

16qT0S6I.png

The problem is that (for an inclusive split) I have to define a default flow. The problem is that the default sequence only fires when all of the other expressions are false.
So with only two exit sequences (one default and one with condition), the inclusive gateway seems to behave like an exclusive gateway: in all cases only one of the exit sequences is fired.

Does anyone have an idea how to model this correctly?

Thanks in advance,
Stefan

1 answer

1
+1
-1
This one is the BEST answer!

Hi,

Default flow is optional.

So you your design seems to be perfectly valid. For "always" transition you can define a "Constant" expression with value set to true.

I did a quick test with 7.1.5 and it run just fine.

Comments

Submitted by valerioneri.de on Wed, 01/27/2016 - 11:25

The same hack I've used :)

Submitted by stefandebruijn on Thu, 01/28/2016 - 10:11

Thanks for the replies. I have tried this hack as well: the model is executing indeed, but I still get a validation warning: "An output default flow should be defined for Gateway 1" .

Submitted by antoine.mottier on Thu, 01/28/2016 - 10:35

Actually this warning should be an information message. It is just a general best practice to have default transition on exclusive and inclusive gateway to avoid to lock the process execution in the gateway.

You can safely ignore this warning.

Submitted by stefandebruijn on Thu, 01/28/2016 - 10:45

OK. Many thanks Antoine and Velerioneri.

Submitted by stefandebruijn on Sat, 02/06/2016 - 11:42

After a bit of thinking, I guess this is the best way to model it:

1lIudVIE.png

This works without errors or warnings.

Submitted by sunnyape on Wed, 08/10/2016 - 01:14

I'm a newbie converting to Bonita and this hack seems counter-intuitive.

If I don't mark one transition as being the default, the inclusive gateway acts as I expect, but I get a validation warning that an output default flow should be defined for the gateway.

If I mark one of the gateway's transitions as being the default path, I don't get the warning, but the process omits that transition if the true condition is meet for the other transition.

That's not how BPMN 2.0 says a inclusive gateway should behave and not how other modelling apps behave. Having to make a 'ghost' transition between the gateways is silly.

Submitted by antoine.mottier on Mon, 08/29/2016 - 16:50

After reading BPMN 2.0 it seems that Bonita BPM inclusive gateway behave exactly as recommended by the specification. I'm quoting here the specification (10.5.3 Inclusive Gateway):

A diverging Inclusive Gateway (Inclusive Decision) can be used to create alternative but also parallel paths within a Process flow. Unlike the Exclusive Gateway, all condition Expressions are evaluated. The true evaluation of one condition Expression does not exclude the evaluation of other condition Expressions. All Sequence Flows with a true evaluation will be traversed by a token. Since each path is considered to be independent, all combinations of the paths MAY be taken, from zero to all. However, it should be designed so that at least one path is taken.

And about default path:

A default path can optionally be identified, to be taken in the event that none of the conditional Expressions evaluate to true. If a default path is not specified and the Process is executed such that none of the conditional Expressions evaluates to true, a runtime exception occurs.

So again I agree that having a warning if you don't have any default path is probably not the perfect solution but still the behavior as run time comply to BPMN 2.0 standard.

Submitted by sunnyape on Tue, 08/30/2016 - 01:22

OK, fair enough.

I always considered that the path that didn't have a condition associated with it WAS the default path and didn't need to be declared as such. The other path only became included if the condition associated with it became true. This meant the inclusive gateway only needed to test for one condition, not two.

Notifications