client

package
v0.0.0-...-3a63d34 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2018 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	*clientv3.Client
}

func NewClient

func NewClient(dsn string) (*Client, error)

func (*Client) Delete

func (ec *Client) Delete(key string) error

func (*Client) DeleteWithPrefix

func (ec *Client) DeleteWithPrefix(key string) error

func (*Client) Get

func (ec *Client) Get(key string) (string, error)

func (*Client) GetWithPrefix

func (ec *Client) GetWithPrefix(key string) (map[string]string, error)

func (*Client) Put

func (ec *Client) Put(key, val string) error

type Config

type Config struct {
	Addrs    string
	Username string
	Password string
	Path     string
}

func ParseDSN

func ParseDSN(dsn string) *Config

username:password@addr1,addr2/path

Jump to

Keyboard shortcuts

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