Kea 2.7.6
|
This file contains several functions and constants that are used for handling commands and responses sent over control channel. More...
Go to the source code of this file.
Classes | |
class | isc::config::CtrlChannelError |
A standard control channel exception that is thrown if a function is there is a problem with one of the messages. More... | |
Namespaces | |
namespace | isc |
Defines the logger used by the top-level component of kea-lfc. | |
namespace | isc::config |
Functions | |
std::string | isc::config::answerToText (const isc::data::ConstElementPtr &msg) |
Converts answer to printable text. | |
ConstElementPtr | isc::config::combineCommandsLists (const isc::data::ConstElementPtr &response1, const isc::data::ConstElementPtr &response2) |
Combines lists of commands carried in two responses. | |
ConstElementPtr | isc::config::createAnswer () |
Creates a standard config/command level success answer message (i.e. | |
ConstElementPtr | isc::config::createAnswer (const int status_code, const isc::data::ConstElementPtr &arg) |
Creates a standard config/command level answer message (i.e. | |
ConstElementPtr | isc::config::createAnswer (const int status_code, const std::string &status, const isc::data::ConstElementPtr &arg) |
Creates a standard config/command level answer message. | |
ConstElementPtr | isc::config::createAnswer (const int status_code, const std::string &status_text) |
Creates a standard config/command level answer message (i.e. | |
ConstElementPtr | isc::config::createCommand (const std::string &command) |
Creates a standard command message with no argument (of the form { "command": "my_command" }) | |
ConstElementPtr | isc::config::createCommand (const std::string &command, const std::string &service) |
Creates a standard config/command command message with no argument and with the given service (of the form { "command": "my_command", "service": [ service ] }) | |
ConstElementPtr | isc::config::createCommand (const std::string &command, isc::data::ConstElementPtr arg) |
Creates a standard command message with the given argument (of the form { "command": "my_command", "arguments": arg }. | |
ConstElementPtr | isc::config::createCommand (const std::string &command, isc::data::ConstElementPtr arg, const std::string &service) |
Creates a standard config/command command message with the given argument and given service (of the form { "command": "my_command", "arguments": arg, "service": [ service ] }. | |
ConstElementPtr | isc::config::parseAnswer (int &status_code, const isc::data::ConstElementPtr &msg) |
Parses a standard config/command level answer and returns arguments or text status code. | |
ConstElementPtr | isc::config::parseAnswerText (int &rcode, const isc::data::ConstElementPtr &msg) |
Parses a standard config/command level answer and returns text status. | |
std::string | isc::config::parseCommand (isc::data::ConstElementPtr &arg, isc::data::ConstElementPtr command) |
Parses the given command into a string containing the actual command and an ElementPtr containing the optional argument. | |
std::string | isc::config::parseCommandWithArgs (isc::data::ConstElementPtr &arg, isc::data::ConstElementPtr command) |
Parses the given command into a string containing the command name and an ElementPtr containing the mandatory argument. | |
Variables | |
const int | isc::config::CONTROL_RESULT_COMMAND_UNSUPPORTED = 2 |
Status code indicating that the specified command is not supported. | |
const int | isc::config::CONTROL_RESULT_CONFLICT = 4 |
Status code indicating that the command was unsuccessful due to a conflict between the command arguments and the server state. | |
const int | isc::config::CONTROL_RESULT_EMPTY = 3 |
Status code indicating that the specified command was completed correctly, but failed to produce any results. | |
const int | isc::config::CONTROL_RESULT_ERROR = 1 |
Status code indicating a general failure. | |
const int | isc::config::CONTROL_RESULT_SUCCESS = 0 |
Status code indicating a successful operation. | |
This file contains several functions and constants that are used for handling commands and responses sent over control channel.
The design is described here: https://gitlab.isc.org/isc-projects/kea/wikis/Stats-design, but also in Control Channel section in the Developer's Guide.
Definition in file command_interpreter.h.