<br>
you could go with the option of having a parameter for the assert.<br>
<br>
if the user knows they absolutely don&#39;t want shadow and plan to assert
1million facts, they can assert without shadow. otherwise they can call
the default assert.<br>
<br>
jamocha&#39;s assert has 4 parameters<br>
assertObject(Object data, String template, boolean statc, boolean shadow)<br>
<br>
of course if someone uses JSR94, they won&#39;t be able to do anything beyond the stupid API<br>
<br>
peter<br><br><div><span class="gmail_quote">On 2/10/07, <b class="gmail_sendername">Mark Proctor</b> &lt;<a href="mailto:mproctor@codehaus.org">mproctor@codehaus.org</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
I&#39;m finding that in manners shadow facts add on average about 10% or<br>under to execution times.<br><br>test by changing:<br>count.setValue(&nbsp;&nbsp;count.getValue() + 1 );<br>modify( count );<br><br>To (with shadow facts turned off)
<br>retract( count );<br>count.setValue(&nbsp;&nbsp;count.getValue() + 1 );<br>assert( count );<br><br>The problem I&#39;m having is finding a generic and clean way to make shadow<br>facts configurable and have the .drl adapt appropriately, without the
<br>user having to manually do retract and asserts, instead of a modify.<br><br>Having had feedback from users that are asserting a huge number of facts<br>(approx 1mill) into the working memory, having the ability to not deal
<br>with shadowfacts will improve performance and memory, more so than in<br>the case of manners. I&#39;d be interested ot know if the 10% or less rule<br>is still true with those large numbers, and also the size in memory.
<br><br>Mark<br><br>_______________________________________________<br>rules-dev mailing list<br><a href="mailto:rules-dev@lists.jboss.org">rules-dev@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/rules-dev">
https://lists.jboss.org/mailman/listinfo/rules-dev</a><br></blockquote></div><br>