I currently have a session window operator with a trigger time of 2 minutes. I want to know if my understanding of the following is correct.
Is this understanding correct?
Edit. for context, the window is being aggregated
Memory usage depends on whether you are incrementally applying a reduce or aggregate function, or accumulating the window's contents for bulk processing with a ProcessWindowFunction when the window is triggered. E.g., if you are counting events per session with a reduce function, then the state required is just one integer, regardless of session length.
As for CPU, you may want to consider not just the total CPU effort expended over time, but also the CPU required to compute the results each time a window is triggered. If the windows contain a lot of events, and you are not incrementally aggregating them, there could be some noticeable latency each time a window closes.