Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultTlsFunc = func(cnf *config.RedisConfig) (*tls.Config, error) { if strings.EqualFold(cnf.Tls.Key, "false") { return nil, result.RErrNotSupport } if strings.EqualFold(cnf.Tls.Key, "true") { return &tls.Config{}, nil } if strings.EqualFold(cnf.Tls.Key, "skip-verify") || strings.EqualFold(cnf.Tls.Key, "preferred") { return &tls.Config{InsecureSkipVerify: true}, nil } cert, rootCertPool, err := daotls.GetCertificate(&cnf.Tls) if err != nil { return nil, err } return &tls.Config{ RootCAs: rootCertPool, Certificates: []tls.Certificate{cert}, }, nil }
Functions ¶
func WithTlsOption ¶ added in v1.9.15
Types ¶
type Adapter ¶ added in v1.1.23
type Adapter struct {
// contains filtered or unexported fields
}
func NewAdapter ¶ added in v1.1.23
func NewAdapter(name string, cfg *config.RedisConfig, sentinelCfg *config.RedisConfig, clusterCfg *config.RedisConfig, opts ...option.Option) (*Adapter, error)
type Client ¶
type Logger ¶ added in v1.1.23
type Logger struct {
config.RedisLogger
}
Click to show internal directories.
Click to hide internal directories.