{ by david linsin }

January 21, 2007

Drools and Enterprise Services

Weaving complex business logic into application code makes developers deeply responsible for understanding and maintaining that logic, and means that every change in a company's processes requires a recompile and redeploy. Using a rules engine like Drools offers an opportunity to split the rules into their own files, potentially editable by the subject-matter experts instead of developers. Birali Hakizumwami shows how this approach can be made to work for financial applications like mortgage underwriting systems.

This article gives a good overview of how to incorporate Drools Rule Engines (JBoss Rules) into a real world enterprise application. The domain used in this article is quite complex (mortgage underwriting service) and it's a good example of what I think is a big drawback when using a rule engine: testing!

Don't get me wrong, I think using a rule engine to implement business logic is the way to go. What I'm asking myself is how to test those rules. I believe it's quite difficult to test a single rule using a JUnit TestCase, since it can affect other rules or it needs other rules to determine its outcome. And I guess testing gets even harder when you apply conflicting rules.

I'm wondering if their is some kind of test harness when it comes to rule engines?

2 comments:

Mark Proctor said...

Matt Shaw is working on an Eclipse based scenario testing framework for JBoss Rules, there is still lots to do - why not get involved :)

Mark Proctor
http://markproctor.blogspot.com/

david said...

Thanks for the hint Mark, I'll definitely check it out!


com_channels

  • mail(dlinsin@gmail.com)
  • jabber(dlinsin@gmail.com)
  • skype(dlinsin)

recent_postings

loading...