#1 httprate
net/http rate limiter middleware
Package limiter defines rate limiting systems.
Health score 63/100, confidence 75/100.
| Latest version | v1.1.0 |
| Imported by | 66 packages |
| Stars | 0 |
| Forks | 0 |
| Last activity | 6 months ago |
| Latest release | Unknown |
| License | Unknown |
| Known vuln records | 0 |
| Symbol | Kind | Synopsis |
|---|---|---|
| Store | Type | type Store interface{ ... } |
| Store.Burst | Method | Burst func(ctx context.Context, key string, tokens uint64) error |
| Store.Close | Method | Close func(ctx context.Context) error |
| Store.Get | Method | Get func(ctx context.Context, key string) (tokens, remaining uint64, err error) |
| Store.Set | Method | Set func(ctx context.Context, key string, tokens uint64, interval time.Duration) error |
| Store.Take | Method | Take func(ctx context.Context, key string) (tokens, remaining, reset uint64, ok bool, err error) |
| ErrStopped | Variable | var ErrStopped = fmt.Errorf("store is stopped") |
net/http rate limiter middleware
Dead simple rate limit middleware for Go.