From 7356860b487febd12c2e0de2f009a6df9ea0aeec Mon Sep 17 00:00:00 2001 From: Diva Canto Date: Wed, 13 Jan 2010 09:17:30 -0800 Subject: Several more buglets removed. --- .../Server/Handlers/Simulation/AgentHandlers.cs | 12 ++++---- .../Server/Handlers/Simulation/ObjectHandlers.cs | 35 ++++++++++++++-------- 2 files changed, 28 insertions(+), 19 deletions(-) (limited to 'OpenSim/Server/Handlers/Simulation') diff --git a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs index 782034b..da9c015 100644 --- a/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs +++ b/OpenSim/Server/Handlers/Simulation/AgentHandlers.cs @@ -61,11 +61,11 @@ namespace OpenSim.Server.Handlers.Simulation { //m_log.Debug("[CONNECTION DEBUGGING]: AgentHandler Called"); - m_log.Debug("---------------------------"); - m_log.Debug(" >> uri=" + request["uri"]); - m_log.Debug(" >> content-type=" + request["content-type"]); - m_log.Debug(" >> http-method=" + request["http-method"]); - m_log.Debug("---------------------------\n"); + //m_log.Debug("---------------------------"); + //m_log.Debug(" >> uri=" + request["uri"]); + //m_log.Debug(" >> content-type=" + request["content-type"]); + //m_log.Debug(" >> http-method=" + request["http-method"]); + //m_log.Debug("---------------------------\n"); Hashtable responsedata = new Hashtable(); responsedata["content_type"] = "text/html"; @@ -320,7 +320,7 @@ namespace OpenSim.Server.Handlers.Simulation responsedata["int_response_code"] = HttpStatusCode.OK; responsedata["str_response_string"] = "OpenSim agent " + id.ToString(); - m_log.Debug("[AGENT HANDLER]: Agent Deleted."); + m_log.Debug("[AGENT HANDLER]: Agent Released/Deleted."); } } diff --git a/OpenSim/Server/Handlers/Simulation/ObjectHandlers.cs b/OpenSim/Server/Handlers/Simulation/ObjectHandlers.cs index 995a3c4..b6eabe3 100644 --- a/OpenSim/Server/Handlers/Simulation/ObjectHandlers.cs +++ b/OpenSim/Server/Handlers/Simulation/ObjectHandlers.cs @@ -59,13 +59,13 @@ namespace OpenSim.Server.Handlers.Simulation public Hashtable Handler(Hashtable request) { - m_log.Debug("[CONNECTION DEBUGGING]: ObjectHandler Called"); + //m_log.Debug("[CONNECTION DEBUGGING]: ObjectHandler Called"); - m_log.Debug("---------------------------"); - m_log.Debug(" >> uri=" + request["uri"]); - m_log.Debug(" >> content-type=" + request["content-type"]); - m_log.Debug(" >> http-method=" + request["http-method"]); - m_log.Debug("---------------------------\n"); + //m_log.Debug("---------------------------"); + //m_log.Debug(" >> uri=" + request["uri"]); + //m_log.Debug(" >> content-type=" + request["content-type"]); + //m_log.Debug(" >> http-method=" + request["http-method"]); + //m_log.Debug("---------------------------\n"); Hashtable responsedata = new Hashtable(); responsedata["content_type"] = "text/html"; @@ -75,7 +75,7 @@ namespace OpenSim.Server.Handlers.Simulation string action; if (!Utils.GetParams((string)request["uri"], out objectID, out regionID, out action)) { - m_log.InfoFormat("[REST COMMS]: Invalid parameters for object message {0}", request["uri"]); + m_log.InfoFormat("[OBJECT HANDLER]: Invalid parameters for object message {0}", request["uri"]); responsedata["int_response_code"] = 404; responsedata["str_response_string"] = "false"; @@ -101,7 +101,7 @@ namespace OpenSim.Server.Handlers.Simulation //} else { - m_log.InfoFormat("[REST COMMS]: method {0} not supported in object message", method); + m_log.InfoFormat("[OBJECT HANDLER]: method {0} not supported in object message", method); responsedata["int_response_code"] = HttpStatusCode.MethodNotAllowed; responsedata["str_response_string"] = "Mthod not allowed"; @@ -148,13 +148,13 @@ namespace OpenSim.Server.Handlers.Simulation ISceneObject sog = null; try { - //sog = SceneObjectSerializer.FromXml2Format(sogXmlStr); + //m_log.DebugFormat("[OBJECT HANDLER]: received {0}", sogXmlStr); sog = s.DeserializeObject(sogXmlStr); sog.ExtraFromXmlString(extraStr); } catch (Exception ex) { - m_log.InfoFormat("[REST COMMS]: exception on deserializing scene object {0}", ex.Message); + m_log.InfoFormat("[OBJECT HANDLER]: exception on deserializing scene object {0}", ex.Message); responsedata["int_response_code"] = HttpStatusCode.BadRequest; responsedata["str_response_string"] = "Bad request"; return; @@ -171,13 +171,22 @@ namespace OpenSim.Server.Handlers.Simulation } catch (Exception ex) { - m_log.InfoFormat("[REST COMMS]: exception on setting state for scene object {0}", ex.Message); + m_log.InfoFormat("[OBJECT HANDLER]: exception on setting state for scene object {0}", ex.Message); // ignore and continue } } } - // This is the meaning of POST object - bool result = m_SimulationService.CreateObject(destination, sog, false); + + bool result = false; + try + { + // This is the meaning of POST object + result = m_SimulationService.CreateObject(destination, sog, false); + } + catch (Exception e) + { + m_log.DebugFormat("[OBJECT HANDLER]: Exception in CreateObject: {0}", e.StackTrace); + } responsedata["int_response_code"] = HttpStatusCode.OK; responsedata["str_response_string"] = result.ToString(); -- cgit v1.1