Re: How should I process a cumulative counter?

2021-01-12 Thread Aljoscha Krettek
Hi Larry, By now, it seems to me that the windowing API might not be the right solution for your use case. The fact that sensors can shut down arbitrarily makes it hard to calculate what window an event should fall into. Have you tried looking into `ProcessFunction`? With this you can keep

Re: How should I process a cumulative counter?

2021-01-11 Thread Larry Aspen
Hi Aljoscha, thank you for your reply. On 2021/01/08 15:44 Aljoscha Krettek wrote: >the basic problem for your use case is that window boundaries are >inclusive for the start timestamp and exclusive for the end timestamp. That's true. What further complicates matters is that the last value of th

Re: How should I process a cumulative counter?

2021-01-08 Thread Aljoscha Krettek
Hi Larry, the basic problem for your use case is that window boundaries are inclusive for the start timestamp and exclusive for the end timestamp. It's setup like this to ensure that consecutive tumbling windows don't overlap. This is only a function of how our `WindowAssigner` works, so it

How should I process a cumulative counter?

2021-01-07 Thread Larry Aspen
Hi, I'm evaluating Flink for our company's IoT use case and read a blog post by Fabian Hueske from 2015 [1]. We have a similar situation except the sensor is sending the value of a cumulative counter instead of a count. We would like to calculate the sum of deltas of consecutive cumulative counter