You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Bo Cui (Jira)" <ji...@apache.org> on 2023/03/26 23:12:00 UTC
[jira] [Commented] (FLINK-31595) MiniBatchLocalGroupAggFunction produces wrong aggregate results with state clean up
[ https://issues.apache.org/jira/browse/FLINK-31595?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17705135#comment-17705135 ]
Bo Cui commented on FLINK-31595:
--------------------------------
like the sql:
select a, max(b), max(c) from (
select * from (
select *, row_number(...) as rn from T
) where rn=1
) group by a
the ttl of job is 1h and minibatch is enabled, so row_number ttl is 1.5h, group ttl is 1h.
The time of retract data may be 1.2h, and minbatch state has expired, so the aggregation result is incorrect.
> MiniBatchLocalGroupAggFunction produces wrong aggregate results with state clean up
> -----------------------------------------------------------------------------------
>
> Key: FLINK-31595
> URL: https://issues.apache.org/jira/browse/FLINK-31595
> Project: Flink
> Issue Type: Bug
> Reporter: Bo Cui
> Priority: Critical
> Labels: pull-request-available
>
> If the upstream operator supports retract data, and the first data in a batch may be retract data, and the retract data should be ignored.
> https://github.com/apache/flink/blob/a64781b1ef8f129021bdcddd3b07548e6caa4a72/flink-table/flink-table-runtime/src/main/java/org/apache/flink/table/runtime/operators/aggregate/MiniBatchLocalGroupAggFunction.java#L68
--
This message was sent by Atlassian Jira
(v8.20.10#820010)