Bug 1705752 - Missing openapi CRD definitions for oc explain to work for image-registry operator CRD
Summary: Missing openapi CRD definitions for oc explain to work for image-registry ope...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Image Registry
Version: 4.1.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: 4.2.0
Assignee: Adam Kaplan
QA Contact: Wenjing Zheng
URL:
Whiteboard:
: 1659897 1708597 (view as bug list)
Depends On: 1712317
Blocks: 1705753 1708600 1714775
TreeView+ depends on / blocked
 
Reported: 2019-05-02 21:06 UTC by Maciej Szulik
Modified: 2019-10-16 06:28 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Cause: CRD doesn't have OpenAPI schema Consequence: oc explain doesn't work for config.imageregistry resource Fix: generate OpenAPI schema Result: oc explain can provide information about config.imageregistry.operator.openshift.io.
Clone Of:
: 1705753 1709090 1714775 (view as bug list)
Environment:
Last Closed: 2019-10-16 06:28:30 UTC
Target Upstream Version:
adam.kaplan: needinfo-


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Github openshift cluster-image-registry-operator pull 291 None closed Bug 1705752: OpenAPI schema 2020-07-06 13:49:50 UTC
Github openshift cluster-image-registry-operator pull 319 None closed Bug 1705752: update crd 2020-07-06 13:49:48 UTC
Github openshift cluster-image-registry-operator pull 331 None closed Bug 1705752: Update crd 2020-07-06 13:49:49 UTC
Red Hat Product Errata RHBA-2019:2922 None None None 2019-10-16 06:28:47 UTC

Description Maciej Szulik 2019-05-02 21:06:23 UTC
The following PR https://github.com/openshift/origin/pull/22696 introduced an e2e which is verifying that all the operators provide descriptive information as part of their schema which is then available through oc explain command. 

Your component has a few missing bits, see the commented out lines from the PR.

This should be fixed similarly to https://github.com/openshift/cluster-version-operator/pull/168 and then update origin's e2e test and uncomment the lines from your components.

Comment 1 Maciej Szulik 2019-05-02 21:10:49 UTC
Adam, I couldn't figure out a component for cluster-samples-operator but I've created just one issue wrt to imageregistry and sample operator configs. 
I'd like to see both addressed.

Comment 2 Ben Parees 2019-05-02 21:17:03 UTC
I created clone https://bugzilla.redhat.com/show_bug.cgi?id=1705753 to cover the samples operator aspect of this.

Comment 3 Adam Kaplan 2019-05-03 16:53:47 UTC
@Maciej this is a bit of a riskier proposition, since adding library-go requires bumping k8s.io deps to 1.13. Can we address this as tech debt in 4.2 (with a potential z-stream update for 4.1)?

Comment 4 Maciej Szulik 2019-05-03 20:16:38 UTC
Yes 4.1.x is perfect.

Comment 5 Paul Weil 2019-05-10 12:06:30 UTC
*** Bug 1708597 has been marked as a duplicate of this bug. ***

Comment 6 Ben Parees 2019-05-13 13:57:30 UTC
moving to 4.2.0, if you decide to backport it to 4.1.z create a clone.

Comment 8 Oleg Bulatov 2019-06-07 12:27:22 UTC
*** Bug 1659897 has been marked as a duplicate of this bug. ***

Comment 9 Adam Kaplan 2019-06-12 19:13:19 UTC
Needs DESCRIPTION to be fully populated in order to pass. Current output from dev clusters:

```
$ oc explain config --api-version imageregistry.operator.openshift.io/v1
KIND:     Config
VERSION:  imageregistry.operator.openshift.io/v1

DESCRIPTION:
     <empty>

FIELDS:
   apiVersion	<string>
     APIVersion defines the versioned schema of this representation of an
     object. Servers should convert recognized schemas to the latest internal
     value, and may reject unrecognized values. More info:
     https://git.k8s.io/community/contributors/devel/api-conventions.md#resources

   kind	<string>
     Kind is a string value representing the REST resource this object
     represents. Servers may infer this from the endpoint the client submits
     requests to. Cannot be updated. In CamelCase. More info:
     https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds

   metadata	<Object>
     Standard object's metadata. More info:
     https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata

   spec	<Object>

   status	<Object>
```

Waiting on input from the CLI team on how to proceed.

Comment 12 Ben Parees 2019-07-30 16:31:23 UTC
Oleg, https://github.com/openshift/cluster-image-registry-operator/pull/319 is closed.  Other PRs associated w/ this BZ are closed or merged.  Should it be moved to modified or back to assigned?  Post doesn't seem correct at this point.

Comment 14 Wenjing Zheng 2019-07-31 09:08:43 UTC
Verified with below version:
Client Version: v4.2.0
Server Version: v1.14.0+1682e38
OpenShift Version: 4.2.0-0.nightly-2019-07-30-000900

$ oc explain config --api-version imageregistry.operator.openshift.io/v1
KIND:     Config
VERSION:  imageregistry.operator.openshift.io/v1

DESCRIPTION:
     Config is the configuration object for a registry instance managed by the
     registry operator

FIELDS:
   apiVersion	<string>
     APIVersion defines the versioned schema of this representation of an
     object. Servers should convert recognized schemas to the latest internal
     value, and may reject unrecognized values. More info:
     https://git.k8s.io/community/contributors/devel/api-conventions.md#resources

   kind	<string>
     Kind is a string value representing the REST resource this object
     represents. Servers may infer this from the endpoint the client submits
     requests to. Cannot be updated. In CamelCase. More info:
     https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds

   metadata	<Object> -required-
     Standard object's metadata. More info:
     https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata

   spec	<Object> -required-

   status	<Object>

Comment 15 errata-xmlrpc 2019-10-16 06:28:30 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2019:2922


Note You need to log in before you can comment on or make changes to this bug.