Skip to content

feat(helm): retain cluster bootstrap topology - #3429

Open
imbajin wants to merge 12 commits into
apache:masterfrom
hugegraph:codex/helm-stable-bootstrap-20261028
Open

imbajin wants to merge 12 commits into
apache:masterfrom
hugegraph:codex/helm-stable-bootstrap-20261028

Conversation

@imbajin

@imbajin imbajin commented Oct 28, 2026 •

Copy link
Copy Markdown
Member

Before → After

Changing PD or Store replica counts also regenerates initial peer lists and client seeds. This change adds an opt-in, immutable retained bootstrap ConfigMap so controlled node operations can change desired capacity without changing existing Pod startup inputs. The default remains disabled.

Adoption imports chart-managed live initialization inputs and rejects ambiguous history; offline upgrades require explicit retained counts. Membership changes, Pending Store admission, safe draining and rollback remain controlled procedures.

Dependency and validation boundary

Node-operation use requires the PD runtime-quorum change to be merged and included in the deployed PD image: #3428 . Static startup-seed and one-PD probe limits remain documented. The source PR reports Helm/Python/render regressions and unchanged default-disabled Pod templates; these checks are not cluster-level node-operation acceptance.

Source and detailed validation: hugegraph#352

Visual overview

Opt-in retained bootstrap inputs and controlled membership operations

Opt-in retained bootstrap counts keep initialization inputs separate from desired capacity. Runtime membership changes remain controlled operations and require a deployed PD image containing #3428. This is a design illustration, not cluster acceptance.

orion added 2 commits October 28, 2026 11:51
Separate retained initialization counts from desired node replicas.

Import live chart-managed bootstrap inputs and reject conflicting history.

Document PD compatibility, controlled membership and startup limits.

@bitflicker64 bitflicker64 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Blocking: yes. Summary: helm/test_helm_bootstrap.py is never run by CI, so its Pod template invariance checks for Store growth and PD growth or shrink do not guard the feature. The bootstrap resolver, legacy import, record guards and default-disabled renders read correctly, and the 13 new helm unittest suites pass.


CHART = Path(__file__).resolve().parent / "hugegraph"


Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Important: .github/actions/helm-checks/action.yml runs only named Python files (test_helm_package.py, test_helm_seatunnel.py, test_helm_vermeer*.py, test_helm_metadata_cluster.py, test_helm_hook.py), so these lifecycle tests never run in the build. Add a python3 -m unittest discover -s helm -p 'test_helm_bootstrap.py' -v step to that action.

MrJs133
MrJs133 previously approved these changes Oct 29, 2026
MrJs133
MrJs133 previously approved these changes Oct 29, 2026

@bitflicker64 bitflicker64 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Blocking: yes. Summary: two new helm unittest suites fail at this head, so the helm unittest CI step fails and the legacy-import success path has no passing coverage. A PD shrink below the recorded bootstrap majority also leaves the Store startup wait unsatisfiable.

template:
spec:
containers:
- name: store

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Important: this live Store fixture has no HG_STORE_PD_ADDRESS env, so the consumer guard added in 0519f2b fails every test in this suite with bootstrap import requires the existing store template to expose HG_STORE_PD_ADDRESS as a literal value. Add HG_STORE_PD_ADDRESS with the three original PD gRPC seeds to this container's env.

template: store-statefulset.yaml
asserts:
- failedTemplate:
errorPattern: bootstrap import only supports the chart

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Important: this pattern never matches: 96ef3e2 renamed the message to bootstrap only supports the chart's ..., and the one-entry custom-store:8500 list with count 3 fails first on initialStoreCount cannot exceed bootstrap.storeReplicas. Match the renamed message and give the fixture a custom list with at least three entries.

- |
set -eu
REQUIRED={{ include "hugegraph.pd.quorum" . }}
REQUIRED={{ include "hugegraph.pd.bootstrapQuorum" . }}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Important: after a controlled PD shrink below the recorded majority, such as bootstrap.pdReplicas=3 with pd.replicas=1, this renders REQUIRED=2 against seeds where only pd-0 exists, so every restarted Store times out in the wait init container. Fail the render when bootstrap.enabled and pd.replicas is below hugegraph.pd.bootstrapQuorum, or document that this shrink is unsupported.

orion and others added 2 commits October 29, 2026 16:53
Correct legacy fixtures and isolate fresh topology guards.
Cover retained-record checks in enabled and disabled installs.
Clarify recovery, consumer drift and static seed limits.

@bitflicker64 bitflicker64 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Blocking: no. Score: 9/10. Summary: The disabled path renders the same PD peers, Store allowlist, initial Store count, seed quorum and shard count as before, and the enabled resolver rejects conflicting pins, foreign or corrupt records and customized live endpoints. The earlier comments are addressed at this head, and helm-checks passes with test_helm_bootstrap.py and all 60 helm unittest suites.

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