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

Image digests for referencing bundles #103

Merged

Conversation

anik120
Copy link
Contributor

@anik120 anik120 commented Oct 23, 2019

Description of the change:

  • Change schema of OperatorBundle to include field 'bundlepath'
  • Extend GetBundle API to return bundle image path
  • Modify GetBundle API to return struct with avaiable fields
    instead of error while querrying empty bundles

Reviewer Checklist

  • Implementation matches the proposed design, or proposal is updated to match implementation
  • Sufficient unit test coverage
  • Sufficient end-to-end test coverage
  • Docs updated or added to /docs
  • Commit messages sensible and descriptive

@anik120 anik120 requested a review from kevinrizza October 23, 2019 13:46
@openshift-ci-robot openshift-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Oct 23, 2019
@anik120 anik120 requested a review from ecordell October 23, 2019 13:47
@anik120 anik120 mentioned this pull request Oct 23, 2019
5 tasks
@anik120 anik120 force-pushed the image-digests2 branch 2 times, most recently from ef4bb48 to 9b74e52 Compare October 25, 2019 19:59
@openshift-ci-robot openshift-ci-robot added size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Oct 25, 2019
@anik120
Copy link
Contributor Author

anik120 commented Oct 25, 2019

@ecordell @kevinrizza I've rebased it on top of #101. PTAL

Copy link
Member

@ecordell ecordell left a comment

Choose a reason for hiding this comment

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

Overall this looks great - can you add positive tests for the grpc apis (i.e. if bundle = nil and bundlepath = path in the db, the grpc apis return the right thing)?

@@ -0,0 +1,310 @@
// Code generated by go-bindata.
Copy link
Member

Choose a reason for hiding this comment

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

I think you can delete this

- Change schema of OperatorBundle to include field 'bundlepath'
- Extend GetBundle API to return bundle image path
- Modify GetBundle API to return struct with avaiable fields
  instead of error while querrying empty bundles
@openshift-ci-robot openshift-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Oct 28, 2019
@anik120
Copy link
Contributor Author

anik120 commented Oct 28, 2019

can you add positive tests for the grpc apis (i.e. if bundle = nil and bundlepath = path in the db, the grpc apis return the right thing)?

@ecordell looks like there's two ways we can add this test with the way the tests are laid out now:

  1. Wait for Adding OPM cli with registry add and rm commands #89 to merge which will then allow us to add an operator bundle from a bundle path
  2. Merge this now and add the test after Adding OPM cli with registry add and rm commands #89 merges.

There is also a third option: Write a test that creates a database and populates it with the information that we need to query, but I feel that'll just be dead code soon.

What do we think is our preference here?

@ecordell
Copy link
Member

/lgtm

That's fine, we can come back with tests after #89 merges

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Oct 28, 2019
@openshift-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: anik120, ecordell

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 28, 2019
@openshift-merge-robot openshift-merge-robot merged commit d090428 into operator-framework:master Oct 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants