From e175cf543ca532ba1ffc3abb7f076c000e2f529e Mon Sep 17 00:00:00 2001 From: "Justin Clark-Casey (justincc)" Date: Fri, 12 Oct 2012 00:26:15 +0100 Subject: [PATCH] Fix percentage stats to multiply by 100. Adjust container name for packetpool stats. --- OpenSim/Framework/Monitoring/StatsManager.cs | 4 ++-- OpenSim/Region/ClientStack/Linden/UDP/PacketPool.cs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/OpenSim/Framework/Monitoring/StatsManager.cs b/OpenSim/Framework/Monitoring/StatsManager.cs index d7aff034d2..31989e50ad 100644 --- a/OpenSim/Framework/Monitoring/StatsManager.cs +++ b/OpenSim/Framework/Monitoring/StatsManager.cs @@ -351,7 +351,7 @@ namespace OpenSim.Framework.Monitoring if (c == 0) return 0; - return (double)Antecedent / c; + return (double)Antecedent / c * 100; } set @@ -367,7 +367,7 @@ namespace OpenSim.Framework.Monitoring public override string ToConsoleString() { return string.Format( - "{0}.{1}.{2} : {3:0.###}{4} ({5}/{6})", + "{0}.{1}.{2} : {3:0.##}{4} ({5}/{6})", Category, Container, ShortName, Value, UnitName, Antecedent, Consequent); } } diff --git a/OpenSim/Region/ClientStack/Linden/UDP/PacketPool.cs b/OpenSim/Region/ClientStack/Linden/UDP/PacketPool.cs index fd6b0eda47..a8a1bfe9d4 100644 --- a/OpenSim/Region/ClientStack/Linden/UDP/PacketPool.cs +++ b/OpenSim/Region/ClientStack/Linden/UDP/PacketPool.cs @@ -48,14 +48,14 @@ namespace OpenSim.Region.ClientStack.LindenUDP "PacketsReused", "Packets reused", "clientstack", - "simulator", + "packetpool", StatVerbosity.Debug, "Number of packets reused out of all requests to the packet pool"); private PercentageStat m_blocksReusedStat = new PercentageStat( "BlocksReused", "Blocks reused", - "clientstack", + "packetpool", "simulator", StatVerbosity.Debug, "Number of data blocks reused out of all requests to the packet pool");