Hi
why should rule2 be ignored ?
when $tx:Transaction();
So it is true whatever is in transaction.
Cheers
Nicolas
2014-03-28 16:37 GMT+01:00 007reader [via Drools] <
ml-node+s46999n4029009h12(a)n3.nabble.com>:
I have a group of rules marked with "activation-group"
where I want only
one rule to fire and ignore the rest. I also want to evaluate rules in
particular order, so I use salience to prioritize the rules within the
group. Here are my rules:
rule "rule1"
no-loop
salience 100
activation-group "Group1"
when
$tx:Transaction(amount < 100);
then
$tx.setStatus(true);
update($tx);
end
rule "rule2"
salience -50
activation-group "Group1"
when
$tx:Transaction();
then
System.out.println("catch all: "+$tx.toString());
end
I expect that if Transaction amount<100, then rule1 will fire, and rule2
ignored. However both rules get executed. What am I doing wrong?
Thx
------------------------------
If you reply to this email, your message will be added to the discussion
below:
http://drools.46999.n3.nabble.com/Activation-group-and-salience-tp4029009...
To start a new topic under Drools: User forum, email
ml-node+s46999n47000h33(a)n3.nabble.com
To unsubscribe from Drools, click
here<http://drools.46999.n3.nabble.com/template/NamlServlet.jtp?macro=...
.
NAML<http://drools.46999.n3.nabble.com/template/NamlServlet.jtp?macro=...
-----
Nicolas Héron
--
View this message in context:
http://drools.46999.n3.nabble.com/Activation-group-and-salience-tp4029009...
Sent from the Drools: User forum mailing list archive at
Nabble.com.