Daemon::configureLogger(json->get("Logging"),
CfgMgr::instance().getStagingCfg());
+ // Apply the new logger configuration to log4cplus. It is done before
+ // commit in case something goes wrong and before configuration load
+ // in order to log possible configuration problems.
+ CfgMgr::instance().getStagingCfg()->applyLoggingCfg();
+
// Get Dhcp4 component from the config
dhcp4 = json->get("Dhcp4");
if (!dhcp4) {
isc_throw(isc::BadValue, reason);
}
- // If configuration was parsed successfully, apply the new logger
- // configuration to log4cplus. It is done before commit in case
- // something goes wrong.
- CfgMgr::instance().getStagingCfg()->applyLoggingCfg();
-
// Use new configuration.
/// @todo: This commit should be moved to
/// CtrlDhcp4Srv::commandConfigReloadHandler.
Daemon::configureLogger(json->get("Logging"),
CfgMgr::instance().getStagingCfg());
+ // Apply the new logger configuration to log4cplus. It is done before
+ // commit in case something goes wrong and before configuration load
+ // in order to log possible configuration problems.
+ CfgMgr::instance().getStagingCfg()->applyLoggingCfg();
+
// Get Dhcp6 component from the config
dhcp6 = json->get("Dhcp6");
isc_throw(isc::BadValue, reason);
}
- // If configuration was parsed successfully, apply the new logger
- // configuration to log4cplus. It is done before commit in case
- // something goes wrong.
- CfgMgr::instance().getStagingCfg()->applyLoggingCfg();
-
// Use new configuration.
CfgMgr::instance().commit();