Skip to content

[backport] Backport sweep for 9.1#4225

Open
valkeyrie-ops[bot] wants to merge 2 commits into
9.1from
agent/backport/sweep/9.1
Open

[backport] Backport sweep for 9.1#4225
valkeyrie-ops[bot] wants to merge 2 commits into
9.1from
agent/backport/sweep/9.1

Conversation

@valkeyrie-ops

@valkeyrie-ops valkeyrie-ops Bot commented Jul 20, 2026

Copy link
Copy Markdown

Backport sweep for 9.1

Automated cherry-picks from PRs marked "To be backported".

Applied

Source PR Title Detail
#4104 Avoid offloading writes to IO threads for the slot migration export job while snapshotting. conflicts resolved by Claude Code

AI resolution details are posted as comments on this PR when available.


Generated by valkey-ci-agent using Claude Code.

…ob while snapshotting. (#4104)

**Problem Description**

Atomic slot migration is failing when io-threads enabled and pipeline
requests are ongoing

```== CRITICAL == This slot-import-target is sending an error to its slot-import-source: 'Protocol error: invalid CRLF in request' after processing the command 'set'```

**Proposed Fix**
 Disable I/O threads offloading for slot migration jobs when snapshotting to prevent query buffer desynchronization during pipelining

Signed-off-by: Satheesha Gowda <satheesha.balaji@gmail.com>
@valkeyrie-ops valkeyrie-ops Bot added ai-resolved-conflicts AI is used to resolve conflicts in automated backport PRs. backport Backport PR opened by valkey-ci-agent labels Jul 20, 2026
@valkeyrie-ops

valkeyrie-ops Bot commented Jul 20, 2026

Copy link
Copy Markdown
Author

AI conflict resolution: source PR #4104

Avoid offloading writes to IO threads for the slot migration export job while snapshotting.

1 conflicted file

Claude Summary

Both conflicts are resolved and the result matches the upstream PR exactly in size and shape (28 insertions, 9 deletions across the same 3 files). I did not run git add, per the constraints, so the test file still shows as unmerged in git status — but its contents are fully resolved with no conflict markers.

What I did:

  • tests/unit/cluster/cluster-migrateslots.tcl — Both conflicts were on start_cluster header lines for the two slot-migration-max-failover-repl-bytes test blocks. The PR's only change to those lines was adding the network tag; the repl-timeout 3600 override on the incoming side came from an unrelated upstream commit that isn't on the 9.1 branch. I merged by adding just the network tag while keeping 9.1's existing overrides (no repl-timeout 3600), consistent with the other seven start_cluster headers that auto-merged cleanly with only the tag added.

  • src/cluster_migrateslots.c and src/io_threads.c — Auto-merged identically to the upstream diff (skip SIGUSR1 when the child exit pipe is closed, defer snapshotting while client IO state isn't idle, and skip IO-thread write offload for slot-migration export clients). No adaptation needed.

Verification: I confirmed all symbols the new code relies on exist on 9.1 (clusterSlotMigrationShouldInstallWriteHandler, slot_migration_child_exit_pipe, io_read_state/io_write_state, CLIENT_IDLE, and the network tag which is recognized in test_helper.tcl and already used by other test files). Both C files pass gcc -fsyntax-only, and no conflict markers remain in any of the three files.

AI-resolved conflicted files

  • tests/unit/cluster/cluster-migrateslots.tclview diff

Full backport commit diff: commit 270c167226a6.

Please review these AI resolutions for correctness before merging.

@codecov

codecov Bot commented Jul 20, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 76.67%. Comparing base (d27f9ba) to head (66b7144).

Additional details and impacted files
@@            Coverage Diff             @@
##              9.1    #4225      +/-   ##
==========================================
- Coverage   76.67%   76.67%   -0.01%     
==========================================
  Files         163      163              
  Lines       81286    81292       +6     
==========================================
+ Hits        62330    62334       +4     
- Misses      18956    18958       +2     
Files with missing lines Coverage Δ
src/cluster_migrateslots.c 92.17% <100.00%> (+0.03%) ⬆️
src/io_threads.c 76.09% <100.00%> (+0.05%) ⬆️

... and 19 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai-resolved-conflicts AI is used to resolve conflicts in automated backport PRs. backport Backport PR opened by valkey-ci-agent

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants