From a42faca5b92f5c17c16b79fcf0df446d1aa08ae1 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Wed, 19 Jan 2011 01:13:10 +0000 Subject: With mic's permission, adjust long call time info messages to 500ms from 200ms --- OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'OpenSim/Framework/Servers') diff --git a/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs b/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs index 86ad7aa..d4ee7ba 100644 --- a/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs +++ b/OpenSim/Framework/Servers/HttpServer/BaseHttpServer.cs @@ -587,8 +587,9 @@ namespace OpenSim.Framework.Servers.HttpServer // Every month or so this will wrap and give bad numbers, not really a problem // since its just for reporting, 200ms limit can be adjusted int tickdiff = Environment.TickCount - tickstart; - if (tickdiff > 200) - m_log.InfoFormat("[BASE HTTP SERVER]: slow request <{0}> for {1} took {2} ms",reqnum,request.RawUrl,tickdiff); + if (tickdiff > 500) + m_log.InfoFormat( + "[BASE HTTP SERVER]: slow request <{0}> for {1} took {2} ms", reqnum, request.RawUrl, tickdiff); } } -- cgit v1.1 From b0aebc6f3d8d0a9b086b4af3c8ad81c2daba7610 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Thu, 20 Jan 2011 21:41:48 +0000 Subject: minor: make "show info" help slightly clearer --- OpenSim/Framework/Servers/BaseOpenSimServer.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'OpenSim/Framework/Servers') diff --git a/OpenSim/Framework/Servers/BaseOpenSimServer.cs b/OpenSim/Framework/Servers/BaseOpenSimServer.cs index cbab2db..865a0ed 100644 --- a/OpenSim/Framework/Servers/BaseOpenSimServer.cs +++ b/OpenSim/Framework/Servers/BaseOpenSimServer.cs @@ -175,7 +175,7 @@ namespace OpenSim.Framework.Servers m_console.Commands.AddCommand("base", false, "show info", "show info", - "Show general information", HandleShow); + "Show general information about the server", HandleShow); m_console.Commands.AddCommand("base", false, "show stats", "show stats", -- cgit v1.1 From 43f948d6913ab33a9f5e11c631b0d64b2ef73b04 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Fri, 21 Jan 2011 23:05:53 +0000 Subject: add current console log level to "show info" --- OpenSim/Framework/Servers/BaseOpenSimServer.cs | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'OpenSim/Framework/Servers') diff --git a/OpenSim/Framework/Servers/BaseOpenSimServer.cs b/OpenSim/Framework/Servers/BaseOpenSimServer.cs index 865a0ed..6eb7686 100644 --- a/OpenSim/Framework/Servers/BaseOpenSimServer.cs +++ b/OpenSim/Framework/Servers/BaseOpenSimServer.cs @@ -371,8 +371,7 @@ namespace OpenSim.Framework.Servers switch (showParams[0]) { case "info": - Notice("Version: " + m_version); - Notice("Startup directory: " + m_startupDirectory); + ShowInfo(); break; case "stats": @@ -395,6 +394,14 @@ namespace OpenSim.Framework.Servers break; } } + + protected void ShowInfo() + { + Notice("Version: " + m_version); + Notice("Startup directory: " + m_startupDirectory); + if (null != m_consoleAppender) + Notice(String.Format("Console log level: {0}", m_consoleAppender.Threshold)); + } /// /// Console output is only possible if a console has been established. -- cgit v1.1 From e44ceaaea3ec42fad63c5437e57e8c96a74e64e0 Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Fri, 21 Jan 2011 23:07:19 +0000 Subject: make "show info" and "show version" show the same version text --- OpenSim/Framework/Servers/BaseOpenSimServer.cs | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'OpenSim/Framework/Servers') diff --git a/OpenSim/Framework/Servers/BaseOpenSimServer.cs b/OpenSim/Framework/Servers/BaseOpenSimServer.cs index 6eb7686..147fbd5 100644 --- a/OpenSim/Framework/Servers/BaseOpenSimServer.cs +++ b/OpenSim/Framework/Servers/BaseOpenSimServer.cs @@ -388,20 +388,23 @@ namespace OpenSim.Framework.Servers break; case "version": - Notice( - String.Format( - "Version: {0} (interface version {1})", m_version, VersionInfo.MajorInterfaceVersion)); + Notice(GetVersionText()); break; } } protected void ShowInfo() { - Notice("Version: " + m_version); + Notice(GetVersionText()); Notice("Startup directory: " + m_startupDirectory); if (null != m_consoleAppender) Notice(String.Format("Console log level: {0}", m_consoleAppender.Threshold)); } + + protected string GetVersionText() + { + return String.Format("Version: {0} (interface version {1})", m_version, VersionInfo.MajorInterfaceVersion); + } /// /// Console output is only possible if a console has been established. -- cgit v1.1 From cb14e1d2720fdee0c77280d7c397c02116c278ca Mon Sep 17 00:00:00 2001 From: Justin Clark-Casey (justincc) Date: Fri, 21 Jan 2011 23:59:55 +0000 Subject: Update the "config get
" command to "config get [
] []" The config get command shows a current config value on the console. Now, if is omitted then all the values for the given section are printed. If
is ommitted then all sections and all keys are printed. Current config can also be dumped to a file using "config save ". This can be handy for resolving or eliminating config issues --- OpenSim/Framework/Servers/BaseOpenSimServer.cs | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'OpenSim/Framework/Servers') diff --git a/OpenSim/Framework/Servers/BaseOpenSimServer.cs b/OpenSim/Framework/Servers/BaseOpenSimServer.cs index 147fbd5..b28ad69 100644 --- a/OpenSim/Framework/Servers/BaseOpenSimServer.cs +++ b/OpenSim/Framework/Servers/BaseOpenSimServer.cs @@ -411,6 +411,7 @@ namespace OpenSim.Framework.Servers /// That is something that cannot be determined within this class. So /// all attempts to use the console MUST be verified. ///
+ /// protected void Notice(string msg) { if (m_console != null) @@ -418,6 +419,19 @@ namespace OpenSim.Framework.Servers m_console.Output(msg); } } + + /// + /// Console output is only possible if a console has been established. + /// That is something that cannot be determined within this class. So + /// all attempts to use the console MUST be verified. + /// + /// + /// + protected void Notice(string format, params string[] components) + { + if (m_console != null) + m_console.OutputFormat(format, components); + } /// /// Enhance the version string with extra information if it's available. -- cgit v1.1