restore higher resolution clock on udpserver and lower uaeraccouts caching time
parent
d8812ba2d1
commit
e281876ecd
|
@ -323,10 +323,10 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
protected int m_elapsedMSSinceLastStatReport = 0;
|
protected int m_elapsedMSSinceLastStatReport = 0;
|
||||||
|
|
||||||
/// <summary>Environment.TickCount of the last time the outgoing packet handler executed</summary>
|
/// <summary>Environment.TickCount of the last time the outgoing packet handler executed</summary>
|
||||||
protected int m_tickLastOutgoingPacketHandler;
|
protected double m_tickLastOutgoingPacketHandler;
|
||||||
|
|
||||||
/// <summary>Keeps track of the number of elapsed milliseconds since the last time the outgoing packet handler looped</summary>
|
/// <summary>Keeps track of the number of elapsed milliseconds since the last time the outgoing packet handler looped</summary>
|
||||||
protected int m_elapsedMSOutgoingPacketHandler;
|
protected double m_elapsedMSOutgoingPacketHandler;
|
||||||
|
|
||||||
/// <summary>Keeps track of the number of 100 millisecond periods elapsed in the outgoing packet handler executed</summary>
|
/// <summary>Keeps track of the number of 100 millisecond periods elapsed in the outgoing packet handler executed</summary>
|
||||||
protected int m_elapsed100MSOutgoingPacketHandler;
|
protected int m_elapsed100MSOutgoingPacketHandler;
|
||||||
|
@ -2073,21 +2073,17 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
m_sendPing = false;
|
m_sendPing = false;
|
||||||
|
|
||||||
// Update elapsed time
|
// Update elapsed time
|
||||||
int thisTick = Environment.TickCount & Int32.MaxValue;
|
double thisTick = Util.GetTimeStampMS();
|
||||||
if (m_tickLastOutgoingPacketHandler > thisTick)
|
|
||||||
m_elapsedMSOutgoingPacketHandler += ((Int32.MaxValue - m_tickLastOutgoingPacketHandler) + thisTick);
|
|
||||||
else
|
|
||||||
m_elapsedMSOutgoingPacketHandler += (thisTick - m_tickLastOutgoingPacketHandler);
|
|
||||||
|
|
||||||
m_tickLastOutgoingPacketHandler = thisTick;
|
|
||||||
|
|
||||||
// update some 1ms resolution chained timers
|
// update some 1ms resolution chained timers
|
||||||
|
m_elapsedMSOutgoingPacketHandler += thisTick - m_tickLastOutgoingPacketHandler;
|
||||||
|
m_tickLastOutgoingPacketHandler = thisTick;
|
||||||
|
|
||||||
// Check for pending outgoing resends every 100ms
|
// Check for pending outgoing resends every 100ms
|
||||||
if (m_elapsedMSOutgoingPacketHandler >= 100)
|
if (m_elapsedMSOutgoingPacketHandler >= 100.0)
|
||||||
{
|
{
|
||||||
m_resendUnacked = true;
|
m_resendUnacked = true;
|
||||||
m_elapsedMSOutgoingPacketHandler = 0;
|
m_elapsedMSOutgoingPacketHandler = 0.0;
|
||||||
m_elapsed100MSOutgoingPacketHandler += 1;
|
m_elapsed100MSOutgoingPacketHandler += 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -36,10 +36,8 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.UserAccounts
|
||||||
{
|
{
|
||||||
public class UserAccountCache : IUserAccountCacheModule
|
public class UserAccountCache : IUserAccountCacheModule
|
||||||
{
|
{
|
||||||
// private const double CACHE_EXPIRATION_SECONDS = 3600.0; // 1 hour!
|
private const double CACHE_EXPIRATION_SECONDS = 3600.0; // 1 hour!
|
||||||
// private const double CACHE_NULL_EXPIRATION_SECONDS = 600; // 10minutes
|
private const double CACHE_NULL_EXPIRATION_SECONDS = 600; // 10minutes
|
||||||
private const double CACHE_EXPIRATION_SECONDS = 120000.0;
|
|
||||||
private const double CACHE_NULL_EXPIRATION_SECONDS = 120000.0;
|
|
||||||
|
|
||||||
// private static readonly ILog m_log =
|
// private static readonly ILog m_log =
|
||||||
// LogManager.GetLogger(
|
// LogManager.GetLogger(
|
||||||
|
|
Loading…
Reference in New Issue