Kea
1.9.9-git
|
Ctrl Netconf Configuration Manager. More...
#include <netconf_cfg_mgr.h>
Public Member Functions | |
NetconfCfgMgr () | |
Constructor. More... | |
virtual | ~NetconfCfgMgr () |
Destructor. More... | |
virtual std::string | getConfigSummary (const uint32_t selection) |
Returns configuration summary in the textual format. More... | |
NetconfConfigPtr | getNetconfConfig () |
Convenience method that returns the Netconf configuration context. More... | |
std::list< std::list< std::string > > | jsonPathsToRedact () const |
Return a list of all paths that contain passwords or secrets for kea-netconf. More... | |
Public Member Functions inherited from isc::process::DCfgMgrBase | |
DCfgMgrBase (ConfigPtr context) | |
Constructor. More... | |
virtual | ~DCfgMgrBase () |
Destructor. More... | |
ConfigPtr & | getContext () |
Fetches the configuration context. More... | |
isc::data::ConstElementPtr | redactConfig (isc::data::ConstElementPtr const &config) const |
Redact the configuration. More... | |
isc::data::ConstElementPtr | simpleParseConfig (isc::data::ConstElementPtr config, bool check_only=false, const std::function< void()> &post_config_cb=nullptr) |
Acts as the receiver of new configurations. More... | |
Protected Member Functions | |
virtual process::ConfigPtr | createNewContext () |
Creates a new, blank NetconfConfig context. More... | |
virtual isc::data::ConstElementPtr | parse (isc::data::ConstElementPtr config, bool check_only) |
Parses configuration of Netconf. More... | |
Protected Member Functions inherited from isc::process::DCfgMgrBase | |
void | resetContext () |
Replaces existing context with a new, empty context. More... | |
virtual void | setCfgDefaults (isc::data::ElementPtr mutable_config) |
Adds default values to the given config. More... | |
void | setContext (ConfigPtr &context) |
Update the current context. More... | |
Ctrl Netconf Configuration Manager.
Provides the mechanisms for managing the Netconf application's configuration.
Definition at line 124 of file netconf_cfg_mgr.h.
isc::netconf::NetconfCfgMgr::NetconfCfgMgr | ( | ) |
Constructor.
Definition at line 49 of file netconf_cfg_mgr.cc.
|
virtual |
Destructor.
Definition at line 53 of file netconf_cfg_mgr.cc.
|
protectedvirtual |
Creates a new, blank NetconfConfig context.
This method is used at the beginning of configuration process to create a fresh, empty copy of a NetconfConfig. This new context will be populated during the configuration process and will replace the existing context provided the configuration process completes without error.
Implements isc::process::DCfgMgrBase.
Definition at line 87 of file netconf_cfg_mgr.cc.
|
virtual |
Returns configuration summary in the textual format.
selection | Bitfield which describes the parts of the configuration to be returned. This parameter is ignored for Netconf. |
Implements isc::process::DCfgMgrBase.
Definition at line 57 of file netconf_cfg_mgr.cc.
References getNetconfConfig().
|
inline |
Convenience method that returns the Netconf configuration context.
Definition at line 137 of file netconf_cfg_mgr.h.
References isc::process::DCfgMgrBase::getContext().
Referenced by getConfigSummary(), and parse().
|
virtual |
Return a list of all paths that contain passwords or secrets for kea-netconf.
Reimplemented from isc::process::DCfgMgrBase.
Definition at line 168 of file netconf_cfg_mgr.cc.
|
protectedvirtual |
Parses configuration of Netconf.
config | Pointer to a configuration specified for netconf. |
check_only | Boolean flag indicating if this method should only verify correctness of the provided configuration. |
Reimplemented from isc::process::DCfgMgrBase.
Definition at line 92 of file netconf_cfg_mgr.cc.
References isc::config::CONTROL_RESULT_ERROR, isc::config::CONTROL_RESULT_SUCCESS, isc::config::createAnswer(), isc::netconf::NetconfSimpleParser::deriveParameters(), getNetconfConfig(), isc_throw, LOG_ERROR, isc::netconf::NETCONF_CONFIG_CHECK_FAIL, isc::netconf::NETCONF_CONFIG_FAIL, isc::netconf::netconf_logger, isc::netconf::NetconfSimpleParser::parse(), isc::netconf::NetconfSimpleParser::setAllDefaults(), and isc::Exception::what().