Versions in this module Expand all Collapse all v0 v0.0.6 Apr 9, 2023 v0.0.5 Mar 6, 2023 Changes in this version + var ErrAcquireFailed = errors.New("Number of requests exceeds threshold") + var SentinelRedisKey = "sentinel:configs" + func Allow(ctx context.Context, resource string) error + func IsValidRule(rule *Rule) error + func LoadRules(ctx context.Context, rdb *redis.Client, rules []*Rule) error + func Wait(ctx context.Context, resource string, retry int) error + type Rule struct + ForcedUpdate bool + Resource string + Threshold int64 + type TokenBucketLimiter struct