remove rate limiter metric as it is not in use

Change-Id: I91157653e3860eeecc3f572aee88da6ffc65faed
This commit is contained in:
Han Kang
2022-10-13 12:03:35 -07:00
parent b601769721
commit 2bbd445f50
28 changed files with 0 additions and 275 deletions

View File

@@ -46,7 +46,6 @@ import (
"k8s.io/client-go/tools/cache"
"k8s.io/client-go/tools/record"
"k8s.io/client-go/util/workqueue"
"k8s.io/component-base/metrics/prometheus/ratelimiter"
"k8s.io/kubernetes/pkg/controller"
"k8s.io/kubernetes/pkg/controller/deployment/util"
)
@@ -103,11 +102,6 @@ type DeploymentController struct {
func NewDeploymentController(dInformer appsinformers.DeploymentInformer, rsInformer appsinformers.ReplicaSetInformer, podInformer coreinformers.PodInformer, client clientset.Interface) (*DeploymentController, error) {
eventBroadcaster := record.NewBroadcaster()
if client != nil && client.CoreV1().RESTClient().GetRateLimiter() != nil {
if err := ratelimiter.RegisterMetricAndTrackRateLimiterUsage("deployment_controller", client.CoreV1().RESTClient().GetRateLimiter()); err != nil {
return nil, err
}
}
dc := &DeploymentController{
client: client,
eventBroadcaster: eventBroadcaster,