discovery

package
v0.0.0-...-ba27772 Latest Latest
Warning

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

Go to latest
Published: Jul 18, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Discoverable

type Discoverable interface {
	Start() error
	Stop() error
}

Discoverable is an interface to make oneself discoverable (by type). For environments where discoverability is implicit, this is unnecessary.

type Discoverer

type Discoverer interface {
	Discover(svcName string, add, remove func(api.Remote)) Getter
}

Discoverer is an interface to find other services by type (e.g. node).

type Getter

type Getter interface {

	// Get returns all of the currently known remotes.
	// TODO: Support some kind of filters here, like region and AZ.
	// TODO: Update callers to use add/remove callbacks and remove this method.
	Get() ([]api.Remote, error)

	// Stop terminates this getter. It should not call the remove callback for
	// any known remotes. Get will return no results after this is called.
	Stop() error
}

Getter is returned by Discoverer.Discover.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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