MCPcopy
hub / github.com/grafana/dskit / Resolver

Struct Resolver

dns/miekgdns/resolver.go:51–60  ·  view source on GitHub ↗

Resolver is a DNS service discovery backend that retries on errors, only uses TCP, and pools connections to nameservers to increase reliability. This backend: * Does _not_ use search domains, all names are assumed to be fully qualified * Only uses TCP connections to the nameservers * Keeps several

Source from the content-addressed store, hash-verified

49// * `timeout` option
50// * `ndots` option
51type Resolver struct {
52 client Client
53 logger log.Logger
54 confPath string
55 reloadPeriod time.Duration
56 stop chan struct{}
57
58 mtx sync.RWMutex
59 conf *dns.ClientConfig
60}
61
62// NewResolver creates a new Resolver that uses the provided resolv.conf configuration
63// to perform DNS queries. Configuration from resolv.conf will be periodically reloaded.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected