I am working on making a CEP using Drools Fusion. I have two classes of events ExpectedEvent and ActualEvent. I need to make sure ActualEvent objects occur before ExpectedEvent objects. However, I cannot get the before key word to work. This is in stream mode.
import hellodrools.ExpectedEvent
import hellodrools.ActualEvent
dialect "java"
rule "On Time"
when
ExpectedEvent($expectedtime : getStart_time()) from entry-point entry one
$actual:ActualEvent( this after[ 1m ] $expected ) from entry-point entryone
then
System.out.println("ON TIME expected time: " + $expectedtime + " actual time " + $actualtime);
end
In IntelliJ I keep getting errors on $actual saying '$actual' unexpected. I cannot solve this syntax error.