Documentation ¶
Overview ¶
Package endpoint provides the type Endpoint, to be used with the targets.Targets interface.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NamesFromEndpoints ¶ added in v0.11.4
NamesFromEndpoints is convenience function to build a list of names from endpoints.
Types ¶
type Endpoint ¶
type Endpoint struct { Name string Labels map[string]string LastUpdated time.Time Port int IP net.IP }
Endpoint represents a targets and associated parameters.
func EndpointsFromNames ¶
EndpointsFromNames is convenience function to build a list of endpoints from only names. It leaves the Port field in Endpoint unset and initializes Labels field to an empty map.
func FromProtoMessage ¶ added in v0.13.1
func FromProtoMessage(endpointspb []*endpointpb.Endpoint) ([]Endpoint, error)
type KeyOption ¶ added in v0.13.7
type KeyOption func(*keyOptions) *keyOptions
func WithIgnoreLabels ¶ added in v0.13.7
WithIgnoreLabels specifies a list of labels that should not be included in the key computation.
type Lister ¶ added in v0.11.4
type Lister interface { // ListEndpoints returns list of endpoints (name, port tupples). ListEndpoints() []Endpoint }
Lister should implement the ListEndpoints method.
type ResolverOption ¶ added in v0.13.1
type ResolverOption func(*resolverOptions)
func WithNameOverride ¶ added in v0.13.1
func WithNameOverride(nameOverride string) ResolverOption
Click to show internal directories.
Click to hide internal directories.