Hugo Calado
Hugo Calado

Reputation: 15

WSO2 CEP event lifecycle

Is there any document/article explaining the event lifecycle in WSO2 CEP? I dont quite understand how the events are discarded from the event streams.

Thank you, Hugo Calado

Upvotes: 0

Views: 168

Answers (1)

Tharik Kanaka
Tharik Kanaka

Reputation: 2510

Events will be discarded immediately. Basic flow is stream will receive events from and receivers and it will immediately push events to publisher without storing. If you want to collect event for certain time periods you can use somwthing like time windows in Siddhi Execution Plans [1].

In following Siddhi query it collects events for 10 minutes and insert into AvgTempStream by calculating average stream. In that case events will be stored for 10 minutes in memory.

from TempStream#window.time(10 min)
select avg(temp) as avgTemp, roomNo, deviceID
insert all events into AvgTempStream;

[1] https://docs.wso2.com/display/CEP400/SiddhiQL+Guide+3.0#SiddhiQLGuide3.0-Window

Upvotes: 1

Related Questions