<br>&nbsp;&nbsp; Do you know the concept of sliding time windows? Meaning you define a time interval, for instance the last 30 seconds, so at time T30, the window contains anything that happened between T1 and T30. At T31, it forgets anything that happened on T1 and the window now contains everything from T2 to T31, and so on.<br>
<br>&nbsp;&nbsp; So, think about sliding windows as a filter.<br><br>
StockTick( symbol == &quot;RHAT&quot; ) over window:time( 60s )<br><br>&nbsp;&nbsp; The pattern above will match all StockTicks whose symbol is RHAT and that happened in the last 60 seconds. Since time is continuous (unless you use a pseudo clock that you control manually), events will age and fall outside the boundary of the window (in this case, older than 60 seconds). When that happens, they will expired and will no longer match.<br>
<br>&nbsp;&nbsp; Once a regular activation is created, it will remain in the agenda until it is fired. Even if the event expires before the activation is fired. The only &quot;special case&quot; for this are the aggregations, that are constantly updated and at fire time, will contain the current result.<br>
<br>&nbsp;&nbsp; Over is just the keyword used to introduce behaviors of a pattern, like time windows, length windows and so on. Hopefully docs will contain a better explanation.<br><br>&nbsp;&nbsp; []s<br>&nbsp;&nbsp; Edson<br><br><br><div class="gmail_quote">
2009/2/2 Trägenap <span dir="ltr">&lt;<a href="mailto:traegenap@ttc-informatik.de">traegenap@ttc-informatik.de</a>&gt;</span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
I hope you will not be interrupted by too many postings....<br>
<br>
but -sorry- what is the result of<div class="Ih2E3d"><br>
<br>
StockTick( symbol == &quot;RHAT&quot; ) over window:time( 1h30m15s )<br>
<br></div>
?<br>
<br>
a) all StockTick Entities which has symbol &quot;RHAT&quot; at some point during the time period? In other words: are StockTicks included where symbol had changed for e.g. within the first 30 minutes?<br>
<br>
b) all StockTick Entities which have symbol &quot;RHAT&quot; when rule fires?<br>
<br>
What means &quot;over&quot;? Is the rule allowed to fire after period of 1h30m14s, is this right?<br>
<br>
<br>
Thanks<br>
Thorsten<br>
<br>
<br>
Edson Tirelli schrieb:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="Ih2E3d">
<br>
 &nbsp; I started writing fusion docs a couple days ago. You can follow the progress through hudson builds or checking out the source code from svn.<br>
<br>
 &nbsp; Regarding your question, clock ticks are an abstract concept that depends on the clock implementation you are using. Since I wrote the test case you saw, I added support for proper time units, and as so, I recommend you use them. So, if you want to create a sliding window of 1 hour 30 min and 15 seconds, for instance, just do:<br>

<br>
StockTick( symbol == &quot;RHAT&quot; ) over window:time( 1h30m15s )<br>
<br>
 &nbsp; I did not wrote that part of the docs yet, and in case anyone want to help, it would be most welcome.<br>
<br>
 &nbsp; []s<br>
 &nbsp; Edson<br>
<br></div>
2009/2/1 Trägenap &lt;<a href="mailto:traegenap@ttc-informatik.de" target="_blank">traegenap@ttc-informatik.de</a> &lt;mailto:<a href="mailto:traegenap@ttc-informatik.de" target="_blank">traegenap@ttc-informatik.de</a>&gt;&gt;<div class="Ih2E3d">
<br>
<br>
 &nbsp; &nbsp;Hi,<br>
<br>
 &nbsp; &nbsp;2 questions:<br>
<br>
 &nbsp; &nbsp;1. I want to start a ruleflow-group for e.g. only once a day? I am<br>
 &nbsp; &nbsp;not interested in the pattern matches during the complete day, just<br>
 &nbsp; &nbsp;interested in the result of the single computation. My<br>
 &nbsp; &nbsp;ruleflow-group is ordered using a salience, the final/last rule<br>
 &nbsp; &nbsp;should be processed once a day, repeating at the next day, and so on...<br>
<br>
 &nbsp; &nbsp;I found the example like this<br>
<br>
 &nbsp; &nbsp;StockTick( symbol == &quot;RHAT&quot; ) over window:time( 60 )<br>
<br>
 &nbsp; &nbsp;(...that happened in the last 60 clock ticks...)<br>
<br>
 &nbsp; &nbsp;What is declared as &quot;clock ticks&quot;?<br>
<br>
<br>
 &nbsp; &nbsp;2. I guess that drools fusion can solve my problem, is some more<br>
 &nbsp; &nbsp;detailed doc available at this moment? (more than the ´pure´<br>
 &nbsp; &nbsp;headlines containing doc I found everywhere?)<br>
<br>
 &nbsp; &nbsp;Thanks for advice, including just giving keywords!<br>
<br>
 &nbsp; &nbsp;Thorsten<br>
 &nbsp; &nbsp;_______________________________________________<br>
 &nbsp; &nbsp;rules-users mailing list<br></div>
 &nbsp; &nbsp;<a href="mailto:rules-users@lists.jboss.org" target="_blank">rules-users@lists.jboss.org</a> &lt;mailto:<a href="mailto:rules-users@lists.jboss.org" target="_blank">rules-users@lists.jboss.org</a>&gt;<div class="Ih2E3d">
<br>
 &nbsp; &nbsp;<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
<br>
<br>
<br>
<br>
-- <br>
&nbsp;Edson Tirelli<br>
&nbsp;JBoss Drools Core Development<br></div>
&nbsp;JBoss, a division of Red Hat @ <a href="http://www.jboss.com" target="_blank">www.jboss.com</a> &lt;<a href="http://www.jboss.com" target="_blank">http://www.jboss.com</a>&gt;<br>
<br>
<br>
------------------------------------------------------------------------<div class="Ih2E3d"><br>
<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org" target="_blank">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>
</div></blockquote>
<br>
<br>
-- <br>
<br>
<br>
*Gesprächspartner:*<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;<br>
<br>
<br>
<br>
*Datum:*<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;<br>
<br>
<br>
<br>
*Inhalt:*<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;<br>
<br>
<br>
<br>
*TODO:*<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;<br>
<br>
<br>
<br>
*Rückmeldung bis:*<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;<br>
<br>
<br>
<br>
*Absender:*<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;<br>
<br>
&nbsp;TT<div><div></div><div class="Wj3C7c"><br>
<br>
<br>
<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org" target="_blank">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>
</div></div></blockquote></div><br><br clear="all"><br>-- <br> &nbsp;Edson Tirelli<br> &nbsp;JBoss Drools Core Development<br> &nbsp;JBoss, a division of Red Hat @ <a href="http://www.jboss.com">www.jboss.com</a><br>