]> git.ipfire.org Git - thirdparty/squid.git/blobdiff - src/main.cc
cache_log_message directive (#775)
[thirdparty/squid.git] / src / main.cc
index e0f94492360dda1307d2a5ff19c249a41e93cad3..29bb7bd1c4e1ef59fdf782cf418b6de18574923c 100644 (file)
@@ -29,6 +29,7 @@
 #include "CommandLine.h"
 #include "ConfigParser.h"
 #include "CpuAffinity.h"
+#include "DebugMessages.h"
 #include "DiskIO/DiskIOModule.h"
 #include "dns/forward.h"
 #include "errorpage.h"
@@ -290,8 +291,8 @@ SignalEngine::doShutdown(time_t wait)
     if (AvoidSignalAction("shutdown", do_shutdown))
         return;
 
-    debugs(1, DBG_IMPORTANT, "Preparing for shutdown after " << statCounter.client_http.requests << " requests");
-    debugs(1, DBG_IMPORTANT, "Waiting " << wait << " seconds for active connections to finish");
+    debugs(1, Important(2), "Preparing for shutdown after " << statCounter.client_http.requests << " requests");
+    debugs(1, Important(3), "Waiting " << wait << " seconds for active connections to finish");
 
 #if KILL_PARENT_OPT
     if (!IamMasterProcess() && !parentKillNotified && ShutdownSignal > 0 && parentPid > 1) {
@@ -1117,7 +1118,7 @@ mainSetCwd(void)
 
     if (Config.coredump_dir && strcmp("none", Config.coredump_dir) != 0) {
         if (mainChangeDir(Config.coredump_dir)) {
-            debugs(0, DBG_IMPORTANT, "Set Current Directory to " << Config.coredump_dir);
+            debugs(0, Important(4), "Set Current Directory to " << Config.coredump_dir);
             return;
         }
     }
@@ -1150,7 +1151,7 @@ mainInitialize(void)
         Config.Port.icp = (unsigned short) icpPortNumOverride;
 
     debugs(1, DBG_CRITICAL, "Starting Squid Cache version " << version_string << " for " << CONFIG_HOST_TYPE << "...");
-    debugs(1, DBG_CRITICAL, "Service Name: " << service_name);
+    debugs(1, Critical(5), "Service Name: " << service_name);
 
 #if _SQUID_WINDOWS_
     if (WIN32_run_mode == _WIN_SQUID_RUN_MODE_SERVICE) {
@@ -1159,12 +1160,12 @@ mainInitialize(void)
         debugs(1, DBG_CRITICAL, "Running on " << WIN32_OS_string);
 #endif
 
-    debugs(1, DBG_IMPORTANT, "Process ID " << getpid());
+    debugs(1, Important(6), "Process ID " << getpid());
 
-    debugs(1, DBG_IMPORTANT, "Process Roles:" << ProcessRoles());
+    debugs(1, Important(7), "Process Roles:" << ProcessRoles());
 
     setSystemLimits();
-    debugs(1, DBG_IMPORTANT, "With " << Squid_MaxFD << " file descriptors available");
+    debugs(1, Important(8), "With " << Squid_MaxFD << " file descriptors available");
 
 #if _SQUID_WINDOWS_
 
@@ -2084,7 +2085,7 @@ SquidShutdown()
     WIN32_svcstatusupdate(SERVICE_STOP_PENDING, 10000);
 #endif
 
-    debugs(1, DBG_IMPORTANT, "Shutting down...");
+    debugs(1, Important(9), "Shutting down...");
 #if USE_SSL_CRTD
     Ssl::Helper::Shutdown();
 #endif
@@ -2168,7 +2169,7 @@ SquidShutdown()
 
     memClean();
 
-    debugs(1, DBG_IMPORTANT, "Squid Cache (Version " << version_string << "): Exiting normally.");
+    debugs(1, Important(10), "Squid Cache (Version " << version_string << "): Exiting normally.");
 
     /*
      * DPW 2006-10-23