Is there any way to find out last two events with some common properties. In my app I'd defined a pojo as drools event whose expiry time is say 5 mins. Now I want to access the properties of last two events.
say something like this rule "Props" when $E1 : MyEvent(prop1 = "MyProp") from entry-point MyStream $E2 : MyEvent(prop1 = "MyProp", this != $E1) from entry-point MyStream then Do something end In the above rule my concern is that since the expiry time is 5 minutes and I can receive any no of events during this period. How can I be sure that the above two events $E1 and $E2 are the latest one i.e. last two events received. I also thought of using sliding window but I don't know when they are going to be received say 1s, 1m, or 5m. kindly suggest -- View this message in context: http://drools-java-rules-engine.46999.n3.nabble.com/Is-there-any-way-to-find-out-last-two-events-with-some-common-properties-tp2262553p2262553.html Sent from the Drools - User mailing list archive at Nabble.com. _______________________________________________ rules-users mailing list [email protected] https://lists.jboss.org/mailman/listinfo/rules-users
