When using "next", this pattern works fine for the both a match as well as
a timeout:
Pattern<Event, Event> pattern = Pattern.<Event>begin("start")
.where(evt -> evt.value.equals("ni"))
.next("last").where(evt ->
evt.value.equals("ar")).within(Time.seconds(5));
1. "ni" then "ar" within 5 seconds - triggers match
2. "ni" then no "ar" within 5 seconds - triggers timeout
But with "followedBy", this does not behave as expected:
Pattern<Event, Event> pattern = Pattern.<Event>begin("start")
.where(evt -> evt.value.equals("ni"))
.followedBy("last").where(evt ->
evt.value.equals("ar")).within(Time.seconds(5));
"ni" then "ar" within 5 seconds - triggers match and also triggers timeout.
Why is the timeout triggered when using followedBy (when there is a match)?
Version - 1.1.5.