Allow to place the connection strings and providers for estate and region
in their oqn sections, for those of us who don't want a catch-all DatabaseService section.viewer-2-initial-appearance
parent
8ed08a10d9
commit
585e575d23
|
@ -65,6 +65,14 @@ namespace OpenSim.Services.Connectors
|
||||||
connString = dbConfig.GetString("ConnectionString", String.Empty);
|
connString = dbConfig.GetString("ConnectionString", String.Empty);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Try reading the [EstateDataStore] section, if it exists
|
||||||
|
IConfig estConfig = config.Configs["EstateDataStore"];
|
||||||
|
if (estConfig != null)
|
||||||
|
{
|
||||||
|
dllName = estConfig.GetString("StorageProvider", dllName);
|
||||||
|
connString = dbConfig.GetString("ConnectionString", connString);
|
||||||
|
}
|
||||||
|
|
||||||
// We tried, but this doesn't exist. We can't proceed
|
// We tried, but this doesn't exist. We can't proceed
|
||||||
if (dllName == String.Empty)
|
if (dllName == String.Empty)
|
||||||
throw new Exception("No StorageProvider configured");
|
throw new Exception("No StorageProvider configured");
|
||||||
|
|
|
@ -63,6 +63,14 @@ namespace OpenSim.Services.Connectors
|
||||||
connString = dbConfig.GetString("ConnectionString", String.Empty);
|
connString = dbConfig.GetString("ConnectionString", String.Empty);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Try reading the [SimulationDataStore] section
|
||||||
|
IConfig simConfig = config.Configs["SimulationDataStore"];
|
||||||
|
if (simConfig != null)
|
||||||
|
{
|
||||||
|
dllName = simConfig.GetString("StorageProvider", dllName);
|
||||||
|
connString = simConfig.GetString("ConnectionString", connString);
|
||||||
|
}
|
||||||
|
|
||||||
// We tried, but this doesn't exist. We can't proceed
|
// We tried, but this doesn't exist. We can't proceed
|
||||||
if (dllName == String.Empty)
|
if (dllName == String.Empty)
|
||||||
throw new Exception("No StorageProvider configured");
|
throw new Exception("No StorageProvider configured");
|
||||||
|
|
Loading…
Reference in New Issue