etcd

package
v1.0.7 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2021 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ETCD_TIMEOUT   = 5 * time.Second //etcd连接超时
	ETCD_GRANT_TTL = 6               //etcd jtimer to live
	InValidLeaseId = -1
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Etcd

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

func NewEtcd

func NewEtcd(endpoints, prefix string) *Etcd

func (*Etcd) IsStop

func (s *Etcd) IsStop() bool

func (*Etcd) RegistService

func (s *Etcd) RegistService(key, value string) error

注册kv

func (*Etcd) Start

初始化并启动etcd本地服务

func (*Etcd) Stop

func (s *Etcd) Stop()

Jump to

Keyboard shortcuts

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