From 7f000ea88e3fb09ae1e6cb725ff6c32bef03e3bd Mon Sep 17 00:00:00 2001
From: Justin Clark-Casey (justincc)
Date: Wed, 19 Jan 2011 00:33:25 +0000
Subject: Correct "show queues" to show queued packet numbers for each client
instead of bytes.
Byte amounts aren't actually available - this was a misunderstanding of TokenBucket.Content. But raw packet numbers are.
---
OpenSim/Region/ClientStack/LindenUDP/LLUDPClient.cs | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
(limited to 'OpenSim/Region/ClientStack/LindenUDP')
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLUDPClient.cs b/OpenSim/Region/ClientStack/LindenUDP/LLUDPClient.cs
index e02783a..d4c3307 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLUDPClient.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLUDPClient.cs
@@ -256,18 +256,18 @@ namespace OpenSim.Region.ClientStack.LindenUDP
public string GetStats()
{
return string.Format(
- "{0,9} {1,9} {2,9} {3,8} {4,7} {5,7} {6,7} {7,7} {8,9} {9,7} {10,7}",
+ "{0,7} {1,7} {2,9} {3,8} {4,7} {5,7} {6,7} {7,7} {8,9} {9,7} {10,7}",
PacketsSent,
PacketsReceived,
UnackedBytes,
- m_throttleCategories[(int)ThrottleOutPacketType.Resend].Content,
- m_throttleCategories[(int)ThrottleOutPacketType.Land].Content,
- m_throttleCategories[(int)ThrottleOutPacketType.Wind].Content,
- m_throttleCategories[(int)ThrottleOutPacketType.Cloud].Content,
- m_throttleCategories[(int)ThrottleOutPacketType.Task].Content,
- m_throttleCategories[(int)ThrottleOutPacketType.Texture].Content,
- m_throttleCategories[(int)ThrottleOutPacketType.Asset].Content,
- m_throttleCategories[(int)ThrottleOutPacketType.State].Content);
+ m_packetOutboxes[(int)ThrottleOutPacketType.Resend].Count,
+ m_packetOutboxes[(int)ThrottleOutPacketType.Land].Count,
+ m_packetOutboxes[(int)ThrottleOutPacketType.Wind].Count,
+ m_packetOutboxes[(int)ThrottleOutPacketType.Cloud].Count,
+ m_packetOutboxes[(int)ThrottleOutPacketType.Task].Count,
+ m_packetOutboxes[(int)ThrottleOutPacketType.Texture].Count,
+ m_packetOutboxes[(int)ThrottleOutPacketType.Asset].Count,
+ m_packetOutboxes[(int)ThrottleOutPacketType.State].Count);
}
public void SendPacketStats()
--
cgit v1.1
From c383dbd06dd98ca96543c9bfdf9a7376a7e55cc2 Mon Sep 17 00:00:00 2001
From: Justin Clark-Casey (justincc)
Date: Fri, 21 Jan 2011 00:38:16 +0000
Subject: implement "show throttles" command for showing current agent
throttles and the server settings.
This is in a very crude state, currently.
The LindenUDPModule was renamed LindenUDPInfoModule and moved to OptionalModules
OptionalModules was given a direct reference to OpenSim.Region.ClientStack.LindenUDP so that it can inspect specific LindenUDP settings without having to generalize those to all client views (some of which may have no concept of the settings involved).
This might be ess messy if OpenSim.Region.ClientStack.LindenUDP were a region module instead, like MXP, IRC and NPC
---
OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs | 1 +
OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs | 8 +++++---
2 files changed, 6 insertions(+), 3 deletions(-)
(limited to 'OpenSim/Region/ClientStack/LindenUDP')
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
index e43e3c9..5dab1bc 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
@@ -368,6 +368,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
#region Properties
public LLUDPClient UDPClient { get { return m_udpClient; } }
+ public LLUDPServer UDPServer { get { return m_udpServer; } }
public IPEndPoint RemoteEndPoint { get { return m_udpClient.RemoteEndPoint; } }
public UUID SecureSessionId { get { return m_secureSessionId; } }
public IScene Scene { get { return m_scene; } }
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs b/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs
index 571624b..df8ddbb 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs
@@ -114,8 +114,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP
//private UDPClientCollection m_clients = new UDPClientCollection();
/// Bandwidth throttle for this UDP server
protected TokenBucket m_throttle;
+
/// Bandwidth throttle rates for this UDP server
- protected ThrottleRates m_throttleRates;
+ public ThrottleRates ThrottleRates { get; private set; }
+
/// Manages authentication for agent circuits
private AgentCircuitManager m_circuitManager;
/// Reference to the scene this UDP server is attached to
@@ -226,7 +228,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
#endregion BinaryStats
m_throttle = new TokenBucket(null, sceneThrottleBps, sceneThrottleBps);
- m_throttleRates = new ThrottleRates(configSource);
+ ThrottleRates = new ThrottleRates(configSource);
}
public void Start()
@@ -922,7 +924,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP
protected virtual void AddClient(uint circuitCode, UUID agentID, UUID sessionID, IPEndPoint remoteEndPoint, AuthenticateResponse sessionInfo)
{
// Create the LLUDPClient
- LLUDPClient udpClient = new LLUDPClient(this, m_throttleRates, m_throttle, circuitCode, agentID, remoteEndPoint, m_defaultRTO, m_maxRTO);
+ LLUDPClient udpClient = new LLUDPClient(this, ThrottleRates, m_throttle, circuitCode, agentID, remoteEndPoint, m_defaultRTO, m_maxRTO);
IClientAPI existingClient;
if (!m_scene.TryGetClient(agentID, out existingClient))
--
cgit v1.1