Documentation ¶
Index ¶
- type EtcdClient
- func (c *EtcdClient) Apply(d *KVPair) (*KVPair, error)
- func (c *EtcdClient) Create(d *KVPair) (*KVPair, error)
- func (c *EtcdClient) Delete(d *KVPair) error
- func (c *EtcdClient) Get(k Key) (*KVPair, error)
- func (c *EtcdClient) List(l ListInterface) ([]*KVPair, error)
- func (c *EtcdClient) Syncer(callbacks api.SyncerCallbacks) api.Syncer
- func (c *EtcdClient) Update(d *KVPair) (*KVPair, error)
- type EtcdConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EtcdClient ¶
type EtcdClient struct {
// contains filtered or unexported fields
}
func NewEtcdClient ¶
func NewEtcdClient(config *EtcdConfig) (*EtcdClient, error)
func (*EtcdClient) Apply ¶
func (c *EtcdClient) Apply(d *KVPair) (*KVPair, error)
Set an existing entry in the datastore. This ignores whether an entry already exists.
func (*EtcdClient) Create ¶
func (c *EtcdClient) Create(d *KVPair) (*KVPair, error)
Create an entry in the datastore. This errors if the entry already exists.
func (*EtcdClient) Delete ¶
func (c *EtcdClient) Delete(d *KVPair) error
Delete an entry in the datastore. This errors if the entry does not exists.
func (*EtcdClient) Get ¶
func (c *EtcdClient) Get(k Key) (*KVPair, error)
Get an entry from the datastore. This errors if the entry does not exist.
func (*EtcdClient) List ¶
func (c *EtcdClient) List(l ListInterface) ([]*KVPair, error)
List entries in the datastore. This may return an empty list of there are no entries matching the request in the ListInterface.
func (*EtcdClient) Syncer ¶
func (c *EtcdClient) Syncer(callbacks api.SyncerCallbacks) api.Syncer
func (*EtcdClient) Update ¶
func (c *EtcdClient) Update(d *KVPair) (*KVPair, error)
Update an existing entry in the datastore. This errors if the entry does not exist.
type EtcdConfig ¶
type EtcdConfig struct { EtcdScheme string `json:"etcdScheme" envconfig:"ETCD_SCHEME" default:"http"` EtcdAuthority string `json:"etcdAuthority" envconfig:"ETCD_AUTHORITY" default:"127.0.0.1:2379"` EtcdEndpoints string `json:"etcdEndpoints" envconfig:"ETCD_ENDPOINTS"` EtcdUsername string `json:"etcdUsername" envconfig:"ETCD_USERNAME"` EtcdPassword string `json:"etcdPassword" envconfig:"ETCD_PASSWORD"` EtcdKeyFile string `json:"etcdKeyFile" envconfig:"ETCD_KEY_FILE"` EtcdCertFile string `json:"etcdCertFile" envconfig:"ETCD_CERT_FILE"` EtcdCACertFile string `json:"etcdCACertFile" envconfig:"ETCD_CA_CERT_FILE"` }
Click to show internal directories.
Click to hide internal directories.