Clock is the minimum necessary interface to instantiate a rate limiter with a clock or mock clock, compatible with clocks created using github.com/andres-erbsen/clock.
Limiter is used to rate-limit some process, possibly across goroutines. The process is expected to call Take() before every iteration, which may block to throttle the goroutine.
New returns a Limiter that will limit to the given RPS.
type Option func(l *limiter)
Option configures a Limiter.
var WithoutSlack Option = withoutSlackOption
WithoutSlack is an option for ratelimit.New that initializes the limiter without any initial tolerance for bursts of traffic.