discovering

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Discover

type Discover interface {
	Scheme() string
	Build(target resolver.Target, cc resolver.ClientConn, opts resolver.BuildOptions) (resolver.Resolver, error)
	Run() error
	Errors() <-chan error
	Messages() <-chan string
	Close()
}

type DiscoverRegistry

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

DiscoverRegistry can choose an appropriate Discover based on the provided, with name or service prefix key.

func NewDiscoverRegistry

func NewDiscoverRegistry() *DiscoverRegistry

NewDiscoverRegistry returns a new, initialized DiscoverRegistry.

func (*DiscoverRegistry) Close

func (r *DiscoverRegistry) Close()

Close all the discovers.

func (*DiscoverRegistry) CloseWithParam

func (r *DiscoverRegistry) CloseWithParam(name, scheme, service string)

CloseWithParam close all the running discovers with the specified name or the combine: scheme and service.

func (*DiscoverRegistry) Info

func (r *DiscoverRegistry) Info() string

Info return the basic info, service key.

func (*DiscoverRegistry) Register

func (r *DiscoverRegistry) Register(config *etcd.Config, client *clientV3.Client, etcdConfig *clientV3.Config) error

Register the Discover for the service.

func (*DiscoverRegistry) Run

func (r *DiscoverRegistry) Run() (errs []error)

Run the discovers have been registered.

func (*DiscoverRegistry) RunWithParam

func (r *DiscoverRegistry) RunWithParam(name, scheme, service string) (errs []error)

RunWithParam run discover has been registered and with the specified name or the combine: scheme and service.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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