Is there a way to get the last inserted event in esper core prior to rule completion?
Configuration cepConfig = new Configuration();
cepConfig.getEngineDefaults().getMetricsReporting().
setEnableMetricsReporting(true);
cepConfig.addEventType("Stream", Stream.class.getName());
EPServiceProvider cep = EPServiceProviderManager.getProvider("myCEPEngine", cepConfig);
EPRuntime cepRT = cep.getEPRuntime();
EPAdministrator cepAdm = cep.getEPAdministrator();
EPStatement cepStatement = cepAdm.createEPL("select * from Stream.win:length(100)") ;
cepStatement.addListener(new CEPListener());
Now for event insertion i am using this sample code
for (int i = 0; i < 500; i++) {
GenerateRandomStream(cepRT);
//Here I want get the last inserted event
}
Any help will be appreciated.