Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(crd-generator): Deprecation warning for CRD versions #5787

Merged

Conversation

baloo42
Copy link
Contributor

@baloo42 baloo42 commented Mar 10, 2024

Description

Add support for deprecation warnings in CRDGenerator.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • Feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change
  • Chore (non-breaking change which doesn't affect codebase;
    test, version modification, documentation, etc.)

Checklist

  • Code contributed by me aligns with current project license: Apache 2.0
  • I Added CHANGELOG entry regarding this change
  • I have implemented unit tests to cover my changes
  • I have added/updated the javadocs and other documentation accordingly
  • No new bugs, code smells, etc. in SonarCloud report
  • I tested my code in Kubernetes
  • I tested my code in OpenShift

@baloo42 baloo42 changed the title CRDGenerator: Add support for deprecation warnings of CustomResource versions CRDGenerator: Deprecation warnings for CRD versions Mar 10, 2024
@baloo42 baloo42 changed the title CRDGenerator: Deprecation warnings for CRD versions CRDGenerator: Deprecation warnings for CustomResourceDefinitionVersions Mar 10, 2024
@baloo42 baloo42 marked this pull request as ready for review March 10, 2024 18:12
@baloo42 baloo42 changed the title CRDGenerator: Deprecation warnings for CustomResourceDefinitionVersions feat (crd-generator): Deprecation warning for CRD version Mar 11, 2024
@baloo42 baloo42 changed the title feat (crd-generator): Deprecation warning for CRD version feat(crd-generator): Deprecation warning for CRD version Mar 11, 2024
@baloo42 baloo42 changed the title feat(crd-generator): Deprecation warning for CRD version feat(crd-generator): Deprecation warning for CRD versions Mar 11, 2024
@baloo42 baloo42 force-pushed the feature/crd_generator_deprecation_warnings branch from f93bbb7 to 0002db1 Compare March 11, 2024 01:24
Copy link

sonarcloud bot commented Mar 11, 2024

Quality Gate Failed Quality Gate failed

Failed conditions
51.4% Coverage on New Code (required ≥ 80%)
12.8% Duplication on New Code (required ≤ 3%)

See analysis details on SonarCloud

Copy link
Member

@andreaTP andreaTP left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for improving this aspect!

Copy link
Member

@manusa manusa left a comment

Choose a reason for hiding this comment

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

LGTM, thx! ❤️

@manusa manusa added the changelog missing A line to changelog.md regarding the change is not added label Mar 11, 2024
@manusa manusa merged commit bd0c549 into fabric8io:main Mar 11, 2024
16 of 19 checks passed
manusa added a commit to manusa/kubernetes-client that referenced this pull request Mar 11, 2024
@manusa manusa removed the changelog missing A line to changelog.md regarding the change is not added label Mar 11, 2024
@baloo42
Copy link
Contributor Author

baloo42 commented Mar 11, 2024

Thanks for merging and sorry for the missing changelog entry...

One follow up question:
At the moment the deprecated flag and the deprecationWarning are only added to the generated manifests if they are required (if deprecated=true).
Do you think it's a good strategy to keep the resulting manifests as small as possible or do you prefer to add the deprecated attribute explicitly (like served or storage)?

@manusa
Copy link
Member

manusa commented Mar 12, 2024

Thanks for merging and sorry for the missing changelog entry...

No worries

One follow up question: At the moment the deprecated flag and the deprecationWarning are only added to the generated manifests if they are required (if deprecated=true). Do you think it's a good strategy to keep the resulting manifests as small as possible or do you prefer to add the deprecated attribute explicitly (like served or storage)?

@andreaTP @metacosm ?

@andreaTP
Copy link
Member

I think that the current strategy is aligned with the other fields, thanks for asking!

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.

None yet

3 participants