Skip to content

Conversation

@Aias00
Copy link
Contributor

@Aias00 Aias00 commented Jan 18, 2026

Ⅰ. Describe what this PR did

Implement CRD version validation at server startup, providing warnings and update instructions for outdated CRDs
fixes: #2278

Ⅱ. Does this pull request fix one issue?

Ⅲ. Why don't you add test cases (unit test/integration test)?

Ⅳ. Describe how to verify it

Ⅴ. Special notes for reviews

Ⅵ. AI Coding Tool Usage Checklist (if applicable)

Please check all applicable items:

  • For new standalone features (e.g., new wasm plugin or golang-filter plugin):

    • I have created a design/ directory in the plugin folder
    • I have added the design document to the design/ directory
    • I have included the AI Coding summary below
  • For regular updates/changes (not new plugins):

    • I have provided the prompts/instructions I gave to the AI Coding tool below
    • I have included the AI Coding summary below

AI Coding Prompts (for regular updates)

AI Coding Summary

…arnings and update instructions for outdated CRDs
Copilot AI review requested due to automatic review settings January 18, 2026 06:49
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR implements CRD (Custom Resource Definition) version validation at server startup to detect outdated or missing CRDs and provide actionable warnings with update instructions. The feature helps prevent runtime issues by validating that required Higress CRDs are installed with the correct versions and schemas before the server starts.

Changes:

  • Added CRD version validation logic that checks for required CRDs, their versions, and schema fields
  • Integrated validation into server startup with formatted warning messages and update instructions
  • Added comprehensive unit tests for validation helper functions

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 8 comments.

File Description
pkg/kube/crd_version.go Implements core CRD validation logic including version checking and schema field validation
pkg/kube/crd_version_test.go Provides unit tests for validation helper functions and CRD definition verification
pkg/bootstrap/server.go Integrates CRD validation into server startup sequence with user-friendly warning output

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant