enhance: add sentinel auth config for redis (#3348)

This commit is contained in:
laushunyu
2024-03-06 19:27:52 +08:00
committed by GitHub
parent fbd266fad0
commit 9b48da459e
2 changed files with 21 additions and 17 deletions

View File

@ -25,6 +25,8 @@ type Config struct {
Db int `json:"db"` // Redis db.
User string `json:"user"` // Username for AUTH.
Pass string `json:"pass"` // Password for AUTH.
SentinelUser string `json:"sentinel_user"` // Username for sentinel AUTH.
SentinelPass string `json:"sentinel_pass"` // Password for sentinel AUTH.
MinIdle int `json:"minIdle"` // Minimum number of connections allowed to be idle (default is 0)
MaxIdle int `json:"maxIdle"` // Maximum number of connections allowed to be idle (default is 10)
MaxActive int `json:"maxActive"` // Maximum number of connections limit (default is 0 means no limit).