mirror of
https://github.com/opensim/opensim.git
synced 2026-08-07 17:55:48 +08:00
Massive tab and trailing space cleanup
This commit is contained in:
@@ -56,7 +56,7 @@ namespace OpenSim.Framework.Servers
|
||||
protected ICommandConsole m_console;
|
||||
|
||||
protected OpenSimAppender m_consoleAppender;
|
||||
protected FileAppender m_logFileAppender;
|
||||
protected FileAppender m_logFileAppender;
|
||||
|
||||
protected DateTime m_startuptime;
|
||||
protected string m_startupDirectory = Environment.CurrentDirectory;
|
||||
@@ -81,7 +81,7 @@ namespace OpenSim.Framework.Servers
|
||||
{
|
||||
if (File.Exists(path))
|
||||
m_log.ErrorFormat(
|
||||
"[SERVER BASE]: Previous pid file {0} still exists on startup. Possibly previously unclean shutdown.",
|
||||
"[SERVER BASE]: Previous pid file {0} still exists on startup. Possibly previously unclean shutdown.",
|
||||
path);
|
||||
|
||||
try
|
||||
@@ -103,7 +103,7 @@ namespace OpenSim.Framework.Servers
|
||||
m_log.Warn(string.Format("[SERVER BASE]: Could not create PID file at {0} ", path), e);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
protected void RemovePIDFile()
|
||||
{
|
||||
if (m_pidFile != String.Empty)
|
||||
@@ -166,11 +166,11 @@ namespace OpenSim.Framework.Servers
|
||||
{
|
||||
// FIXME: This should be done through an interface rather than casting.
|
||||
m_consoleAppender.Console = (ConsoleBase)m_console;
|
||||
|
||||
|
||||
// If there is no threshold set then the threshold is effectively everything.
|
||||
if (null == m_consoleAppender.Threshold)
|
||||
m_consoleAppender.Threshold = Level.All;
|
||||
|
||||
|
||||
Notice(String.Format("Console log level is {0}", m_consoleAppender.Threshold));
|
||||
}
|
||||
|
||||
@@ -205,11 +205,11 @@ namespace OpenSim.Framework.Servers
|
||||
"General", false, "show uptime", "show uptime", "Show server uptime", HandleShow);
|
||||
|
||||
m_console.Commands.AddCommand(
|
||||
"General", false, "get log level", "get log level", "Get the current console logging level",
|
||||
"General", false, "get log level", "get log level", "Get the current console logging level",
|
||||
(mod, cmd) => ShowLogLevel());
|
||||
|
||||
m_console.Commands.AddCommand(
|
||||
"General", false, "set log level", "set log level <level>",
|
||||
"General", false, "set log level", "set log level <level>",
|
||||
"Set the console logging level for this session.", HandleSetLogLevel);
|
||||
|
||||
m_console.Commands.AddCommand(
|
||||
@@ -222,14 +222,14 @@ namespace OpenSim.Framework.Servers
|
||||
"config get [<section>] [<key>]",
|
||||
"Synonym for config show",
|
||||
HandleConfig);
|
||||
|
||||
|
||||
m_console.Commands.AddCommand(
|
||||
"General", false, "config show",
|
||||
"config show [<section>] [<key>]",
|
||||
"Show config information",
|
||||
"Show config information",
|
||||
"If neither section nor field are specified, then the whole current configuration is printed." + Environment.NewLine
|
||||
+ "If a section is given but not a field, then all fields in that section are printed.",
|
||||
HandleConfig);
|
||||
HandleConfig);
|
||||
|
||||
m_console.Commands.AddCommand(
|
||||
"General", false, "config save",
|
||||
@@ -280,7 +280,7 @@ namespace OpenSim.Framework.Servers
|
||||
"debug threadpool status",
|
||||
"Show current debug threadpool parameters.",
|
||||
HandleDebugThreadpoolStatus);
|
||||
|
||||
|
||||
m_console.Commands.AddCommand(
|
||||
"Debug", false, "debug threadpool level",
|
||||
"debug threadpool level 0.." + Util.MAX_THREADPOOL_LEVEL,
|
||||
@@ -332,7 +332,7 @@ namespace OpenSim.Framework.Servers
|
||||
{
|
||||
WebUtil.SerializeOSDRequestsPerEndpoint = networkConfig.GetBoolean("SerializeOSDRequests", false);
|
||||
}
|
||||
|
||||
|
||||
m_serverStatsCollector = new ServerStatsCollector();
|
||||
m_serverStatsCollector.Initialise(configSource);
|
||||
m_serverStatsCollector.Start();
|
||||
@@ -432,7 +432,7 @@ namespace OpenSim.Framework.Servers
|
||||
|
||||
ThreadPool.GetAvailableThreads(out workerThreads, out iocpThreads);
|
||||
Notice("Available worker threads: {0}", workerThreads);
|
||||
Notice("Available IOCP threads: {0}", iocpThreads);
|
||||
Notice("Available IOCP threads: {0}", iocpThreads);
|
||||
}
|
||||
|
||||
private void HandleDebugThreadpoolSet(string module, string[] args)
|
||||
@@ -488,7 +488,7 @@ namespace OpenSim.Framework.Servers
|
||||
fail = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (fail)
|
||||
{
|
||||
Notice("ERROR: Could not set {0} {1} threads to {2}", poolType, bound, newThreads);
|
||||
@@ -582,7 +582,7 @@ namespace OpenSim.Framework.Servers
|
||||
if (cmdparams.Length > 0)
|
||||
{
|
||||
string firstParam = cmdparams[0].ToLower();
|
||||
|
||||
|
||||
switch (firstParam)
|
||||
{
|
||||
case "set":
|
||||
@@ -633,12 +633,12 @@ namespace OpenSim.Framework.Servers
|
||||
{
|
||||
Notice("[{0}]", config.Name);
|
||||
foreach (string key in config.GetKeys())
|
||||
Notice(" {0} = {1}", key, config.GetString(key));
|
||||
Notice(" {0} = {1}", key, config.GetString(key));
|
||||
}
|
||||
else
|
||||
{
|
||||
Notice(
|
||||
"config get {0} {1} : {2}",
|
||||
"config get {0} {1} : {2}",
|
||||
cmdparams[1], cmdparams[2], config.GetString(cmdparams[2]));
|
||||
}
|
||||
}
|
||||
@@ -692,10 +692,10 @@ namespace OpenSim.Framework.Servers
|
||||
}
|
||||
|
||||
string rawLevel = cmd[3];
|
||||
|
||||
|
||||
ILoggerRepository repository = LogManager.GetRepository();
|
||||
Level consoleLevel = repository.LevelMap[rawLevel];
|
||||
|
||||
|
||||
if (consoleLevel != null)
|
||||
m_consoleAppender.Threshold = consoleLevel;
|
||||
else
|
||||
@@ -770,9 +770,9 @@ namespace OpenSim.Framework.Servers
|
||||
protected void ShowInfo()
|
||||
{
|
||||
Notice(GetVersionText());
|
||||
Notice("Startup directory: " + m_startupDirectory);
|
||||
Notice("Startup directory: " + m_startupDirectory);
|
||||
if (null != m_consoleAppender)
|
||||
Notice(String.Format("Console log level: {0}", m_consoleAppender.Threshold));
|
||||
Notice(String.Format("Console log level: {0}", m_consoleAppender.Threshold));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -873,7 +873,7 @@ namespace OpenSim.Framework.Servers
|
||||
|
||||
public string GetVersionText()
|
||||
{
|
||||
return String.Format("Version: {0} (SIMULATION/{1} - SIMULATION/{2})",
|
||||
return String.Format("Version: {0} (SIMULATION/{1} - SIMULATION/{2})",
|
||||
m_version, VersionInfo.SimulationServiceVersionSupportedMin, VersionInfo.SimulationServiceVersionSupportedMax);
|
||||
}
|
||||
|
||||
@@ -898,7 +898,7 @@ namespace OpenSim.Framework.Servers
|
||||
foreach (Watchdog.ThreadWatchdogInfo twi in threads)
|
||||
{
|
||||
Thread t = twi.Thread;
|
||||
|
||||
|
||||
sb.AppendFormat(
|
||||
reportFormat,
|
||||
t.ManagedThreadId,
|
||||
@@ -1005,7 +1005,7 @@ namespace OpenSim.Framework.Servers
|
||||
MainConsole.Instance.OutputFormat("Aborted thread with id {0}", threadId);
|
||||
else
|
||||
MainConsole.Instance.OutputFormat("ERROR - Thread with id {0} not found in managed threads", threadId);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Console output is only possible if a console has been established.
|
||||
@@ -1020,13 +1020,13 @@ namespace OpenSim.Framework.Servers
|
||||
m_console.Output(msg);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 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.
|
||||
/// </summary>
|
||||
/// <param name="format"></param>
|
||||
/// <param name="format"></param>
|
||||
/// <param name="components"></param>
|
||||
protected void Notice(string format, params object[] components)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user