Documentation ¶
Overview ¶
package resolver contains functions to handle resolving .mesos domains
Index ¶
- type Resolver
- func (res *Resolver) HandleMesos(w dns.ResponseWriter, r *dns.Msg)
- func (res *Resolver) HandleNonMesos(w dns.ResponseWriter, r *dns.Msg)
- func (res *Resolver) LaunchDNS() <-chan error
- func (res *Resolver) LaunchHTTP() <-chan error
- func (res *Resolver) LaunchZK(initialDetectionTimeout time.Duration) (<-chan struct{}, <-chan error)
- func (res *Resolver) Reload()
- func (res *Resolver) RestConfig(req *restful.Request, resp *restful.Response)
- func (res *Resolver) RestHost(req *restful.Request, resp *restful.Response)
- func (res *Resolver) RestPorts(req *restful.Request, resp *restful.Response)
- func (res *Resolver) RestService(req *restful.Request, resp *restful.Response)
- func (res *Resolver) RestVersion(req *restful.Request, resp *restful.Response)
- func (res *Resolver) Serve(net string) error
- func (res *Resolver) ZKdetect(leaderChanged func(bool)) (<-chan struct{}, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Resolver ¶
type Resolver struct {
// contains filtered or unexported fields
}
holds configuration state and the resource records
func (*Resolver) HandleMesos ¶
func (res *Resolver) HandleMesos(w dns.ResponseWriter, r *dns.Msg)
HandleMesos is a resolver request handler that responds to a resource question with resource answer(s) it can handle {A, SRV, ANY}
func (*Resolver) HandleNonMesos ¶
func (res *Resolver) HandleNonMesos(w dns.ResponseWriter, r *dns.Msg)
makes non-mesos queries to external nameserver
func (*Resolver) LaunchDNS ¶ added in v0.1.2
launches DNS server for a resolver, returns immediately
func (*Resolver) LaunchHTTP ¶ added in v0.1.2
starts an http server for mesos-dns queries, returns immediately
func (*Resolver) LaunchZK ¶ added in v0.1.2
func (res *Resolver) LaunchZK(initialDetectionTimeout time.Duration) (<-chan struct{}, <-chan error)
launches Zookeeper detector, returns immediately two chans: the first fires an empty struct whenever there's a new mesos leader, the second if there's an unrecoverable error in the master detector.
func (*Resolver) RestConfig ¶ added in v0.1.2
func (res *Resolver) RestConfig(req *restful.Request, resp *restful.Response)
Reports configuration through REST interface
func (*Resolver) RestHost ¶ added in v0.1.2
func (res *Resolver) RestHost(req *restful.Request, resp *restful.Response)
Reports Mesos-DNS version through http interface
func (*Resolver) RestPorts ¶ added in v0.1.2
func (res *Resolver) RestPorts(req *restful.Request, resp *restful.Response)
Reports Mesos-DNS version through http interface
func (*Resolver) RestService ¶ added in v0.1.2
func (res *Resolver) RestService(req *restful.Request, resp *restful.Response)
Reports Mesos-DNS version through http interface
func (*Resolver) RestVersion ¶ added in v0.1.2
func (res *Resolver) RestVersion(req *restful.Request, resp *restful.Response)
Reports Mesos-DNS version through REST interface