mirror of
https://github.com/rancher/norman.git
synced 2025-07-01 09:42:06 +00:00
Move ratelimit to wrangler
This commit is contained in:
parent
8841c697b8
commit
52ab7b61fb
@ -1,19 +0,0 @@
|
||||
package ratelimit
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"k8s.io/client-go/util/flowcontrol"
|
||||
)
|
||||
|
||||
var (
|
||||
None = flowcontrol.RateLimiter((*none)(nil))
|
||||
)
|
||||
|
||||
type none struct{}
|
||||
|
||||
func (*none) TryAccept() bool { return true }
|
||||
func (*none) Stop() {}
|
||||
func (*none) Accept() {}
|
||||
func (*none) QPS() float32 { return 1 }
|
||||
func (*none) Wait(_ context.Context) error { return nil }
|
@ -3,7 +3,7 @@ package restwatch
|
||||
import (
|
||||
"time"
|
||||
|
||||
"github.com/rancher/norman/pkg/ratelimit"
|
||||
"github.com/rancher/wrangler/pkg/ratelimit"
|
||||
"k8s.io/client-go/rest"
|
||||
)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user