Simplification of HG configs: HomeURI and GatekeeperURI now are defined as default under [Startup]. They can then be overwritten in the other sections (but probably shouldn't). I kept the existing code for backwards compatibility, so this should not cause any breaks from people's current configurations. But people should move to have these 2 vars under [Startup] -- see OpenSim.ini.example and Robust.HG.ini.example. And yes, both names now end with "URI" for consistency.

This commit is contained in:
Diva Canto
2013-02-21 17:26:19 -08:00
parent efb5da0aa6
commit e515cdddec
16 changed files with 152 additions and 66 deletions

View File

@@ -2137,9 +2137,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
CheckThreatLevel(ThreatLevel.Moderate, "osGetGridHomeURI");
m_host.AddScriptLPS(1);
string HomeURI = String.Empty;
IConfigSource config = m_ScriptEngine.ConfigSource;
string HomeURI = Util.GetConfigVarWithDefaultSection(config, "HomeURI", string.Empty);
if (!string.IsNullOrEmpty(HomeURI))
return HomeURI;
// Legacy. Remove soon!
if (config.Configs["LoginService"] != null)
HomeURI = config.Configs["LoginService"].GetString("SRV_HomeURI", HomeURI);
@@ -2154,9 +2158,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
CheckThreatLevel(ThreatLevel.Moderate, "osGetGridGatekeeperURI");
m_host.AddScriptLPS(1);
string gatekeeperURI = String.Empty;
IConfigSource config = m_ScriptEngine.ConfigSource;
string gatekeeperURI = Util.GetConfigVarWithDefaultSection(config, "GatekeeperURI", string.Empty);
if (!string.IsNullOrEmpty(gatekeeperURI))
return gatekeeperURI;
// Legacy. Remove soon!
if (config.Configs["GridService"] != null)
gatekeeperURI = config.Configs["GridService"].GetString("Gatekeeper", gatekeeperURI);