Window Process function is not getting trigger

2021-02-23 Thread sagar
I have simple flink stream program, where I am using socket as my continuous source I have window size of 2 seconds. Somehow my window process function is not triggering and even if I pass events in any order, flink is not ignoring I can see the output only when I kill my socket , please find the

Re: Window Process function is not getting trigger

2021-02-23 Thread Kezhu Wang
I saw one potential issue. Your timestamp assigner returns timestamp in second resolution while Flink requires millisecond resolution. Best, Kezhu Wang On February 24, 2021 at 11:49:59, sagar (sagarban...@gmail.com) wrote: I have simple flink stream program, where I am using socket as my contin

Re: Window Process function is not getting trigger

2021-02-23 Thread sagar
HI Corrected with below code, but still getting same issue Instant instant = p.getAsOfDateTime().atZone(ZoneId.systemDefault()).toInstant(); long timeInMillis = instant.toEpochMilli(); System.out.println(timeInMillis); return timeInMillis; On Wed, Feb 24, 2021 at 10:34 AM Kezhu Wang wrote: >

Re: Window Process function is not getting trigger

2021-02-23 Thread sagar
It is fairly simple requirement, if I changed it to PRocessing time it works fine , but not working with event time..help appreciated! On Wed, Feb 24, 2021 at 10:51 AM sagar wrote: > HI > > Corrected with below code, but still getting same issue > > Instant instant = > p.getAsOfDateTime().atZon

Re: Window Process function is not getting trigger

2021-02-24 Thread Kezhu Wang
Try `env.setParallelism(1)`. Default parallelism for local environment is `Runtime.getRuntime.availableProcessors`. You test data set are so small that when they are scatter cross multiple parallel instances, there will be no data with event time assigned to trigger downstream computation. Or you

Re: Window Process function is not getting trigger

2021-02-24 Thread sagar
Thanks Kezhu, It worked!!! On Wed, Feb 24, 2021 at 2:47 PM Kezhu Wang wrote: > Try `env.setParallelism(1)`. Default parallelism for local environment is > `Runtime.getRuntime.availableProcessors`. > > You test data set are so small that when they are scatter cross multiple > parallel instances,

Re: Window Process function is not getting trigger

2021-02-28 Thread Kezhu Wang
Hi, Glad to hear. Normally, you would not encounter this if there are massive data. `WatermarkStrategy.withIdleness` could be more appropriate in production. Best, Kezhu Wang On February 24, 2021 at 22:35:11, sagar (sagarban...@gmail.com) wrote: Thanks Kezhu, It worked!!! On Wed, Feb 24, 20