aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2013-07-22 23:30:09 +0100
committerJustin Clark-Casey (justincc)2013-07-23 00:35:09 +0100
commitbf517899a7a63278d4ed22d5485c37d61d47bb58 (patch)
tree0deda695b605f06cde0e7e404cad0e6287749723 /OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
parentAdded check for user movement specification before discarding an incoming (diff)
downloadopensim-SC-bf517899a7a63278d4ed22d5485c37d61d47bb58.zip
opensim-SC-bf517899a7a63278d4ed22d5485c37d61d47bb58.tar.gz
opensim-SC-bf517899a7a63278d4ed22d5485c37d61d47bb58.tar.bz2
opensim-SC-bf517899a7a63278d4ed22d5485c37d61d47bb58.tar.xz
Add AverageUDPProcessTime stat to try and get a handle on how long we're taking on the initial processing of a UDP packet.
If we're not receiving packets with multiple threads (m_asyncPacketHandling) then this is critical since it will limit the number of incoming UDP requests that the region can handle and affects packet loss. If m_asyncPacketHandling then this is less critical though a long process will increase the scope for threads to race. This is an experimental stat which may be changed.
Diffstat (limited to 'OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs')
-rw-r--r--OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs19
1 files changed, 17 insertions, 2 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
index f5c0b05..d3823f3 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
@@ -70,8 +70,8 @@ namespace OpenSim.Region.ClientStack.LindenUDP
70 StatsManager.RegisterStat( 70 StatsManager.RegisterStat(
71 new Stat( 71 new Stat(
72 "IncomingPacketsProcessedCount", 72 "IncomingPacketsProcessedCount",
73 "Number of inbound UDP packets processed", 73 "Number of inbound LL protocol packets processed",
74 "Number of inbound UDP packets processed", 74 "Number of inbound LL protocol packets processed",
75 "", 75 "",
76 "clientstack", 76 "clientstack",
77 scene.Name, 77 scene.Name,
@@ -79,6 +79,21 @@ namespace OpenSim.Region.ClientStack.LindenUDP
79 MeasuresOfInterest.AverageChangeOverTime, 79 MeasuresOfInterest.AverageChangeOverTime,
80 stat => stat.Value = m_udpServer.IncomingPacketsProcessed, 80 stat => stat.Value = m_udpServer.IncomingPacketsProcessed,
81 StatVerbosity.Debug)); 81 StatVerbosity.Debug));
82
83 StatsManager.RegisterStat(
84 new Stat(
85 "AverageUDPProcessTime",
86 "Average number of milliseconds taken to process each incoming UDP packet in a sample.",
87 "This is for initial receive processing which is separate from the later client LL packet processing stage.",
88 "ms",
89 "clientstack",
90 scene.Name,
91 StatType.Pull,
92 MeasuresOfInterest.None,
93 stat => stat.Value = m_udpServer.AverageReceiveTicksForLastSamplePeriod / TimeSpan.TicksPerMillisecond,
94// stat =>
95// stat.Value = Math.Round(m_udpServer.AverageReceiveTicksForLastSamplePeriod / TimeSpan.TicksPerMillisecond, 7),
96 StatVerbosity.Debug));
82 } 97 }
83 98
84 public bool HandlesRegion(Location x) 99 public bool HandlesRegion(Location x)