ulule / limiter

Dead simple rate limit middleware for Go.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Limit for every 5 minute

tqdo opened this issue · comments

commented

Just wondering whether there is a way to impose a rate limit every 5 minutes instead of every minute?

Hello,

I think you could use this:

rate := limiter.Rate{
    Period: 5 * time.Minute,
    Limit:  200,
}