Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client struct { // raw client Client *clientv3.Client // interfaces rooted by namespace -- use these for all operations instead of the raw client KV clientv3.KV Watcher clientv3.Watcher Lease clientv3.Lease LeaseID clientv3.LeaseID }
Client is a wrapper around etcd client v3.
func ProvideClient ¶
ProvideClient creates a new Etcd Client and provides it via Fx.
type ClientIn ¶
type ClientIn struct { fx.In Unmarshaller config.Unmarshaller Lifecycle fx.Lifecycle Shutdowner fx.Shutdowner }
ClientIn holds parameters for ProvideClient.
type EtcdConfig ¶
type EtcdConfig struct { // Lease time-to-live LeaseTTL config.Duration `json:"lease_ttl" validate:"gte=1s" default:"60s"` // List of Etcd server endpoints Endpoints []string `json:"endpoints" validate:"dive,hostname_port|url|fqdn"` }
EtcdConfig holds configuration for etcd client. swagger:model
Click to show internal directories.
Click to hide internal directories.