* Added the "show connections" command to print out all of the currently tracked IClientAPIs

prioritization
John Hurliman 2009-10-14 13:00:42 -07:00
parent c033477d2f
commit 25878d6828
1 changed files with 23 additions and 1 deletions

View File

@ -239,6 +239,10 @@ namespace OpenSim
"show users [full]",
"Show user data", HandleShow);
m_console.Commands.AddCommand("region", false, "show connections",
"show connections",
"Show connection data", HandleShow);
m_console.Commands.AddCommand("region", false, "show users full",
"show users full",
String.Empty, HandleShow);
@ -921,7 +925,25 @@ namespace OpenSim
regionName));
}
m_log.Info("");
m_log.Info(String.Empty);
break;
case "connections":
System.Text.StringBuilder connections = new System.Text.StringBuilder("Connections:\n");
m_sceneManager.ForEachScene(
delegate(Scene scene)
{
scene.ClientManager.ForEach(
delegate(IClientAPI client)
{
connections.AppendFormat("{0}: {1} ({2}) from {3} on circuit {4}\n",
scene.RegionInfo.RegionName, client.Name, client.AgentId, client.RemoteEndPoint, client.CircuitCode);
}
);
}
);
m_log.Info(connections.ToString());
break;
case "modules":