Skip to content

feat(producer): partition muting for msg ordering#6

Merged
3AceShowHand merged 5 commits intopingcap:v1.41.2-pingcapfrom
3AceShowHand:cherry-pick-fix-out-of-order-pr
Apr 15, 2026
Merged

feat(producer): partition muting for msg ordering#6
3AceShowHand merged 5 commits intopingcap:v1.41.2-pingcapfrom
3AceShowHand:cherry-pick-fix-out-of-order-pr

Conversation

@3AceShowHand
Copy link
Copy Markdown
Collaborator

@3AceShowHand 3AceShowHand commented Apr 14, 2026

When MaxOpenRequests > 1, mute partitions with in-flight batches to prevent out-of-order delivery during retries.

This PR backports the producer ordering fix from IBM/sarama#3422 onto v1.41.2-pingcap, and keeps go.mod on go 1.25.0.

Upstream references and why these changes are needed

  • IBM/sarama#3422 feat(producer): partition muting for msg ordering

    • commits:
      • 8d3ebceafc333a42f6783d43588adbef90a1649a feat(producer): partition muting for msg ordering
      • 2a3604789240d5162e739468bd9db362bf60d69f fix(test): retry GetOffset on leader electio
      • 29f83cada48f1cba691de9738c14a6399bb3875b fix: simplify muter helpers
    • needed because this is the actual producer ordering fix we want to merge. Cherry-picking it incompletely leaves the old branch with missing code/test pieces, and CI stops before the feature can be validated.
  • IBM/sarama#3047 commit ab8a26611e8a7f08991d06d7d919a88682583221 fix(test): refactor helpers into common files

    • needed because v1.41.2-pingcap does not have the shared test helpers that the newer IBM tests rely on (appendInterceptor, closeProducer*, TestMessage). Without backfilling them, the #3422 tests do not compile.
  • IBM/sarama#3026 and IBM/sarama#3088

    • commits:
      • 7c75cc4 feat(producer): add retry buffer tuning option to prevent OOM
      • 26d7c7b51699274209b0b106a3d896377d8cc5f1 feat(producer): add MaxBufferBytes to limit retry buffer size
    • needed because the older pingcap branch does not contain Producer.Retry.MaxBufferLength / Producer.Retry.MaxBufferBytes, while the newer IBM producer/test code assumes that configuration surface exists.
  • IBM/sarama#3113 commit 4979ecefa0793ca59733b054a8af1038dc6be220 chore: bump minimum Go version to 1.23.0

    • needed as the upstream CI pattern for newer Go directives: once go.mod is go 1.25.0, running CI with 1.17.x / 1.20.x / 1.21.x fails immediately on the go directive/toolchain check. Switching unit/FVT workflows to stable / oldstable and setting GOTOOLCHAIN: local is required to make CI compatible with Go 1.25.
  • IBM/sarama#3160 commit 4d2b166e5c2770f6b23f83eab587d7801878d429 fix(ci): bump golangci-lint to v2

    • needed because the old .golangci.yml format is not compatible with the newer golangci-lint releases required for Go 1.25 support.
  • IBM/sarama#3400 commit 265af947 chore(deps): update golangci/golangci-lint-action action to v9.2.0

    • needed to align the GitHub Action wrapper with the upstream-supported lint stack.
  • IBM/sarama#3482 commit 52f24214 chore(deps): update dependency golangci/golangci-lint to v2.11.4

    • needed because older golangci-lint versions on this branch do not support Go 1.25 correctly.
  • IBM/sarama#3453 commit d4862ce chore(deps): bump golang.org/x/net from 0.50.0 to 0.51.0 in the golang-x group across 1 directory

    • relevant because upstream main is already on go 1.25.0; this PR aligns the pingcap branch CI/tooling with that upstream state instead of downgrading the module directive.

Backport-specific notes

  • This maintenance branch is older than the IBM baseline used by the PRs above, so a few minimal branch-local lint/test cleanups are included to make go test and golangci-lint pass under Go 1.25. These are compatibility adjustments for the backport, not new behavior changes.

dnwe and others added 3 commits April 15, 2026 17:26
When MaxOpenRequests > 1, mute partitions with in-flight batches to
prevent out-of-order delivery during retries.

Signed-off-by: Dominic Evans <dominic.evans@uk.ibm.com>
Signed-off-by: Dominic Evans <dominic.evans@uk.ibm.com>
@3AceShowHand 3AceShowHand force-pushed the cherry-pick-fix-out-of-order-pr branch from 1b755f5 to 79ef27f Compare April 15, 2026 09:31
@3AceShowHand 3AceShowHand merged commit 5d919a8 into pingcap:v1.41.2-pingcap Apr 15, 2026
10 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.

3 participants