zookeeper

package
v0.0.0-...-0d3b4e3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 21, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetChildConf

func GetChildConf(key string) (map[string]string, error)

func GetChildKey

func GetChildKey(key string) ([]string, error)

func GetConf

func GetConf(key string) (string, error)

func GetUnmarshalConf

func GetUnmarshalConf(key string, target any) error

func RegisterAfterConnected

func RegisterAfterConnected(handler func())

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewZookeeperClient

func NewZookeeperClient() (*Client, error)

func (*Client) ChildrenW

func (z *Client) ChildrenW(path string) ([]string, *zk.Stat, <-chan zk.Event, error)

func (*Client) Close

func (z *Client) Close()

func (*Client) Create

func (z *Client) Create(path string, data []byte, flag int32, acl []zk.ACL) (string, error)

func (*Client) Delete

func (z *Client) Delete(path string, version int32) error

func (*Client) Exists

func (z *Client) Exists(path string) (bool, *zk.Stat, error)

func (*Client) Get

func (z *Client) Get(path string) ([]byte, *zk.Stat, error)

func (*Client) GetW

func (z *Client) GetW(path string) ([]byte, *zk.Stat, <-chan zk.Event, error)

func (*Client) State

func (z *Client) State() zk.State

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL