Hi all, Hope you are doing well. I'm starting this thread to discuss $title. As we discussed in the mail thread [1], having a common window semantic that can be leveraged by every PE can be very useful.
I'm thinking of two ways to achieve the same; 1. Introduce a dedicated Window PE which can be used before any existing PE. - No need for API changes. - But, might have to flag event in a way for the next processor to identify, to which window the event belongs to (i.e with sliding windows, etc...). - So, have to change the processing logic of existing PEs to check event flag and process accordingly. - So all the existing PEs might not work with window semantics. In that case, we need a way to show window compatible PEs (because, having a window before a normal PE might result in un-expected outputs) 2. Introduce windowed EventProcessor/EventSink APIs which allows users to write their own windowed extensions (i.e aggregators, etc...) - No need for event flagging. Can introduce API methods like onCurrentEvent, onExpiredEvent, onResetEvent, etc... - Need API changes/refactoring in EventProcessor/EventSink, as well as in existing PEs. - Need a way to expose the window related parameters through existing PEs DataProcessorDescription. Since there're pros/cons to both, what do you think is the best approach? Or is there any other approach that we can try out? [1] PE to rate-limit events Grainier Perera.