mirror of
https://github.com/charlienet/go-mixed.git
synced 2025-07-18 00:22:41 +08:00
add DB
This commit is contained in:
@ -28,6 +28,10 @@ type ReidsOption struct {
|
||||
Prefix string
|
||||
Separator string
|
||||
|
||||
// Database to be selected after connecting to the server.
|
||||
// Only single-node and failover clients.
|
||||
DB int
|
||||
|
||||
MaxRetries int
|
||||
MinRetryBackoff time.Duration
|
||||
MaxRetryBackoff time.Duration
|
||||
@ -56,6 +60,8 @@ func New(opt *ReidsOption) Client {
|
||||
Addrs: opt.Addrs,
|
||||
Password: opt.Password,
|
||||
|
||||
DB: opt.DB,
|
||||
|
||||
MaxRetries: opt.MaxRetries,
|
||||
MinRetryBackoff: opt.MinRetryBackoff,
|
||||
MaxRetryBackoff: opt.MaxRetryBackoff,
|
||||
|
Reference in New Issue
Block a user