* Reinstate grid receive and send keys to user server config

* Looks like these weren't so unused after all - oops!
* Remove message from grid server config
0.6.0-stable
Justin Clarke Casey 2008-08-09 21:01:33 +00:00
parent e73b9c5f0a
commit 6630706dd9
5 changed files with 22 additions and 21 deletions

View File

@ -42,7 +42,6 @@ namespace OpenSim.Framework
public string DatabaseConnect = String.Empty; public string DatabaseConnect = String.Empty;
public string DefaultAssetServer = String.Empty; public string DefaultAssetServer = String.Empty;
public string DefaultUserServer = String.Empty; public string DefaultUserServer = String.Empty;
public string GridOwner = String.Empty;
public uint HttpPort = DefaultHttpPort; public uint HttpPort = DefaultHttpPort;
public string SimRecvKey = String.Empty; public string SimRecvKey = String.Empty;
public string SimSendKey = String.Empty; public string SimSendKey = String.Empty;
@ -58,9 +57,6 @@ namespace OpenSim.Framework
public void loadConfigurationOptions() public void loadConfigurationOptions()
{ {
configMember.addConfigurationOption("grid_owner",
ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY,
"OGS Grid Owner", "OGS development team", false);
configMember.addConfigurationOption("default_asset_server", configMember.addConfigurationOption("default_asset_server",
ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY,
"Default Asset Server URI", "Default Asset Server URI",
@ -101,9 +97,6 @@ namespace OpenSim.Framework
{ {
switch (configuration_key) switch (configuration_key)
{ {
case "grid_owner":
GridOwner = (string) configuration_result;
break;
case "default_asset_server": case "default_asset_server":
DefaultAssetServer = (string) configuration_result; DefaultAssetServer = (string) configuration_result;
break; break;

View File

@ -42,6 +42,8 @@ namespace OpenSim.Framework
public string DefaultStartupMsg = String.Empty; public string DefaultStartupMsg = String.Empty;
public uint DefaultX = 1000; public uint DefaultX = 1000;
public uint DefaultY = 1000; public uint DefaultY = 1000;
public string GridRecvKey = String.Empty;
public string GridSendKey = String.Empty;
public uint HttpPort = DefaultHttpPort; public uint HttpPort = DefaultHttpPort;
public bool HttpSSL = DefaultHttpSSL; public bool HttpSSL = DefaultHttpSSL;
@ -96,6 +98,10 @@ namespace OpenSim.Framework
ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY,
"Default Grid Server URI", "Default Grid Server URI",
"http://127.0.0.1:" + GridConfig.DefaultHttpPort + "/", false); "http://127.0.0.1:" + GridConfig.DefaultHttpPort + "/", false);
configMember.addConfigurationOption("grid_send_key", ConfigurationOption.ConfigurationTypes.TYPE_STRING,
"Key to send to grid server", "null", false);
configMember.addConfigurationOption("grid_recv_key", ConfigurationOption.ConfigurationTypes.TYPE_STRING,
"Key to expect from grid server", "null", false);
configMember.addConfigurationOption("default_inventory_server", configMember.addConfigurationOption("default_inventory_server",
ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY, ConfigurationOption.ConfigurationTypes.TYPE_STRING_NOT_EMPTY,
@ -129,6 +135,12 @@ namespace OpenSim.Framework
case "default_grid_server": case "default_grid_server":
GridServerURL = new Uri( (string) configuration_result ); GridServerURL = new Uri( (string) configuration_result );
break; break;
case "grid_send_key":
GridSendKey = (string) configuration_result;
break;
case "grid_recv_key":
GridRecvKey = (string) configuration_result;
break;
case "default_inventory_server": case "default_inventory_server":
InventoryUrl = new Uri((string) configuration_result); InventoryUrl = new Uri((string) configuration_result);
break; break;

View File

@ -77,7 +77,7 @@ namespace OpenSim.Grid.GridServer
{ {
base.Startup(); base.Startup();
Config(); m_config = new GridConfig("GRID SERVER", (Path.Combine(Util.configDir(), "GridServer_Config.xml")));
SetupGridManager(); SetupGridManager();
@ -132,11 +132,6 @@ namespace OpenSim.Grid.GridServer
m_gridManager.Config = m_config; m_gridManager.Config = m_config;
} }
public void Config()
{
m_config = new GridConfig("GRID SERVER", (Path.Combine(Util.configDir(), "GridServer_Config.xml")));
}
public void CheckSims(object sender, ElapsedEventArgs e) public void CheckSims(object sender, ElapsedEventArgs e)
{ {
/* /*

View File

@ -39,15 +39,15 @@ namespace OpenSim.Grid.GridServer
GridServerBase app = new GridServerBase(); GridServerBase app = new GridServerBase();
if (args.Length > 0 && args[0] == "-setuponly") // if (args.Length > 0 && args[0] == "-setuponly")
{ // {
app.Config(); // app.Config();
} // }
else // else
{ // {
app.Startup(); app.Startup();
app.Work(); app.Work();
} // }
} }
} }
} }

View File

@ -72,18 +72,19 @@ namespace OpenSim.Grid.UserServer
SimInfo = RegionProfileData.RequestSimProfileData( SimInfo = RegionProfileData.RequestSimProfileData(
theUser.CurrentAgent.Handle, m_config.GridServerURL, theUser.CurrentAgent.Handle, m_config.GridServerURL,
m_config.GridSendKey, m_config.GridRecvKey); m_config.GridSendKey, m_config.GridRecvKey);
if (SimInfo == null) if (SimInfo == null)
{ {
m_log.Error("[GRID]: Region user was in isn't currently logged in"); m_log.Error("[GRID]: Region user was in isn't currently logged in");
return; return;
} }
} }
catch (Exception) catch (Exception)
{ {
m_log.Error("[GRID]: Unable to look up region to log user off"); m_log.Error("[GRID]: Unable to look up region to log user off");
return; return;
} }
// Prepare notification // Prepare notification
Hashtable SimParams = new Hashtable(); Hashtable SimParams = new Hashtable();
SimParams["agent_id"] = theUser.ID.ToString(); SimParams["agent_id"] = theUser.ID.ToString();