From af4b81f94434b7680250553bfa444c6983628cdb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20K=C4=99pie=C5=84?= Date: Wed, 6 Mar 2019 08:31:07 +0100 Subject: [PATCH] Log plugin unloading at debug level During server reconfiguration, plugin instances set up for the old views are unloaded very close to the end of the whole process, after new plugin instances are set up. As the log message announcing plugin unloading is emitted at the default "info" level, the user might be misled into thinking that it is the new plugin instances that are being unloaded for some reason, particularly because all other messages logged at the "info" level around the same time inform about setting things up rather than tearing them down. Since no distinction is currently made between destroying a view due to reconfiguration and due to a shutdown in progress, there is no easy way to vary the contents of the log message depending on circumstances. Since this message is not a particularly critical one, demote it to debug level to prevent confusion. --- lib/ns/hooks.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/ns/hooks.c b/lib/ns/hooks.c index 327ae6909e..0d8c3511cd 100644 --- a/lib/ns/hooks.c +++ b/lib/ns/hooks.c @@ -231,7 +231,7 @@ unload_plugin(ns_plugin_t **pluginp) { *pluginp = NULL; isc_log_write(ns_lctx, NS_LOGCATEGORY_GENERAL, - NS_LOGMODULE_HOOKS, ISC_LOG_INFO, + NS_LOGMODULE_HOOKS, ISC_LOG_DEBUG(1), "unloading plugin '%s'", plugin->modpath); if (plugin->inst != NULL) { @@ -352,7 +352,7 @@ unload_plugin(ns_plugin_t **pluginp) { *pluginp = NULL; isc_log_write(ns_lctx, NS_LOGCATEGORY_GENERAL, - NS_LOGMODULE_HOOKS, ISC_LOG_INFO, + NS_LOGMODULE_HOOKS, ISC_LOG_DEBUG(1), "unloading plugin '%s'", plugin->modpath); if (plugin->inst != NULL) {