Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Limiter ¶
type Limiter struct { // 限流器 名称 Name string // contains filtered or unexported fields }
Limiter 限流器结构定义
func NewLimiter ¶
NewLimiter 创建限流器 rateLimitEvery 每秒产生多少个令牌 rateLimitBucket 令牌桶大小
Click to show internal directories.
Click to hide internal directories.