-
Notifications
You must be signed in to change notification settings - Fork 450
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
Drop unused generated clients #4592
Drop unused generated clients #4592
Conversation
The funcs add all versioned API types (i.e., all but internal types). They can be used as an replacement for the AddToScheme funcs generated by client-gen.
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.
Love it! I assume you plan to remove the other clients with subsequent PRs?
d307c39
to
d172215
Compare
That won't be possible so easily, as they are used in admission plugins. However, what is possible and planned is to remove usages of |
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.
/lgtm
/squash |
* Add AddToScheme to all install packages The funcs add all versioned API types (i.e., all but internal types). They can be used as an replacement for the AddToScheme funcs generated by client-gen. * Replace usages of generated schemes * Drop generated extensions client * Remove usages of generated operations client * Drop generated operations client * Drop unused API{Registration,Extension} from kubernetes.Interface * [generated] make revendor * Replace usages of kubernetes.Interface.GardenSeedManagement() * Drop unused Garden{Core,SeedManagement} from kubernetes.Interface * Drop unused ForwardPodPort from kubernetes.Interface
* Add AddToScheme to all install packages The funcs add all versioned API types (i.e., all but internal types). They can be used as an replacement for the AddToScheme funcs generated by client-gen. * Replace usages of generated schemes * Drop generated extensions client * Remove usages of generated operations client * Drop generated operations client * Drop unused API{Registration,Extension} from kubernetes.Interface * [generated] make revendor * Replace usages of kubernetes.Interface.GardenSeedManagement() * Drop unused Garden{Core,SeedManagement} from kubernetes.Interface * Drop unused ForwardPodPort from kubernetes.Interface
How to categorize this PR?
/area scalability dev-productivity
/kind cleanup
What this PR does / why we need it:
This PR drops some unused generated client code (extensions and operations group).
It also drops some unused clients (
Garden{Core,SeedManagement,Operations}
andAPI{Registration,Extension}
) fromkubernetes.Interface
.All of this is dropped in favor of (cached) controller-runtime clients to simplify/unify our code and leverage the clients' caches wherever possible.
Which issue(s) this PR fixes:
Part of #2414
Special notes for your reviewer:
kubernetes.Interface.Kubernetes()
is not dropped in this PR, as there are still a lot of usages.This can be tackled in a future PR.
The generated operations clients might be needed in the future, when we add some checks in admission plugins (e.g. for
Bastion
s). I decided to drop them nevertheless for the sake of simplification. We can still add them back with a few lines later on if needed.Release note: