etcd

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2016 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package etcd provides the default SkyDNS server Backend implementation, which looks up records stored under the `/skydns` key in etcd when queried.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Backend

type Backend struct {
	// contains filtered or unexported fields
}

func NewBackend

func NewBackend(client *etcd.Client, config *Config) *Backend

NewBackend returns a new Backend for SkyDNS, backed by etcd.

func (*Backend) Client

func (g *Backend) Client() *etcd.Client

Client exposes the underlying Etcd client.

func (*Backend) Records

func (g *Backend) Records(name string, exact bool) ([]msg.Service, error)

func (*Backend) ReverseRecord

func (g *Backend) ReverseRecord(name string) (*msg.Service, error)

func (*Backend) UpdateClient

func (g *Backend) UpdateClient(client *etcd.Client)

UpdateClient allows the etcd client used by this backend to be replaced on the fly.

type Config

type Config struct {
	Ttl      uint32
	Priority uint16
}

Config represents configuration for the Etcd backend - these values should be taken directly from server.Config

Jump to

Keyboard shortcuts

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