dns

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MaxConcurrency    uint32 = 5
	RetryAfter               = 5 * time.Millisecond
	DeRefreshInterval        = 15 * time.Second
)

Variables

This section is empty.

Functions

This section is empty.

Types

type DNSResolver

type DNSResolver struct {
	DnsResolverChan chan []*clusterv3.Cluster

	sync.RWMutex
	// contains filtered or unexported fields
}

func NewDNSResolver

func NewDNSResolver(adsCache *ads.AdsCache) (*DNSResolver, error)

func (*DNSResolver) GetAllCachedDomains

func (r *DNSResolver) GetAllCachedDomains() []string

func (*DNSResolver) GetDNSAddresses

func (r *DNSResolver) GetDNSAddresses(domain string) []string

func (*DNSResolver) Query

func (r *DNSResolver) Query(req *dns.Msg) *dns.Msg

Query is copied and adapted from github.com/istio/istio/pilot/pkg/model/network.go.

func (*DNSResolver) StartDNSResolver

func (r *DNSResolver) StartDNSResolver(stopCh <-chan struct{})

Jump to

Keyboard shortcuts

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