etcdCached

package
v0.0.0-...-172d49c Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2019 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const ErrorCodeKeyNotFound = "key not found"

Variables

This section is empty.

Functions

func LoopNodes

func LoopNodes(kv []*mvccpb.KeyValue) (sx []dnsServer.ServiceRecord, err error)

Types

type Backend

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

func NewBackend

func NewBackend(clientv3 etcdv3.Client, ctx context.Context, timeOut int, ttl uint32, priority uint16) *Backend

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

func (*Backend) Get

func (g *Backend) Get(name string) ([]dnsServer.ServiceRecord, int64, error)

func (*Backend) GetRaw

func (g *Backend) GetRaw(path string) (*etcdv3.GetResponse, error)

func (*Backend) Records

func (g *Backend) Records(name string) ([]dnsServer.ServiceRecord, error)

func (*Backend) ReverseRecord

func (g *Backend) ReverseRecord(name string) (*dnsServer.ServiceRecord, error)

Jump to

Keyboard shortcuts

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