type PassiveRateLimiter …
type RateLimiter …
type tokenBucketPassiveRateLimiter …
type tokenBucketRateLimiter …
func NewTokenBucketRateLimiter(qps float32, burst int) RateLimiter { … }
func NewTokenBucketPassiveRateLimiter(qps float32, burst int) PassiveRateLimiter { … }
type Clock …
var _ …
func NewTokenBucketRateLimiterWithClock(qps float32, burst int, c Clock) RateLimiter { … }
func NewTokenBucketPassiveRateLimiterWithClock(qps float32, burst int, c clock.PassiveClock) PassiveRateLimiter { … }
func newTokenBucketRateLimiterWithClock(limiter *rate.Limiter, c Clock, qps float32) *tokenBucketRateLimiter { … }
func newTokenBucketRateLimiterWithPassiveClock(limiter *rate.Limiter, c clock.PassiveClock, qps float32) *tokenBucketPassiveRateLimiter { … }
func (tbprl *tokenBucketPassiveRateLimiter) Stop() { … }
func (tbprl *tokenBucketPassiveRateLimiter) QPS() float32 { … }
func (tbprl *tokenBucketPassiveRateLimiter) TryAccept() bool { … }
func (tbrl *tokenBucketRateLimiter) Accept() { … }
func (tbrl *tokenBucketRateLimiter) Wait(ctx context.Context) error { … }
type fakeAlwaysRateLimiter …
func NewFakeAlwaysRateLimiter() RateLimiter { … }
func (t *fakeAlwaysRateLimiter) TryAccept() bool { … }
func (t *fakeAlwaysRateLimiter) Stop() { … }
func (t *fakeAlwaysRateLimiter) Accept() { … }
func (t *fakeAlwaysRateLimiter) QPS() float32 { … }
func (t *fakeAlwaysRateLimiter) Wait(ctx context.Context) error { … }
type fakeNeverRateLimiter …
func NewFakeNeverRateLimiter() RateLimiter { … }
func (t *fakeNeverRateLimiter) TryAccept() bool { … }
func (t *fakeNeverRateLimiter) Stop() { … }
func (t *fakeNeverRateLimiter) Accept() { … }
func (t *fakeNeverRateLimiter) QPS() float32 { … }
func (t *fakeNeverRateLimiter) Wait(ctx context.Context) error { … }
var _ …
var _ …
var _ …
var _ …