Sliding Window
Sliding windows, unlike Tumbling windows, output events only for points in time when the content of the window actually changes. In other words, when an event enters or exits the window. So, every window has at least one event. Note events can belong to more than one sliding window.
Time based windows
Example
Configures a sliding time based window with a size of 10 seconds.
Attributes
Attribute | Description | Data Type | Required |
---|---|---|---|
window size | Size of window with respect to timeUnit | Long | |
slide | Time interval to shift in to next window | Long | |
time unit | TimeUnit used for configuring window trigger. Supported types:
| TimeUnit Default: MILLISECONDS |
Event count based windows
Example
Configures a sliding window with a maximum of 1000 events with a slide size of 300
Attributes
Attribute | Description | Data Type | Required |
---|---|---|---|
window size | Maximum number of events before triggering window processing | Long | |
slide | Number of latest events to shift in to the next window | Long |
Last updated