<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">Your eval, you could probably replace by something like this:</span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"><br>
</span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">rule &quot;status-Fixed-Open&quot;</span></p><p class="MsoNormal" style="margin-left: 37.5pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">               when</span></p>
<p class="MsoNormal" style="margin-left: 37.5pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">                             event : FieldChangedEvent(fieldName == &quot;status&quot;, oldValue == &quot;Fixed&quot;);</span></p>
<p class="MsoNormal" style="margin-left: 37.5pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">                             entity : Entity(entityType == &quot;mock-entity&quot;,  field == &quot;status&quot;, value == &quot;Open&quot;);</span></p>
<p class="MsoNormal" style="margin-left: 37.5pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"></span></p><p class="MsoNormal" style="margin-left: 37.5pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">               then                          </span></p>
<p class="MsoNormal" style="margin-left: 75pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">                  do Something…</span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">end <br>
</span></p><p class="MsoNormal"><br><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"></span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"><br>
</span></p><br><br><div class="gmail_quote">2011/4/26 Shebs, Liron <span dir="ltr">&lt;<a href="mailto:liron.shebs@hp.com">liron.shebs@hp.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div bgcolor="white" background="?ui=2&amp;ik=93bf04badd&amp;view=att&amp;th=12f917ea09ff5478&amp;attid=0.0.1&amp;disp=emb&amp;zw" link="blue" vlink="purple" style="margin-left: 37.5pt;" lang="EN-US"><img src="https://mail.google.com/mail/?ui=2&amp;ik=93bf04badd&amp;view=att&amp;th=12f917ea09ff5478&amp;attid=0.0.1&amp;disp=emb&amp;zw" style="width: 0pt; min-height: 0pt;" width="0" height="0"><div>
<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">Hello All,</span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"> </span></p>
<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">I’m working at HP Software R&amp;D and we are considering using drools in our product.</span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">Benchmarking tests showed that running 10,000 rules consumes 382mb. </span></p>
<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">This is too high for our system requirements, and we would like to know how we can improve it.</span></p><p class="MsoNormal">
<span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">Technical details:</span></p><p><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"><span>-<span style="font: 7pt &quot;Times New Roman&quot;;">      </span></span></span><span dir="LTR"></span><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">Drools version: 5.1 with default configuration. </span></p>
<p><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"><span>-<span style="font: 7pt &quot;Times New Roman&quot;;">      </span></span></span><span dir="LTR"></span><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">All rules look like this:</span></p>
<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"> </span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">rule &quot;status-Fixed-Open&quot;</span></p>
<p class="MsoNormal" style="margin-left: 37.5pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">               when</span></p><p class="MsoNormal" style="margin-left: 37.5pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">                             event : FieldChangedEvent(fieldName == &quot;status&quot;, oldValue == &quot;Fixed&quot;);</span></p>
<p class="MsoNormal" style="margin-left: 37.5pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">                             entity : Entity(entityType == &quot;mock-entity&quot;);</span></p>
<p class="MsoNormal" style="margin-left: 37.5pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">                             eval(((String) entity.getFieldValue(&quot;status&quot;)).equals(&quot;Open&quot;));</span></p>
<p class="MsoNormal" style="margin-left: 37.5pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">               then                          </span></p><p class="MsoNormal" style="margin-left: 75pt;">
<span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">                  do Something…</span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">end </span></p>
<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"> </span></p><p><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"><span>-<span style="font: 7pt &quot;Times New Roman&quot;;">      </span></span></span><span dir="LTR"></span><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">Loading code:</span></p>
<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"> </span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">KnowledgeBuilder knowledgeBuilder = KnowledgeBuilderFactory.newKnowledgeBuilder();</span></p>
<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">for(all resources)</span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">{</span></p>
<p class="MsoNormal" style="margin-left: 37.5pt; text-indent: 34.5pt;"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">knowledgeBuilder.add(resource, ResourceType.DRL);</span></p><p class="MsoNormal">
<span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">}</span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">knowledgeBase = KnowledgeBaseFactory.newKnowledgeBase();</span></p>
<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">knowledgeBase.addKnowledgePackages(knowledgeBuilder.getKnowledgePackages());</span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"> </span></p>
<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">Any insights are most appreciated.</span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"> </span></p>
<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">Thank You,</span></p><p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);">Liron, HP Software R&amp;D</span></p>
<p class="MsoNormal"><span style="font-family: &quot;Comic Sans MS&quot;; color: rgb(153, 51, 255);"> </span></p><div><p class="MsoNormal"><span style="font-size: 11pt; color: rgb(153, 51, 255);"> </span></p></div><p class="MsoNormal">
 </p></div></div><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>
<br></blockquote></div><br>