Documentation ¶
Index ¶
- type Client
- func (p *Client) Close()
- func (p *Client) Delete(key string) error
- func (p *Client) Get(key string) (map[string]string, error)
- func (p *Client) GetKSort(key string) ([]string, []string, error)
- func (p *Client) GetWithPrefix(prefix string) (map[string]string, error)
- func (p *Client) LeasePutKeep(key, val string, ttl int64) (clientv3.LeaseID, <-chan *clientv3.LeaseKeepAliveResponse, error)
- func (p *Client) Put(key, val string) error
- func (p *Client) Watch(key string, handle func(ctx context.Context, tp string, key, val []byte))
- func (p *Client) WatchWithPrefix(prefix string, handle func(ctx context.Context, tp string, key, val []byte))
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) GetWithPrefix ¶
前缀获取数据
func (*Client) LeasePutKeep ¶
func (p *Client) LeasePutKeep(key, val string, ttl int64) (clientv3.LeaseID, <-chan *clientv3.LeaseKeepAliveResponse, error)
put租约key val
Click to show internal directories.
Click to hide internal directories.