2
0
mirror of https://gitlab.isc.org/isc-projects/kea synced 2025-08-30 13:37:55 +00:00

[#3446] updated documentation

This commit is contained in:
Razvan Becheriu
2024-07-10 23:40:51 +03:00
parent 8a25cf329d
commit f1672edf2c
5 changed files with 23 additions and 18 deletions

View File

@@ -799,7 +799,7 @@ ControlledDhcpv4Srv::commandStatusGetHandler(const string&,
}
status->set("sockets", sockets);
status->set("dhcp-state": network_state_->toElement());
status->set("dhcp-state", network_state_->toElement());
return (createAnswer(CONTROL_RESULT_SUCCESS, status));
}

View File

@@ -804,7 +804,7 @@ ControlledDhcpv6Srv::commandStatusGetHandler(const string&,
}
status->set("sockets", sockets);
status->set("dhcp-state": network_state_->toElement());
status->set("dhcp-state", network_state_->toElement());
return (createAnswer(CONTROL_RESULT_SUCCESS, status));
}

View File

@@ -184,18 +184,16 @@ public:
result->set("disabled-by-db-connection", Element::create(disabled_by_db_connection_ != 0));
bool disabled_by_user = false;
ElementPtr local_origin = Element::createList();
uint16_t local_count = 0;
ElementPtr remote_origin = Element::createList();
uint16_t remote_count = 0;
for (auto const& origin : disabled_by_origin_) {
if (origin == NetworkState::USER_COMMAND) {
disabled_by_user = true;
}
if (origin >= NetworkState::HA_LOCAL_COMMAND && origin < NetworkState::HA_REMOTE_COMMAND) {
local_origin->set(local_count++, Element::create(origin - NetworkState::HA_LOCAL_COMMAND));
local_origin->add(Element::create(origin - NetworkState::HA_LOCAL_COMMAND));
}
if (origin >= NetworkState::HA_REMOTE_COMMAND && origin < NetworkState::DB_CONNECTION) {
remote_origin->set(remote_count++, Element::create(origin - NetworkState::HA_REMOTE_COMMAND));
remote_origin->add(Element::create(origin - NetworkState::HA_REMOTE_COMMAND));
}
}
result->set("disabled-by-user", Element::create(disabled_by_user));

View File

@@ -38,15 +38,15 @@
" \"occurrences\": 501,",
" \"start-time\": \"2024-06-12 17:52:06.814884\",",
" \"total-duration-usecs\": 23951",
" }",
" ..",
" ]",
" },",
" ...",
" ],",
" \"result-set-format\": false,",
" \"interval-width-secs\": 5,",
" \"timestamp\": \"2024-06-12 17:52:22.397233\"",
" }",
"\"result\": 0,",
"\"text\": \"perfmon-get-all-durations: n found\"",
" },",
" \"result\": 0,",
" \"text\": \"perfmon-get-all-durations: n found\"",
"}",
"If result-set-format is true, the output will be as shown below:",
"{",
@@ -62,7 +62,7 @@
" \"occurences\",",
" \"min-duration-usecs\",",
" \"max-duration-usecs\",",
" \"total-duration-usecs\"",
" \"total-duration-usecs\",",
" \"mean-duration-usecs\"",
" ],",
" \"rows\": [",
@@ -79,15 +79,15 @@
" 23951,",
" 47",
" ],",
" ..",
" ...",
" ]",
" }",
" },",
" \"result-set-format\": true,",
" \"interval-width-secs\": 5,",
" \"timestamp\": \"2024-06-12 17:52:22.397233\"",
" }",
"\"result\": 0,",
"\"text\": \"perfmon-get-all-durations: n found\"",
" },",
" \"result\": 0,",
" \"text\": \"perfmon-get-all-durations: n found\"",
"}"
],
"support": [

View File

@@ -48,6 +48,13 @@
" \"sockets\": {",
" \"errors\": [ <error received during the last attempt to open all sockets> ],",
" \"status\": <ready, retrying, or failed>",
" },",
" \"dhcp-state\": {",
" \"disabled-by-db-connection\": false,",
" \"disabled-by-local-command\": [],",
" \"disabled-by-remote-command\": [],",
" \"disabled-by-user\": false,",
" \"globally-disabled\": false",
" }",
" }",
"}"