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

⚠ Add testenv support for CRDv1/CRDv1beta1 + update to k8s 1.16.4 #752

Merged
merged 1 commit into from
Jan 22, 2020

Conversation

vincepri
Copy link
Member

@vincepri vincepri commented Jan 8, 2020

Signed-off-by: Vince Prignano vincepri@vmware.com

This PR adds support for testenv to load CRDv1 and CRDv1beta1 by using runtime.Object and controller-runtime unstructured client.

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Jan 8, 2020
@vincepri
Copy link
Member Author

vincepri commented Jan 8, 2020

/test pull-controller-runtime-test

@vincepri
Copy link
Member Author

vincepri commented Jan 8, 2020

The failure seems like a race condition, it doesn't happen locally. I can take a look after getting some feedback on the current approach

@gerred
Copy link
Contributor

gerred commented Jan 10, 2020

/ok-to-test

@k8s-ci-robot k8s-ci-robot added the ok-to-test Indicates a non-member PR verified by an org member that is safe to test. label Jan 10, 2020
@gerred
Copy link
Contributor

gerred commented Jan 10, 2020

/retest

@gerred
Copy link
Contributor

gerred commented Jan 10, 2020

@vincepri looks reasonable, I will test locally as well, but kicking the flake for now.

@gerred
Copy link
Contributor

gerred commented Jan 10, 2020

/assign gerred

@vincepri
Copy link
Member Author

@gerred @DirectXMan12 Thoughts on how to proceed here?

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jan 14, 2020
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jan 14, 2020
@DirectXMan12
Copy link
Contributor

looks like it's passing. Will defer to @gerred for the LGTM. Let me know when that's in place

@gerred
Copy link
Contributor

gerred commented Jan 14, 2020 via email

@gerred
Copy link
Contributor

gerred commented Jan 14, 2020 via email

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jan 14, 2020
@gerred
Copy link
Contributor

gerred commented Jan 14, 2020 via email

@@ -19,7 +19,7 @@ set -e
hack_dir=$(dirname ${BASH_SOURCE})
source ${hack_dir}/common.sh

k8s_version=1.14.1
k8s_version=1.16.4

Choose a reason for hiding this comment

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

Can we mention this version upgrade in the PR message itself. Is CRD with version v1 supported from 1.16.4?

Copy link
Member Author

Choose a reason for hiding this comment

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

Added a message

gvs := []schema.GroupVersion{}
if crd.Spec.Version != "" {
gvs = append(gvs, schema.GroupVersion{Group: crd.Spec.Group, Version: crd.Spec.Version})
crdGroup, _, err := unstructured.NestedString(crd.Object, "spec", "group")

Choose a reason for hiding this comment

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

Will it be good to check the found option & return err for both spec.group not found as well err cases?

Copy link
Member Author

Choose a reason for hiding this comment

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

I'm ok either way, although it's a change from the previous behavior

Copy link

@AmitKumarDas AmitKumarDas left a comment

Choose a reason for hiding this comment

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

/lgtm

@k8s-ci-robot
Copy link
Contributor

@AmitKumarDas: changing LGTM is restricted to collaborators

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.

@vincepri vincepri changed the title ⚠ Add testenv support for CRDv1/CRDv1beta1 ⚠ Add testenv support for CRDv1/CRDv1beta1 + update to k8s 1.16.4 Jan 18, 2020
Signed-off-by: Vince Prignano <vincepri@vmware.com>
@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jan 21, 2020
@vincepri
Copy link
Member Author

@DirectXMan12 @gerred Any updates on the status of this PR?

@gerred
Copy link
Contributor

gerred commented Jan 21, 2020

@vincepri I can't approve as a reviewer. @DirectXMan12 @droot @pwittrock are we OK approving here? I don't mind also becoming a CR approver to help here more. :)

@DirectXMan12
Copy link
Contributor

/approve

as per the reviewers' LGTMs

This has the nice effect of getting CRD out of our public API surface.

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: DirectXMan12, vincepri

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

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jan 22, 2020
@vincepri
Copy link
Member Author

Thanks @DirectXMan12 !

@gerred need another lgtm if you're around :)

@DirectXMan12
Copy link
Contributor

/lgtm
(reapplying as per above)

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jan 22, 2020
@k8s-ci-robot k8s-ci-robot merged commit eae89ba into kubernetes-sigs:master Jan 22, 2020
DirectXMan12 pushed a commit that referenced this pull request Jan 31, 2020
Doc Clarification: Using an External Type
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. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. 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.

5 participants