<!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">
feel free to work on a patch for us and let us know what you come up
with.<br>
<br>
Mark<br>
Felipe Piccolini wrote:
<blockquote cite="mid:FF1320A9-B34D-4FBD-A9C2-4D840DCEFC16@bluesoft.cl"
type="cite">
<div style="margin: 0px;">Mark,</div>
<div
style="margin: 0px; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal; min-height: 14px;"><br>
</div>
<div style="margin: 0px;"> What about my previous mail where I
report an issue with update using dynamic JavaBeans (using
propertyListeners)?</div>
<div
style="margin: 0px; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">The problem is that when the engine is
fired again from an propertyListener the evaluations on conditions
(seems to me)</div>
<div style="margin: 0px;">dont take the new state of the Facts
changed in the set<Attribute> call.</div>
<div
style="margin: 0px; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">I will try using MVEL modify, but thats not
the better solution, because the feature of propertyListerners inside
javaBeans let</div>
<div style="margin: 0px;">me write my rules in a cleaner way from
BRMS/bussines editor.</div>
<div
style="margin: 0px; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">Thanks.</div>
<div><br class="khtml-block-placeholder">
</div>
<br>
<div>
<div>On 28-06-2007, at 8:28, Mark Proctor wrote:</div>
<br class="Apple-interchange-newline">
<blockquote type="cite">
<div style="margin: 0px;">If it can be done cleanly I'm not averse
to it. however there is something else...</div>
<div style="margin: 0px;">In the new MVEL dialect you no longer
need propertychangelisteners if you don't want to call update()</div>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">modify ( cheese ) { price = 25, quality =
premium }</div>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">This will modify all the setters and
notify the engine at the end of the block setter. Is that good enough
for you?</div>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">Mark</div>
<div style="margin: 0px;">Yuri de Wit wrote:</div>
<blockquote type="cite">
<div style="margin: 0px;">Mark,</div>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">btw, If this is a feature that makes
sense from Drools pov I wouldnt</div>
<div style="margin: 0px;">mind giving a shot at implementing it
and contributing it back to</div>
<div style="margin: 0px;">Drools.</div>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">-- yuri</div>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">On 6/28/07, Yuri de Wit <<a
moz-do-not-send="true" href="mailto:ydewit@gmail.com">ydewit@gmail.com</a>>
wrote:</div>
<blockquote type="cite">
<div style="margin: 0px;">Sure. The solution I am taking right
now is dont use dynamic</div>
<div style="margin: 0px;">properties, which is not optimal
(depending on the problem property</div>
<div style="margin: 0px;">changes not being batched defeats the
purpose of dynamic beans).</div>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">The bottom line is that I was hoping
that this feature would (1)</div>
<div style="margin: 0px;">either already be taken care of in
4.0 or (2) become a feature request</div>
<div style="margin: 0px;">for future releases.</div>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">-- yuri</div>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">On 6/28/07, Mark Proctor <<a
moz-do-not-send="true" href="mailto:mproctor@codehaus.org">mproctor@codehaus.org</a>>
wrote:</div>
<div style="margin: 0px;">> No we don't do anything to batch
property change listener results. But</div>
<div style="margin: 0px;">> maybe you can do this yourself.</div>
<div style="margin: 0px;">> instead of calling modify, add
it to a transaction list (that you make</div>
<div style="margin: 0px;">> available in the current
context). Then at the end of the consequence</div>
<div style="margin: 0px;">> you can iterate that list and
call modify on each object. Or</div>
<div style="margin: 0px;">> alternatively don't use dynamic
properties.</div>
<div style="margin: 0px;">></div>
<div style="margin: 0px;">> Mark</div>
<div style="margin: 0px;">> Yuri de Wit wrote:</div>
<div style="margin: 0px;">> > I am not talking about
assert, but modify. I have a dynamic fact</div>
<div style="margin: 0px;">> > already asserted but now I
need to perform N changes on N different</div>
<div style="margin: 0px;">> > properties on the same
object on the same consequence. Drools is going</div>
<div style="margin: 0px;">> > to traverse the RETE
network N times once for each time the</div>
<div style="margin: 0px;">> > PropertiesListener is
called (each setProperty called).</div>
<div style="margin: 0px;">> ></div>
<div style="margin: 0px;">> > -- yuri</div>
<div style="margin: 0px;">> ></div>
<div style="margin: 0px;">> > On 6/28/07, Mark Proctor
<<a moz-do-not-send="true" href="mailto:mproctor@codehaus.org">mproctor@codehaus.org</a>>
wrote:</div>
<div style="margin: 0px;">> >> Why would doing the
assert work at the end of the consequence be any</div>
<div style="margin: 0px;">> >> quicker than doing it
during the consequence?</div>
<div style="margin: 0px;">> >></div>
<div style="margin: 0px;">> >> Mark</div>
<div style="margin: 0px;">> >> Yuri de Wit wrote:</div>
<div style="margin: 0px;">> >> > I noticed that
changes performed on facts asserted dynamically causes</div>
<div style="margin: 0px;">> >> > the fact to be
modified right away and therefore triggering a RETE</div>
<div style="margin: 0px;">> >> > network traversal
and rule schedulings.</div>
<div style="margin: 0px;">> >> ></div>
<div style="margin: 0px;">> >> > For apps with a
large number of facts this could be a significant</div>
<div style="margin: 0px;">> >> > scalability
problem. At least in my case, I would like to be able to</div>
<div style="margin: 0px;">> >> > use dynamic facts
and perform any number of updates and have those</div>
<div style="margin: 0px;">> >> > updates commited
to working memory only when the rule consequence is</div>
<div style="margin: 0px;">> >> > completed.</div>
<div style="margin: 0px;">> >> ></div>
<div style="margin: 0px;">> >> > Looking at the
code, it seems that it would not be a major effort to</div>
<div style="margin: 0px;">> >> > collect the facts
received by the ReteooWorkingMemory.propertyChange</div>
<div style="margin: 0px;">> >> > and perform the
actual modifyObject() only when the consequence</div>
<div style="margin: 0px;">> >> > evaluation is
actually completed.</div>
<div style="margin: 0px;">> >> ></div>
<div style="margin: 0px;">> >> > Does that makes
sense? Or are there side effects I am not seeing? Is</div>
<div style="margin: 0px;">> >> > this a problem
that 4.0 already resolves?</div>
<div style="margin: 0px;">> >> ></div>
<div style="margin: 0px;">> >> > thanks in advance,</div>
<div style="margin: 0px;">> >> ></div>
<div style="margin: 0px;">> >> > -- yuri</div>
<div style="margin: 0px;">> >> >
_______________________________________________</div>
<div style="margin: 0px;">> >> > rules-users
mailing list</div>
<div style="margin: 0px;">> >> > <a
moz-do-not-send="true" href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a></div>
<div style="margin: 0px;">> >> > <a
moz-do-not-send="true"
href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a></div>
<div style="margin: 0px;">> >> ></div>
<div style="margin: 0px;">> >></div>
<div style="margin: 0px;">> >>
_______________________________________________</div>
<div style="margin: 0px;">> >> rules-users mailing list</div>
<div style="margin: 0px;">> >> <a
moz-do-not-send="true" href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a></div>
<div style="margin: 0px;">> >> <a
moz-do-not-send="true"
href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a></div>
<div style="margin: 0px;">> >></div>
<div style="margin: 0px;">> >
_______________________________________________</div>
<div style="margin: 0px;">> > rules-users mailing list</div>
<div style="margin: 0px;">> > <a moz-do-not-send="true"
href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a></div>
<div style="margin: 0px;">> > <a moz-do-not-send="true"
href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a></div>
<div style="margin: 0px;">> ></div>
<div style="margin: 0px;">></div>
<div style="margin: 0px;">>
_______________________________________________</div>
<div style="margin: 0px;">> rules-users mailing list</div>
<div style="margin: 0px;">> <a moz-do-not-send="true"
href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a></div>
<div style="margin: 0px;">> <a moz-do-not-send="true"
href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a></div>
<div style="margin: 0px;">></div>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
</blockquote>
<div style="margin: 0px;">_______________________________________________</div>
<div style="margin: 0px;">rules-users mailing list</div>
<div style="margin: 0px;"><a moz-do-not-send="true"
href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a></div>
<div style="margin: 0px;"><a moz-do-not-send="true"
href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a></div>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
</blockquote>
<div style="margin: 0px; min-height: 14px;"><br>
</div>
<div style="margin: 0px;">_______________________________________________</div>
<div style="margin: 0px;">rules-users mailing list</div>
<div style="margin: 0px;"><a moz-do-not-send="true"
href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a></div>
<div style="margin: 0px;"><a moz-do-not-send="true"
href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a></div>
</blockquote>
</div>
<br>
<div> <span class="Apple-style-span"
style="border-collapse: separate; border-spacing: 0px; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; orphans: 2; white-space: normal; widows: 2; word-spacing: 0px;">
<div><span class="Apple-style-span"
style="text-decoration: underline;"><span class="Apple-style-span"
style="">
</span></span>
<div><font class="Apple-style-span" size="3"><span
class="Apple-style-span" style="font-size: 13px;"><b
style="font-size: 13px; font-weight: bold;"><span
class="Apple-style-span" style="font-size: 13px; font-weight: bold;">Felipe
Piccolini M.</span></b></span></font></div>
<div><a moz-do-not-send="true"
href="mailto:felipe.piccolini@bluesoft.cl"><span
class="Apple-style-span" style="color: rgb(0, 0, 238);">felipe.piccolini@bluesoft.cl</span></a></div>
<br class="khtml-block-placeholder">
</div>
<div><br class="khtml-block-placeholder">
</div>
<br class="Apple-interchange-newline">
</span> </div>
<br>
<pre wrap="">
<hr size="4" width="90%">
_______________________________________________
rules-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a>
<a class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a>
</pre>
</blockquote>
<br>
</body>
</html>