I'll say it before someone else...
Evals are the devil, avoid them. From memory, the newer drools handles old
rules poorly, using extensive use of evals. It's the reason we have not
moved up to the newest version yet. It's probably not pretty but you may
have to rewrite/reconfigure your rules to avoid the use of evals, if that
3x performance is a significant issue.
-Michael
-----Original Message-----
From: rules-users-bounces(a)lists.jboss.org
[mailto:rules-users-bounces@lists.jboss.org] On Behalf Of Rout, Sushanta
(ThoughtMill)
Sent: Friday, September 05, 2008 10:32 AM
To: Rules Users List
Subject: [rules-users] Drools, Performance issues on 4.0.7 Vs 2.5
We were using Drools 2.5 version earlier. Now we have switched to drools
4.0.7. But we see significant issues with performance like drools 4.0.7
is three times slower than 2.5 . Has anybody encountered the issue?
Here is a sample of the rule, we have some more similar to this.
rule "test"
dialect "java"
activation-group "group1"
when
$croNumberDetailsRequest : CRONumberDetailsRequest()
$resdirectPhoneNumber : ResdirectPhoneNumber()
eval($resdirectPhoneNumber.getType().getId() == 5 &&
$resdirectPhoneNumber.isValidForBrand($croNumberDetailsRequest.getBrand(
)) &&
$croNumberDetailsRequest.getRegion() != null &&
$resdirectPhoneNumber.isValidRegion($croNumberDetailsRequest.getRegion()
) &&
$croNumberDetailsRequest.getLocale() != null &&
$resdirectPhoneNumber.isValidForLocaleId($croNumberDetailsRequest.getLoc
ale()) &&
$resdirectPhoneNumber.isValidSlot($croNumberDetailsRequest.getSlot()));
then
ResultList.add($resdirectPhoneNumber);
end
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users