From d33964222aa9e3b2e639469a32d0af4728b0f77d Mon Sep 17 00:00:00 2001
From: Justin Clark-Casey (justincc)
Date: Fri, 10 Oct 2014 23:36:50 +0100
Subject: Fix an issue where specifying both max client and server outgoing UDP
throttles would cause client throttles to be lower than expected when total
requests exceeded the scene limit.
This was because specifying a max client throttle would always request the max from the parent server throttle, no matter the actual total requests on the client throttle.
This would lead to a lower server multiplier than expected.
This change also adds a 'target' column to the "show throttles" output that shows the target rate (as set by client) if adaptive throttles is active.
This commit also re-adds the functionality lost in recent 5c1a1458 to set a max client throttle when adaptive is active.
This commit also adds TestClientThrottlePerClientAndRegionLimited and TestClientThrottleAdaptiveNoLimit regression tests
---
OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
(limited to 'OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs')
diff --git a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
index 610067e..64548f2 100644
--- a/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
+++ b/OpenSim/Region/ClientStack/Linden/UDP/LLUDPServer.cs
@@ -245,11 +245,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
/// Bandwidth throttle for this UDP server
public TokenBucket Throttle { get; private set; }
-
- ///
- /// Gets the maximum total drip rate allowed to all clients.
- ///
- public long MaxTotalDripRate { get { return Throttle.RequestedDripRate; } }
/// Per client throttle rates enforced by this server
///
@@ -452,7 +447,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
// = new TokenBucket(
// string.Format("server throttle bucket for {0}", Scene.Name), null, sceneThrottleBps);
- Throttle = new TokenBucket("server throttle bucket", null, sceneThrottleBps);
+ Throttle = new TokenBucket("server throttle bucket", null, sceneThrottleBps, sceneThrottleBps);
ThrottleRates = new ThrottleRates(configSource);
--
cgit v1.1