[rules-users] Firing only changed object rules in stateful sessions

orchid maya.pollack at gmail.com
Mon Jan 11 08:31:23 EST 2010


I have a question to salaboy:

If you have several rules which check and modify an object, will you need to
add several properties to indicate which rule chagned that object. For
example:

rule "Rule1" 
no-loop true 
  when 
    $c:Chesse(type="Chedar") 
  then 
    modify ($c){addRule("Rule1")} 
end 

rule "Rule2" 
no-loop true 
  when 
    $c:Chesse(price < 100) 
  then 
    modify ($c){addRule("Rule2")} 
end 

rule "Rule3" 
no-loop true 
  when 
    $c:Chesse(color == "yellow") 
  then 
    modify ($c){addRule("Rule3")} 
end 

I guess I missed something. Don't I :-) ???
-- 
View this message in context: http://n3.nabble.com/Firing-only-changed-object-rules-in-stateful-sessions-tp116659p116773.html
Sent from the Drools - User mailing list archive at Nabble.com.



More information about the rules-users mailing list