I read both articles and I'm grateful. I will be pushing to try an use this in
future rule-based projects. However, I saw in the latter of the two articles, you
had a daoFactory providing a dao for a data request.
Is it possible to have Spring set this dependency. In other words, is there an
existing Spring integration for Drools, or would this have to be an in-house module?
Thank you in advance.
Onyeje "Jay" Bose
Drools does come with a Spring Integration module (more info at http://drools.org/Spring+Integration). Most of the integration listed on this page deals with the rules , rather than where the rules get their data from.
While there are many ways to integrate Spring to the example you give , the easiest would be to follow standard Spring practice , and allow the framework to set the data source on the bean , then refer to that value (via a standard getter method) from the rule.
The Red-Piranha open source project has a sample of using a Dao with spring. More at http://cvs.sourceforge.net/viewcvs.py/red-piranha/CVSROOT/samples/
(follow the sample-db-access-code/ links)