Fix failed to cache resources if group version not found (#5408)

This commit is contained in:
hongming
2022-12-09 16:18:34 +08:00
committed by GitHub
parent 75e05c59da
commit 5151556663

View File

@@ -412,7 +412,7 @@ func waitForCacheSync(discoveryClient discovery.DiscoveryInterface, sharedInform
if err != nil {
if errors.IsNotFound(err) {
klog.Warningf("group version %s not exists in the cluster", groupVersion)
return nil
continue
}
return fmt.Errorf("failed to fetch group version %s: %s", groupVersion, err)
}