Skip to content

Flink: Cherry-pick #16011 and its v1.20/v2.0 backport - Fix duplicate commits in DynamicCommitter when Flink jobId changes on restart - #10

Merged
nickwu241 merged 6 commits into
1.11.0-affirm-patchfrom
nick/cherry-pick-16011-dynamic-committer
Sep 22, 2026
Merged

nickwu241 merged 6 commits into
1.11.0-affirm-patchfrom
nick/cherry-pick-16011-dynamic-committer

Conversation

@nickwu241

@nickwu241 nickwu241 commented Sep 8, 2026 •

Copy link
Copy Markdown
Member

Cherry-picks apache#16011 onto 1.11.0-affirm-patch, covering flink/v2.1, flink/v1.20, and flink/v2.0.

Fixes duplicate commits in DynamicCommitter when the Flink jobId changes on restart (e.g. stop-with-savepoint, autoscaler resubmit). The committer previously deduped commits using only the newest jobId in a batch, which hid snapshots produced under a prior jobId and caused replayed committables to be committed a second time.

This is included in the upstream Iceberg 1.12.0 milestone, so this cherry-pick should no longer be needed once we upgrade to 1.12.

Commits

  1. flink/v2.1 cherry-pick — direct cherry-pick of Flink: Fix duplicate commits in DynamicCommitter when Flink jobId changes on restart apache/iceberg#16011 (apache/iceberg@c11404c).
  2. flink/v1.20 + flink/v2.0 backport — direct cherry-pick of upstream's own backport of this fix, Flink: Backport DynamicCommitter jobId fix to v1.20 and v2.0 apache/iceberg#16648 (apache/iceberg@96edcba).

Conflicts resolved (both commits)

Each cherry-pick hit the same import-only conflict in TestDynamicIcebergSink.java, in all three Flink modules: upstream adds imports for org.apache.flink.api.common.JobID and org.apache.flink.api.common.operators.SlotSharingGroup. SlotSharingGroup turned out unused/dead on this branch — this branch already carries the native-slot-sharing-group-inheritance backport, so that part of the upstream diff doesn't apply here. Kept only the JobID import; no logic changes were needed to resolve.

@github-actions github-actions Bot added the FLINK label Sep 8, 2026
@nickwu241
nickwu241 force-pushed the nick/cherry-pick-16011-dynamic-committer branch from d002fa8 to 0007093 Compare September 8, 2026 18:32
@nickwu241 nickwu241 changed the title Flink: Cherry-pick #16011 - Fix duplicate commits in DynamicCommitter when Flink jobId changes on restart Flink: Cherry-pick #16011 to flink/v2.1 and v2.0 - Fix duplicate commits in DynamicCommitter when Flink jobId changes on restart Sep 8, 2026
@nickwu241
nickwu241 force-pushed the nick/cherry-pick-16011-dynamic-committer branch 2 times, most recently from da11f45 to ca5c888 Compare September 8, 2026 18:41
@nickwu241
nickwu241 force-pushed the nick/cherry-pick-16011-dynamic-committer branch from ca5c888 to be156de Compare September 8, 2026 18:47
@nickwu241 nickwu241 changed the title Flink: Cherry-pick #16011 to flink/v2.1 and v2.0 - Fix duplicate commits in DynamicCommitter when Flink jobId changes on restart Flink: Cherry-pick #16011 and its v1.20/v2.0 backport - Fix duplicate commits in DynamicCommitter when Flink jobId changes on restart Sep 8, 2026
@github-actions github-actions Bot added the INFRA label Sep 17, 2026
@nickwu241
nickwu241 force-pushed the nick/cherry-pick-16011-dynamic-committer branch from 8712708 to 7a148cd Compare September 17, 2026 19:26
version.txt was previously untracked, so build.gradle's getProjectVersion()
silently falls back to a git-describe-derived version if the file is ever
missing from the working tree (e.g. after a checkout/clean) instead of
failing loudly. This has already caused one unintended publish under
1.10.0-SNAPSHOT.

AFFIRM_VERSIONS.md records which Affirm-local patches are carried by each
published version.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@nickwu241
nickwu241 force-pushed the nick/cherry-pick-16011-dynamic-committer branch from 7a148cd to 7782d42 Compare September 17, 2026 19:42
@davkim

davkim commented Sep 18, 2026

Copy link
Copy Markdown

AFFIRM_VERSIONS.md: the recorded "Published commit" for 1.11.0-affirm-patch.1 (be156de39ca3a49bf47fe1e22a47d489c0adaa0b) is an earlier commit in this same PR that doesn't yet contain version.txt — that file is only added in the final commit (7782d420385...). Checking out the documented SHA wouldn't actually build as 1.11.0-affirm-patch.1; getProjectVersion() would fall back to the git-describe SNAPSHOT path — the exact versioning issue this doc is meant to prevent — unless that jar was published out-of-band from this tree. Worth double-checking the recorded SHA points at a commit that actually contains version.txt.

Git tags are the source of truth for the commit published to Artifactory, not this file.
@nickwu241

Copy link
Copy Markdown
Member Author

@davkim Good catch — fixed by dropping the "Published commit" field from AFFIRM_VERSIONS.md entirely. The git tag for a version is now the source of truth for the commit published to Artifactory, so there's no separate SHA in the doc that can drift out of sync.

@nickwu241
nickwu241 requested a review from davkim September 18, 2026 20:27

@davkim davkim left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

comment addressed - let's just make sure the CI passes

nickwu241 and others added 2 commits September 22, 2026 14:23
Records the Docker Hub -> Quay MinIO fix as part of 1.11.0-affirm-patch.1
now that it's merged onto 1.11.0-affirm-patch.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@nickwu241

Copy link
Copy Markdown
Member Author

Passes all CI tests now!

@nickwu241
nickwu241 merged commit 167d9e8 into 1.11.0-affirm-patch Sep 22, 2026
34 checks passed
@nickwu241
nickwu241 deleted the nick/cherry-pick-16011-dynamic-committer branch September 22, 2026 23:34
nickwu241 added a commit that referenced this pull request Sep 25, 2026
* Document and stage 1.11.0-affirm-patch.2

Bumps version.txt and adds the AFFIRM_VERSIONS.md changelog entry for the next
patch release, covering the 3 review-triggered fixes from all-the-things#222721
(#12/#13/#14). Those PRs are open, not yet merged — rebase this branch onto
1.11.0-affirm-patch once they land, then tag 1.11.0-affirm-patch.2 at the
resulting commit and publish per RUNBOOK_ICEBERG_PATCH_PUBLISH.md.

* Update AFFIRM_VERSIONS.md: base off 1.11.0-affirm-patch.1, drop reviewer names

* Drop #10/#11 from .2 table (already covered by .1 base)

* Note #12/#13/#14 merged and branch rebased; ready to tag

* Drop 'not yet published' framing now that .2 contents are final

* Drop trailing note from .2 section to match .1 format
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants