aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServerCommands.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/ClientStack/Linden/UDP/LLUDPServerCommands.cs')
-rw-r--r--OpenSim/Region/ClientStack/Linden/UDP/LLUDPServerCommands.cs46
1 files changed, 46 insertions, 0 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServerCommands.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServerCommands.cs
index e0398d5..17a394d 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServerCommands.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServerCommands.cs
@@ -186,6 +186,15 @@ namespace OpenSim.Region.ClientStack.LindenUDP
186 "debug lludp toggle agentupdate", 186 "debug lludp toggle agentupdate",
187 "Toggle whether agentupdate packets are processed or simply discarded.", 187 "Toggle whether agentupdate packets are processed or simply discarded.",
188 HandleAgentUpdateCommand); 188 HandleAgentUpdateCommand);
189
190 MainConsole.Instance.Commands.AddCommand(
191 "Debug",
192 false,
193 "debug lludp oqre",
194 "debug lludp oqre <start|stop|status>",
195 "Start, stop or get status of OutgoingQueueRefillEngine.",
196 "If stopped then refill requests are processed directly via the threadpool.",
197 HandleOqreCommand);
189 } 198 }
190 199
191 private void HandleShowServerThrottlesCommand(string module, string[] args) 200 private void HandleShowServerThrottlesCommand(string module, string[] args)
@@ -758,5 +767,42 @@ namespace OpenSim.Region.ClientStack.LindenUDP
758 MainConsole.Instance.OutputFormat( 767 MainConsole.Instance.OutputFormat(
759 "Packet debug level for new clients is {0}", m_udpServer.DefaultClientPacketDebugLevel); 768 "Packet debug level for new clients is {0}", m_udpServer.DefaultClientPacketDebugLevel);
760 } 769 }
770
771 private void HandleOqreCommand(string module, string[] args)
772 {
773 if (SceneManager.Instance.CurrentScene != null && SceneManager.Instance.CurrentScene != m_udpServer.Scene)
774 return;
775
776 if (args.Length != 4)
777 {
778 MainConsole.Instance.Output("Usage: debug lludp oqre <stop|start|status>");
779 return;
780 }
781
782 string subCommand = args[3];
783
784 if (subCommand == "stop")
785 {
786 m_udpServer.OqrEngine.Stop();
787 MainConsole.Instance.OutputFormat("Stopped OQRE for {0}", m_udpServer.Scene.Name);
788 }
789 else if (subCommand == "start")
790 {
791 m_udpServer.OqrEngine.Start();
792 MainConsole.Instance.OutputFormat("Started OQRE for {0}", m_udpServer.Scene.Name);
793 }
794 else if (subCommand == "status")
795 {
796 MainConsole.Instance.OutputFormat("OQRE in {0}", m_udpServer.Scene.Name);
797 MainConsole.Instance.OutputFormat("Running: {0}", m_udpServer.OqrEngine.IsRunning);
798 MainConsole.Instance.OutputFormat(
799 "Requests waiting: {0}",
800 m_udpServer.OqrEngine.IsRunning ? m_udpServer.OqrEngine.JobsWaiting.ToString() : "n/a");
801 }
802 else
803 {
804 MainConsole.Instance.OutputFormat("Unrecognized OQRE subcommand {0}", subCommand);
805 }
806 }
761 } 807 }
762} \ No newline at end of file 808} \ No newline at end of file