You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Aljoscha Krettek (JIRA)" <ji...@apache.org> on 2018/07/17 12:56:00 UTC

[jira] [Closed] (FLINK-9857) Processing-time timers fire too early

     [ https://issues.apache.org/jira/browse/FLINK-9857?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Aljoscha Krettek closed FLINK-9857.
-----------------------------------
    Resolution: Fixed

Fixed on master in
690bc370e19d8003add4e41c05acfb4dccc662b4

Fixed on release-1.6 in
ffeb978260c0ce770911183ff042e502724a3fd3

Fixed on release-1.5 in
726f1cce32ed3f0f7c04c289f2d089438ecdaae6

> Processing-time timers fire too early
> -------------------------------------
>
>                 Key: FLINK-9857
>                 URL: https://issues.apache.org/jira/browse/FLINK-9857
>             Project: Flink
>          Issue Type: Bug
>          Components: DataStream API
>    Affects Versions: 1.3.4, 1.4.2, 1.5.1, 1.6.0
>            Reporter: Aljoscha Krettek
>            Assignee: Aljoscha Krettek
>            Priority: Blocker
>              Labels: pull-request-available
>             Fix For: 1.5.2, 1.6.0
>
>
> The firing of processing-time timers is off by one. This leads to problems in edge cases, as discovered [here (mailing list)|https://lists.apache.org/thread.html/e49748fa5fa1c9217b9dfb65eea7a37af1f2895c769528e77a1a93fa@%3Cuser.flink.apache.org%3E] when elements arrive at the timestamp that is the end of the window.
> The problem is [here (github)|https://github.com/apache/flink/blob/79b38f8f9a79b917d525842cf46087c5b8c40f3d/flink-streaming-java/src/main/java/org/apache/flink/streaming/api/operators/HeapInternalTimerService.java#L231]. For event-time, we fire timers when the watermark is >= the timestamp, this is correct because a watermark T says that we will not see elements with a timestamp smaller or equal to T. For processing time, a time of T does not say that we won't see an element with timestamp T, which makes processing-time timers fire one ms too early.
> I think we can fix it by turning that {{<=}} into a {{<}}.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)