Documentation ¶
Index ¶
- Variables
- type Config
- type Discovery
- func (d *Discovery) Close() error
- func (d *Discovery) Deregister(_ context.Context, service *registry.ServiceInstance) error
- func (d *Discovery) GetService(ctx context.Context, serviceName string) ([]*registry.ServiceInstance, error)
- func (d *Discovery) Register(ctx context.Context, service *registry.ServiceInstance) (err error)
- func (d *Discovery) Watch(ctx context.Context, serviceName string) (registry.Watcher, error)
- type Resolve
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrDuplication = errors.New("register failed: instance duplicated: ") ErrServerError = errors.New("server error") )
Functions ¶
This section is empty.
Types ¶
type Discovery ¶
type Discovery struct {
// contains filtered or unexported fields
}
func New ¶
New construct a Discovery instance which implements registry.Registrar, registry.Discovery and registry.Watcher.
func (*Discovery) Deregister ¶
func (*Discovery) GetService ¶
Click to show internal directories.
Click to hide internal directories.