Documentation
¶
Index ¶
- type Config
- type Server
- type TopoUpdate
- type Topology
- func (top *Topology) Close(proxyName string)
- func (top *Topology) CreateProxyFenceNode(pi *models.ProxyInfo) (string, error)
- func (top *Topology) CreateProxyInfo(pi *models.ProxyInfo) (string, error)
- func (top *Topology) DoResponse(seq int, pi *models.ProxyInfo) error
- func (top *Topology) Exist(path string) (bool, error)
- func (top *Topology) GetActionResponsePath(seq int) string
- func (top *Topology) GetActionSeqList(productName string) ([]int, error)
- func (top *Topology) GetActionWithSeq(seq int64) (*models.Action, error)
- func (top *Topology) GetActionWithSeqObject(seq int64, act *models.Action) error
- func (top *Topology) GetGroup(groupId int) (*models.ServerGroup, error)
- func (top *Topology) GetProxyInfo(proxyName string) (*models.ProxyInfo, error)
- func (top *Topology) GetSlotByIndex(i int) (*models.Slot, *models.ServerGroup, error)
- func (top *Topology) InitZkConn()
- func (top *Topology) IsChildrenChangedEvent(e interface{}) bool
- func (top *Topology) SetProxyStatus(proxyName string, status string) error
- func (top *Topology) WatchChildren(path string, evtbus chan interface{}) ([]string, error)
- func (top *Topology) WatchNode(path string, evtbus chan interface{}) ([]byte, error)
- type ZkFactory
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TopoUpdate ¶
这个接口用途是?
type Topology ¶
type Topology struct { ProductName string // contains filtered or unexported fields }
func (*Topology) CreateProxyFenceNode ¶
func (*Topology) CreateProxyInfo ¶
func (*Topology) GetActionResponsePath ¶
func (*Topology) GetActionSeqList ¶
func (*Topology) GetActionWithSeq ¶
func (*Topology) GetActionWithSeqObject ¶
func (*Topology) GetGroup ¶
func (top *Topology) GetGroup(groupId int) (*models.ServerGroup, error)
zk path:
fmt.Sprintf("/zk/codis/db_%s/servers/group_%d", productName, groupId) 这个信息是由用户更新进去,然后codis对实例进行设置
func (*Topology) GetProxyInfo ¶
func (*Topology) GetSlotByIndex ¶
zk path:
fmt.Sprintf("/zk/codis/db_%s/slots/slot_%d", productName, slotId)
这个接口确保了slot-id & group-id 都是有效的
func (*Topology) InitZkConn ¶
func (top *Topology) InitZkConn()
func (*Topology) IsChildrenChangedEvent ¶
func (*Topology) SetProxyStatus ¶
func (*Topology) WatchChildren ¶
Click to show internal directories.
Click to hide internal directories.