[
https://issues.apache.org/jira/browse/FLINK-38217?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
ASF GitHub Bot updated FLINK-38217:
-----------------------------------
Labels: pull-request-available (was: )
> ChangelogNormalize unnecessarily emits updates for equal rows
> -------------------------------------------------------------
>
> Key: FLINK-38217
> URL: https://issues.apache.org/jira/browse/FLINK-38217
> Project: Flink
> Issue Type: Bug
> Components: Table SQL / Runtime
> Affects Versions: 2.0.0, 1.19.3, 1.20.2
> Reporter: Dawid Wysakowicz
> Assignee: Sergey Nuyanzin
> Priority: Major
> Labels: pull-request-available
>
> DeduplicateFunctionHelper has logic for skipping rows if the previous emitted
> row is the same as the new incoming record:
> *
> https://github.com/apache/flink/blob/e36309a420c4c30ad98026c192881784edc58b7f/flink-table/flink-table-runtime/src/main/java/org/apache/flink/table/runtime/operators/deduplicate/utils/DeduplicateFunctionHelper.java#L120
> *
> https://github.com/apache/flink/blob/e36309a420c4c30ad98026c192881784edc58b7f/flink-table/flink-table-runtime/src/main/java/org/apache/flink/table/runtime/operators/deduplicate/utils/DeduplicateFunctionHelper.java#L179
> Unfortunately it has a bug that it compares the entire Row including the
> RowKind. The Row stored in the state has always {{INSERT}} RowKind whereas
> the incoming records will have {{UPDATE_AFTER}} causing this optimisation to
> never trigger.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)