Priority and Rule Chaining

Priority and Rule Chaining

Old forum URL: forums.lhotka.net/forums/t/11525.aspx


mtavares posted on Friday, August 10, 2012

If you are chaining multiple rules together, and want to set the priority to a value higher than the default, do you need to set the priority on each individual rule in the chain, or only on the outer rule?  I'm thinking just the outer rule, but want to make sure.

 

Thanks,

Mike

JonnyBee replied on Friday, August 10, 2012

All rules have a default priority of 0.

So you only need to set the priority on the rule(s) that you want to have at another priority.

Within the same priority you should regard the sequence as random and insignificant.
IE Rules is ONLY sorted by Priority to determine the sequence.

If you have rule chaining as in inner rules in a BusinessRule -  the rule engine only have knowledge of the outermost Rule (registered rule)  and only looks  for this rules Priority.

 

Copyright (c) Marimer LLC