aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services/Connectors/Simulation
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Services/Connectors/Simulation')
-rw-r--r--OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs23
1 files changed, 17 insertions, 6 deletions
diff --git a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
index b1b2a30..683fe79 100644
--- a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
+++ b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
@@ -65,6 +65,11 @@ namespace OpenSim.Services.Connectors.Simulation
65 65
66 #region Agents 66 #region Agents
67 67
68 protected virtual string AgentPath()
69 {
70 return "/agent/";
71 }
72
68 public bool CreateAgent(GridRegion destination, AgentCircuitData aCircuit, uint flags, out string reason) 73 public bool CreateAgent(GridRegion destination, AgentCircuitData aCircuit, uint flags, out string reason)
69 { 74 {
70 reason = String.Empty; 75 reason = String.Empty;
@@ -80,7 +85,7 @@ namespace OpenSim.Services.Connectors.Simulation
80 string uri = string.Empty; 85 string uri = string.Empty;
81 try 86 try
82 { 87 {
83 uri = "http://" + destination.ExternalEndPoint.Address + ":" + destination.HttpPort + "/agent/" + aCircuit.AgentID + "/"; 88 uri = "http://" + destination.ExternalEndPoint.Address + ":" + destination.HttpPort + AgentPath() + aCircuit.AgentID + "/";
84 } 89 }
85 catch (Exception e) 90 catch (Exception e)
86 { 91 {
@@ -197,7 +202,8 @@ namespace OpenSim.Services.Connectors.Simulation
197 catch (WebException ex) 202 catch (WebException ex)
198 { 203 {
199 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of DoCreateChildAgentCall {0}", ex.Message); 204 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of DoCreateChildAgentCall {0}", ex.Message);
200 // ignore, really 205 reason = "Destination did not reply";
206 return false;
201 } 207 }
202 finally 208 finally
203 { 209 {
@@ -224,7 +230,7 @@ namespace OpenSim.Services.Connectors.Simulation
224 string uri = string.Empty; 230 string uri = string.Empty;
225 try 231 try
226 { 232 {
227 uri = "http://" + destination.ExternalEndPoint.Address + ":" + destination.HttpPort + "/agent/" + cAgentData.AgentID + "/"; 233 uri = "http://" + destination.ExternalEndPoint.Address + ":" + destination.HttpPort + AgentPath() + cAgentData.AgentID + "/";
228 } 234 }
229 catch (Exception e) 235 catch (Exception e)
230 { 236 {
@@ -329,7 +335,7 @@ namespace OpenSim.Services.Connectors.Simulation
329 { 335 {
330 agent = null; 336 agent = null;
331 // Eventually, we want to use a caps url instead of the agentID 337 // Eventually, we want to use a caps url instead of the agentID
332 string uri = "http://" + destination.ExternalEndPoint.Address + ":" + destination.HttpPort + "/agent/" + id + "/" + destination.RegionID.ToString() + "/"; 338 string uri = "http://" + destination.ExternalEndPoint.Address + ":" + destination.HttpPort + AgentPath() + id + "/" + destination.RegionID.ToString() + "/";
333 //Console.WriteLine(" >>> DoRetrieveRootAgentCall <<< " + uri); 339 //Console.WriteLine(" >>> DoRetrieveRootAgentCall <<< " + uri);
334 340
335 HttpWebRequest request = (HttpWebRequest)WebRequest.Create(uri); 341 HttpWebRequest request = (HttpWebRequest)WebRequest.Create(uri);
@@ -426,7 +432,7 @@ namespace OpenSim.Services.Connectors.Simulation
426 string uri = string.Empty; 432 string uri = string.Empty;
427 try 433 try
428 { 434 {
429 uri = "http://" + destination.ExternalEndPoint.Address + ":" + destination.HttpPort + "/agent/" + id + "/" + destination.RegionID.ToString() + "/"; 435 uri = "http://" + destination.ExternalEndPoint.Address + ":" + destination.HttpPort + AgentPath() + id + "/" + destination.RegionID.ToString() + "/";
430 } 436 }
431 catch (Exception e) 437 catch (Exception e)
432 { 438 {
@@ -474,10 +480,15 @@ namespace OpenSim.Services.Connectors.Simulation
474 480
475 #region Objects 481 #region Objects
476 482
483 protected virtual string ObjectPath()
484 {
485 return "/object/";
486 }
487
477 public bool CreateObject(GridRegion destination, ISceneObject sog, bool isLocalCall) 488 public bool CreateObject(GridRegion destination, ISceneObject sog, bool isLocalCall)
478 { 489 {
479 string uri 490 string uri
480 = "http://" + destination.ExternalEndPoint.Address + ":" + destination.HttpPort + "/object/" + sog.UUID + "/"; 491 = "http://" + destination.ExternalEndPoint.Address + ":" + destination.HttpPort + ObjectPath() + sog.UUID + "/";
481 //m_log.Debug(" >>> DoCreateObjectCall <<< " + uri); 492 //m_log.Debug(" >>> DoCreateObjectCall <<< " + uri);
482 493
483 WebRequest ObjectCreateRequest = WebRequest.Create(uri); 494 WebRequest ObjectCreateRequest = WebRequest.Create(uri);