Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Go/regworkerid/regworkerid/reghelper.go 无法连接哨兵模式的redis #70

Open
ZhenbPeng opened this issue Jul 28, 2023 · 1 comment

Comments

@ZhenbPeng
Copy link

在连接哨兵模式的redis时
func newRedisClient() redis.UniversalClient {
client := redis.NewUniversalClient(&redis.UniversalOptions{
Addrs: strings.Split(_RedisConnString, ","),
Password: _RedisPassword,
DB: _RedisDB,
MasterName: _RedisMasterName,
//PoolSize: 1000,
//ReadTimeout: time.Millisecond * time.Duration(100),
//WriteTimeout: time.Millisecond * time.Duration(100),
//IdleTimeout: time.Second * time.Duration(60),
})
return client
}
应该要使用SentinelPassword与SentinelUsername

@yitter
Copy link
Owner

yitter commented Aug 9, 2023

麻烦你提交一个 pr

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants