Skip to content

feat: Report what is pending for a ClusterSummary of a paused cluster - #2143

Merged
gianlucam76 merged 1 commit into
projectsveltos:mainfrom
gianlucam76:paused-pending-features
Dec 3, 2026
Merged

gianlucam76 merged 1 commit into
projectsveltos:mainfrom
gianlucam76:paused-pending-features

Conversation

@gianlucam76

Copy link
Copy Markdown
Member

While a cluster is paused its ClusterSummary is not deployed, so nothing recorded that a change was waiting. In the paused branch the ClusterSummary reconciler now compares, for each feature, the hash of the desired configuration with the hash stored at the last deployment and writes Status.PendingFeatures. Nothing is deployed and nothing is written to the managed cluster.

Each PendingFeature carries a reason (ConfigurationChanged, NotDeployed, PendingRemoval, EvaluationFailed) and, when it can be established, the items that changed:

  • Helm: chart added, removed, or changed (version, values, patches), derived from Status.HelmReleaseSummaries.
  • Resources and Kustomize: referenced ConfigMaps, Secrets, sources and templateResourceRefs added, removed or changed. The feature configuration hash is now computed in one pass together with a short hash of each referenced resource, stored in FeatureSummary.ReferenceHashes at the same moment as the hash. The aggregate hash is unchanged: pinned by tests whose expected values were produced by the previous code.
  • When the change is not in a referenced resource (profile settings, remote URL content) Message says so. A feature deployed before this change reports that what changed is not known until it is deployed again. Items are capped (MaxPendingItems) and flagged as truncated.

When Profile/ClusterProfile has maxUpdate set, the ClusterSummaries of paused clusters are now patched last, once the ClusterSummaries of the clusters not paused are Provisioned, without using an update slot.

Tests: Ginkgo specs for pending detection and items, hash pinning, reference hashes, scope staging and the maxUpdate ordering; functional tests for the Resources, Helm and Kustomize items on a paused cluster.

While a cluster is paused its ClusterSummary is not deployed, so nothing
recorded that a change was waiting. In the paused branch the ClusterSummary
reconciler now compares, for each feature, the hash of the desired
configuration with the hash stored at the last deployment and writes
Status.PendingFeatures. Nothing is deployed and nothing is written to the
managed cluster.

Each PendingFeature carries a reason (ConfigurationChanged, NotDeployed,
PendingRemoval, EvaluationFailed) and, when it can be established, the items
that changed:
- Helm: chart added, removed, or changed (version, values, patches), derived
  from Status.HelmReleaseSummaries.
- Resources and Kustomize: referenced ConfigMaps, Secrets, sources and
  templateResourceRefs added, removed or changed. The feature configuration
  hash is now computed in one pass together with a short hash of each
  referenced resource, stored in FeatureSummary.ReferenceHashes at the same
  moment as the hash. The aggregate hash is unchanged: pinned by tests whose
  expected values were produced by the previous code.
- When the change is not in a referenced resource (profile settings, remote
  URL content) Message says so. A feature deployed before this change reports
  that what changed is not known until it is deployed again.
Items are capped (MaxPendingItems) and flagged as truncated.

When Profile/ClusterProfile has maxUpdate set, the ClusterSummaries of paused
clusters are now patched last, once the ClusterSummaries of the clusters not
paused are Provisioned, without using an update slot.

Tests: Ginkgo specs for pending detection and items, hash pinning, reference
hashes, scope staging and the maxUpdate ordering; functional tests for the
Resources, Helm and Kustomize items on a paused cluster.
@gianlucam76
gianlucam76 merged commit 4075d98 into projectsveltos:main Dec 3, 2026
14 checks passed
@gianlucam76
gianlucam76 deleted the paused-pending-features branch December 3, 2026 10:19
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