class Consul::KV
- Consul::KV
- Consul::Transport
- Reference
- Object
Defined in:
consul/client/kv.crInstance Method Summary
-
#create_key(path : String, content : String)
create_key creates or updates an key.
-
#delete_key(path : String)
delete_key deletes a single key or all keys sharing a prefix
-
#get_key(path : String, recurse : Bool, keys : Bool) : Array(String)
overload get key - get all keys without value
-
#get_key(path : String, recurse : Bool) : Array(Consul::Types::KV::KvPair)
overload get_key, recurse option
-
#get_key(path : String) : Consul::Types::KV::KvPair
get_key returns the specified key.
Instance methods inherited from class Consul::Transport
client : HTTP::Client
client,
consistency : String
consistency,
delete(path : String) : HTTP::Client::Response
delete,
get(path : String) : HTTP::Client::Response
get,
get_consistency : String
get_consistency,
put(path : String, data : JSON::Any) : HTTP::Client::Responseput(path : String, data : String) : HTTP::Client::Response
put(path : String) : HTTP::Client::Response put
Constructor methods inherited from class Consul::Transport
new(client : HTTP::Client, consistency : String = "default")
new
Instance Method Detail
def create_key(path : String, content : String)
#
create_key creates or updates an key. The return value is either true or false, indicating whether the create/update succeeded
def get_key(path : String, recurse : Bool, keys : Bool) : Array(String)
#
overload get key - get all keys without value
def get_key(path : String, recurse : Bool) : Array(Consul::Types::KV::KvPair)
#
overload get_key, recurse option
def get_key(path : String) : Consul::Types::KV::KvPair
#
get_key returns the specified key. If no key exists at the given path, a 404 is returned instead of a 200 response