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

⚠ Implement API changes according to RFC spec #1166

Merged
merged 1 commit into from
Aug 29, 2024

Conversation

jsm84
Copy link
Contributor

@jsm84 jsm84 commented Aug 22, 2024

resolves #1088

Summary:

  • v1 API now uses a SourceConfig discriminated union which will allow modularity for future install sources (bundles, charts, etc).
  • SourceConfig uses CEL validation to ensure only valid field names & values are utilized (sourceType: Catalog ensures that the catalog field is also set in SourceConfig).
  • Added new clusterextension_admission unit test for SourceConfig objects. The test covers both valid and invalid cases.
  • Fixed clusterextension_controller test where an unset ClusterExtension spec caused a null pointer deref.
  • Moved ClusterSelector from ClusterExtension.Spec to ClusterExtension.Source.Catalog
    and renamed to Selector.
  • Updated GoDocs to reflect the new API spec and included post-review changes
  • Fixed all definitions of kind: ClusterExtension in docs and scripts
    to reflect the API changes.

@jsm84 jsm84 requested a review from a team as a code owner August 22, 2024 20:55
Copy link

netlify bot commented Aug 22, 2024

Deploy Preview for olmv1 ready!

Name Link
🔨 Latest commit f943ddb
🔍 Latest deploy log https://app.netlify.com/sites/olmv1/deploys/66d0973dda051f0008b860e7
😎 Deploy Preview https://deploy-preview-1166--olmv1.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Contributor

@everettraven everettraven left a comment

Choose a reason for hiding this comment

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

Thanks for this PR @jsm84 !

Requesting changes on my current comments. I'll be out tomorrow, so I'll circle around for further review on Monday.

Copy link

codecov bot commented Aug 22, 2024

Codecov Report

Attention: Patch coverage is 57.14286% with 12 lines in your changes missing coverage. Please review.

Project coverage is 77.18%. Comparing base (bf7f766) to head (8e55961).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
api/v1alpha1/zz_generated.deepcopy.go 45.45% 12 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1166      +/-   ##
==========================================
- Coverage   77.55%   77.18%   -0.38%     
==========================================
  Files          35       35              
  Lines        1916     1937      +21     
==========================================
+ Hits         1486     1495       +9     
- Misses        296      308      +12     
  Partials      134      134              
Flag Coverage Δ
e2e 58.59% <53.57%> (-0.18%) ⬇️
unit 54.67% <21.42%> (-0.60%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@everettraven
Copy link
Contributor

Just finished combing through the rest of the PR and I don't have any additional comments

@jsm84 jsm84 force-pushed the unionized branch 2 times, most recently from a991906 to 00528fc Compare August 27, 2024 01:08
Copy link
Contributor

@everettraven everettraven left a comment

Choose a reason for hiding this comment

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

Some more comments on the comments. Overall I think they are good.

api/v1alpha1/clusterextension_types.go Outdated Show resolved Hide resolved
api/v1alpha1/clusterextension_types.go Outdated Show resolved Hide resolved
api/v1alpha1/clusterextension_types.go Outdated Show resolved Hide resolved
api/v1alpha1/clusterextension_types.go Outdated Show resolved Hide resolved
api/v1alpha1/clusterextension_types.go Outdated Show resolved Hide resolved
api/v1alpha1/clusterextension_types.go Outdated Show resolved Hide resolved
@jsm84 jsm84 force-pushed the unionized branch 2 times, most recently from f188dd1 to fe81727 Compare August 28, 2024 18:01
everettraven
everettraven previously approved these changes Aug 28, 2024
Copy link
Contributor

@everettraven everettraven left a comment

Choose a reason for hiding this comment

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

Changes looks good to me, thanks for the contribution @jsm84 !

I finished my review on mobile and it doesn't look like I can kick CI via the GH mobile app. I'll kick it first thing tomorrow morning and try to get this merged.

@everettraven everettraven added this pull request to the merge queue Aug 29, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Aug 29, 2024
@everettraven everettraven added this pull request to the merge queue Aug 29, 2024
@everettraven everettraven removed this pull request from the merge queue due to a manual request Aug 29, 2024
@everettraven
Copy link
Contributor

Closing and re-opening to try and reset the netlify checks that seem to be stuck

auto-merge was automatically disabled August 29, 2024 17:25

Pull request was closed

@everettraven everettraven reopened this Aug 29, 2024
resolves operator-framework#1088

Summary:
* v1 API now uses a `SourceConfig` discriminated union which will allow
  modularity for future install sources (bundles, charts, etc).
* `SourceConfig` uses CEL validation to ensure only valid field names &
  values are utilized (`sourceType: Catalog` ensures that the `catalog`
field is also set in `SourceConfig`).
* Added new `clusterextension_admission` unit test for `SourceConfig`
  objects. The test covers both valid and invalid cases.
* Fixed `clusterextension_controller` test where an unset
  `ClusterExtension` spec caused a null pointer deref.
* Moved `ClusterSelector` from `ClusterExtension.Spec` to `ClusterExtension.Source.Catalog`
  and renamed to `Selector`.
* Updated GoDocs to reflect the new API spec and included post-review changes
* Fixed all definitions of `kind: ClusterExtension` in docs and scripts
  to reflect the API changes.

Signed-off-by: Josh Manning <19478595+jsm84@users.noreply.github.com>
@everettraven everettraven added this pull request to the merge queue Aug 29, 2024
Merged via the queue into operator-framework:main with commit fc888e5 Aug 29, 2024
15 of 19 checks passed
@skattoju skattoju mentioned this pull request Sep 25, 2024
4 tasks
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.

api: move catalog sourcing fields to discriminated union
2 participants