etcd

package
v1.4.4 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2022 License: MIT Imports: 4 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// etcd endpoints
	Endpoints []string

	// timeout
	DialTimeout time.Duration

	// prefix request option
	Prefix bool

	// limit request option
	Limit bool

	// number of limited pairs
	NLimit int64

	// key, key with prefix, etc.
	Key string
}

type Etcd

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

Etcd implements the etcd config provider.

func Provider

func Provider(cfg Config) *Etcd

Provider returns a provider that takes etcd config.

func (*Etcd) Read

func (e *Etcd) Read() (map[string]interface{}, error)

Read returns a nested config map.

func (*Etcd) ReadBytes

func (e *Etcd) ReadBytes() ([]byte, error)

ReadBytes is not supported by etcd provider.

Directories

Path Synopsis
module

Jump to

Keyboard shortcuts

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