Complex Event Processing (CEP) is an area that I had been thinking about for quite some time. I had been wanting to write about how the Business Rules technology relates to CEP.

If you do not know CEP, here are some useful links.

  1. CEP Articles
  2. CEP Usecases.

There are many use cases discussed in the above post. Let me discuss 2 cases, where business rules technology can help.

Order Management and Advanced Pricing

Sample Business Rules

  1. On New Order , If Item Count IN Warehouse of Any Item in Order Goes Below It’s Threshold, then Reorder this Item.
  2. If Order.Customer.Level == GOLD & Today >OrderDate +2 Then Push Order to High Priority Queue.
  3. when the average size of the canceled orders in the last 30 days is greater than the 60 day average by 25%, Then Send Alert EMail to Manager

Traditional Approach

  1. Business Rules in Database as Stored Procedures
  2. Zero Visibility for Business
  3. Need Expert IT to change Rules.
  4. Change driven by Business, but controlled by IT.
  5. Chained by technology complexity.

Business Rules Approach

  1. All these Rules captured as Business Rules using a Business Rules Management System (BRMS). On Event, application invokes the rule engine.
  2. Business Analysts & managers have complete visibility into their rules.
  3. Change driven by business & managed by business.

Capital Market Surveillance

Investigation officers are interested to find out market abuses and abnormalities by applying intelligence and predefined business logic on statistical data for a selected investigation period. This logic can be created in the form of business Rules.This is already being done at the Bombay Stock Exchange.

Sample Business Rules

  1. If (% of group of clients quantity to Settlement total traded quantity is less than Parameter (Some Parameter)), then trading pattern for that settlement by group of connected or same clients is considered as “Ignore
  2. If % change in shareholding pattern is more than 5% then, Set % S_H_C_LIMIT=YES
  3. If % of Net Buying during POI to the total capital of the company is more than 50% then “Net Buying more than 50% of the capital of the company” will be displayed as “Yes” else “No”

Traditional Approach

  1. Recommendation Logic & alerts conditions written in Code
  2. These are maintained by developers, and surveillance officers send change request to IT
  3. Surveillance officers have zero visibility into the system
  4. Time to change is high.

Business Rules Approach

  1. Surveillance officers use a custom interface and write alerts logic, which get stored as rules. Capture recommendation logic as Business Rules (Alerts)
  2. ON all Trades, Rules are applied. This is done by calling the business rule engine from the application.
  3. Alerts maintained by the Surveillance Department. No IT involvement.
  4. Daily updates to the Alerts. Changes today, go into tomorrow’s trading session

Conclusions

One common problem with Enterprise applications is that of the Blind Business. It is difficult for the business to see and understand what is going on. Business Rules offer a best solution for capturing, automating and managing business decisions , that are driven by ever changing business rules/policies.

There are IT driven changes, and there are business driven changes. If you are looking for Visibility & flexibility into your business rules, and the business decisions that they drive, you need business rules management.

Share and Enjoy! These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Digg
  • del.icio.us
  • Netvouz
  • DZone
  • ThisNext
  • MisterWong
  • Wists
  • BlinkList
  • Furl
  • Ma.gnolia
  • NewsVine
  • Spurl
  • TailRank
  • Reddit
  • SphereIt
  • StumbleUpon
  • Technorati
  • YahooMyWeb

One Response to “Complex Event Processing and Business Rules”  

  1. 1 James Taylor

    I think decision management and CEP are very complimentary. Like you I think CEP needs business rules and that Complex Event Processing is an interesting approach. I think there is a risk of confusiing business rules with routing or event rules and that there is a powerful rule for decision management in support of SOA, BPM and CEP.

Leave a Reply