[ 
https://issues.apache.org/jira/browse/FLINK-8594?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16355530#comment-16355530
 ] 

Fabian Hueske commented on FLINK-8594:
--------------------------------------

Copying my comment from FLINK-8564

Yes, that would be possible. However, I'm unsure if we should do that. It might 
be perceived as an inconsistent behavior. I'd rather add a dedicated 
{{DISTINCT}} operator and handle the messages to reset the clean-up timers 
differently. Then {{DISTINCT}} would always produce append streams, even with 
configured state retention time.

Does that make sense?


> Make producesUpdates in DataStreamGroupAggregate return false if it is a 
> distinct group by without state retention configuration 
> ---------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: FLINK-8594
>                 URL: https://issues.apache.org/jira/browse/FLINK-8594
>             Project: Flink
>          Issue Type: Improvement
>          Components: Table API & SQL
>            Reporter: Hequn Cheng
>            Assignee: Hequn Cheng
>            Priority: Major
>
> Internally, the {{DISTINCT}} is translated into a {{GROUP BY}} with all 
> distinct fields being keys and no aggregation functions. However, this kind 
> of \{{GROUP BY}} don't generate update at all if the state retention time has 
> not been configured. We can treat the result table as an append table. 
> Therefore, we can make the \{{producesUpdates}} function return false, so the 
> downstream group by will not choose the correspond retract agg function, 
> i.e., {{MaxWithRetractAggFunction}}



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

Reply via email to