Hi Guys, I have one question about how lenght windows will work. I have a rule like this. Basically, it is a "crosses" function, where the value of my object crosses a value.
rule "mytest" dialect "mvel" when t2_1 : Tick( value < 102.352 ) over window:length (1) t1_1 : Tick( this before t2_1 , value >= 102.352 ) over window:length (2) then //DO SOMETHING end 23:51:32,150 INFO [org.drools.core.audit.WorkingMemoryConsoleLogger] (Camel (camel-1) thread #2 - JmsConsumer[]) ACTIVATION FIRED rule:mytest activationId:berarrr_1 [0, 27, 26] declarations: t2_1=Tick [value=102.351, tickTime=Fri May 02 05:51:31 ART 2014](27); t1_1=Tick [value=102.352, tickTime=Fri May 02 05:51:12 ART 2014](26) 23:53:30,560 INFO [org.drools.core.audit.WorkingMemoryConsoleLogger] (Camel (camel-1) thread #2 - JmsConsumer[]) ACTIVATION CREATED rule:mytest activationId:berarrr_1 [0, 146, 26] declarations: t2_1=Tick [value=102.349, tickTime=Fri May 02 05:53:30 ART 2014](146); t1_1=Tick [value=102.352, tickTime=Fri May 02 05:51:12 ART 2014](26) If you see, the first activation, the window:length(1), matched the object 27 window:length(2), matched the object 26 Then, after 2 minutes and some Ticks insertes in the WM window:length(1), matched the object 146 but window:length(2), still matched the object 26 I would expect, that, as object 26 was the first one to be inserted, then it is outside the window:length(2). Is my understanding correct? Am I making something wrong? I am using Drools 6. Thanks! Demian
_______________________________________________ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users