Remove deprecated discovery/ServerResources function

ServerResources function was deprecated and instead ServerGroupsAndResources
function is suggested.

This PR removes ServerResources function and move every place to use ServerGroupsAndResources.

Kubernetes-commit: ef39a8914291ba200bd5486c88a7575ffd4b7d1d
This commit is contained in:
Arda Güçlü
2021-12-22 11:14:09 +03:00
committed by Kubernetes Publisher
parent 23ab4aec8e
commit 7e062f8fa4
8 changed files with 7 additions and 69 deletions

View File

@@ -401,10 +401,6 @@ func (d *fakeFailingDiscovery) ServerResourcesForGroupVersion(groupVersion strin
return nil, fmt.Errorf("not found")
}
func (d *fakeFailingDiscovery) ServerResources() ([]*metav1.APIResourceList, error) {
return ServerResources(d)
}
func (d *fakeFailingDiscovery) ServerPreferredResources() ([]*metav1.APIResourceList, error) {
return ServerPreferredResources(d)
}
@@ -464,11 +460,6 @@ func (c *fakeCachedDiscoveryInterface) ServerResourcesForGroupVersion(groupVersi
return nil, errors.NewNotFound(schema.GroupResource{}, "")
}
// Deprecated: use ServerGroupsAndResources instead.
func (c *fakeCachedDiscoveryInterface) ServerResources() ([]*metav1.APIResourceList, error) {
return ServerResources(c)
}
func (c *fakeCachedDiscoveryInterface) ServerPreferredResources() ([]*metav1.APIResourceList, error) {
if c.enabledGroupA {
return []*metav1.APIResourceList{