From afab4b276ebc87f70307ac65e158bb3489d7634b Mon Sep 17 00:00:00 2001 From: Melanie Date: Mon, 12 Dec 2011 13:51:31 +0100 Subject: Remove spammy log messages when querying sim health --- .../RemoteController/RemoteAdminPlugin.cs | 8 -------- OpenSim/Region/Framework/Scenes/Scene.cs | 16 ++++++++++++++-- 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs b/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs index 7a1956f..2930753 100644 --- a/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs +++ b/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs @@ -1724,8 +1724,6 @@ namespace OpenSim.ApplicationPlugins.RemoteController private void XmlRpcRegionQueryMethod(XmlRpcRequest request, XmlRpcResponse response, IPEndPoint remoteClient) { - m_log.Info("[RADMIN]: Received Query XML Administrator Request"); - Hashtable responseData = (Hashtable)response.Value; Hashtable requestData = (Hashtable)request.Params[0]; @@ -1736,16 +1734,12 @@ namespace OpenSim.ApplicationPlugins.RemoteController UUID region_uuid = (UUID) (string) requestData["region_uuid"]; if (!m_application.SceneManager.TrySetCurrentScene(region_uuid)) throw new Exception(String.Format("failed to switch to region {0}", region_uuid.ToString())); - - m_log.InfoFormat("[RADMIN]: Switched to region {0}", region_uuid.ToString()); } else if (requestData.Contains("region_name")) { string region_name = (string) requestData["region_name"]; if (!m_application.SceneManager.TrySetCurrentScene(region_name)) throw new Exception(String.Format("failed to switch to region {0}", region_name)); - - m_log.InfoFormat("[RADMIN]: Switched to region {0}", region_name); } else { @@ -1760,8 +1754,6 @@ namespace OpenSim.ApplicationPlugins.RemoteController responseData["health"] = health; responseData["flags"] = flags; responseData["message"] = text; - - m_log.Info("[RADMIN]: Query XML Administrator Request complete"); } private void XmlRpcConsoleCommandMethod(XmlRpcRequest request, XmlRpcResponse response, IPEndPoint remoteClient) diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index ad2192d..bfabcc2 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs @@ -1171,8 +1171,8 @@ namespace OpenSim.Region.Framework.Scenes if(m_hbRestarts > 10) Environment.Exit(1); m_log.ErrorFormat("[SCENE]: Restarting heartbeat thread because it hasn't reported in in region {0}", RegionInfo.RegionName); - int pid = System.Diagnostics.Process.GetCurrentProcess().Id; - + +//int pid = System.Diagnostics.Process.GetCurrentProcess().Id; //System.Diagnostics.Process proc = new System.Diagnostics.Process(); //proc.EnableRaisingEvents=false; //proc.StartInfo.FileName = "/bin/kill"; @@ -4630,6 +4630,18 @@ namespace OpenSim.Region.Framework.Scenes health+=1; flags |= 4; } + else + { +int pid = System.Diagnostics.Process.GetCurrentProcess().Id; +System.Diagnostics.Process proc = new System.Diagnostics.Process(); +proc.EnableRaisingEvents=false; +proc.StartInfo.FileName = "/bin/kill"; +proc.StartInfo.Arguments = "-QUIT " + pid.ToString(); +proc.Start(); +proc.WaitForExit(); +Thread.Sleep(1000); +Environment.Exit(1); + } if (flags != 7) return health; -- cgit v1.1