Added some more try/catch blocks and sanity checking
parent
5eec666476
commit
284a3b49a9
|
@ -150,12 +150,22 @@ namespace OpenSim
|
||||||
m_console.WriteLine("Starting in Grid mode");
|
m_console.WriteLine("Starting in Grid mode");
|
||||||
}
|
}
|
||||||
|
|
||||||
GridServers.Initialise();
|
try {
|
||||||
|
GridServers.Initialise();
|
||||||
|
} catch (Exception e) {
|
||||||
|
m_console.WriteLine(e.Message + "\nSorry, could not setup the grid interface");
|
||||||
|
Environment.Exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
startuptime = DateTime.Now;
|
startuptime = DateTime.Now;
|
||||||
|
|
||||||
AssetCache = new AssetCache(GridServers.AssetServer);
|
try {
|
||||||
InventoryCache = new InventoryCache();
|
AssetCache = new AssetCache(GridServers.AssetServer);
|
||||||
|
InventoryCache = new InventoryCache();
|
||||||
|
} catch (Exception e) {
|
||||||
|
m_console.WriteLine(e.Message + "\nSorry, could not setup local cache");
|
||||||
|
Environment.Exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
PacketServer packetServer = new PacketServer(this);
|
PacketServer packetServer = new PacketServer(this);
|
||||||
|
|
||||||
|
@ -189,9 +199,14 @@ namespace OpenSim
|
||||||
{
|
{
|
||||||
// The grid server has told us who we are
|
// The grid server has told us who we are
|
||||||
// We must obey the grid server.
|
// We must obey the grid server.
|
||||||
regionData.RegionLocX = Convert.ToUInt32(((RemoteGridBase)(GridServers.GridServer)).GridData["region_locx"].ToString());
|
try {
|
||||||
regionData.RegionLocY = Convert.ToUInt32(((RemoteGridBase)(GridServers.GridServer)).GridData["region_locy"].ToString());
|
regionData.RegionLocX = Convert.ToUInt32(((RemoteGridBase)(GridServers.GridServer)).GridData["region_locx"].ToString());
|
||||||
regionData.RegionName = ((RemoteGridBase)(GridServers.GridServer)).GridData["regionname"].ToString();
|
regionData.RegionLocY = Convert.ToUInt32(((RemoteGridBase)(GridServers.GridServer)).GridData["region_locy"].ToString());
|
||||||
|
regionData.RegionName = ((RemoteGridBase)(GridServers.GridServer)).GridData["regionname"].ToString();
|
||||||
|
} catch(Exception e) {
|
||||||
|
m_console.WriteLine(e.Message + "\nBAD ERROR! THIS SHOULD NOT HAPPEN! Bad GridData from the grid interface!!!! ZOMG!!!");
|
||||||
|
Environment.Exit(1);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -234,7 +249,8 @@ namespace OpenSim
|
||||||
if (gridServer.GetName() == "Remote")
|
if (gridServer.GetName() == "Remote")
|
||||||
{
|
{
|
||||||
// should startup the OGS protocol server here
|
// should startup the OGS protocol server here
|
||||||
OGSServer = new OpenGridProtocolServer(this.regionData.IPListenPort - 500); // Changed so we can have more than one OGSServer per machine.
|
// Are we actually using this?
|
||||||
|
OGSServer = new OpenGridProtocolServer(this.regionData.IPListenPort - 500); // Changed so we can have more than one OGSServer per machine.
|
||||||
|
|
||||||
// we are in Grid mode so set a XmlRpc handler to handle "expect_user" calls from the user server
|
// we are in Grid mode so set a XmlRpc handler to handle "expect_user" calls from the user server
|
||||||
httpServer.AddXmlRPCHandler("expect_user",
|
httpServer.AddXmlRPCHandler("expect_user",
|
||||||
|
|
Loading…
Reference in New Issue