After previous discussion, put eye-catcher 'SCRIPT READY' messages to console rather than log as warning

The problem with logging at warn is that these aren't actually warnings, and so are false positives to scripts that monitor for problems.
Ideally, log4net would have a separate "status" logging level, but currently we will compromise by putting them to console, as they are user-oriented
master-beforevarregion
Justin Clark-Casey (justincc) 2013-12-14 01:34:28 +00:00
parent 63ccc3dbf5
commit 996a6c2eea
2 changed files with 7 additions and 5 deletions

View File

@ -135,8 +135,8 @@ namespace OpenSim.Framework.Servers
TimeSpan timeTaken = DateTime.Now - m_startuptime; TimeSpan timeTaken = DateTime.Now - m_startuptime;
m_log.InfoFormat( MainConsole.Instance.OutputFormat(
"[STARTUP]: Non-script portion of startup took {0}m {1}s. PLEASE WAIT FOR LOGINS TO BE ENABLED ON REGIONS ONCE SCRIPTS HAVE STARTED.", "PLEASE WAIT FOR LOGINS TO BE ENABLED ON REGIONS ONCE SCRIPTS HAVE STARTED. Non-script portion of startup took {0}m {1}s.",
timeTaken.Minutes, timeTaken.Seconds); timeTaken.Minutes, timeTaken.Seconds);
} }

View File

@ -216,9 +216,11 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
// m_log.InfoFormat("[RegionReady]: Logins enabled for {0}, Oar {1}", // m_log.InfoFormat("[RegionReady]: Logins enabled for {0}, Oar {1}",
// m_scene.RegionInfo.RegionName, m_oarFileLoading.ToString()); // m_scene.RegionInfo.RegionName, m_oarFileLoading.ToString());
// Warn level because the region cannot be used while logins are disabled // Putting this out to console to make it eye-catching for people who are running OpenSimulator
m_log.WarnFormat( // without info log messages enabled. Making this a warning is arguably misleading since it isn't a
"[RegionReady]: INITIALIZATION COMPLETE FOR {0} - LOGINS ENABLED", m_scene.Name); // warning, and monitor scripts looking for warn/error/fatal messages will received false positives.
// Arguably, log4net needs a status log level (like Apache).
MainConsole.Instance.OutputFormat("INITIALIZATION COMPLETE FOR {0} - LOGINS ENABLED", m_scene.Name);
} }
m_scene.SceneGridService.InformNeighborsThatRegionisUp( m_scene.SceneGridService.InformNeighborsThatRegionisUp(