feat: support redis rate limiting

This commit is contained in:
2026-01-17 12:04:55 +08:00
parent c399a65d83
commit 419877ffa8
4 changed files with 134 additions and 0 deletions

View File

@@ -34,6 +34,15 @@ type RateLimit struct {
WindowSeconds int
Message string
SkipPaths []string
Redis *RateLimitRedis
}
type RateLimitRedis struct {
Addrs []string
Username string
Password string
DB int
Prefix string
}
type Whitelist struct {