<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
I guess its more to do with the drl.<br>
<br>
We currently have:<br>
count.setValue(.....);<br>
modify( count );<br>
<br>
now I can do a regexp that changes<br>
count.setValue(....); to<br>
retract( count ); count.setValue(...); assert( account );<br>
<br>
But then what happens if the user used modify. One of the advantages of
using modify(....) is you control when the progation occurs, ideal if
you are updating lots of values on the same object. And ofcourse i have
the backward compatability issue.<br>
<br>
Mark<br>
Peter Lin wrote:
<blockquote
 cite="mid:27e674a90702102026w5cf207c0u32ff1e158cb33ccc@mail.gmail.com"
 type="cite"><br>
you could go with the option of having a parameter for the assert.<br>
  <br>
if the user knows they absolutely don't want shadow and plan to assert
1million facts, they can assert without shadow. otherwise they can call
the default assert.<br>
  <br>
jamocha'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'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 moz-do-not-send="true"
 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'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'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'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 moz-do-not-send="true" href="mailto:rules-dev@lists.jboss.org">rules-dev@lists.jboss.org</a><br>
    <a moz-do-not-send="true"
 href="https://lists.jboss.org/mailman/listinfo/rules-dev">https://lists.jboss.org/mailman/listinfo/rules-dev</a><br>
  </blockquote>
  </div>
  <br>
  <pre wrap="">
<hr size="4" width="90%">
_______________________________________________
rules-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:rules-dev@lists.jboss.org">rules-dev@lists.jboss.org</a>
<a class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/rules-dev">https://lists.jboss.org/mailman/listinfo/rules-dev</a>
  </pre>
</blockquote>
<br>
</body>
</html>