aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs44
1 files changed, 4 insertions, 40 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
index 059a705..567bbb5 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
@@ -402,16 +402,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
402 public int IncomingOrphanedPacketCount { get; protected set; } 402 public int IncomingOrphanedPacketCount { get; protected set; }
403 403
404 /// <summary> 404 /// <summary>
405 /// Record current outgoing client for monitoring purposes.
406 /// </summary>
407 protected IClientAPI m_currentOutgoingClient;
408
409 /// <summary>
410 /// Recording current incoming client for monitoring purposes.
411 /// </summary>
412 protected IClientAPI m_currentIncomingClient;
413
414 /// <summary>
415 /// Queue some low priority but potentially high volume async requests so that they don't overwhelm available 405 /// Queue some low priority but potentially high volume async requests so that they don't overwhelm available
416 /// threadpool threads. 406 /// threadpool threads.
417 /// </summary> 407 /// </summary>
@@ -548,7 +538,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
548 ThreadPriority.Normal, 538 ThreadPriority.Normal,
549 true, 539 true,
550 true, 540 true,
551 GetWatchdogIncomingAlarmData, 541 null,
552 Watchdog.DEFAULT_WATCHDOG_TIMEOUT_MS); 542 Watchdog.DEFAULT_WATCHDOG_TIMEOUT_MS);
553 } 543 }
554 544
@@ -564,7 +554,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
564 ThreadPriority.Normal, 554 ThreadPriority.Normal,
565 true, 555 true,
566 true, 556 true,
567 GetWatchdogOutgoingAlarmData, 557 null,
568 Watchdog.DEFAULT_WATCHDOG_TIMEOUT_MS); 558 Watchdog.DEFAULT_WATCHDOG_TIMEOUT_MS);
569 } 559 }
570 560
@@ -654,27 +644,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP
654 m_incomingPacketPoolStat = null; 644 m_incomingPacketPoolStat = null;
655 } 645 }
656 646
657 /// <summary> 647 /// <summary>
658 /// If the outgoing UDP thread times out, then return client that was being processed to help with debugging. 648 /// If the outgoing UDP thread times out, then return client that was being processed to help with debugging.
659 /// </summary> 649 /// </summary>
660 /// <returns></returns> 650 /// <returns></returns>
661 protected string GetWatchdogIncomingAlarmData()
662 {
663 return string.Format(
664 "Client is {0}",
665 m_currentIncomingClient != null ? m_currentIncomingClient.Name : "none");
666 }
667
668 /// <summary>
669 /// If the outgoing UDP thread times out, then return client that was being processed to help with debugging.
670 /// </summary>
671 /// <returns></returns>
672 protected string GetWatchdogOutgoingAlarmData()
673 {
674 return string.Format(
675 "Client is {0}",
676 m_currentOutgoingClient != null ? m_currentOutgoingClient.Name : "none");
677 }
678 651
679 public void AddScene(IScene scene) 652 public void AddScene(IScene scene)
680 { 653 {
@@ -2106,8 +2079,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
2106 // client. m_packetSent will be set to true if a packet is sent 2079 // client. m_packetSent will be set to true if a packet is sent
2107 Scene.ForEachClient(clientPacketHandler); 2080 Scene.ForEachClient(clientPacketHandler);
2108 2081
2109 m_currentOutgoingClient = null;
2110
2111 // If nothing was sent, sleep for the minimum amount of time before a 2082 // If nothing was sent, sleep for the minimum amount of time before a
2112 // token bucket could get more tokens 2083 // token bucket could get more tokens
2113 2084
@@ -2132,8 +2103,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
2132 2103
2133 protected void ClientOutgoingPacketHandler(IClientAPI client) 2104 protected void ClientOutgoingPacketHandler(IClientAPI client)
2134 { 2105 {
2135 m_currentOutgoingClient = client;
2136
2137 try 2106 try
2138 { 2107 {
2139 if (client is LLClientView) 2108 if (client is LLClientView)
@@ -2163,6 +2132,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
2163 m_log.Error( 2132 m_log.Error(
2164 string.Format("[LLUDPSERVER]: OutgoingPacketHandler iteration for {0} threw ", client.Name), ex); 2133 string.Format("[LLUDPSERVER]: OutgoingPacketHandler iteration for {0} threw ", client.Name), ex);
2165 } 2134 }
2135 client = null;
2166 } 2136 }
2167 2137
2168 #region Emergency Monitoring 2138 #region Emergency Monitoring
@@ -2198,8 +2168,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
2198 if(!client.IsActive) 2168 if(!client.IsActive)
2199 return; 2169 return;
2200 2170
2201 m_currentIncomingClient = client;
2202
2203 try 2171 try
2204 { 2172 {
2205 // Process this packet 2173 // Process this packet
@@ -2220,10 +2188,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
2220 client.Name,packet.Type), 2188 client.Name,packet.Type),
2221 e); 2189 e);
2222 } 2190 }
2223 finally
2224 {
2225 m_currentIncomingClient = null;
2226 }
2227 2191
2228 IncomingPacketsProcessed++; 2192 IncomingPacketsProcessed++;
2229 } 2193 }