You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "John Roesler (JIRA)" <ji...@apache.org> on 2019/06/19 18:59:00 UTC
[jira] [Commented] (KAFKA-8504) Update Docs to explain how to use
suppress() in more details
[ https://issues.apache.org/jira/browse/KAFKA-8504?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16867907#comment-16867907 ]
John Roesler commented on KAFKA-8504:
-------------------------------------
Hi Simone,
Sorry for the confusion. This sharp edge was and is a big concern for me, but I think we're "trapped" by the backward compatibility requirement.
I've tried to call it out whenever I discuss suppression, but it seems I missed it in the actual documentation. For reference, I think a special note callout should be added to this section of the docs, starting in 2.1: https://kafka.apache.org/21/documentation/streams/developer-guide/dsl-api.html#window-final-results
Is there anywhere else you think should be updated?
Thanks,
-John
> Update Docs to explain how to use suppress() in more details
> ------------------------------------------------------------
>
> Key: KAFKA-8504
> URL: https://issues.apache.org/jira/browse/KAFKA-8504
> Project: Kafka
> Issue Type: Improvement
> Components: documentation, streams
> Affects Versions: 2.2.1
> Reporter: Simone Esposito
> Priority: Minor
> Labels: newbie
>
> Hi, I'm playing a bit with KafkaStream and the new suppress feature. I noticed that when using a {{TimeWindows}} without explicitly setting the grace {{suppress}} will not emit any message if used with {{Suppressed.untilWindowCloses.}}
> I look a bit into the code and from what I understood with this configuration {{suppress}} should use the {{grace}} setting of the {{TimeWindows}}. But since using {{TimeWindows.of(Duration)}} default the grace to {{-1}} and when getting the grace using the method {{TimeWindows.gracePeriodMs()}} in case of grace equals to -1 the return value is set to {{maintainMs() - size()}} I think that the end of window is not properly calculated.
> Of course is possible to avoid this problem forcing the {{grace}} to 0 when creating the TimeWindows but I think that this should be the default behaviour at least when it comes to the suppress feature.
> I hope I have not misunderstood the code in my analysis, thank you :)
> Simone
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)