Documentation ¶
Index ¶
- Constants
- func IsEnabled(addrs []string) bool
- func MakeApplicationsKeyInManager() string
- func MakeBucketKeyInManager(name string) string
- func MakeKeyInManager(namespace, id string) string
- func MakeKeyInScheduler(namespace, id string) string
- func MakeNamespaceKeyInManager(namespace string) string
- func MakeNamespaceKeyInScheduler(namespace string) string
- func MakeNetworkTopologyKeyInScheduler(srcHostID, destHostID string) string
- func MakePeerKeyInManager(hostname, ip string) string
- func MakeProbedCountKeyInScheduler(hostID string) string
- func MakeProbesKeyInScheduler(srcHostID, destHostID string) string
- func MakeSchedulerKeyInManager(clusterID uint, hostname, ip string) string
- func MakeSchedulersKeyForPeerInManager(hostname, ip string) string
- func MakeSeedPeerKeyInManager(clusterID uint, hostname, ip string) string
- func NewRedis(cfg *redis.UniversalOptions) (redis.UniversalClient, error)
- func ParseNetworkTopologyKeyInScheduler(key string) (string, string, string, string, error)
- func ParseProbedCountKeyInScheduler(key string) (string, string, string, error)
Constants ¶
const ( // SeedPeerNamespace prefix of seed peers namespace cache key. SeedPeersNamespace = "seed-peers" // PeersNamespace prefix of peers namespace cache key. PeersNamespace = "peers" // SchedulersNamespace prefix of schedulers namespace cache key. SchedulersNamespace = "schedulers" // ApplicationsNamespace prefix of applications namespace cache key. ApplicationsNamespace = "applications" // BucketsNamespace prefix of buckets namespace cache key. BucketsNamespace = "buckets" // NetworkTopologyNamespace prefix of network topology namespace cache key. NetworkTopologyNamespace = "network-topology" // ProbesNamespace prefix of probes namespace cache key. ProbesNamespace = "probes" // ProbedCountNamespace prefix of probed count namespace cache key. ProbedCountNamespace = "probed-count" )
const (
// KeySeparator is the separator of redis key.
KeySeparator = ":"
)
Variables ¶
This section is empty.
Functions ¶
func MakeApplicationsKeyInManager ¶
func MakeApplicationsKeyInManager() string
MakeApplicationsKeyInManager make applications key in manager.
func MakeBucketKeyInManager ¶
MakeBucketKeyInManager make bucket key in manager.
func MakeKeyInManager ¶
MakeKeyInManager make key in manager.
func MakeKeyInScheduler ¶
MakeKeyInScheduler make key in scheduler.
func MakeNamespaceKeyInManager ¶
MakeNamespaceKeyInManager make namespace key in manager.
func MakeNamespaceKeyInScheduler ¶
MakeNamespaceKeyInScheduler make namespace key in scheduler.
func MakeNetworkTopologyKeyInScheduler ¶
MakeNetworkTopologyKeyInScheduler make network topology key in scheduler.
func MakePeerKeyInManager ¶
MakePeerKeyInManager make peer key in manager.
func MakeProbedCountKeyInScheduler ¶
MakeProbedCountKeyInScheduler make probed count key in scheduler.
func MakeProbesKeyInScheduler ¶
MakeProbesKeyInScheduler make probes key in scheduler.
func MakeSchedulerKeyInManager ¶
MakeSchedulerKeyInManager make scheduler key in manager.
func MakeSchedulersKeyForPeerInManager ¶
MakeSchedulersKeyForPeerInManager make schedulers key for peer in manager.
func MakeSeedPeerKeyInManager ¶
MakeSeedPeerKeyInManager make seed peer key in manager.
func NewRedis ¶
func NewRedis(cfg *redis.UniversalOptions) (redis.UniversalClient, error)
NewRedis returns a new redis client.
func ParseNetworkTopologyKeyInScheduler ¶
ParseNetworkTopologyKeyInScheduler parse network topology key in scheduler.
Types ¶
This section is empty.