Business Rules Solutions: What Happens When Behavioral Business Rules and Decision Logic Collide?

Do behavioral business rules and decision rules ever cross paths? Yes, indeed, all the time! What happens when they do? Which rules 'win'? Understanding this question brings significant clarity to how business logic should fundamentally work. Indeed, it is basic to handling real-world rules. Having problems handling exceptions in your decision logic? Read this Column

In the real world (not software), rules can be broken. Why two decades into the 21st century that obvious reality is still not taken into account in software (e.g., rule engines) is a complete mystery to me. It needs to be corrected!

Rules that people or organizations can break are called behavioral business rules. Think laws, regulations, contracts, service level agreements, etc., etc.

The second major category of business rules is definitional rules. As the name suggests, this kind of rule pertains to the meaning of concepts. Definitional rules cannot be broken; they indicate how things have to be understood.

Definitional rules often take the form of decision rules – rules by which decisions are made. The rules you find in decision models and decision tables are decision rules. Decision rules imply new facts from existing facts – that is, they are about logical implication, able to perform what is commonly called inference. Do behavioral business rules and decision rules ever cross paths? Yes, indeed! All the time.

What happens when they do? Understanding this question brings significant clarity to how business logic should fundamentally work. Indeed, it is basic to handling real-world rules.

Example

To understand the issue, let's take a relatively simple example. Suppose a city is operating its recreational facilities and needs to assess usage fees. The city has the following behavioral business rule (expressed in RuleSpeak®1):

A senior citizen must not be charged a recreational fee for use of facilities.

The city also has also created a decision table to determine appropriate usage fees for its recreational facilities based on length of usage and when the usage occurs.

BehavioralBusinessRules_fig1

The decision table is actually a set of decision rules, specifically nine of them (in green). These nine rules could, of course, have been written out as nine individual statements. With a well-formed decision table like the above, however, there is no need to do so2. For example, the statement in the lower right-most cell could have been written as follows (also in RuleSpeak®):

The recreational fee for use of facilities must be deemed $15 if during peak hours on a weekend and for more than 2 hours.

In the case of senior citizens, the earlier behavioral rule is in direct conflict with all the decision rules in the decision table. A senior citizen is never to be charged a recreational fee no matter what the circumstances of usage. So, which rule 'wins' in any given case of usage by a senior citizen?

The answer is it depends. Which rule do you want to win? What's correct according to the business? Let's consider each of the two possible scenarios.

Scenario 1. The Decision Logic Should Win

Let's suppose you want the decision logic to override the behavioral business rule. That seems a bit odd, but no matter for this discussion. Achieving this result is a whole lot easier than you might imagine.

To see how the decision logic could win you need to understand about enforcement level, a unique feature of behavioral business rules that arises because they can be broken. How strictly you want a behavioral rule enforced is a different question from the logic it expresses.

A set of common-sense enforcement levels is given in Table 1.3 To save you a bit of reading, the enforcement level that would satisfy the present scenario is the very last one in the table.

Table 1

Table 1. Enforcement Levels for Behavioral Rules and Their Implications for Designing Procedures

1Refer to www.RuleSpeak.com.
2Refer to TableSpeak Primer (free download) http://www.brsolutions.com/b_ipspeakprimers.php.

3Reference: Business Rule Concepts: Getting to the Point of Knowledge (4th ed), by Ronald G. Ross 2013, p. 135.

Ron Ross

Ron Ross

Ronald G. Ross is Co-Founder and Principal of Business Rule Solutions, LLC (www.BRSolutions.com). BRS provides workshops, consulting services, publications, and methodology supporting business analysis, business rules, business vocabulary, and rule management. His popular public seminars on business rules and business analysis, the first on business rules (starting in 1996) and the longest-running in the industry, are given through AttainingEdge (www.AttainingEdge.com). At BRS, Mr. Ross co-develops Proteus®, its landmark business analysis and business rules methodology, which features numerous innovative techniques including the popular RuleSpeak® (available free through www.BRCommunity.com). These are the latest offerings in a 30-year career that has consistently featured creative, business-driven solutions. Mr. Ross also serves as Executive Editor of www.BRCommunity.com and its flagship on-line publication, Business Rules Journal. He is a regular columnist for the Journal's Commentary section which also features John Zachman, Chris Date, Terry Halpin, and Roger Burlton. BRCommunity.com, hosted and sponsored by BRS, is a vertical community for professionals working with business rules and related areas. Mr. Ross was formerly Editor of the Data Base Newsletter from 1977 to 1998. Mr. Ross is recognized internationally as the "father of business rules." He has served as Co-Chair of the annual Business Rules Forum Conference since 1997. He was a charter member of the Business Rules Group (BRG) in the 1980s, and an editor of the two landmark BRG papers,"The Business Motivation Model: Business Governance in a Volatile World" (2000, revised 2005) and the "Business Rules Manifesto" (2003). He is also active in OMG standards development for business rules and business models. Mr. Ross is the author of eight professional books. His newest are: Business Rule Concepts (2005), a second edition of his popular, easy-to-read 1998 handbook, and Principles of the Business Rule Approach, Addison-Wesley (2003), featuring the business rationale and opportunity for business rules. An earlier work, The Business Rule Book (1994, 1997), was the seminal work in the field. Mr. Ross received his M.S. in information science from Illinois Institute of Technology, and his B.A. from Rice University.
Share

Speak Your Mind

*

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Share
Share