The OnePerHost pod-distribution value is dead code: the constant is marked // Deprecated value at pkg/apis/deployment/affinity.go:55, and no switch in pkg/model/common/affinity/pod-anti-affinity.go or pkg/model/common/normalizer/templates/pod.go matches it. A user-supplied OnePerHost is silently normalized to Unspecified and produces no affinity rules — i.e. it looks like it works but does nothing.
It should be cleaned out of:
- Go constant —
pkg/apis/deployment/affinity.go:55 (PodDistributionOnePerHost = "OnePerHost").
- CRDs — drop
"OnePerHost" from the distribution/podDistribution.type enum in:
deploy/operatorhub/<current-version>/clickhouseinstallations.clickhouse.altinity.com.crd.yaml
deploy/operatorhub/<current-version>/clickhouseinstallationtemplates.clickhouse.altinity.com.crd.yaml
deploy/operatorhub/<current-version>/clickhousekeeperinstallations.clickhouse-keeper.altinity.com.crd.yaml
- any matching CRDs under
deploy/builder/, deploy/helm/, deploy/operator/ that the build pipeline regenerates.
(Older deploy/operatorhub/0.x.y/ directories are historical snapshots — leave those alone.)
- Docs —
docs/custom_resource_explained.md lines 564–606 still list OnePerHost as a valid distribution value and show it in two examples. Replace with the supported equivalents (type: ClickHouseAntiAffinity or type: MaxNumberPerNode, number: 1).
- Examples —
docs/chit-examples/104-templates.yaml uses a top-level distribution: "OnePerHost" field that doesn't even exist on PodTemplate in the Go types. Rewrite using podDistribution:.
- Requirements — mention in
tests/requirements/requirements.md:1016.
Compatibility note
Removing the enum value is technically a breaking CRD change for any user who literally wrote OnePerHost. Since the value already does nothing, the user impact is just a validation error instead of silent no-op — arguably an improvement, but worth calling out in the release notes.
The
OnePerHostpod-distribution value is dead code: the constant is marked// Deprecated valueatpkg/apis/deployment/affinity.go:55, and no switch inpkg/model/common/affinity/pod-anti-affinity.goorpkg/model/common/normalizer/templates/pod.gomatches it. A user-suppliedOnePerHostis silently normalized toUnspecifiedand produces no affinity rules — i.e. it looks like it works but does nothing.It should be cleaned out of:
pkg/apis/deployment/affinity.go:55(PodDistributionOnePerHost = "OnePerHost")."OnePerHost"from thedistribution/podDistribution.typeenum in:deploy/operatorhub/<current-version>/clickhouseinstallations.clickhouse.altinity.com.crd.yamldeploy/operatorhub/<current-version>/clickhouseinstallationtemplates.clickhouse.altinity.com.crd.yamldeploy/operatorhub/<current-version>/clickhousekeeperinstallations.clickhouse-keeper.altinity.com.crd.yamldeploy/builder/,deploy/helm/,deploy/operator/that the build pipeline regenerates.(Older
deploy/operatorhub/0.x.y/directories are historical snapshots — leave those alone.)docs/custom_resource_explained.mdlines 564–606 still listOnePerHostas a validdistributionvalue and show it in two examples. Replace with the supported equivalents (type: ClickHouseAntiAffinityortype: MaxNumberPerNode, number: 1).docs/chit-examples/104-templates.yamluses a top-leveldistribution: "OnePerHost"field that doesn't even exist onPodTemplatein the Go types. Rewrite usingpodDistribution:.tests/requirements/requirements.md:1016.Compatibility note
Removing the enum value is technically a breaking CRD change for any user who literally wrote
OnePerHost. Since the value already does nothing, the user impact is just a validation error instead of silent no-op — arguably an improvement, but worth calling out in the release notes.