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
Clarify cached object type in apiserver log #88979
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: liggitt 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 |
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.
Thanks. Looks good to me, although it continues a problematic naming convention.
@@ -88,6 +90,17 @@ func StorageWithCacher(capacity int) generic.StorageDecorator { | |||
} | |||
} | |||
|
|||
func objectTypeToString(obj runtime.Object) string { |
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.
In a language with runtime representations for types, such as go, it is actually confusing to use the name "object type" instead of "example object" when the latter is meant. (This complaint applies to a lot of code --- particularly code that uses the golang type interface{}
for the value in question --- not just this change.)
/lgtm |
/retest Review the full test history for this PR. Silence the bot with an |
/sig api-machinery |
/test all (wake up CI?) |
/retest Review the full test history for this PR. Silence the bot with an |
/sig api-machinery |
I don't know what's going on with the sig stuff. At #88979 (comment) the bot added both the |
/remove-sig api-machinery |
/sig api-machinery |
/retest Review the full test history for this PR. Silence the bot with an |
/priority important-longterm Just trying to kick CI |
/priority backlog |
/remove-priority important-longterm |
What type of PR is this?
/kind cleanup
What this PR does / why we need it:
Clarifies the cached object type in the API server log for custom resources.
Before:
After:
/cc @MikeSpreitzer
/sig api-machinery
/priority backlog