aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs36
1 files changed, 36 insertions, 0 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
index e45de51..9757d35 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
@@ -774,6 +774,14 @@ namespace OpenSim.Region.ClientStack.LindenUDP
774 MainConsole.Instance.Commands.AddCommand( 774 MainConsole.Instance.Commands.AddCommand(
775 "Debug", 775 "Debug",
776 false, 776 false,
777 "debug lludp throttle status",
778 "debug lludp throttle status <avatar-first-name> <avatar-last-name>",
779 "Return status information about throttles.",
780 HandleThrottleStatusCommand);
781
782 MainConsole.Instance.Commands.AddCommand(
783 "Debug",
784 false,
777 "debug lludp toggle agentupdate", 785 "debug lludp toggle agentupdate",
778 "debug lludp toggle agentupdate", 786 "debug lludp toggle agentupdate",
779 "Toggle whether agentupdate packets are processed or simply discarded.", 787 "Toggle whether agentupdate packets are processed or simply discarded.",
@@ -842,6 +850,34 @@ namespace OpenSim.Region.ClientStack.LindenUDP
842 }); 850 });
843 } 851 }
844 852
853 private void HandleThrottleStatusCommand(string module, string[] args)
854 {
855 if (SceneManager.Instance.CurrentScene != null && SceneManager.Instance.CurrentScene != Scene)
856 return;
857
858 if (args.Length != 6)
859 {
860 MainConsole.Instance.OutputFormat("Usage: debug lludp throttle status <avatar-first-name> <avatar-last-name>");
861 return;
862 }
863
864 string firstName = args[4];
865 string lastName = args[5];
866
867 Scene.ForEachScenePresence(sp =>
868 {
869 if (sp.Firstname == firstName && sp.Lastname == lastName)
870 {
871 MainConsole.Instance.OutputFormat(
872 "Status for {0} ({1}) in {2}",
873 sp.Name, sp.IsChildAgent ? "child" : "root", Scene.Name);
874
875 LLUDPClient udpClient = ((LLClientView)sp.ControllingClient).UDPClient;
876 MainConsole.Instance.OutputFormat("Adaptive throttle: {0}", udpClient.FlowThrottle.Enabled);
877 }
878 });
879 }
880
845 private void HandlePacketCommand(string module, string[] args) 881 private void HandlePacketCommand(string module, string[] args)
846 { 882 {
847 if (SceneManager.Instance.CurrentScene != null && SceneManager.Instance.CurrentScene != Scene) 883 if (SceneManager.Instance.CurrentScene != null && SceneManager.Instance.CurrentScene != Scene)