I'd say you are using
dialect "mvel"
There is no try/catch statement in MVEL. You have the options:
(1) Use Java, not MVEL.
(2) Surround the fireAllRules() with try/catch and put it in a loop that's terminated
if there is no exception.
-W
Hi All,
I have a set of rules. After firing the rules if an exception occurs in a rule the following rules are not getting evaluated. So i tried writing a try catch block inside the consequence part of the rule, but then i get an error saying "'unable to build the consequence.[Error:was expecting type: java.lang.Object but found type:null]"
Here follows my code
rule 'Test rule'
ruleflow-group "Test Ruleflow"
no-loop
when
$c:Car()
Driver()
then
try{
$c.getModel()
} catch (Exception Ee) {
System.out.println("caught an exception: "+Ee.toString());
}
end
However if i remove the try catch block it buils fine.
Can anyone let me know if i'm missing something here.
Thanks in advance :)
--
cheers
Sumatheja
_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users