Skip to content

[Bug] Key-only deletes silently disabled on Flink versions without a patch component #9052

Description

@thswlsqls

Search before asking

  • I searched in the issues and found nothing similar.

Paimon version
master @ b15bda5

Compute Engine
Flink 2.x (paimon-flink2-common)

Minimal reproduce step

  1. Run a Flink cluster built from a release branch or master. The ASF snapshot repository publishes flink-runtime as 2.1-SNAPSHOT / 2.2-SNAPSHOT, so EnvironmentInformation.getVersion() has no patch component.
  2. Write to a primary-key table with sink.key-only-deletes.enabled = true.
  3. ChangelogModeUtils.isFlink21OrAbove() (paimon-flink2-common/.../flink/utils/ChangelogModeUtils.java line 42) splits on . only, so the minor part is 2-SNAPSHOT, Integer.parseInt throws, catch (RuntimeException) swallows it, and it returns false.

What doesn't meet your expectations?
Expected: key-only deletes are enabled, since this runtime does provide the FLIP-510 ChangelogMode.Builder#keyOnlyDeletes API. Actual: ChangelogNormalize stays in the plan and the log shows the self-contradicting warning requires Flink 2.1+ (current version: 2.2-SNAPSHOT).

Anything else?
Only versions without a patch component break. 2.1.0 and 2.1.0-amzn-0 already parse correctly.

Are you willing to submit a PR?

  • I'm willing to submit a PR!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions