Kea 2.7.6
|
Utility class to apply multi threading configurations. More...
#include <cfg_multi_threading.h>
Static Public Member Functions | |
static void | apply (data::ConstElementPtr value) |
apply multi threading configuration | |
static void | extract (data::ConstElementPtr value, bool &enabled, uint32_t &thread_count, uint32_t &queue_size) |
Extract multi-threading parameters from a given configuration. | |
Utility class to apply multi threading configurations.
Definition at line 16 of file cfg_multi_threading.h.
|
static |
apply multi threading configuration
value | The multi-threading configuration |
Definition at line 21 of file cfg_multi_threading.cc.
References isc::util::MultiThreadingMgr::apply(), extract(), and isc::util::MultiThreadingMgr::instance().
Referenced by isc::dhcp::ControlledDhcpv4Srv::processConfig(), and isc::dhcp::ControlledDhcpv6Srv::processConfig().
|
static |
Extract multi-threading parameters from a given configuration.
If the configuration does not contain the enable parameter, multi-threading is disabled. This is very useful as a default value for unit tests, so that they are kept simple, and that they can enable multi-threading on their own if it is in their scope to test MT.
[in] | value | The multi-threading configuration |
[out] | enabled | The enabled flag |
[out] | thread_count | The thread count |
[out] | queue_size | The queue size |
Definition at line 31 of file cfg_multi_threading.cc.
References isc::data::SimpleParser::getBoolean(), and isc::data::SimpleParser::getInteger().
Referenced by apply(), isc::dhcp::configureDhcp4Server(), isc::dhcp::configureDhcp6Server(), isc::dhcp::processDhcp4Config(), isc::dhcp::processDhcp6Config(), and isc::ha::HAConfig::validate().