WSO2 CEP event lifecycle

你离开我真会死。 提交于 2019-12-13 07:22:50

问题


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


回答1:


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



来源:https://stackoverflow.com/questions/35267646/wso2-cep-event-lifecycle

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!