aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorMW2008-11-05 18:00:45 +0000
committerMW2008-11-05 18:00:45 +0000
commit204ef95843908a3c5e27ae42b5ffcb0a235a9552 (patch)
tree9e5269aa234ed323dbf0fc31ab54fe038c4a7234
parentmore startup/initialisation refactoring (diff)
downloadopensim-SC_OLD-204ef95843908a3c5e27ae42b5ffcb0a235a9552.zip
opensim-SC_OLD-204ef95843908a3c5e27ae42b5ffcb0a235a9552.tar.gz
opensim-SC_OLD-204ef95843908a3c5e27ae42b5ffcb0a235a9552.tar.bz2
opensim-SC_OLD-204ef95843908a3c5e27ae42b5ffcb0a235a9552.tar.xz
Moved a couple of more configuration fields to ConfigSettings
-rw-r--r--OpenSim/Framework/ConfigSettings.cs16
-rw-r--r--OpenSim/Region/Application/OpenSimBase.cs15
-rw-r--r--OpenSim/Region/ClientStack/RegionApplicationBase.cs8
3 files changed, 29 insertions, 10 deletions
diff --git a/OpenSim/Framework/ConfigSettings.cs b/OpenSim/Framework/ConfigSettings.cs
index 7efc778..275ab69 100644
--- a/OpenSim/Framework/ConfigSettings.cs
+++ b/OpenSim/Framework/ConfigSettings.cs
@@ -132,5 +132,21 @@ namespace OpenSim.Framework
132 get { return m_assetStorage; } 132 get { return m_assetStorage; }
133 set { m_assetStorage = value; } 133 set { m_assetStorage = value; }
134 } 134 }
135
136 protected string m_storageConnectionString;
137
138 public string StorageConnectionString
139 {
140 get { return m_storageConnectionString; }
141 set { m_storageConnectionString = value; }
142 }
143
144 protected string m_estateConnectionString;
145
146 public string EstateConnectionString
147 {
148 get { return m_estateConnectionString; }
149 set { m_estateConnectionString = value; }
150 }
135 } 151 }
136} 152}
diff --git a/OpenSim/Region/Application/OpenSimBase.cs b/OpenSim/Region/Application/OpenSimBase.cs
index a3b557d..61e6f09 100644
--- a/OpenSim/Region/Application/OpenSimBase.cs
+++ b/OpenSim/Region/Application/OpenSimBase.cs
@@ -286,9 +286,9 @@ namespace OpenSim
286 Console.WriteLine("WARNING: OpenSim.DataStore.MonoSqlite.dll is deprecated. Set storage_plugin to OpenSim.Data.SQLite.dll."); 286 Console.WriteLine("WARNING: OpenSim.DataStore.MonoSqlite.dll is deprecated. Set storage_plugin to OpenSim.Data.SQLite.dll.");
287 Thread.Sleep(3000); 287 Thread.Sleep(3000);
288 } 288 }
289 289
290 m_storageConnectionString = startupConfig.GetString("storage_connection_string"); 290 m_configSettings.StorageConnectionString = startupConfig.GetString("storage_connection_string");
291 m_estateConnectionString = startupConfig.GetString("estate_connection_string", m_storageConnectionString); 291 m_configSettings.EstateConnectionString = startupConfig.GetString("estate_connection_string", m_configSettings.StorageConnectionString);
292 m_configSettings.AssetStorage = startupConfig.GetString("asset_database"); 292 m_configSettings.AssetStorage = startupConfig.GetString("asset_database");
293 m_configSettings.ClientstackDll = startupConfig.GetString("clientstack_plugin"); 293 m_configSettings.ClientstackDll = startupConfig.GetString("clientstack_plugin");
294 } 294 }
@@ -589,9 +589,14 @@ namespace OpenSim
589 Scene target; 589 Scene target;
590 if (m_sceneManager.TryGetScene(name, out target)) 590 if (m_sceneManager.TryGetScene(name, out target))
591 RemoveRegion(target, cleanUp); 591 RemoveRegion(target, cleanUp);
592 } 592 }
593
594 protected override StorageManager CreateStorageManager()
595 {
596 return CreateStorageManager(m_configSettings.StorageConnectionString, m_configSettings.EstateConnectionString);
597 }
593 598
594 protected override StorageManager CreateStorageManager(string connectionstring, string estateconnectionstring) 599 protected StorageManager CreateStorageManager(string connectionstring, string estateconnectionstring)
595 { 600 {
596 return new StorageManager(m_configSettings.StorageDll, connectionstring, estateconnectionstring); 601 return new StorageManager(m_configSettings.StorageDll, connectionstring, estateconnectionstring);
597 } 602 }
diff --git a/OpenSim/Region/ClientStack/RegionApplicationBase.cs b/OpenSim/Region/ClientStack/RegionApplicationBase.cs
index b671fc5..cac4591 100644
--- a/OpenSim/Region/ClientStack/RegionApplicationBase.cs
+++ b/OpenSim/Region/ClientStack/RegionApplicationBase.cs
@@ -61,9 +61,7 @@ namespace OpenSim.Region.ClientStack
61 protected SceneManager m_sceneManager = new SceneManager(); 61 protected SceneManager m_sceneManager = new SceneManager();
62 62
63 protected StorageManager m_storageManager; 63 protected StorageManager m_storageManager;
64 protected string m_storageConnectionString; 64
65 protected string m_estateConnectionString;
66
67 protected ClientStackManager m_clientStackManager; 65 protected ClientStackManager m_clientStackManager;
68 66
69 public SceneManager SceneManager 67 public SceneManager SceneManager
@@ -73,14 +71,14 @@ namespace OpenSim.Region.ClientStack
73 71
74 protected abstract void Initialize(); 72 protected abstract void Initialize();
75 protected abstract PhysicsScene GetPhysicsScene(); 73 protected abstract PhysicsScene GetPhysicsScene();
76 protected abstract StorageManager CreateStorageManager(string connectionstring, string estateconnectionstring); 74 protected abstract StorageManager CreateStorageManager();
77 protected abstract ClientStackManager CreateClientStackManager(); 75 protected abstract ClientStackManager CreateClientStackManager();
78 protected abstract Scene CreateScene(RegionInfo regionInfo, StorageManager storageManager, 76 protected abstract Scene CreateScene(RegionInfo regionInfo, StorageManager storageManager,
79 AgentCircuitManager circuitManager); 77 AgentCircuitManager circuitManager);
80 78
81 protected override void StartupSpecific() 79 protected override void StartupSpecific()
82 { 80 {
83 m_storageManager = CreateStorageManager(m_storageConnectionString, m_estateConnectionString); 81 m_storageManager = CreateStorageManager();
84 82
85 m_clientStackManager = CreateClientStackManager(); 83 m_clientStackManager = CreateClientStackManager();
86 84