I using the code from https://github.com/gwenshap/kafka-streams-stockstats with latest windowedBy()
final TimeWindows window = TimeWindows.of(Duration.ofMinutes(1));
......
.windowedBy(window)
Then printing the stream
stats.foreach((key, value) -> logger.info("Key >>>>> "+ key +
" Value => "+value.countTrades));
I am getting the below output for the same key and 1 Minute windowed. I am expecting a single record with this key per 1 min windowed. What I am missing here?
> Line 817: [2021-03-29 15:40:21,444] INFO Key >>>>>> [AES@1617012600000/1617012660000] Value => 19 > Line 823: [2021-03-29 15:40:52,111] INFO Key >>>>>> [AES@1617012600000/1617012660000] Value => 43 > Line 837: [2021-03-29 15:41:24,076] INFO Key >>>>>> [AES@1617012600000/1617012660000] Value => 55
Note: I have tried to suppress() also.