From 37916c7b1c611f25eed146e9b3855e21ee5465e3 Mon Sep 17 00:00:00 2001 From: Wen Zhou Date: Thu, 23 Jan 2025 15:35:23 +0100 Subject: [PATCH] update: change previous workaround for subscription and add smcp in the list - remove subs from client cache - add smcp into exclude cache Signed-off-by: Wen Zhou --- main.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/main.go b/main.go index a9c7e79e8a4..2f482846d63 100644 --- a/main.go +++ b/main.go @@ -269,7 +269,6 @@ func main() { //nolint:funlen,maintidx,gocyclo &rbacv1.RoleBinding{}: { Namespaces: oDHCache, }, - &ofapiv1alpha1.Subscription{}: {}, // TODO: workaround to get all subs work, without specify it seems it does not cache from all namespaces &rbacv1.ClusterRole{}: {}, &rbacv1.ClusterRoleBinding{}: {}, &securityv1.SecurityContextConstraints{}: {}, @@ -302,6 +301,8 @@ func main() { //nolint:funlen,maintidx,gocyclo Cache: &client.CacheOptions{ DisableFor: []client.Object{ resources.GvkToUnstructured(gvk.OpenshiftIngress), + &ofapiv1alpha1.Subscription{}, + resources.GvkToUnstructured(gvk.ServiceMeshControlPlane), &authorizationv1.SelfSubjectRulesReview{}, }, // Set it to true so the cache-backed client reads unstructured objects