etcd

package
v1.0.138 Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2026 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithCA

func WithCA(caCertPEM []byte, caKeyPEM []byte) optFun

WithCA allows overriding the CA PEM

func WithContext

func WithContext(ctx context.Context) optFun

WithContext allows overriding the default context (which is nil)

func WithEndpoints

func WithEndpoints(endpoints []string) optFun

WithEndpoints allows overriding the default etcd endpoints

func WithLogger

func WithLogger(logger logger.Logger) optFun

WithLogger allows overriding the default logger (which is nil)

func WithPrefix

func WithPrefix(prefix string) optFun

WithPrefix allows overriding the default prefix (which is empty)

func WithURL

func WithURL(url string) optFun

WithURL will override the default etcd endpoints with a single URL if provided (can be empty which means no override)

Types

type Client

type Client struct {
	*clientv3.Client
}

Client is a simple wrapper around the etcd client

func New

func New(opts ...optFun) (*Client, error)

New creates a new EtcdClient instance with the provided options

Jump to

Keyboard shortcuts

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