Skip to content

Commit

Permalink
disable client-side rate-limiter (#64)
Browse files Browse the repository at this point in the history
Signed-off-by: yue9944882 <[email protected]>
  • Loading branch information
yue9944882 authored Mar 22, 2022
1 parent 3276d64 commit bd6789b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions pkg/apis/cluster/v1alpha1/clustergateway_types_secret.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import (
"k8s.io/apiserver/pkg/registry/rest"
"k8s.io/apiserver/pkg/util/feature"
"k8s.io/client-go/kubernetes"
clientgorest "k8s.io/client-go/rest"
"k8s.io/klog/v2"
ocmclient "open-cluster-management.io/api/client/cluster/clientset/versioned"
clusterv1 "open-cluster-management.io/api/cluster/v1"
Expand Down Expand Up @@ -156,9 +157,11 @@ func (in *ClusterGateway) ConvertToTable(ctx context.Context, object runtime.Obj

func initClientOnce() {
initClient.Do(func() {
copiedCfg := clientgorest.CopyConfig(loopback.GetLoopbackMasterClientConfig())
copiedCfg.RateLimiter = nil
setClient(
kubernetes.NewForConfigOrDie(loopback.GetLoopbackMasterClientConfig()),
ocmclient.NewForConfigOrDie(loopback.GetLoopbackMasterClientConfig()))
kubernetes.NewForConfigOrDie(copiedCfg),
ocmclient.NewForConfigOrDie(copiedCfg))
})
}

Expand Down

0 comments on commit bd6789b

Please sign in to comment.