Skip to content

Add crd sync logic in plural cd clusters reinstall - #835

Merged
michaeljguarino merged 1 commit into
mainfrom
crd-reinstall
Nov 7, 2026
Merged

michaeljguarino merged 1 commit into
mainfrom
crd-reinstall

Conversation

@michaeljguarino

Copy link
Copy Markdown
Member

This should help solve for the whole issue of helm not reinstalling the crd folder for god knows what reason

Summary

Labels

Test Plan

Checklist

  • If required, I have updated the Plural documentation accordingly.
  • I have added tests to cover my changes.
  • I have added a meaningful title and summary to convey the impact of this PR to a user.
  • I have added relevant labels to this PR to help with categorization for release notes.

This should help solve for the whole issue of helm not reinstalling the crd folder for god knows what reason
@greptile-apps

greptile-apps Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 4/5

[Medium impact] The change reaches Kubernetes clusters where the CLI upgrades the deployment operator.

The PR appears safe to merge, with a non-blocking request to test the new CRD write path.

Findings

  1. P2 CRD updates lack tests ▶

Summary

Adds CRD updates before upgrading an existing deployment operator release.

  • Operator upgrades sync chart CRDs before Helm runs.

Reviews (1) · Last reviewed commit: "Add crd sync logic in plural cd clusters..." · Reviewed by Greptile

Comment thread pkg/console/agent.go

// syncCRDs server-side applies the chart's crds/ directory, which helm upgrade never touches.
// Client-side apply can't be used since some CRDs exceed the 256KB last-applied-configuration annotation limit.
func syncCRDs(config *action.Configuration, chart *chart.Chart) error {

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.

P2 CRD updates lack tests

syncCRDs adds forced writes to cluster-wide CRDs without tests. Add coverage for missing and existing CRDs, multiple documents in one file, and apply or wait errors stopping the upgrade. These checks would catch changes that silently skip CRDs or upgrade the operator before its CRDs are ready.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

@michaeljguarino michaeljguarino added the enhancement New feature or request label Nov 6, 2026
@michaeljguarino
michaeljguarino merged commit b99fd58 into main Nov 7, 2026
15 of 16 checks passed
@michaeljguarino
michaeljguarino deleted the crd-reinstall branch November 7, 2026 17:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants