切换go-redis库
This commit is contained in:
10
client.go
10
client.go
@ -18,14 +18,11 @@ import (
|
||||
wrapperOperate "git.zhangdeman.cn/zhangdeman/wrapper"
|
||||
redisClient "github.com/go-redis/redis/v8"
|
||||
"github.com/pkg/errors"
|
||||
redisClientV9 "github.com/redis/go-redis/v9"
|
||||
"go.uber.org/zap"
|
||||
)
|
||||
|
||||
var (
|
||||
Client abstract.IRedisClient
|
||||
ClientV9 abstract.IRedisClient
|
||||
ClientVersion = define.ClientVersionV8
|
||||
Client abstract.IRedisClient
|
||||
)
|
||||
|
||||
func init() {
|
||||
@ -34,11 +31,6 @@ func init() {
|
||||
instanceTable: make(map[string]*redisClient.ClusterClient),
|
||||
whiteCommandTable: make(map[string]bool),
|
||||
}
|
||||
ClientV9 = &OwnClientV9{
|
||||
lock: &sync.RWMutex{},
|
||||
instanceTable: make(map[string]*redisClientV9.ClusterClient),
|
||||
whiteCommandTable: make(map[string]bool),
|
||||
}
|
||||
}
|
||||
|
||||
type OwnClient struct {
|
||||
|
Reference in New Issue
Block a user