refactor(redis): add NonBlock config, disable redis ping by default (#3073)

This commit is contained in:
cong
2023-03-29 10:28:12 +08:00
committed by GitHub
parent ca4ce7bce8
commit 95b85336d6
5 changed files with 98 additions and 14 deletions

View File

@@ -33,6 +33,9 @@ func getClient(r *Redis) (*red.Client, error) {
TLSConfig: tlsConfig,
})
store.AddHook(durationHook)
for _, hook := range r.hooks {
store.AddHook(hook)
}
return store, nil
})