MCPcopy Create free account
hub / github.com/OpenArkStudio/ARK / DelKeyValue

Method DelKeyValue

src/plugin/consul/src/AFCConsulModule.cpp:74–86  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

72}
73
74ananas::Future<std::pair<bool, std::string>> AFCConsulModule::DelKeyValue(const std::string& key)
75{
76 ananas::Promise<std::pair<bool, std::string>> promise;
77 if (key.empty())
78 {
79 promise.SetValue(std::make_pair(false, std::string()));
80 return promise.GetFuture();
81 }
82
83 std::string url = KV_API + key;
84 return m_pHttpClientModule->AsyncRequest(
85 brynet::net::http::HttpRequest::HTTP_METHOD::HTTP_METHOD_DELETE, consul_ip_, consul_port_, url);
86}
87
88ananas::Future<std::pair<bool, std::string>> AFCConsulModule::GetHealthServices(
89 const std::string& service_name, const std::string& tag_filter)

Callers

nothing calls this directly

Calls 4

GetFutureMethod · 0.80
emptyMethod · 0.45
SetValueMethod · 0.45
AsyncRequestMethod · 0.45

Tested by

no test coverage detected