Skip to content

Update NuRaft snapshot IO setting - #106285

Merged
antonio2368 merged 5 commits into
masterfrom
update-nuraft-bg-snapshot-io
Jun 9, 2026
Merged

antonio2368 merged 5 commits into
masterfrom
update-nuraft-bg-snapshot-io

Conversation

@antonio2368

@antonio2368 antonio2368 commented Jun 2, 2026 •

Copy link
Copy Markdown
Member

Update NuRaft and expose its background snapshot IO mode through the Keeper coordination setting nuraft_use_bg_thread_for_snapshot_io. The setting is enabled by default so snapshot objects are read by a background thread instead of Raft worker threads.

Changelog category (leave one):

  • Improvement

Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):

Added Keeper setting nuraft_use_bg_thread_for_snapshot_io, enabled by default, to make NuRaft read snapshot objects from a background thread instead of Raft worker threads.

Documentation entry:

  • Documentation is not needed because this is an internal Keeper coordination setting tied to a NuRaft update.

Version info

  • Merged into: 26.6.1.538

Update `contrib/NuRaft` to `77f325d3642005ee095760c04e62dde45c6b56bd`.

Expose `use_bg_thread_for_snapshot_io_` through coordination setting `nuraft_use_bg_thread_for_snapshot_io` with default `true`.
@clickhouse-gh

clickhouse-gh Bot commented Jun 2, 2026 •

Copy link
Copy Markdown
Contributor

Workflow [PR], commit [cc5a7fb]

Summary: ❌

job_name test_name status info comment
Stateless tests (arm_asan_ubsan, azure, parallel) FAIL
Server died FAIL cidb
02801_transform_nullable UNKNOWN cidb
02771_semi_join_use_nulls UNKNOWN cidb
03773_deterministic_functions_key_condition_explain UNKNOWN cidb
03985_kill_query_dict_load UNKNOWN cidb
03742_nested_loop_join_long UNKNOWN cidb
Logical error: Part A intersects next part B. It is a bug or a result of manual intervention (STID: 3562-5547) FAIL cidb

AI Review

Summary
  • This PR updates NuRaft, exposes use_bg_thread_for_snapshot_io_ as the Keeper coordination setting nuraft_use_bg_thread_for_snapshot_io, enables it by default, and shuts down the global snapshot I/O manager during KeeperServer shutdown. I reviewed the current ClickHouse diff, the expanded NuRaft submodule range, the setting propagation, snapshot context lifetime handling, shutdown ordering, PR metadata, and the current CI report; I did not find a high-confidence blocker or major issue requiring an inline comment.
Final Verdict
  • Status: ✅ Approve

@clickhouse-gh clickhouse-gh Bot added pr-improvement Pull request with some product improvements submodule changed At least one submodule changed in this PR. labels Jun 2, 2026
Advance `contrib/NuRaft` to `9b6eb6ed31734e24c68cad59b10209d251cdbb07` and shut down `snapshot_io_mgr` during `KeeperServer` shutdown.
@kssenii kssenii self-assigned this Jun 2, 2026
@kssenii

kssenii commented Jun 5, 2026

Copy link
Copy Markdown
Member

test_keeper_snapshot_chunked_transfer, test_keeper_snapshot_rotation_race

🤔

@antonio2368

Copy link
Copy Markdown
Member Author

Yes, the failures are related.

antonio2368 and others added 2 commits June 8, 2026 13:32
Merge of upstream master into the ClickHouse fork. The resulting source
tree is identical to the previously pinned `b350375`, so no build or
source changes are required — this only advances the submodule pointer
to the merge commit.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
@clickhouse-gh

clickhouse-gh Bot commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

LLVM Coverage Report

Metric Baseline Current Δ
Lines 84.60% 84.60% +0.00%
Functions 92.30% 92.30% +0.00%
Branches 77.20% 77.20% +0.00%

Changed lines: Changed C/C++ lines covered by tests: 17/17 (100.00%) | Lost baseline coverage: none · Uncovered code

Full report · Diff report

@antonio2368
antonio2368 added this pull request to the merge queue Jun 9, 2026
Merged via the queue into master with commit e0752d2 Jun 9, 2026
164 of 166 checks passed
@antonio2368
antonio2368 deleted the update-nuraft-bg-snapshot-io branch June 9, 2026 08:27
@robot-ch-test-poll1 robot-ch-test-poll1 added the pr-synced-to-cloud The PR is synced to the cloud repo label Jun 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-improvement Pull request with some product improvements pr-synced-to-cloud The PR is synced to the cloud repo submodule changed At least one submodule changed in this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants