etcd

package
v0.0.0-...-281483f Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2020 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewResolver

func NewResolver(etcdAddr string) resolver.Builder

NewResolver initialize an etcd client

func Register

func Register(etcdAddr, name string, addr string, ttl int64) error

Register register service with name as prefix to etcd, multi etcd addr should use ; to split etcdAddr etcd地址 name 服务名称 addr 服务的地址 ttl 服务注册在etcd键的过期时间

func UnRegister

func UnRegister(name string, addr string)

UnRegister remove service from etcd

Types

This section is empty.

Jump to

Keyboard shortcuts

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