-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
🐛 Fix lazy rest mapper cache invalidation #2687
🐛 Fix lazy rest mapper cache invalidation #2687
Conversation
When a group version is not found, if the group version is cached in apiGroups but not cached in knownGroups, the cache is not invalidated. Moreover and even worse, in that scenario an error is returned.
Perfect. Thank you very much! /lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: g-gaston, sbueringer 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 |
@g-gaston Do you have some time to open cherry-pick PRs for release-0.17 and release-0.16? |
/cherry-pick release-0.17 |
@g-gaston: new pull request created: #2688 In response to this:
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. |
This fixes a bug introduced by my previous PR #2663
When a group version is not found, if the group version is cached in apiGroups but not cached in knownGroups, the cache is not invalidated. Moreover and even worse, in that scenario an error is returned.
This is only an issue under the very rare case where a version has been removed during a call just after caching in apiGroups but before it's cached in knownGroups.
After the change now an error is never returned for not found versions no matter if the version was cached or not. And now the two different caches are checked and invalidated independently.