-
Bug
-
Resolution: Done
-
Critical
-
6.1.0.CR2, 6.2.0.Beta1
-
None
-
None
Hello guys,
we found some contradiction between actual Drools behavior,
We use the following Rule:
import drools.test.Event;
dialect "mvel"
declare Event
@role(event)
@expires(10s)
end
rule "ExampleRule"
when
( $a : Event(name == "event a") ) and
( $b : Event((name == "event b") && (this after [1ms, 15s] $a)) )
then
System.out.println("bingo!");
end
In the code above Drools should wait for the second event when the first event came. But it turns out that Drools doesn't wait for the second event because of @expires tag. The value in this tag is less than this after value.
According to documentation
"The engine will make this analysis for the whole rulebase and find the offset for every event type. Whenever an implicit expiration offset clashes with the explicit expiration offset, then engine will use the greater of the two."
but it is not calculating maximal expiration offset. Also we are using STREAM mode.
Could you please clarify the situation?