Creates a new etcd client.
array of etcd hosts to use
Note: currently only the first server is used, this will be fixed before version 1
additional options, see defaults for actual defaults
KeepAliveToken's created by this client
closes the network connection and stops all keep alives started with this client.
delete a key from etcd.
key to start from (inclusive)
key to end on (exclusive)
number of keys deleted
blocking version of delete()
get the value of a key from etcd
key to get
value
(default) - return the as a string
json
- parse as JSON and return the resultbuffer
- return a NodeJS Bufferraw
- return the value as it came from etcdvalue of the key as defined by returnType
get the value of a key from etcd
key to get
value
(default) - return the as a string
json
- parse as JSON and return the resultbuffer
- return a NodeJS Bufferraw
- return the value as it came from etcdvalue of the key as defined by returnType
get the value of a key from etcd
key to get
value
(default) - return the as a string
json
- parse as JSON and return the resultbuffer
- return a NodeJS Bufferraw
- return the value as it came from etcdvalue of the key as defined by returnType
get the value of a key from etcd
key to get
value
(default) - return the as a string
json
- parse as JSON and return the resultbuffer
- return a NodeJS Bufferraw
- return the value as it came from etcdvalue of the key as defined by returnType
get the managed client lease. If it isn't created yet, it will be created. The Client lease will be kept alive automatic.
lease ID
blocking version of get()
blocking version of get()
blocking version of get()
blocking version of get()
request a new lease from etcd
requested TTL of the lease
blocking version of leaseGrant()
keep a lease alive
lease to keep alive
interval in which to send keep alives
KeepAliveToken
that was created
get a range of key from etcd
key to start from (inclusive)
key to end on (exclusive)
value
(default) - return the as a string
json
- parse as JSON and return the resultbuffer
- return a NodeJS Bufferraw
- return the value as it came from etcdobject with a key for each key returned, value of the key as defined by returnType
blocking version of range()
set a key/value to etcd.
Buffer
is saved as-isnull
is saved as an empty stringundefined
is saved as an empty stringJSON.stringify(value)
if you set "lease" to "client" a lease uniq to the instance of the Client will be used. This lease will be created automatic and will be kept alive automatic.
etcd key to set
content to set
lease ID to use, or client
to the client lease
lease ID used if any was used, else null
blocking version of set()
Generated using TypeDoc
etcd client using the grpc protocol of etcd version 3 and later.