limiter

package
v0.69.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 22, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RateLimiter

type RateLimiter struct {
	// contains filtered or unexported fields
}

RateLimiter limits callback calls

func NewRateLimiter

func NewRateLimiter(limit int64, duration time.Duration) *RateLimiter

NewRateLimiter returns limiter with limit per duration

func (*RateLimiter) Throttle added in v0.68.4

func (rt *RateLimiter) Throttle() bool

Throttle registers reconcile event and checks if it must be throttled

type ReconcileRateLimiter added in v0.68.4

type ReconcileRateLimiter struct {
	RateLimiter
	// contains filtered or unexported fields
}

ReconcileRateLimiter limits reconcile callback calls

func NewReconcileRateLimiter added in v0.68.4

func NewReconcileRateLimiter(limiterName string, limit int64) *ReconcileRateLimiter

NewReconcileRateLimiter returns limiter with limit per 2 seconds

func (*ReconcileRateLimiter) Throttle added in v0.68.4

func (rt *ReconcileRateLimiter) Throttle() bool

Throttle registers reconcile event and checks if it must be throttled

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL