aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs')
-rw-r--r--OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs52
1 files changed, 26 insertions, 26 deletions
diff --git a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
index c4284eb..7936cb8 100644
--- a/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
+++ b/OpenSim/Services/Connectors/Simulation/SimulationServiceConnector.cs
@@ -1,4 +1,4 @@
1/* 1/*
2 * Copyright (c) Contributors, http://opensimulator.org/ 2 * Copyright (c) Contributors, http://opensimulator.org/
3 * See CONTRIBUTORS.TXT for a full list of copyright holders. 3 * See CONTRIBUTORS.TXT for a full list of copyright holders.
4 * 4 *
@@ -139,13 +139,13 @@ namespace OpenSim.Services.Connectors.Simulation
139 AgentCreateRequest.ContentLength = buffer.Length; //Count bytes to send 139 AgentCreateRequest.ContentLength = buffer.Length; //Count bytes to send
140 os = AgentCreateRequest.GetRequestStream(); 140 os = AgentCreateRequest.GetRequestStream();
141 os.Write(buffer, 0, strBuffer.Length); //Send it 141 os.Write(buffer, 0, strBuffer.Length); //Send it
142 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: Posted CreateAgent request to remote sim {0}, region {1}, x={2} y={3}", 142 m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: Posted CreateAgent request to remote sim {0}, region {1}, x={2} y={3}",
143 uri, destination.RegionName, destination.RegionLocX, destination.RegionLocY); 143 uri, destination.RegionName, destination.RegionLocX, destination.RegionLocY);
144 } 144 }
145 //catch (WebException ex) 145 //catch (WebException ex)
146 catch 146 catch
147 { 147 {
148 //m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: Bad send on ChildAgentUpdate {0}", ex.Message); 148 //m_log.ErrorFormat("[REMOTE SIMULATION CONNECTOR]: Bad send on ChildAgentUpdate {0}", ex.Message);
149 reason = "cannot contact remote region"; 149 reason = "cannot contact remote region";
150 return false; 150 return false;
151 } 151 }
@@ -172,19 +172,19 @@ namespace OpenSim.Services.Connectors.Simulation
172 webResponse = AgentCreateRequest.GetResponse(); 172 webResponse = AgentCreateRequest.GetResponse();
173 if (webResponse == null) 173 if (webResponse == null)
174 { 174 {
175 m_log.Info("[REMOTE SIMULATION CONNECTOR]: Null reply on DoCreateChildAgentCall post"); 175 m_log.Debug("[REMOTE SIMULATION CONNECTOR]: Null reply on DoCreateChildAgentCall post");
176 } 176 }
177 else 177 else
178 { 178 {
179 179
180 sr = new StreamReader(webResponse.GetResponseStream()); 180 sr = new StreamReader(webResponse.GetResponseStream());
181 response = sr.ReadToEnd().Trim(); 181 response = sr.ReadToEnd().Trim();
182 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: DoCreateChildAgentCall reply was {0} ", response); 182 m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: DoCreateChildAgentCall reply was {0} ", response);
183 } 183 }
184 } 184 }
185 catch (WebException ex) 185 catch (WebException ex)
186 { 186 {
187 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of DoCreateChildAgentCall {0}", ex.Message); 187 m_log.WarnFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of DoCreateChildAgentCall {0}", ex.Message);
188 reason = "Destination did not reply"; 188 reason = "Destination did not reply";
189 return string.Empty; 189 return string.Empty;
190 } 190 }
@@ -212,7 +212,7 @@ namespace OpenSim.Services.Connectors.Simulation
212 } 212 }
213 catch (NullReferenceException e) 213 catch (NullReferenceException e)
214 { 214 {
215 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of DoCreateChildAgentCall {0}", e.Message); 215 m_log.WarnFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of DoCreateChildAgentCall {0}", e.Message);
216 216
217 // check for old style response 217 // check for old style response
218 if (response.ToLower().StartsWith("true")) 218 if (response.ToLower().StartsWith("true"))
@@ -232,7 +232,7 @@ namespace OpenSim.Services.Connectors.Simulation
232 } 232 }
233 catch (Exception e) 233 catch (Exception e)
234 { 234 {
235 m_log.Debug("[REMOTE SIMULATION CONNECTOR]: PackAgentCircuitData failed with exception: " + e.Message); 235 m_log.Warn("[REMOTE SIMULATION CONNECTOR]: PackAgentCircuitData failed with exception: " + e.Message);
236 return null; 236 return null;
237 } 237 }
238 // Add the input arguments 238 // Add the input arguments
@@ -258,6 +258,7 @@ namespace OpenSim.Services.Connectors.Simulation
258 private bool UpdateAgent(GridRegion destination, IAgentData cAgentData) 258 private bool UpdateAgent(GridRegion destination, IAgentData cAgentData)
259 { 259 {
260 // Eventually, we want to use a caps url instead of the agentID 260 // Eventually, we want to use a caps url instead of the agentID
261
261 string uri = destination.ServerURI + AgentPath() + cAgentData.AgentID + "/"; 262 string uri = destination.ServerURI + AgentPath() + cAgentData.AgentID + "/";
262 263
263 HttpWebRequest ChildUpdateRequest = (HttpWebRequest)WebRequest.Create(uri); 264 HttpWebRequest ChildUpdateRequest = (HttpWebRequest)WebRequest.Create(uri);
@@ -274,7 +275,7 @@ namespace OpenSim.Services.Connectors.Simulation
274 } 275 }
275 catch (Exception e) 276 catch (Exception e)
276 { 277 {
277 m_log.Debug("[REMOTE SIMULATION CONNECTOR]: PackUpdateMessage failed with exception: " + e.Message); 278 m_log.Warn("[REMOTE SIMULATION CONNECTOR]: PackUpdateMessage failed with exception: " + e.Message);
278 } 279 }
279 // Add the input arguments 280 // Add the input arguments
280 args["destination_x"] = OSD.FromString(destination.RegionLocX.ToString()); 281 args["destination_x"] = OSD.FromString(destination.RegionLocX.ToString());
@@ -303,12 +304,12 @@ namespace OpenSim.Services.Connectors.Simulation
303 ChildUpdateRequest.ContentLength = buffer.Length; //Count bytes to send 304 ChildUpdateRequest.ContentLength = buffer.Length; //Count bytes to send
304 os = ChildUpdateRequest.GetRequestStream(); 305 os = ChildUpdateRequest.GetRequestStream();
305 os.Write(buffer, 0, strBuffer.Length); //Send it 306 os.Write(buffer, 0, strBuffer.Length); //Send it
306 //m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: Posted AgentUpdate request to remote sim {0}", uri); 307 //m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: Posted AgentUpdate request to remote sim {0}", uri);
307 } 308 }
308 catch (WebException ex) 309 catch (WebException ex)
309 //catch 310 //catch
310 { 311 {
311 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: Bad send on AgentUpdate {0}", ex.Message); 312 m_log.WarnFormat("[REMOTE SIMULATION CONNECTOR]: Bad send on AgentUpdate {0}", ex.Message);
312 313
313 return false; 314 return false;
314 } 315 }
@@ -319,7 +320,7 @@ namespace OpenSim.Services.Connectors.Simulation
319 } 320 }
320 321
321 // Let's wait for the response 322 // Let's wait for the response
322 //m_log.Info("[REMOTE SIMULATION CONNECTOR]: Waiting for a reply after ChildAgentUpdate"); 323 //m_log.Debug("[REMOTE SIMULATION CONNECTOR]: Waiting for a reply after ChildAgentUpdate");
323 324
324 WebResponse webResponse = null; 325 WebResponse webResponse = null;
325 StreamReader sr = null; 326 StreamReader sr = null;
@@ -328,19 +329,19 @@ namespace OpenSim.Services.Connectors.Simulation
328 webResponse = ChildUpdateRequest.GetResponse(); 329 webResponse = ChildUpdateRequest.GetResponse();
329 if (webResponse == null) 330 if (webResponse == null)
330 { 331 {
331 m_log.Info("[REMOTE SIMULATION CONNECTOR]: Null reply on ChilAgentUpdate post"); 332 m_log.Debug("[REMOTE SIMULATION CONNECTOR]: Null reply on ChilAgentUpdate post");
332 } 333 }
333 334
334 sr = new StreamReader(webResponse.GetResponseStream()); 335 sr = new StreamReader(webResponse.GetResponseStream());
335 //reply = sr.ReadToEnd().Trim(); 336 //reply = sr.ReadToEnd().Trim();
336 sr.ReadToEnd().Trim(); 337 sr.ReadToEnd().Trim();
337 sr.Close(); 338 sr.Close();
338 //m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: ChilAgentUpdate reply was {0} ", reply); 339 //m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: ChilAgentUpdate reply was {0} ", reply);
339 340
340 } 341 }
341 catch (WebException ex) 342 catch (WebException ex)
342 { 343 {
343 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of ChilAgentUpdate from {0}: {1}", uri, ex.Message); 344 m_log.WarnFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of ChilAgentUpdate from {0}: {1}", uri, ex.Message);
344 // ignore, really 345 // ignore, really
345 } 346 }
346 finally 347 finally
@@ -371,7 +372,7 @@ namespace OpenSim.Services.Connectors.Simulation
371 webResponse = (HttpWebResponse)request.GetResponse(); 372 webResponse = (HttpWebResponse)request.GetResponse();
372 if (webResponse == null) 373 if (webResponse == null)
373 { 374 {
374 m_log.Info("[REMOTE SIMULATION CONNECTOR]: Null reply on agent get "); 375 m_log.Debug("[REMOTE SIMULATION CONNECTOR]: Null reply on agent get ");
375 } 376 }
376 377
377 sr = new StreamReader(webResponse.GetResponseStream()); 378 sr = new StreamReader(webResponse.GetResponseStream());
@@ -381,7 +382,7 @@ namespace OpenSim.Services.Connectors.Simulation
381 } 382 }
382 catch (WebException ex) 383 catch (WebException ex)
383 { 384 {
384 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of agent get {0}", ex.Message); 385 m_log.WarnFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of agent get {0}", ex.Message);
385 // ignore, really 386 // ignore, really
386 return false; 387 return false;
387 } 388 }
@@ -420,7 +421,7 @@ namespace OpenSim.Services.Connectors.Simulation
420 WebResponse webResponse = request.GetResponse(); 421 WebResponse webResponse = request.GetResponse();
421 if (webResponse == null) 422 if (webResponse == null)
422 { 423 {
423 m_log.Info("[REMOTE SIMULATION CONNECTOR]: Null reply on ReleaseAgent"); 424 m_log.Debug("[REMOTE SIMULATION CONNECTOR]: Null reply on ReleaseAgent");
424 } 425 }
425 426
426 sr = new StreamReader(webResponse.GetResponseStream()); 427 sr = new StreamReader(webResponse.GetResponseStream());
@@ -432,7 +433,7 @@ namespace OpenSim.Services.Connectors.Simulation
432 } 433 }
433 catch (WebException ex) 434 catch (WebException ex)
434 { 435 {
435 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of ReleaseAgent {0}", ex.Message); 436 m_log.WarnFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of ReleaseAgent {0}", ex.Message);
436 return false; 437 return false;
437 } 438 }
438 finally 439 finally
@@ -448,7 +449,6 @@ namespace OpenSim.Services.Connectors.Simulation
448 { 449 {
449 string uri = destination.ServerURI + AgentPath() + id + "/" + destination.RegionID.ToString() + "/"; 450 string uri = destination.ServerURI + AgentPath() + id + "/" + destination.RegionID.ToString() + "/";
450 451
451
452 WebRequest request = WebRequest.Create(uri); 452 WebRequest request = WebRequest.Create(uri);
453 request.Method = "DELETE"; 453 request.Method = "DELETE";
454 request.Timeout = 10000; 454 request.Timeout = 10000;
@@ -459,7 +459,7 @@ namespace OpenSim.Services.Connectors.Simulation
459 WebResponse webResponse = request.GetResponse(); 459 WebResponse webResponse = request.GetResponse();
460 if (webResponse == null) 460 if (webResponse == null)
461 { 461 {
462 m_log.Info("[REMOTE SIMULATION CONNECTOR]: Null reply on agent delete "); 462 m_log.Debug("[REMOTE SIMULATION CONNECTOR]: Null reply on agent delete ");
463 } 463 }
464 464
465 sr = new StreamReader(webResponse.GetResponseStream()); 465 sr = new StreamReader(webResponse.GetResponseStream());
@@ -471,7 +471,7 @@ namespace OpenSim.Services.Connectors.Simulation
471 } 471 }
472 catch (WebException ex) 472 catch (WebException ex)
473 { 473 {
474 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of agent delete from {0}: {1}", destination.RegionName, ex.Message); 474 m_log.WarnFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of agent delete from {0}: {1}", destination.RegionName, ex.Message);
475 return false; 475 return false;
476 } 476 }
477 finally 477 finally
@@ -536,11 +536,11 @@ namespace OpenSim.Services.Connectors.Simulation
536 ObjectCreateRequest.ContentLength = buffer.Length; //Count bytes to send 536 ObjectCreateRequest.ContentLength = buffer.Length; //Count bytes to send
537 os = ObjectCreateRequest.GetRequestStream(); 537 os = ObjectCreateRequest.GetRequestStream();
538 os.Write(buffer, 0, strBuffer.Length); //Send it 538 os.Write(buffer, 0, strBuffer.Length); //Send it
539 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: Posted CreateObject request to remote sim {0}", uri); 539 m_log.DebugFormat("[REMOTE SIMULATION CONNECTOR]: Posted CreateObject request to remote sim {0}", uri);
540 } 540 }
541 catch (WebException ex) 541 catch (WebException ex)
542 { 542 {
543 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: Bad send on CreateObject {0}", ex.Message); 543 m_log.WarnFormat("[REMOTE SIMULATION CONNECTOR]: Bad send on CreateObject {0}", ex.Message);
544 return false; 544 return false;
545 } 545 }
546 finally 546 finally
@@ -558,7 +558,7 @@ namespace OpenSim.Services.Connectors.Simulation
558 WebResponse webResponse = ObjectCreateRequest.GetResponse(); 558 WebResponse webResponse = ObjectCreateRequest.GetResponse();
559 if (webResponse == null) 559 if (webResponse == null)
560 { 560 {
561 m_log.Info("[REMOTE SIMULATION CONNECTOR]: Null reply on CreateObject post"); 561 m_log.Warn("[REMOTE SIMULATION CONNECTOR]: Null reply on CreateObject post");
562 return false; 562 return false;
563 } 563 }
564 564
@@ -570,7 +570,7 @@ namespace OpenSim.Services.Connectors.Simulation
570 } 570 }
571 catch (WebException ex) 571 catch (WebException ex)
572 { 572 {
573 m_log.InfoFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of CreateObject {0}", ex.Message); 573 m_log.WarnFormat("[REMOTE SIMULATION CONNECTOR]: exception on reply of CreateObject {0}", ex.Message);
574 return false; 574 return false;
575 } 575 }
576 finally 576 finally