Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrStopped = errors.New("limiter stopped")
Functions ¶
This section is empty.
Types ¶
type Limiter ¶
type Limiter struct { }
Limiter is precise rate limiter with context support.
func NewLimiter ¶
NewLimiter returns limiter that throttles rate of successful Acquire() calls to maxSize events at any given interval.
Click to show internal directories.
Click to hide internal directories.