parent
7bced74f51
commit
ee3999303d
4 changed files with 5 additions and 5 deletions
|
@ -287,7 +287,7 @@ func (h *dnsContext) validateZonesAndListeningAddresses() error {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// groupSiteConfigsByListenAddr groups site configs by their listen
|
// groupConfigsByListenAddr groups site configs by their listen
|
||||||
// (bind) address, so sites that use the same listener can be served
|
// (bind) address, so sites that use the same listener can be served
|
||||||
// on the same server instance. The return value maps the listen
|
// on the same server instance. The return value maps the listen
|
||||||
// address (what you pass into net.Listen) to the list of site configs.
|
// address (what you pass into net.Listen) to the list of site configs.
|
||||||
|
|
|
@ -2,7 +2,7 @@ package file
|
||||||
|
|
||||||
import "github.com/miekg/dns"
|
import "github.com/miekg/dns"
|
||||||
|
|
||||||
// replaceWithWildcard replaces the left most label with '*'.
|
// replaceWithAsteriskLabel replaces the left most label with '*'.
|
||||||
func replaceWithAsteriskLabel(qname string) (wildcard string) {
|
func replaceWithAsteriskLabel(qname string) (wildcard string) {
|
||||||
i, shot := dns.NextLabel(qname, 0)
|
i, shot := dns.NextLabel(qname, 0)
|
||||||
if shot {
|
if shot {
|
||||||
|
|
|
@ -605,7 +605,7 @@ func (dns *dnsControl) detectChanges(oldObj, newObj interface{}) {
|
||||||
dns.updateModified()
|
dns.updateModified()
|
||||||
}
|
}
|
||||||
if emod {
|
if emod {
|
||||||
dns.updateExtModifed()
|
dns.updateExtModified()
|
||||||
}
|
}
|
||||||
case *object.Pod:
|
case *object.Pod:
|
||||||
dns.updateModified()
|
dns.updateModified()
|
||||||
|
@ -749,7 +749,7 @@ func (dns *dnsControl) updateModified() {
|
||||||
}
|
}
|
||||||
|
|
||||||
// updateExtModified set dns.extModified to the current time.
|
// updateExtModified set dns.extModified to the current time.
|
||||||
func (dns *dnsControl) updateExtModifed() {
|
func (dns *dnsControl) updateExtModified() {
|
||||||
unix := time.Now().Unix()
|
unix := time.Now().Unix()
|
||||||
atomic.StoreInt64(&dns.extModified, unix)
|
atomic.StoreInt64(&dns.extModified, unix)
|
||||||
}
|
}
|
||||||
|
|
|
@ -42,7 +42,7 @@ func newTransport(addr string) *Transport {
|
||||||
return t
|
return t
|
||||||
}
|
}
|
||||||
|
|
||||||
// connManagers manages the persistent connection cache for UDP and TCP.
|
// connManager manages the persistent connection cache for UDP and TCP.
|
||||||
func (t *Transport) connManager() {
|
func (t *Transport) connManager() {
|
||||||
ticker := time.NewTicker(defaultExpire)
|
ticker := time.NewTicker(defaultExpire)
|
||||||
defer ticker.Stop()
|
defer ticker.Stop()
|
||||||
|
|
Loading…
Add table
Reference in a new issue