flink-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From John Sherwood <...@vt.edu>
Subject Re: implementing a continuous time window
Date Thu, 21 Apr 2016 19:14:01 GMT
You are looking for sliding windows:
https://flink.apache.org/news/2015/12/04/Introducing-windows.html

Here you would do

.timeWindow(Time.seconds(5), Time.seconds(1))

On Thu, Apr 21, 2016 at 12:06 PM, Jonathan Yom-Tov <jon.yomtov@gmail.com>
wrote:

> hi,
>
> Is it possible to implement a continuous time window with flink? Here's an
> example. Say I want to count events within a window. The window length is 5
> seconds and I get events at t = 1, 2, 7, 8 seconds. I would then expect to
> get events with a count at t = 1 (count = 1), t = 2 (count = 2), t = 6
> (count = 1), t = 7 (count = 2), t = 8 (count = 2), t = 12 (count = 1) and t
> = 13 (count = 0).
>
> How would I go about doing that?.
>
> thanks,
> Jon.
>

Mime
View raw message