Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var JudgeActiveNode = NewNodeMap()
Functions ¶
func RebuildConsistentHashRing ¶
func RebuildConsistentHashRing(hashRing *ConsistentHashRing, nodes []string, replicas int)
func SyncCollects ¶
func SyncCollects()
Types ¶
type CollectCacheMap ¶
var CollectCache *CollectCacheMap
func NewCollectCache ¶
func NewCollectCache() *CollectCacheMap
type ConsistentHashRing ¶
var JudgeHashRing *ConsistentHashRing
func NewConsistentHashRing ¶
func NewConsistentHashRing(replicas int32, nodes []string) *ConsistentHashRing
func (*ConsistentHashRing) GetNode ¶
func (r *ConsistentHashRing) GetNode(pk string) (string, error)
func (*ConsistentHashRing) GetRing ¶
func (r *ConsistentHashRing) GetRing() *consistent.Consistent
func (*ConsistentHashRing) Set ¶
func (r *ConsistentHashRing) Set(ring *consistent.Consistent)
type NodeMap ¶
func NewNodeMap ¶
func NewNodeMap() NodeMap
type StraCacheMap ¶
var StraCache *StraCacheMap
func NewStraCache ¶
func NewStraCache() *StraCacheMap
func (*StraCacheMap) GetAll ¶
func (s *StraCacheMap) GetAll() []*model.Stra
Click to show internal directories.
Click to hide internal directories.