Manukyan, Sergey wrote:
Manukyan, Sergey's message received 10/17/2007 5:13 PM:
Folks,
I have to restate the question as didn't find the answer anywhere and
have not get response to it in my previous email.
Using 4.0.2. So I have a set of rules, _each_ with a specific
*ruleflow-group *defined. And I have a rule flow file defined.
Altogether everything works fine.
Now I need to fire a single specific rule from this rule set. Using
the
RuleNameEqualsAgendaFilter didn't help, it didn't fire the rule...
How is it supposed to be done?
A couple of reasons a rule won't fire: if the facts aren't
asserted or the conditions aren't met.
Scott, both conditions are met. The problem is in
filtering agenda to a single rule, and it only happens when rules have
ruleflow-group defined...
If a rule defines a ruleflow-group then it can only fire when that ruleflow-group is active. So the ruleflow-group, when active, place's its activations onto the Agenda where when the rule is attempted to be fired the AgendaFilter may stop that rule from firing.
The ruleflow-group is active. Here is what I do:
session.insert(fact);
session.startProcess("Validation");
session.fireAllRules(new RuleNameEqualsAgendaFilter("My specific rule I want to be fired")); // doesn’t fire any rule
Looks right to you?