registry

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: May 7, 2018 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	//HTTP is protocol prefix constant
	HTTP = "http://"
)

Variables

This section is empty.

Functions

func Deregister

func Deregister(discovery ServiceDiscovery) error

Deregister de-registers instance giving several tries

func Register

func Register(discovery ServiceDiscovery)

Register registers instance giving several tries

Types

type ServiceDiscovery

type ServiceDiscovery interface {
	Register() error
	Deregister() error
	DoWithClient(func(client interface{}) (interface{}, error)) (interface{}, error)
}

ServiceDiscovery provides methods to interact with registry (service discovery) service

func NewConsul

func NewConsul(cfg *conf.RpConfig) ServiceDiscovery

NewConsul creates new instance of Consul implementation of ServiceDiscovery based on provided config

Jump to

Keyboard shortcuts

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