Fix: cleanup ResourceRegistry controller logs

Signed-off-by: xigang <wangxigang2014@gmail.com>
This commit is contained in:
xigang 2023-04-28 11:21:59 +08:00
parent 5fb4680ea7
commit 50d155f72a
1 changed files with 2 additions and 2 deletions

View File

@ -410,7 +410,7 @@ func (c *Controller) deleteCluster(obj interface{}) {
c.queue.Add(cluster.GetName()) c.queue.Add(cluster.GetName())
} }
// getClusterAndResource returns the cluster and resources from the resourceRegistry object // getClusters returns the cluster from the resourceRegistry object
func (c *Controller) getClusters(affinity policyv1alpha1.ClusterAffinity) []string { func (c *Controller) getClusters(affinity policyv1alpha1.ClusterAffinity) []string {
clusters := make([]string, 0) clusters := make([]string, 0)
lst, err := c.clusterLister.List(labels.Everything()) lst, err := c.clusterLister.List(labels.Everything())
@ -426,7 +426,7 @@ func (c *Controller) getClusters(affinity policyv1alpha1.ClusterAffinity) []stri
return clusters return clusters
} }
// getClusterAndResource returns the cluster and resources from the resourceRegistry object // getResources returns the resources from the resourceRegistry object
func (c *Controller) getResources(selectors []searchv1alpha1.ResourceSelector) []schema.GroupVersionResource { func (c *Controller) getResources(selectors []searchv1alpha1.ResourceSelector) []schema.GroupVersionResource {
resources := make([]schema.GroupVersionResource, 0) resources := make([]schema.GroupVersionResource, 0)
for _, rs := range selectors { for _, rs := range selectors {