From 3ed3e553e762d445c9920aecf797ffdf0a463e83 Mon Sep 17 00:00:00 2001 From: Stefan Prodan Date: Mon, 26 Apr 2021 15:32:13 +0300 Subject: [PATCH] Avoid throttling when some Flux CRDs are not registered Signed-off-by: Stefan Prodan --- internal/utils/utils.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/internal/utils/utils.go b/internal/utils/utils.go index c8bdb657..3e949c8b 100644 --- a/internal/utils/utils.go +++ b/internal/utils/utils.go @@ -156,6 +156,10 @@ func KubeConfig(kubeConfigPath string, kubeContext string) (*rest.Config, error) return nil, fmt.Errorf("kubernetes configuration load failed: %w", err) } + // avoid throttling request when some Flux CRDs are not registered + cfg.QPS = 50 + cfg.Burst = 100 + return cfg, nil }