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

@@ -113,9 +113,16 @@ namespace OpenSim.Region.DataSnapshot
try
{
m_enabled = config.Configs["DataSnapshot"].GetBoolean("index_sims", m_enabled);
IConfig conf = config.Configs["GridService"];
if (conf != null)
m_gridinfo.Add("gatekeeperURL", conf.GetString("Gatekeeper", String.Empty));
string gatekeeper = Util.GetConfigVarWithDefaultSection(config, "GatekeeperURI", "GridService");
// Legacy. Remove soon!
if (string.IsNullOrEmpty(gatekeeper))
{
IConfig conf = config.Configs["GridService"];
if (conf != null)
gatekeeper = conf.GetString("Gatekeeper", gatekeeper);
}
if (!string.IsNullOrEmpty(gatekeeper))
m_gridinfo.Add("gatekeeperURL", gatekeeper);
m_gridinfo.Add(
"name", config.Configs["DataSnapshot"].GetString("gridname", "the lost continent of hippo"));