I am new to Esper. I need help to maintain the EPL flow. I have a java class EsperTest.java, that class is sending the data to EPL for the calculation in every 10 Sec.
In EPL's I have 4 Compression Level. E.g. CompressionA, CompressionB, CompressionC, CompressionD. In each compression, we are performing grouping based on some fields.
After the calculation has been completed for CompressionA, we raised an Event i.e 'CompressionACompleted'. On the basis of 'CompressionACompleted', we start calculation of CompressionB. And after the calculation has been completed for CompressionB, we raised an Event i.e 'CompressionBCompleted'. On the basis of 'CompressionBCompleted', we start calculation of CompressionC and so on.
Now the problem is that I have a list that contains 100 values. The java class (EsperTest.java) is sending the value to Esper one by one. And so all compressions are calculated for each value in the list.
Now, I want that 1 compression should calculate one for all 100 changes. i.e. when 100 values are sent to EPL then CompressionA should calculate for all 100 value 1 time, then CompressionB should start updating once CompressionA is complete and update for the whole window. Then CompressionC should start updating once B completes calculation.
Our current flow is causing high CPU usage or High memory consumption as if changed value number increases calculation time and complexity increases. Please help me to change EPL's structure in my application.