Skip to content

Commit

Permalink
Need to support redis sentinel username. (#924)
Browse files Browse the repository at this point in the history
  • Loading branch information
Skwol authored Oct 26, 2024
1 parent c8c8adf commit 1e102a5
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions asynq.go
Original file line number Diff line number Diff line change
Expand Up @@ -316,6 +316,9 @@ type RedisFailoverClientOpt struct {
// https://redis.io/topics/sentinel.
SentinelAddrs []string

// Redis sentinel username.
SentinelUsername string

// Redis sentinel password.
SentinelPassword string

Expand Down Expand Up @@ -364,6 +367,7 @@ func (opt RedisFailoverClientOpt) MakeRedisClient() interface{} {
return redis.NewFailoverClient(&redis.FailoverOptions{
MasterName: opt.MasterName,
SentinelAddrs: opt.SentinelAddrs,
SentinelUsername: opt.SentinelUsername,
SentinelPassword: opt.SentinelPassword,
Username: opt.Username,
Password: opt.Password,
Expand Down

0 comments on commit 1e102a5

Please sign in to comment.