aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorSean Dague2007-10-25 15:34:43 +0000
committerSean Dague2007-10-25 15:34:43 +0000
commit32869aec47b9bc7f7046d24aabc3f3d957a929af (patch)
tree32d71f4744fca858d9eb7b2d7ada1b9089bf27e2 /OpenSim
parentmove out the config files to .example files so that they (diff)
downloadopensim-SC-32869aec47b9bc7f7046d24aabc3f3d957a929af.zip
opensim-SC-32869aec47b9bc7f7046d24aabc3f3d957a929af.tar.gz
opensim-SC-32869aec47b9bc7f7046d24aabc3f3d957a929af.tar.bz2
opensim-SC-32869aec47b9bc7f7046d24aabc3f3d957a929af.tar.xz
apply http://bug.opensecondlife.org/view.php?id=512 from chillken
which cleans up the verbose logic
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Framework/Console/LogBase.cs10
-rw-r--r--OpenSim/Grid/AssetServer/Main.cs2
-rw-r--r--OpenSim/Grid/GridServer/Main.cs2
-rw-r--r--OpenSim/Grid/ScriptServer/ScriptServerMain.cs2
-rw-r--r--OpenSim/Grid/UserServer/Main.cs2
-rw-r--r--OpenSim/Region/Application/Application.cs2
-rw-r--r--OpenSim/Region/Application/OpenSimMain.cs6
-rw-r--r--OpenSim/Region/Examples/SimpleApp/Program.cs2
-rw-r--r--OpenSim/Tests/Inventory/TestInventory.cs2
9 files changed, 15 insertions, 15 deletions
diff --git a/OpenSim/Framework/Console/LogBase.cs b/OpenSim/Framework/Console/LogBase.cs
index 246afa1..c976e2c 100644
--- a/OpenSim/Framework/Console/LogBase.cs
+++ b/OpenSim/Framework/Console/LogBase.cs
@@ -51,13 +51,13 @@ namespace OpenSim.Framework.Console
51 StreamWriter Log; 51 StreamWriter Log;
52 public conscmd_callback cmdparser; 52 public conscmd_callback cmdparser;
53 public string componentname; 53 public string componentname;
54 private bool m_silent; 54 private bool m_verbose;
55 55
56 public LogBase(string LogFile, string componentname, conscmd_callback cmdparser, bool silent) 56 public LogBase(string LogFile, string componentname, conscmd_callback cmdparser, bool verbose)
57 { 57 {
58 this.componentname = componentname; 58 this.componentname = componentname;
59 this.cmdparser = cmdparser; 59 this.cmdparser = cmdparser;
60 this.m_silent = silent; 60 this.m_verbose = verbose;
61 System.Console.WriteLine("Creating new local console"); 61 System.Console.WriteLine("Creating new local console");
62 62
63 if (String.IsNullOrEmpty(LogFile)) 63 if (String.IsNullOrEmpty(LogFile))
@@ -170,7 +170,7 @@ namespace OpenSim.Framework.Console
170 /// <param name="args">WriteLine-style message arguments</param> 170 /// <param name="args">WriteLine-style message arguments</param>
171 public void Verbose(string format, params object[] args) 171 public void Verbose(string format, params object[] args)
172 { 172 {
173 if (!m_silent) 173 if (m_verbose)
174 { 174 {
175 WriteNewLine(ConsoleColor.Gray, format, args); 175 WriteNewLine(ConsoleColor.Gray, format, args);
176 return; 176 return;
@@ -185,7 +185,7 @@ namespace OpenSim.Framework.Console
185 /// <param name="args">WriteLine-style message arguments</param> 185 /// <param name="args">WriteLine-style message arguments</param>
186 public void Verbose(string sender, string format, params object[] args) 186 public void Verbose(string sender, string format, params object[] args)
187 { 187 {
188 if (!m_silent) 188 if (m_verbose)
189 { 189 {
190 WritePrefixLine(DeriveColor(sender), sender); 190 WritePrefixLine(DeriveColor(sender), sender);
191 WriteNewLine(ConsoleColor.Gray, format, args); 191 WriteNewLine(ConsoleColor.Gray, format, args);
diff --git a/OpenSim/Grid/AssetServer/Main.cs b/OpenSim/Grid/AssetServer/Main.cs
index 3061e5c..9f1f9a2 100644
--- a/OpenSim/Grid/AssetServer/Main.cs
+++ b/OpenSim/Grid/AssetServer/Main.cs
@@ -86,7 +86,7 @@ namespace OpenSim.Grid.AssetServer
86 { 86 {
87 Directory.CreateDirectory(Util.logDir()); 87 Directory.CreateDirectory(Util.logDir());
88 } 88 }
89 m_console = new LogBase((Path.Combine(Util.logDir(),"opengrid-AssetServer-console.log")), "OpenAsset", this, false); 89 m_console = new LogBase((Path.Combine(Util.logDir(),"opengrid-AssetServer-console.log")), "OpenAsset", this, true);
90 MainLog.Instance = m_console; 90 MainLog.Instance = m_console;
91 } 91 }
92 92
diff --git a/OpenSim/Grid/GridServer/Main.cs b/OpenSim/Grid/GridServer/Main.cs
index 89497d8..2015be5 100644
--- a/OpenSim/Grid/GridServer/Main.cs
+++ b/OpenSim/Grid/GridServer/Main.cs
@@ -90,7 +90,7 @@ namespace OpenSim.Grid.GridServer
90 { 90 {
91 Directory.CreateDirectory(Util.logDir()); 91 Directory.CreateDirectory(Util.logDir());
92 } 92 }
93 m_console = new LogBase((Path.Combine(Util.logDir(),"opengrid-gridserver-console.log")), "OpenGrid", this, false); 93 m_console = new LogBase((Path.Combine(Util.logDir(),"opengrid-gridserver-console.log")), "OpenGrid", this, true);
94 MainLog.Instance = m_console; 94 MainLog.Instance = m_console;
95 95
96 96
diff --git a/OpenSim/Grid/ScriptServer/ScriptServerMain.cs b/OpenSim/Grid/ScriptServer/ScriptServerMain.cs
index f22f2e6..478915b 100644
--- a/OpenSim/Grid/ScriptServer/ScriptServerMain.cs
+++ b/OpenSim/Grid/ScriptServer/ScriptServerMain.cs
@@ -62,7 +62,7 @@ namespace OpenSim.Grid.ScriptServer
62 Directory.CreateDirectory(Util.logDir()); 62 Directory.CreateDirectory(Util.logDir());
63 } 63 }
64 64
65 return new LogBase((Path.Combine(Util.logDir(), m_logFilename)), "Region", this, false); 65 return new LogBase((Path.Combine(Util.logDir(), m_logFilename)), "Region", this, true);
66 } 66 }
67 67
68 public void RunCmd(string command, string[] cmdparams) 68 public void RunCmd(string command, string[] cmdparams)
diff --git a/OpenSim/Grid/UserServer/Main.cs b/OpenSim/Grid/UserServer/Main.cs
index b270171..b8d9065 100644
--- a/OpenSim/Grid/UserServer/Main.cs
+++ b/OpenSim/Grid/UserServer/Main.cs
@@ -67,7 +67,7 @@ namespace OpenSim.Grid.UserServer
67 { 67 {
68 Directory.CreateDirectory(Util.logDir()); 68 Directory.CreateDirectory(Util.logDir());
69 } 69 }
70 m_console = new LogBase((Path.Combine(Util.logDir(),"opengrid-userserver-console.log")), "OpenUser", this , false); 70 m_console = new LogBase((Path.Combine(Util.logDir(), "opengrid-userserver-console.log")), "OpenUser", this, true);
71 MainLog.Instance = m_console; 71 MainLog.Instance = m_console;
72 } 72 }
73 73
diff --git a/OpenSim/Region/Application/Application.cs b/OpenSim/Region/Application/Application.cs
index 8e2793e..8079ab8 100644
--- a/OpenSim/Region/Application/Application.cs
+++ b/OpenSim/Region/Application/Application.cs
@@ -64,7 +64,7 @@ namespace OpenSim
64 configSource.AddSwitch("Startup", "inifile"); 64 configSource.AddSwitch("Startup", "inifile");
65 configSource.AddSwitch("Startup", "gridmode"); 65 configSource.AddSwitch("Startup", "gridmode");
66 configSource.AddSwitch("Startup", "physics"); 66 configSource.AddSwitch("Startup", "physics");
67 configSource.AddSwitch("Startup", "noverbose"); 67 configSource.AddSwitch("Startup", "verbose");
68 configSource.AddSwitch("Startup", "useexecutepath"); 68 configSource.AddSwitch("Startup", "useexecutepath");
69 69
70 OpenSimMain sim = new OpenSimMain(configSource); 70 OpenSimMain sim = new OpenSimMain(configSource);
diff --git a/OpenSim/Region/Application/OpenSimMain.cs b/OpenSim/Region/Application/OpenSimMain.cs
index a345334..55913a8 100644
--- a/OpenSim/Region/Application/OpenSimMain.cs
+++ b/OpenSim/Region/Application/OpenSimMain.cs
@@ -74,7 +74,7 @@ namespace OpenSim
74 protected List<UDPServer> m_udpServers = new List<UDPServer>(); 74 protected List<UDPServer> m_udpServers = new List<UDPServer>();
75 protected List<RegionInfo> m_regionData = new List<RegionInfo>(); 75 protected List<RegionInfo> m_regionData = new List<RegionInfo>();
76 76
77 private bool m_silent; 77 private bool m_verbose;
78 private readonly string m_logFilename = ("region-console.log"); 78 private readonly string m_logFilename = ("region-console.log");
79 private bool m_permissions = false; 79 private bool m_permissions = false;
80 80
@@ -122,7 +122,7 @@ namespace OpenSim
122 m_networkServersInfo = new NetworkServersInfo(); 122 m_networkServersInfo = new NetworkServersInfo();
123 m_sandbox = !m_config.Configs["Startup"].GetBoolean("gridmode", false); 123 m_sandbox = !m_config.Configs["Startup"].GetBoolean("gridmode", false);
124 m_physicsEngine = m_config.Configs["Startup"].GetString("physics", "basicphysics"); 124 m_physicsEngine = m_config.Configs["Startup"].GetString("physics", "basicphysics");
125 m_silent = m_config.Configs["Startup"].GetBoolean("noverbose", false); 125 m_verbose = m_config.Configs["Startup"].GetBoolean("verbose", true);
126 m_permissions = m_config.Configs["Startup"].GetBoolean("serverside_object_permissions", false); 126 m_permissions = m_config.Configs["Startup"].GetBoolean("serverside_object_permissions", false);
127 127
128 m_storageDLL = m_config.Configs["Startup"].GetString("storage_plugin", "OpenSim.DataStore.NullStorage.dll"); 128 m_storageDLL = m_config.Configs["Startup"].GetString("storage_plugin", "OpenSim.DataStore.NullStorage.dll");
@@ -319,7 +319,7 @@ namespace OpenSim
319 Directory.CreateDirectory(Util.logDir()); 319 Directory.CreateDirectory(Util.logDir());
320 } 320 }
321 321
322 return new LogBase((Path.Combine(Util.logDir(), m_logFilename)), "Region", this, m_silent); 322 return new LogBase((Path.Combine(Util.logDir(), m_logFilename)), "Region", this, m_verbose);
323 } 323 }
324 324
325 # region Setup methods 325 # region Setup methods
diff --git a/OpenSim/Region/Examples/SimpleApp/Program.cs b/OpenSim/Region/Examples/SimpleApp/Program.cs
index 35f2051..36be3e8 100644
--- a/OpenSim/Region/Examples/SimpleApp/Program.cs
+++ b/OpenSim/Region/Examples/SimpleApp/Program.cs
@@ -50,7 +50,7 @@ namespace SimpleApp
50 50
51 protected override LogBase CreateLog() 51 protected override LogBase CreateLog()
52 { 52 {
53 return new LogBase(null, "SimpleApp", this, false); 53 return new LogBase(null, "SimpleApp", this, true);
54 } 54 }
55 55
56 protected override void Initialize() 56 protected override void Initialize()
diff --git a/OpenSim/Tests/Inventory/TestInventory.cs b/OpenSim/Tests/Inventory/TestInventory.cs
index f9a791f..697b335 100644
--- a/OpenSim/Tests/Inventory/TestInventory.cs
+++ b/OpenSim/Tests/Inventory/TestInventory.cs
@@ -55,7 +55,7 @@ namespace OpenSim.Test.Inventory
55 55
56 _agent_1_id = LLUUID.Random(); 56 _agent_1_id = LLUUID.Random();
57 57
58 MainLog.Instance = new LogBase("UnitTest.log", "TEST", null, true); 58 MainLog.Instance = new LogBase("UnitTest.log", "TEST", null, false);
59// _dbPlugin = new SQLiteInventoryStore(); 59// _dbPlugin = new SQLiteInventoryStore();
60 _dbPlugin = new MySQLInventoryData(); 60 _dbPlugin = new MySQLInventoryData();
61 _dbPlugin.Initialise(); 61 _dbPlugin.Initialise();