Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Publisher ¶
type Publisher struct {
// contains filtered or unexported fields
}
Publisher yields endpoints taken from the named DNS SRV record. The name is resolved on a fixed schedule. Priorities and weights are ignored.
func NewPublisher ¶
func NewPublisher(name string, ttl time.Duration, f loadbalancer.Factory, logger log.Logger) (*Publisher, error)
NewPublisher returns a DNS SRV publisher. The name is resolved synchronously as part of construction; if that resolution fails, the constructor will return an error. The factory is used to convert a host:port to a usable endpoint. The logger is used to report DNS and factory errors.
Click to show internal directories.
Click to hide internal directories.