From: HonorGod
<jagadeesh.motamarri@barclayscapital.com>
To: rules-users@lists.jboss.org
Sent: Fri, January 15, 2010 11:47:21 AM
Subject: [rules-users] Is this possible in Guvnor?
Hi,
I have a single fact model with 5 [a1, a2,a3, a4, and a5] different
attributes. I have 3 decision tables in the following fashion
Decision Table 1
---------------------------------------------
condition | condition | condition | Action |
---------------------------------------------
a1 | a2 | a3 | a4 = a1+a3|
----------------------------------------------
Once I have the value of a4, I need to hit different set of rules which are
stored in second decision table
Decision Table 2
---------------------------------------------
condition | condition | condition | Action |
---------------------------------------------
a1 | a2 |
a4 | a5 = a4 |
----------------------------------------------
Once I have the value of a5, I need to hit different set of rules which are
store in third decision table
Decision Table 3
------------------------------------------------------------------------
condition | condition | condition | condition | condition | Action
|
-------------------------------------------------------------------------
a1 | a2 | a3 | a4 | a5 |
computeValue() |
------------------------------------------------------------------------
I don't have any problem when I load the rules into individual KnowledgeBase
and fire the rules one after the
other as follows -
<code>
// apply rules from decision table 1
StatefulKnowledgeSession kSession =
knowledgeBase1.newStatefulKnowledgeSession() ;
kSession.insert(caEventDO);
kSession.fireAllRules();
// apply rules from decision table 2
kSession = knowledgeBase2.newStatefulKnowledgeSession() ;
kSession.insert(caEventDO);
kSession.fireAllRules();
// apply rules from decision table 3
kSession = knowledgeBase3.newStatefulKnowledgeSession() ;
kSession.insert(caEventDO);
kSession.fireAllRules();
kSession.dispose() ;
</code>
But when I upload the decision tables into Guvnor and use the package / drl
from the package snapshot my second set of rules are not fired at all.
How do I resolve this issue?
Please help.
Thanks
--
View this message in context: http://n3.nabble.com/Is-this-possible-in-Guvnor-tp122132p122132.htmlSent from the Drools - User mailing list archive at
Nabble.com.
_______________________________________________
rules-users mailing list
rules-users@lists.jboss.orghttps://lists.jboss.org/mailman/listinfo/rules-users