Versions in this module Expand all Collapse all v1 v1.0.0 Mar 24, 2023 Changes in this version + const EPHEMERAL + const EPHEMERAL_SEQUENTIAL + const PERSISTENT + const PERSISTENT_SEQUENTIAL + var EventChildrenNodeChangeNames = map[EventChildrenNodeChangeType]string + var EventCurrntNodeChangeNames = map[EventCurrentNodeChangeType]string + type ChildrenChange struct + OperateType EventChildrenNodeChangeType + Path string + type Event struct + Data string + Err error + Path string + Server string + State zk.State + Type EventType + type EventChildrenNodeChangeType int32 + const EventChildrenNodeDelete + const EventChildrenNodeIncrease + func (e EventChildrenNodeChangeType) String() string + type EventCurrentNodeChangeType int32 + const EventNodeDataChange + const EventNodeDelete + func (t EventCurrentNodeChangeType) String() string + type EventType int32 + const EventRecoverEphemeralNodeFail + const EventRecoverEphemeralNodeSuccess + const EventSession + const Unknown + type NodeChange struct + NewData string + OldData string + OperateType EventCurrentNodeChangeType + Path string + type NodeDetail struct + Acl []zk.ACL + Data string + type Option struct + Addr []string + Name string + SessionTimeout time.Duration + type WatchChildrenResponse struct + ChildrenChangeInfo []*ChildrenChange + Err error + type WatchNodeResponse struct + Err error + NodeChangeInfo *NodeChange + type ZookeeperProxy struct + Conn *zk.Conn + Opt *Option + func New(opt *Option) (*ZookeeperProxy, error) + func (z *ZookeeperProxy) Close() error + func (z *ZookeeperProxy) CreateNode(path string, flag int32, data string) (string, error) + func (z *ZookeeperProxy) CreateNodeParent(path string, flags int32, data string) (string, error) + func (z *ZookeeperProxy) CreateNodeWithAcls(path string, flag int32, acls []zk.ACL, data string) (string, error) + func (z *ZookeeperProxy) Delete(path string) error + func (z *ZookeeperProxy) Exist(path string) (bool, error) + func (z *ZookeeperProxy) GetChildren(path string) ([]string, error) + func (z *ZookeeperProxy) GetConnState() string + func (z *ZookeeperProxy) GetData(path string) (string, error) + func (z *ZookeeperProxy) GetSessionId() int64 + func (z *ZookeeperProxy) SetData(path string, s string) error + func (z *ZookeeperProxy) StartLi() (<-chan Event, error) + func (z *ZookeeperProxy) WatchChildren(path string, listener func(respChan <-chan *WatchChildrenResponse)) + func (z *ZookeeperProxy) WatchNode(path string, listener func(respChan <-chan *WatchNodeResponse)) Other modules containing this package github.com/NetEase-Media/easy-ngo