Skip to content

Stage CHK scale-up so 1→3 does not create all Raft members at once - #2087

Open
alex-zaitsev wants to merge 4 commits into
0.28.0from
fix/chk-staged-scale-up
Open

alex-zaitsev wants to merge 4 commits into
0.28.0from
fix/chk-staged-scale-up

Conversation

@alex-zaitsev

@alex-zaitsev alex-zaitsev commented Sep 30, 2026 •

Copy link
Copy Markdown
Member

Summary

  • During CHK 1→3 / 2→3, extra new members stay out of raft_configuration until the previous join is Ready, so the operator never creates every new StatefulSet in one pass.
  • Fresh bootstrap is unchanged. 3→N added hosts still skip Ready so existing members can roll first.
  • test_020005_2 fail-fast: sts_count <= ready_count + 1 on the existing test-052 manifests.

Not in this PR (still #2041): /keeper/config + mntr barriers, scale-down purge, start_as_follower, rqld, lease election.

Test plan

  • go test -mod=mod ./pkg/controller/chk/ ./pkg/apis/common/types/
  • e2e test_020005_2 (fail-fast 1→3 invariant)
  • e2e test_020005 (happy-path 1→3→1 + CHI replication)

alex-zaitsev and others added 4 commits September 30, 2026 20:21
Publish one new keeper at a time and wait Ready before the next STS, instead of writing the full raft_configuration and creating every replica after a fixed sleep.

Co-authored-by: Cursor <cursoragent@cursor.com>
Do not create a new Keeper STS if raft_configuration was not published, and do not expand membership when STS existence is unknown. Restrict staging to 1→N / 2→3 and require the e2e join to become Ready.

Co-authored-by: Cursor <cursoragent@cursor.com>
Identify 1→N / 2→3 joiners by topology so an interrupted Ready wait still serializes the next STS after status becomes Same. Do not publish raft_configuration until immediately before STS create, and do not honor readiness:false for that gate.

Co-authored-by: Cursor <cursoragent@cursor.com>
@alex-zaitsev
alex-zaitsev force-pushed the fix/chk-staged-scale-up branch from ffb6ba9 to 9bfc2c0 Compare September 30, 2026 17:21
@alex-zaitsev
alex-zaitsev marked this pull request as ready for review October 1, 2026 07:03

This branch has not been deployed

No deployments
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.

1 participant