-
Notifications
You must be signed in to change notification settings - Fork 118
minor updates to typed-name #1113
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
Conversation
Signed-off-by: Nir Rozenbaum <[email protected]>
✅ Deploy Preview for gateway-api-inference-extension ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: nirrozenbaum 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 |
func (tn *TypedName) String() string { | ||
return tn.Type + Separator + tn.Name | ||
return tn.Name + separator + tn.Type |
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.
Would this be a breaking change to existing usage though?
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.
TLDR:
nope. this field is mainly used for logging.
more details if you're interested:
TypedName
was introduced recently with the understanding that we could potentially have multiple instances of the same plugin type, and then we may distinguish them by name (name is optional, type is mandatory).
the idea behind this change is to keep similar behavior as NamespacedName
- so if both fields exist we get name/type
, if no name was defined we get /type
(instead of current implementation that returns type/
).
this is similar to NamespacedName
, where Name is mandatory and Ns is optional (for cluster-scoped resources), so we either get back ns/name
or /name
for cluster-scoped resources.
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.
Sounds good
/lgtm |
Signed-off-by: Nir Rozenbaum <[email protected]>
cc @elevran