Blog Posts Process Management Process Modeling

How DMN Allows Business Rules to Scale

Blog: Lux Magi – Decision Management for Finance Blog

Experience has shown that sets of business rules, even those administered using Business Rule Management Systems (BRMS), become very hard to manage and understand once they reach a certain level of size and complexity. Although small, very tightly focused rule sets can be effective for simple business domains, large rule sets are challenging to create and even harder to maintain. Small rule sets that become large over time (scale up) present the most difficulty. They are at risk of collapsing under the weight of their own growing complexity or becoming the sole preserve of a small number of ‘gurus’ and ‘high priests’ who alone understand them—defeating a key objective of business rules.

In a previous article, I described how to overcome the challenges of maintaining a business rules over a long period. But how can you manage the complications of rapidly growing rule sets: keeping them easy to understand, changing them safely without unintended consequences  and avoiding ‘stale’ and duplicate rules? Here we show, by example, how Decision Modeling, used from the outset can address all these problems.

Why are Business Rules Hard to Scale?

Why are large business rule sets—those that start large and especially those that become large over time—hard to manage? Why do they often collapse under their own weight, becoming a nightmare of unreliability and an incomprehensible tangle of poorly understood rules? Normally there are four main problems:

All of these problems arise for the same two reasons.

Lack of High Level Organization in BRMS Rule Sets

Most rule sets lack a strong structuring mechanism above and beyond business rules and the vocabulary they require. Rule sets are literally a ‘bag of rules.’ Business Rule Management Systems (BRMS) products do attempt to provide some structuring mechanism, for example:

While these structural concepts may help to organize rules they don’t address any of the problems raised above. This is because all of these classification schemes are entirely imposed by rule authors and don’t represent inherent relationships between the rules themselves.

These mechanisms cannot be used to develop a rule set ‘top down’ driven by business need rather than ‘bottom-up’ driven by detailed rule implementation.

Lack of Connectivity Between Rules and the Business Context

BRMS often cannot support any strong relationships between rules and other artifacts that clarify their business context. For example:

How Decision Modeling Addresses These Issues

A decision is a determination that produces an outcome given one or more data inputs. It isn’t the exactly same as a business rule (the distinction is explained here) but the logic of decisions can be implemented as a Decision Table, Decision Tree, rule text or other artifact supported by a BRMS. Decision Modeling is a technique for representing business decisions in a precise, standardized format that:

Concise Documentation of Dependencies

Decision Models can document the relationships between decisions (and therefore BRMS artifacts) using a standard notation (for illustration we are using DMN). For example consider this Decision Requirement Diagram (DRD) below. We have colored this diagram for ease of reference. DMN diagrams normally have no color, their components are recognized by shape alone.

DMN DRD credit rating full

DMN Decision Requirement Diagram

For clarity, decisions are represented as yellow rectangles, knowledge sources (e.g., policies, mandates, personal expertise, laws) as blue rectangles with wavy undersides and data inputs as green rounded rectangles. The lines between them represent dependencies with the line symbol depicting the dependent end. An arrow depicts the dependent requires data whereas a circle depicts a requirement of knowledge (from say a policy document). Decision Requirement Diagrams can depict the hierarchy of dependencies between rules and can be scaled up easily.

This diagram tells us that the decision Determine Personal Credit Rating requires data from two inputs (Persons Debt Record and Persons Annual Salary), data from a subordinate rule Determine Persons Employment Record and knowledge from the Risk Management Policy knowledge source. The latter indicates that this policy acts as an authority in the definition of the business rule Determine Personal Credit Rating.

Because DRDs force us to consider, at the outset, the needs of every business decision and their alignment to business processes and motivations they save a great deal of time lost to false implementations.

Transparent Definition of Business Logic

Every rectangle in the DRD represents a decision which can have a logic definition. Decision models have a standard way of representing the logic of rules and DMN is no exception. If we represented Determine Personal Credit Rating as a Decision Table rule in DMN it might look like this (I’ve added labels for clarity).

DMN DT credit rating labelled

DMN Decision Table

All decision logic must be consistent with the dependencies documented in the DRD. Therefore all the data required by the Decision Table’s conditions (Persons Employment Record, Persons Total Debt and Persons Annual Salary) are supplied in the data requirements of the DRD, above. Similarly, the conclusion of this table, Personal Credit Rating, is the data required of the Determine Personal Credit Rating decision by its parent decision Determine Personal Loan Limit. The DRD acts like a ‘summary’ of the data dependencies between rules.

More importantly, because the logic of each decision can forgo representation in DMN and be represented as a rule artifact in a BRMS, the DRD can act as the summary (a road map) of an entire ruleset.

Imagine the power this would give to the user of a BRMS: if each of the rectangles in a DRD represents a business rule, this gives us a visual display of rule dependencies. Decision model DRDs become a formal, high level structure for a rule set. Furthermore, each decision (rule) can be reused in many DRDs and, because of their hierarchical structure, they can scale arbitrarily.

Definition of a Decision Service

DMN can also define a graphical representation of a decision service—a capability not offered by most BRMSs. This is depicted in the DRD as a white rounded rectangle with two compartments. All decisions within this rectangle represent rules deployed as part of the decision service. The rules depicted in the top compartment determine the public interface of the service

Decision Service Defined in DMN

Decision Service Defined in DMN

(the conclusion(s) of these decisions represent the outcome of the service). The decisions in the lower compartment are private: they can be used by the public decisions (to satisfy their data requirements) but cannot be seen by decision services users. The data and decision components outside the rounded rectangle represent the needs the service has of the invoker: what data must be provided to user the service.

The decision service shown determines the Personal Loan Limit of the individual when provided with their Employment History, their Employment Record, their Annual Salary, their Debt Record and the Clerk Record of the loan assessor. We will not cover here how the decision model is aware of the relationships between these items.

Benefits of Decision Modeling Your Business Rule Set

In short, but augmenting a rule set with its decision model, you can:

The visual depiction of DRDs also helps to:

Bottom Line

In short, improving the scalability, business alignment and robustness of business rule sets is just one of the beneficial applications of decision modeling that can save time and ensure the life expectancy of rule sets is enhanced.

If you are interested in this or other benefits of decision modeling please feel free to contact us or consult our new book on DMN.

Leave a Comment

Get the BPI Web Feed

Using the HTML code below, you can display this Business Process Incubator page content with the current filter and sorting inside your web site for FREE.

Copy/Paste this code in your website html code:

<iframe src="https://www.businessprocessincubator.com/content/how-dmn-allows-business-rules-to-scale/?feed=html" frameborder="0" scrolling="auto" width="100%" height="700">

Customizing your BPI Web Feed

You can click on the Get the BPI Web Feed link on any of our page to create the best possible feed for your site. Here are a few tips to customize your BPI Web Feed.

Customizing the Content Filter
On any page, you can add filter criteria using the MORE FILTERS interface:

Customizing the Content Filter

Customizing the Content Sorting
Clicking on the sorting options will also change the way your BPI Web Feed will be ordered on your site:

Get the BPI Web Feed

Some integration examples

BPMN.org

XPDL.org

×