etcdv3

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2021 License: MIT Imports: 14 Imported by: 0

Documentation

Overview

Package etcdv3 provides an etcd version 3 registry

Index

Constants

This section is empty.

Variables

View Source
var (
	Name = "etcdv3"
)

Functions

func NewRegistry

func NewRegistry() registry.Registry

Types

type Cfg added in v0.0.3

type Cfg struct {
	Prefix   string   `json:"prefix"`
	Driver   string   `json:"driver"`
	Projects []string `json:"projects"`
}

type Registry

type Registry struct {
	sync.Mutex
	// contains filtered or unexported fields
}

func (*Registry) Deregister

func (e *Registry) Deregister(s *registry.Service, opts ...registry.DeRegOpt) error

func (*Registry) GetService

func (e *Registry) GetService(name string, opts ...registry.GetOpt) ([]*registry.Service, error)

func (*Registry) ListServices

func (e *Registry) ListServices(opts ...registry.ListOpt) ([]*registry.Service, error)

func (*Registry) Register

func (e *Registry) Register(s *registry.Service, opts ...registry.RegOpt) error

func (*Registry) String

func (e *Registry) String() string

func (*Registry) Watch

func (e *Registry) Watch(service string, opts ...registry.WatchOpt) (registry.Watcher, error)

type Watcher

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

func (*Watcher) Next

func (w *Watcher) Next() (*registry.Result, error)

func (*Watcher) Stop

func (w *Watcher) Stop()

Jump to

Keyboard shortcuts

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