Documentation
¶
Index ¶
Constants ¶
View Source
const ConfigKey = "redis"
ConfigKey for this repo
Variables ¶
View Source
var R = new(Config)
R config of redis
View Source
var Rdb redis.UniversalClient
Rdb to describe redis db client 1. If the MasterName option is specified, a sentinel-backed FailoverClient is returned. 2. if the number of Addrs is two or more, a ClusterClient is returned. 3. Otherwise, a single-node Client is returned.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Addrs []string `json:"addrs"`
MasterName string `json:"master_name,omitempty"`
MaxPoolSize int `json:"max_pool_size"`
MinPoolSize int `json:"min_pool_size"`
Username string `json:"username,omitempty"`
Password string `json:"password,omitempty"`
SentinelPassword string `json:"sentinel_password,omitempty"`
DB int `json:"db"`
RunAfters []string `json:"run_after,omitempty"`
}
Config implements tao.Config
Click to show internal directories.
Click to hide internal directories.