aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorRobert Adams2013-08-08 09:41:11 -0700
committerRobert Adams2013-08-08 09:45:30 -0700
commitd9bd6e6b5be3100141a3b1202f859c65a302d4ee (patch)
treef44a5a4cb944270ce90c0e61da473171609c7792 /OpenSim
parentBetter error reporting when registering LSL function extensions (comms module). (diff)
downloadopensim-SC_OLD-d9bd6e6b5be3100141a3b1202f859c65a302d4ee.zip
opensim-SC_OLD-d9bd6e6b5be3100141a3b1202f859c65a302d4ee.tar.gz
opensim-SC_OLD-d9bd6e6b5be3100141a3b1202f859c65a302d4ee.tar.bz2
opensim-SC_OLD-d9bd6e6b5be3100141a3b1202f859c65a302d4ee.tar.xz
Add parameter and explanation of ManagedStats return to OpenSimDefaults.ini.
Add 'callback' query parameter to managed stats return to return function form of JSON data.
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Framework/Monitoring/StatsManager.cs6
-rw-r--r--OpenSim/Region/Application/OpenSim.cs4
2 files changed, 8 insertions, 2 deletions
diff --git a/OpenSim/Framework/Monitoring/StatsManager.cs b/OpenSim/Framework/Monitoring/StatsManager.cs
index 23c6f18..7cf1fa7 100644
--- a/OpenSim/Framework/Monitoring/StatsManager.cs
+++ b/OpenSim/Framework/Monitoring/StatsManager.cs
@@ -281,6 +281,12 @@ namespace OpenSim.Framework.Monitoring
281 281
282 string strOut = StatsManager.GetStatsAsOSDMap(pCategoryName, pContainerName, pStatName).ToString(); 282 string strOut = StatsManager.GetStatsAsOSDMap(pCategoryName, pContainerName, pStatName).ToString();
283 283
284 // If requestor wants it as a callback function, build response as a function rather than just the JSON string.
285 if (request.ContainsKey("callback"))
286 {
287 strOut = request["callback"].ToString() + "(" + strOut + ");";
288 }
289
284 // m_log.DebugFormat("{0} StatFetch: uri={1}, cat={2}, cont={3}, stat={4}, resp={5}", 290 // m_log.DebugFormat("{0} StatFetch: uri={1}, cat={2}, cont={3}, stat={4}, resp={5}",
285 // LogHeader, regpath, pCategoryName, pContainerName, pStatName, strOut); 291 // LogHeader, regpath, pCategoryName, pContainerName, pStatName, strOut);
286 292
diff --git a/OpenSim/Region/Application/OpenSim.cs b/OpenSim/Region/Application/OpenSim.cs
index 13fdb3b..1cdd868 100644
--- a/OpenSim/Region/Application/OpenSim.cs
+++ b/OpenSim/Region/Application/OpenSim.cs
@@ -175,8 +175,8 @@ namespace OpenSim
175 if (managedStatsURI != String.Empty) 175 if (managedStatsURI != String.Empty)
176 { 176 {
177 string urlBase = String.Format("/{0}/", managedStatsURI); 177 string urlBase = String.Format("/{0}/", managedStatsURI);
178 MainServer.Instance.AddHTTPHandler(urlBase, StatsManager.HandleStatsRequest); 178 MainServer.Instance.AddHTTPHandler(urlBase, StatsManager.HandleStatsRequest);
179 m_log.WarnFormat("[OPENSIM] Enabling remote managed stats fetch. URL = {0}", urlBase); 179 m_log.InfoFormat("[OPENSIM] Enabling remote managed stats fetch. URL = {0}", urlBase);
180 } 180 }
181 181
182 if (m_console is RemoteConsole) 182 if (m_console is RemoteConsole)