mirror of
https://github.com/opensim/opensim.git
synced 2026-08-11 03:45:35 +08:00
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.
This commit is contained in:
@@ -281,6 +281,12 @@ namespace OpenSim.Framework.Monitoring
|
||||
|
||||
string strOut = StatsManager.GetStatsAsOSDMap(pCategoryName, pContainerName, pStatName).ToString();
|
||||
|
||||
// If requestor wants it as a callback function, build response as a function rather than just the JSON string.
|
||||
if (request.ContainsKey("callback"))
|
||||
{
|
||||
strOut = request["callback"].ToString() + "(" + strOut + ");";
|
||||
}
|
||||
|
||||
// m_log.DebugFormat("{0} StatFetch: uri={1}, cat={2}, cont={3}, stat={4}, resp={5}",
|
||||
// LogHeader, regpath, pCategoryName, pContainerName, pStatName, strOut);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user