Sliding window

Windows with interval and after processing slide the window on the basis of time interval. One tuple is processed in more than one window. It is explained in the following screenshot:

Here, windows are overlapping and one event can be part of more than one window. In the example of the window function, we will integrate the feed from Kafka and check the output on the console.

The code is taken from https://github.com/apache/storm/blob/v1.0.3/examples/storm-starter/src/jvm/org/apache/storm/starter/trident/TridentKafkaWordCount.java but modified to work with Kafka and also added prints. You will find the complete code in the code ...

Get Practical Real-time Data Processing and Analytics now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.