Skip to content

Conversation

@sttts
Copy link
Contributor

@sttts sttts commented Oct 28, 2019

No description provided.

@openshift-ci-robot openshift-ci-robot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Oct 28, 2019
@sttts sttts force-pushed the sttts-api-crd branch 2 times, most recently from 0920c11 to efb0a6f Compare October 28, 2019 12:30
@damemi
Copy link

damemi commented Oct 28, 2019

This LGTM

submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds'
type: string
metadata:
description: ObjectMeta is metadata that all persisted resources must have,
Copy link
Member

Choose a reason for hiding this comment

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

$ git diff -M20 origin/pr/266^^..origin/pr/266
...
         metadata:
-          description: ObjectMeta is metadata that all persisted resources must have,
-            which includes all objects users must create.
-          properties:
...

Where did the metadata details go? Don't we want those?

Copy link

Choose a reason for hiding this comment

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

@wking no, those were removed in openshift/api#478 to conform to structural schema requirements

Copy link
Member

Choose a reason for hiding this comment

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

... to conform to structural schema requirements

Can you link me to docs on these requirements? I don't see anything that sounds like it here.

Copy link

@damemi damemi Oct 28, 2019

Choose a reason for hiding this comment

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

In the structural schema KEP the section on metadata describes:
The metadata field at the object root is implicitly specified and validated. In order to enforce that every CustomResource is a good citizen in the API Machinery of the API server, i.e. that features like owner references, finalizers, server-side apply etc. work as designed, we do not want that CRDs restrict metadata fields other than name and generateName.

So, we shouldn't be restricting description in the CRD for metadata

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Metadata is exclusively owned by the apiserver and apimachinery. A schema inside a CRD will interfere with apimachinery and we cannot guarantee that a CR from today works tomorrow.

Metadata is validated, but implicitly following the logic inside the kube-apiserver.

Copy link
Contributor

@soltysh soltysh left a comment

Choose a reason for hiding this comment

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

/lgtm

@openshift-ci-robot
Copy link
Contributor

@soltysh: changing LGTM is restricted to collaborators

Details

In response to this:

/lgtm

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

metadata:
type: object
spec:
description: spec hold the intent of how this operator should behave.
Copy link
Member

Choose a reason for hiding this comment

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

I've filed openshift/api#499 to fix this spec hold the typo.

type: object
status:
description: status holds the information about the state of an operator. It
is consistent with status information across the kube ecosystem.
Copy link
Member

Choose a reason for hiding this comment

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

I've filed openshift/api#500 expanding kube -> Kubernetes.

versions:
description: versions is a slice of operand version tuples. Operators
which manage multiple operands will have multiple entries in the array. If
an operator is Available, it must have at least one entry. You must
Copy link
Member

Choose a reason for hiding this comment

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

Even operators with a single operand will have multiple entries, one for operator and one for the operand. And when you're Available, you need to have an operator entry, not just "an entry". I've filed openshift/api#501 to wordsmith that sort of thing.

@abhinavdahiya
Copy link
Contributor

/approve

@wking
Copy link
Member

wking commented Oct 28, 2019

/lgtm

We can always bump the vendored dir again if/when my API PRs land.

@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
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: abhinavdahiya, soltysh, sttts, wking

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

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [abhinavdahiya,wking]

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

1 similar comment
@openshift-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: abhinavdahiya, soltysh, sttts, wking

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

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [abhinavdahiya,wking]

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 b0ce53c into openshift: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/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants