Tumbling
- class windows.Tumbling
-
Window producing a single value at each predicate.
“Tumbling” windows are a series of non-overlapping windows that produce values
each time the predicate evaluates to true. Each window is exclusive of the time
it starts at and inclusive of the end time.
- Parameters:
-
predicate (Timestream | Callable[, Timestream] | bool)
the condition used to determine when the window resets.
NotesLike other systems, Kaskada treats tumbling windows as non-overlapping. When one window ends the next starts. Unlike other systems, tumbling windows do not need to be of a fixed size. Instead, they may be determined by a fixed duration, a calendar duration (such as a “month”), or even a predicate.
- static windows.Tumbling.daily()
-
Return a tumbling window that resets at the start of each calendar day.
- Returns:
-
Window for aggregating values since the predicate.
- static windows.Tumbling.hourly()
-
Return a tumbling window that resets at the start of each calendar hour.
- Returns:
-
Window for aggregating values since the predicate.
- static windows.Tumbling.minutely()
-
Return a tumbling window that resets at the start of each calendar minute.
- Returns:
-
Window for aggregating values since the predicate.
- static windows.Tumbling.monthly()
-
Return a tumbling window that resets at the start of each calendar month.
- Returns:
-
Window for aggregating values since the predicate.
- static windows.Tumbling.yearly()
-
Return a tumbling window that resets at the start of each calendar year.
- Returns:
-
Window for aggregating values since the predicate.