package
0.0.8
Repository: https://github.com/golang-tools/redishelper.git
Documentation: pkg.go.dev

# Packages

Package limiter 限制器可以用于防止短时间内大量请求同时处理,比如缓存防击穿,防爬虫等.

# Functions

New 创建一个新的令牌桶对象@params k *key.Key redis客户端的键对象.
WithCountPerPeriod 设置时间间隔内的token消减数.
WithMaxBurst 设置最大熔断数,最大token数为MaxBurst+1.
WithPeriod 设置token消减间隔时长,单位s.

# Variables

No description provided by the author

# Structs

Options broker的配置.
RedisCell 令牌桶对象.
RedisCellStatus 令牌桶的状态信息.

# Interfaces

Option configures how we set up the connection.