Documentation
¶
Index ¶
- Variables
- type Discovery
- func (d *Discovery) Close() error
- func (d *Discovery) GetInstances(ctx context.Context, options provider.GetInstanceOptions) ([]provider.Instancer, error)
- func (d *Discovery) Lookup(ctx context.Context, host string) ([]string, error)
- func (d *Discovery) Watch(ctx context.Context, _ provider.GetInstanceOptions) (<-chan []provider.Instancer, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNotFound = errors.New("no records found")
ErrNotFound is returned when no DNS records are found for a host.
Functions ¶
This section is empty.
Types ¶
type Discovery ¶ added in v0.10.0
type Discovery struct {
// contains filtered or unexported fields
}
Discovery implements service discovery using DNS.
func NewDNSServiceDiscovery ¶
NewDNSServiceDiscovery creates a new DNSServiceDiscovery instance.
func (*Discovery) GetInstances ¶ added in v0.10.0
func (d *Discovery) GetInstances( ctx context.Context, options provider.GetInstanceOptions, ) ([]provider.Instancer, error)
GetInstances resolves the given host to IP addresses and returns them as service instances.
Click to show internal directories.
Click to hide internal directories.