v2

package
v0.2.0-dev1 Latest Latest
Warning

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

Go to latest
Published: Jun 15, 2017 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bind

type Bind struct {
	Statistics Statistics `xml:"statistics"`
}

type Client

type Client struct {
	*bind.XMLClient
}

Client implements bind.Client and can be used to query a BIND v2 API.

func NewClient

func NewClient(url string, c *http.Client) *Client

NewClient returns an initialized Client.

func (*Client) Stats

func (c *Client) Stats(...bind.StatisticGroup) (bind.Statistics, error)

Stats implements bind.Stats. The BIND v2 API doesn't provide individual endpoints for different statistic groups, the passed parameters don't have any effect.

type Counter

type Counter struct {
	Name    string `xml:"name"`
	Counter uint   `xml:"counter"`
}

type Isc

type Isc struct {
	Bind    Bind     `xml:"bind"`
	XMLName xml.Name `xml:"isc"`
}

type Server

type Server struct {
	BootTime    time.Time `xml:"boot-time"`
	ConfigTime  time.Time `xml:"config-time"`
	NSStats     []Counter `xml:"nsstat"`
	QueriesIn   []Counter `xml:"queries-in>rdtype"`
	Requests    []Counter `xml:"requests>opcode"`
	SocketStats []Counter `xml:"socketstat"`
	ZoneStats   []Counter `xml:"zonestat"`
}

type Statistics

type Statistics struct {
	Memory    struct{}         `xml:"memory"`
	Server    Server           `xml:"server"`
	Socketmgr struct{}         `xml:"socketmgr"`
	Taskmgr   bind.TaskManager `xml:"taskmgr"`
	Views     []View           `xml:"views>view"`
}

type View

type View struct {
	Name    string       `xml:"name"`
	Cache   []bind.Gauge `xml:"cache>rrset"`
	Rdtype  []Counter    `xml:"rdtype"`
	Resstat []Counter    `xml:"resstat"`
	Zones   []Counter    `xml:"zones>zone"`
}

type Zone

type Zone struct {
	Name       string `xml:"name"`
	Rdataclass string `xml:"rdataclass"`
	Serial     string `xml:"serial"`
}

Jump to

Keyboard shortcuts

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