I&#39;ve declared an @expires of 30s for both events. However, my problem is that within a 30 second window it doesn&#39;t seem possible to ascertain whether both of the events occur simultaneously. I could change the @expires to 10 seconds for the above rule, which would make it work. However, I would like to be to perform more complicated matches, e.g. matching sequences of events which occur after another.<br>
<br>        $f : Double(doubleValue &gt; 1.0) from accumulate( Event($v : value, name == &quot;Foo&quot;) over window:time ( 10s )<br>
            from entry-point EntryPoint, average($v))<br><br>        // following event must start immediately _after_ the above.<br><br>        $b : Double(doubleValue &lt; 1.0) from accumulate( Event($v : value, name == &quot;Bar&quot;) over window:time ( 20s )<br>
            from entry-point EntryPoint, average($v))<br><br>Any suggestions how I can achieve this kind of functionality?<br><br>Many Thanks,<br><br>Paul<br><br><br><div class="gmail_quote">On Sun, Jan 17, 2010 at 4:19 AM, Greg Barton <span dir="ltr">&lt;<a href="mailto:greg_barton@yahoo.com">greg_barton@yahoo.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Do your Foo and Bar events declare an @expires value?  If their expiration is less than 10 seconds then the rule below won&#39;t work properly. (And by default an event&#39;s expiration is 0, which makes the rule below go wacky if @expires hasn&#39;t been declared...)  If the @expires is 10s or greater for both events it should work.<br>

<br>
--- On Thu, 1/14/10, Paul R. &lt;<a href="mailto:reverselogic@gmail.com">reverselogic@gmail.com</a>&gt; wrote:<br>
<br>
&gt; From: Paul R. &lt;<a href="mailto:reverselogic@gmail.com">reverselogic@gmail.com</a>&gt;<br>
&gt; Subject: [rules-users] Accumulate + Temporal Operators<br>
&gt; To: <a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
&gt; Date: Thursday, January 14, 2010, 1:56 PM<br>
<div><div></div><div class="h5">&gt; Hi,<br>
&gt;<br>
&gt; I&#39;m using accumulate with sliding windows to verify<br>
&gt; that certain event conditions are present for a specified<br>
&gt; period of time, which works fine, however<br>
&gt; I need to verify that both conditions are present at the<br>
&gt; same time, i.e Foo.value &gt; 1 for 10 seconds and Bar.value<br>
&gt; &lt; 1 for 10 seconds. There doesn&#39;t<br>
&gt;<br>
&gt; appear to be an obvious way to use the temporal operators<br>
&gt; in this situation. Can anybody offer any suggestions?<br>
&gt;<br>
&gt;     rule test no-loop true<br>
&gt;     when<br>
&gt;         $f : Double(doubleValue &gt; 1.0) from<br>
&gt; accumulate( Foo($v : value) over window:time ( 10s )<br>
&gt;<br>
&gt;             from entry-point EntryPoint,<br>
&gt; min($v))<br>
&gt;         $b : Double(doubleValue &lt; 1.0) from<br>
&gt; accumulate( Bar($v : value) over window:time ( 10s )<br>
&gt;             from entry-point EntryPoint,<br>
&gt; max($v))<br>
&gt;     then<br>
&gt;<br>
&gt;         // ...<br>
&gt;     end<br>
&gt;    <br>
&gt; Any help greatly appreciated.<br>
&gt;<br>
&gt; Thanks,<br>
&gt;<br>
&gt; Paul<br>
&gt;<br>
&gt;<br>
</div></div>&gt; -----Inline Attachment Follows-----<br>
<div><div></div><div class="h5">&gt;<br>
&gt; _______________________________________________<br>
&gt; rules-users mailing list<br>
&gt; <a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
&gt; <a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
&gt;<br>
<br>
<br>
<br>
<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org">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>