<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">There is a class called BitSet, which grows the number of bits.<div><div style="margin: 0px; font-size: 12px; "><a href="http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-b14/java/util/BitSet.java">http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-b14/java/util/BitSet.java</a></div><div style="margin: 0px; font-size: 12px; "><br></div><div style="margin: 0px; font-size: 12px; ">This uses an array of longs instead. But i'm really reluctant to use this, because it adds overhead to our currently very lightweight operation, it has to create a for loop:</div><div style="margin: 0px; font-size: 12px; "><div class="line" id="line-644" style="margin-top: -2px; padding-left: 10px; font-family: 'Lucida Grande', Tahoma, Verdana, Arial, Helvetica, sans-serif; font-size: medium; background-color: rgb(255, 255, 255); position: static; z-index: auto; "><pre style="margin-top: 0px; margin-bottom: 0px; display: inline; "><span class="kw" style="color: rgb(127, 0, 85); font-weight: bold; ">public</span>&nbsp;<span class="kw" style="color: rgb(127, 0, 85); font-weight: bold; ">boolean</span>&nbsp;<a class="context-menu" href="http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-b14/java/util/BitSet.java#" style="padding: 0px 0px 0px 4px; margin: 0px; color: rgb(104, 144, 216); text-decoration: none; font-size: 1.4em; "><img class="img_base img_jdt_elcl16_thin_show_toolbar" border="0" title="More ..." width="11" height="16" style="margin-left: 3px; margin-right: 3px; background-image: url(http://grepcode.com/static/app/images/common_sprite.png); background-position: 0% -429px; background-repeat: no-repeat no-repeat; " id="3fd24be7-e9b7-436b-ab4a-f27249267edb" apple-width="yes" apple-height="yes" src="cid:CEB8F210-2FA2-4CC6-9A72-3EC3436A86D7@42sls"></a><a name="BitSet.intersects%28java.util.BitSet%29" style="padding: 0px; margin: 0px; ">intersects</a>(<a href="http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-b14/java/util/BitSet.java#BitSet" title="java.util.BitSet" style="padding: 0px; margin: 0px; color: rgb(51, 102, 187); ">BitSet</a>&nbsp;<span class="mark-70#0">set</span>)&nbsp;{</pre></div><div class="line" id="line-645" style="margin-top: -2px; padding-left: 10px; font-family: 'Lucida Grande', Tahoma, Verdana, Arial, Helvetica, sans-serif; font-size: medium; background-color: rgb(255, 255, 255); position: static; z-index: auto; "><div class="lnml" id="lnml-645" style="display: inline; "><img width="16" height="16" id="79d579bd-3176-4c6d-9bad-775ab50e0aa2" apple-width="yes" apple-height="yes" src="cid:CEB8F210-2FA2-4CC6-9A72-3EC3436A86D7@42sls"></div><pre style="margin-top: 0px; margin-bottom: 0px; display: inline; "><span class="kw" style="color: rgb(127, 0, 85); font-weight: bold; ">for</span>&nbsp;(<span class="kw" style="color: rgb(127, 0, 85); font-weight: bold; ">int</span>&nbsp;<span class="mark-71#0">i</span>&nbsp;=&nbsp;Math.<a href="http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-b14/java/lang/Math.java#Math.min%28int%2Cint%29" title="java.lang.Math.min(int,int) : int" style="padding: 0px; margin: 0px; color: rgb(51, 102, 187); ">min</a>(<span class="mark-6#1" style="background-color: rgb(221, 221, 221); background-position: initial initial; background-repeat: initial initial; "><a href="http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-b14/java/util/BitSet.java#BitSet.0wordsInUse" title="int wordsInUse" class="hidden" style="padding: 0px; margin: 0px; color: rgb(0, 0, 0); text-decoration: none; ">wordsInUse</a></span>,&nbsp;<span class="mark-70#1">set</span>.<span class="mark-6#1" style="background-color: rgb(221, 221, 221); background-position: initial initial; background-repeat: initial initial; ">wordsInUse</span>)&nbsp;-&nbsp;1;&nbsp;<span class="mark-71#1">i</span>&nbsp;&gt;=&nbsp;0;&nbsp;<span class="mark-71#1">i</span>--) {</pre></div><div class="line" id="line-646" style="margin-top: -2px; padding-left: 10px; font-family: 'Lucida Grande', Tahoma, Verdana, Arial, Helvetica, sans-serif; font-size: medium; background-color: rgb(255, 255, 255); position: static; z-index: auto; "><div class="lnml" id="lnml-646" style="display: inline; "><img width="16" height="16" id="1d56e806-c230-4587-a91c-477ab2e01709" apple-width="yes" apple-height="yes" src="cid:CEB8F210-2FA2-4CC6-9A72-3EC3436A86D7@42sls">&nbsp; &nbsp;&nbsp;</div><pre style="margin-top: 0px; margin-bottom: 0px; display: inline; "><span class="kw" style="color: rgb(127, 0, 85); font-weight: bold; ">if</span>&nbsp;((<span class="mark-5#1"><a href="http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-b14/java/util/BitSet.java#BitSet.0words" title="long[] words" class="hidden" style="padding: 0px; margin: 0px; color: rgb(0, 0, 0); text-decoration: none; ">words</a></span>[<span class="mark-71#1">i</span>]&nbsp;&amp;&nbsp;<span class="mark-70#1">set</span>.<span class="mark-5#1">words</span>[<span class="mark-71#1">i</span>])&nbsp;!=&nbsp;0) {</pre></div><div class="line" id="line-647" style="margin-top: -2px; padding-left: 10px; font-size: medium; background-color: rgb(255, 255, 255); position: static; z-index: auto; "><pre style="margin-top: 0px; margin-bottom: 0px; display: inline; "><span class="kw" style="white-space: normal;"><font face="Lucida Grande, Tahoma, Verdana, Arial, Helvetica, sans-serif"></font></span><span class="kw" style="font-family: 'Lucida Grande', Tahoma, Verdana, Arial, Helvetica, sans-serif; color: rgb(127, 0, 85); font-weight: bold; ">            return</span><font face="Lucida Grande, Tahoma, Verdana, Arial, Helvetica, sans-serif">&nbsp;</font><span class="kw" style="font-family: 'Lucida Grande', Tahoma, Verdana, Arial, Helvetica, sans-serif; color: rgb(127, 0, 85); font-weight: bold; ">true</span><font face="Lucida Grande, Tahoma, Verdana, Arial, Helvetica, sans-serif">;</font></pre></div><div class="line" id="line-647" style="margin-top: -2px; padding-left: 10px; font-size: medium; background-color: rgb(255, 255, 255); position: static; z-index: auto; "><pre style="margin-top: 0px; margin-bottom: 0px; display: inline; "><font face="Lucida Grande, Tahoma, Verdana, Arial, Helvetica, sans-serif">         }</font></pre></div><div class="line" id="line-647" style="margin-top: -2px; padding-left: 10px; font-size: medium; background-color: rgb(255, 255, 255); position: static; z-index: auto; "><pre style="margin-top: 0px; margin-bottom: 0px; display: inline; "><font face="Lucida Grande, Tahoma, Verdana, Arial, Helvetica, sans-serif">     }</font></pre></div><div class="line" id="line-648" style="margin-top: -2px; padding-left: 10px; font-family: 'Lucida Grande', Tahoma, Verdana, Arial, Helvetica, sans-serif; font-size: medium; background-color: rgb(255, 255, 255); position: static; z-index: auto; "><div class="lnml" id="lnml-648" style="display: inline; "><img width="16" height="16" id="1a936c84-e3a4-4b9d-9cb2-d5bda24d6bf2" apple-width="yes" apple-height="yes" src="cid:CEB8F210-2FA2-4CC6-9A72-3EC3436A86D7@42sls">&nbsp;</div><pre style="margin-top: 0px; margin-bottom: 0px; display: inline; "><span class="kw" style="color: rgb(127, 0, 85); font-weight: bold; ">return</span>&nbsp;<span class="kw" style="color: rgb(127, 0, 85); font-weight: bold; ">false</span>;</pre></div><div class="line" id="line-649" style="margin-top: -2px; padding-left: 10px; font-family: 'Lucida Grande', Tahoma, Verdana, Arial, Helvetica, sans-serif; font-size: medium; background-color: rgb(255, 255, 255); position: static; z-index: auto; "><pre style="margin-top: 0px; margin-bottom: 0px; display: inline; ">}<br></pre></div><div><br></div></div><div style="margin: 0px; font-size: 12px; ">But we can investigate and see if it adds any noticeable performance. In the meantime the kbuilder should probably throw an exception.</div><div style="margin: 0px; font-size: 12px; "><br></div><div style="margin: 0px; font-size: 12px; ">Mark</div><div style="margin: 0px; font-size: 12px; "><br></div><div><div>On 5 Oct 2012, at 21:44, Davide Sottara &lt;<a href="mailto:dsotty@gmail.com">dsotty@gmail.com</a>&gt; wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">At the moment, @propertyReactive uses a bit mask internally... and I believe<br>that is limited to 64 bits, which corresponds to 64 fields, less than what<br>you have. <br>I'm not 100% sure since I didn't check, but I have the feeling that it may<br>explain what is going on here..<br>You have something like 160 fields, which is 128+32.. adding or removing one<br>might indeed make a difference!<br><br>This may indeed be a (known?) bug or limitation of the current impl, Mario<br>Fusco will be able to provide more insight..<br><br>You can easily work around the problem, at least for now, by preventing the<br>loop with updatedArBankruptcyChapterPopulated != "No"<br><br>A side question would be: do you really need all those fields in the same<br>class? Wouldn't it be more reasonable to split it them in multiple beans,<br>rather than a single generic "Facts" class? I'm not familiar<br>with the domain, but the properties seem very hetherogeneous...<br>Also in terms of efficiency and memory consumption, would an average<br>instance of yours have most of those fields populated?<br><br>Best<br>Davide<br><br><br><br>--<br>View this message in context: <a href="http://drools.46999.n3.nabble.com/rule-infinitely-loops-appears-to-be-depending-on-naming-on-variable-tp4020158p4020159.html">http://drools.46999.n3.nabble.com/rule-infinitely-loops-appears-to-be-depending-on-naming-on-variable-tp4020158p4020159.html</a><br>Sent from the Drools: User forum mailing list archive at <a href="http://Nabble.com">Nabble.com</a>.<br>_______________________________________________<br>rules-users mailing list<br><a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>https://lists.jboss.org/mailman/listinfo/rules-users<br></blockquote></div><br></div></body></html>