<div dir="ltr"><br> Start by eliminating the evals and writing your constraints properly inside the patterns. Drools 3+ is orders of magnitude faster than Drools 2.x, but you need to leverage its power in your rules. Please read the manual as the version 3 was a completely rewrite of version 2. Version 4 is an improvement over 3.<br>
<br> As an example, look at this: <a href="http://blog.athico.com/2006/11/rush-hour-and-content-based-routing.html">http://blog.athico.com/2006/11/rush-hour-and-content-based-routing.html</a><br><br> []s<br> Edson<br>
<br><div class="gmail_quote">2008/9/5 Rout, Sushanta (ThoughtMill) <span dir="ltr"><<a href="mailto:Sushanta.Rout@ihg.com">Sushanta.Rout@ihg.com</a>></span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
We were using Drools 2.5 version earlier. Now we have switched to drools<br>
<a href="http://4.0.7." target="_blank">4.0.7.</a> But we see significant issues with performance like drools 4.0.7<br>
is three times slower than 2.5 . Has anybody encountered the issue?<br>
<br>
Here is a sample of the rule, we have some more similar to this.<br>
rule "test"<br>
dialect "java"<br>
activation-group "group1"<br>
when<br>
$croNumberDetailsRequest : CRONumberDetailsRequest()<br>
$resdirectPhoneNumber : ResdirectPhoneNumber()<br>
eval($resdirectPhoneNumber.getType().getId() == 5 &&<br>
<br>
$resdirectPhoneNumber.isValidForBrand($croNumberDetailsRequest.getBrand(<br>
)) &&<br>
$croNumberDetailsRequest.getRegion() != null &&<br>
<br>
$resdirectPhoneNumber.isValidRegion($croNumberDetailsRequest.getRegion()<br>
) &&<br>
$croNumberDetailsRequest.getLocale() != null &&<br>
<br>
<br>
$resdirectPhoneNumber.isValidForLocaleId($croNumberDetailsRequest.getLoc<br>
ale()) &&<br>
<br>
$resdirectPhoneNumber.isValidSlot($croNumberDetailsRequest.getSlot()));<br>
<br>
then<br>
ResultList.add($resdirectPhoneNumber);<br>
end<br>
<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</blockquote></div><br><br clear="all"><br>-- <br> Edson Tirelli<br> JBoss Drools Core Development<br> JBoss, a division of Red Hat @ <a href="http://www.jboss.com">www.jboss.com</a><br>
</div>