Skip to content

[flink][cdc] Track schema event progress in CDC source reader#8311

Merged
JingsongLi merged 1 commit into
apache:masterfrom
QuakeWang:cdc-schema-progress
Jun 22, 2026
Merged

[flink][cdc] Track schema event progress in CDC source reader#8311
JingsongLi merged 1 commit into
apache:masterfrom
QuakeWang:cdc-schema-progress

Conversation

@QuakeWang

Copy link
Copy Markdown
Member

Purpose

The CDC source reader restored split progress only from data row recordsToSkip. Schema change events can be emitted before any data rows are consumed, but that progress was not checkpointed independently. After recovery, the reader could emit the same schema change events again.

This PR adds explicit schema event progress to TableAwareFileStoreSourceSplit and tracks it with a CDC-specific split state. The split reader skips already emitted schema change events on restore, while preserving V1 checkpoint compatibility through a legacy progress marker.

Tests

  • git diff --cached --check
  • mvn -pl paimon-flink/paimon-flink-cdc -am -DskipTests compile
  • mvn -pl paimon-flink/paimon-flink-cdc -am -Pfast-build -DfailIfNoTests=false -Dtest=CDCCheckpointSerializerTest,CDCSourceEnumeratorTest,CDCSourceSplitReaderTest,CDCSourceTableManagerTest,TableAwareFileStoreSourceSplitSerializerTest,CDCSourceSplitStateTest test

Signed-off-by: QuakeWang <wangfuzheng0814@foxmail.com>
@JingsongLi

Copy link
Copy Markdown
Contributor

+1

@JingsongLi JingsongLi merged commit fa57a21 into apache:master Jun 22, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants