-
Notifications
You must be signed in to change notification settings - Fork 482
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
Mark group as optional in LocalObjectReference #3332
base: main
Are you sure you want to change the base?
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: tamalsaha The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Welcome @tamalsaha! |
Hi @tamalsaha. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. 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-sigs/prow repository. |
d07c276
to
13e5fab
Compare
13e5fab
to
22f1437
Compare
/ok-to-test |
@@ -27,6 +27,8 @@ package v1 | |||
type LocalObjectReference struct { | |||
// Group is the group of the referent. For example, "gateway.networking.k8s.io". | |||
// When unspecified or empty string, core API group is inferred. | |||
// | |||
// +optional |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
also need to make Group a pointer and add an omitempty
tag
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done!
Signed-off-by: Tamal Saha <[email protected]>
22f1437
to
f694a85
Compare
this may not be a breaking change for users, but may be a breaking change for implementations, I still +1 this change to improve user experience (lesser config to write) |
Signed-off-by: Tamal Saha <[email protected]>
42be084
to
3b52d53
Compare
/retest |
Let's hold off on this for a minute, I think this actually requires a bit more discussion. /hold Although I certainly would love to save some unnecessary config here if we can, I'm worried that we're going to end up with some unintended consequences. As far as I can tell, there are currently 3 places in the API where we have a default group, and in all cases we also default kind:
It looks like we're currently using LocalObjectReference in 2 places:
It seems very clear that we'd never want to default to the core ("") API group for ExtensionRef. CACertificateRefs is a little bit less clear on the surface, but given that our goal is to move to recommending something like So with all that said, my proposed change here would be much smaller. We'd just change "When unspecified or empty string" to "When empty string". |
PR needs rebase. 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-sigs/prow repository. |
What type of PR is this?
/kind bug
What this PR does / why we need it:
Make group as optional in LocalObjectReference
Which issue(s) this PR fixes:
Fixes #3322
Does this PR introduce a user-facing change?: