LLCircuitData Class Reference

#include <llcircuit.h>

Collaboration diagram for LLCircuitData:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 LLCircuitData (const LLHost &host, TPACKETID in_id)
 ~LLCircuitData ()
S32 resendUnackedPackets (const F64 now)
void clearDuplicateList (TPACKETID oldest_id)
void dumpResendCountAndReset ()
void pingTimerStart ()
void pingTimerStop (const U8 ping_id)
void ackReliablePacket (TPACKETID packet_num)
const LLUUIDgetRemoteID () const
const LLUUIDgetRemoteSessionID () const
void setRemoteID (const LLUUID &id)
void setRemoteSessionID (const LLUUID &id)
void setTrusted (BOOL t)
const LLUUIDgetLocalEndPointID () const
U32 getPingDelay () const
S32 getPingsInTransit () const
BOOL isAlive () const
BOOL isBlocked () const
BOOL getAllowTimeout () const
F32 getPingDelayAveraged ()
F32 getPingInTransitTime ()
U32 getPacketsIn () const
S32 getBytesIn () const
S32 getBytesOut () const
U32 getPacketsOut () const
U32 getPacketsLost () const
TPACKETID getPacketOutID () const
BOOL getTrusted () const
F32 getAgeInSeconds () const
S32 getUnackedPacketCount () const
S32 getUnackedPacketBytes () const
F64 getNextPingSendTime () const
LLThrottleGroupgetThrottleGroup ()
void checkPeriodTime ()
void getInfo (LLSD &info) const

Protected Types

typedef std::map< TPACKETID, U64packet_time_map
typedef std::map< TPACKETID,
LLReliablePacket * > 
reliable_map
typedef reliable_map::iterator reliable_iter

Protected Member Functions

TPACKETID nextPacketOutID ()
void setPacketInID (TPACKETID id)
void checkPacketInID (TPACKETID id, BOOL receive_resent)
void setPingDelay (U32 ping)
BOOL checkCircuitTimeout ()
void addBytesIn (S32 bytes)
void addBytesOut (S32 bytes)
U8 nextPingID ()
BOOL updateWatchDogTimers (LLMessageSystem *msgsys)
void addReliablePacket (S32 mSocket, U8 *buf_ptr, S32 buf_len, LLReliablePacketParams *params)
BOOL isDuplicateResend (TPACKETID packetnum)
BOOL collectRAck (TPACKETID packet_num)
void setTimeoutCallback (void(*callback_func)(const LLHost &host, void *user_data), void *user_data)
void setAlive (BOOL b_alive)
void setAllowTimeout (BOOL allow)

Protected Attributes

LLHost mHost
LLUUID mRemoteID
LLUUID mRemoteSessionID
LLThrottleGroup mThrottles
TPACKETID mWrapID
TPACKETID mPacketsOutID
TPACKETID mPacketsInID
TPACKETID mHighestPacketID
void(* mTimeoutCallback )(const LLHost &host, void *user_data)
void * mTimeoutUserData
BOOL mTrusted
BOOL mbAllowTimeout
BOOL mbAlive
BOOL mBlocked
F64 mPingTime
F64 mLastPingSendTime
F64 mLastPingReceivedTime
F64 mNextPingSendTime
S32 mPingsInTransit
U8 mLastPingID
U32 mPingDelay
F32 mPingDelayAveraged
packet_time_map mPotentialLostPackets
packet_time_map mRecentlyReceivedReliablePackets
std::vector< TPACKETIDmAcks
reliable_map mUnackedPackets
reliable_map mFinalRetryPackets
S32 mUnackedPacketCount
S32 mUnackedPacketBytes
LLUUID mLocalEndPointID
U32 mPacketsOut
U32 mPacketsIn
S32 mPacketsLost
S32 mBytesIn
S32 mBytesOut
F32 mLastPeriodLength
S32 mBytesInLastPeriod
S32 mBytesOutLastPeriod
S32 mBytesInThisPeriod
S32 mBytesOutThisPeriod
F32 mPeakBPSIn
F32 mPeakBPSOut
F64 mPeriodTime
LLTimer mExistenceTimer
S32 mCurrentResendCount

Friends

class LLCircuit
class LLMessageSystem
class LLEncodedDatagramService
std::ostream & operator<< (std::ostream &s, LLCircuitData &circuit)
void crash_on_spaceserver_timeout (const LLHost &host, void *)

Classes

class  less


Detailed Description

Definition at line 84 of file llcircuit.h.


Member Typedef Documentation

typedef std::map<TPACKETID, U64> LLCircuitData::packet_time_map [protected]

Definition at line 239 of file llcircuit.h.

typedef std::map<TPACKETID, LLReliablePacket *> LLCircuitData::reliable_map [protected]

Definition at line 245 of file llcircuit.h.

typedef reliable_map::iterator LLCircuitData::reliable_iter [protected]

Definition at line 246 of file llcircuit.h.


Constructor & Destructor Documentation

LLCircuitData::LLCircuitData ( const LLHost host,
TPACKETID  in_id 
)

LLCircuitData::~LLCircuitData (  ) 


Member Function Documentation

S32 LLCircuitData::resendUnackedPackets ( const F64  now  ) 

void LLCircuitData::clearDuplicateList ( TPACKETID  oldest_id  ) 

Definition at line 986 of file llcircuit.cpp.

References LLMessageSystem::getMessageTimeUsecs(), LL_DUPLICATE_SUPPRESSION_TIMEOUT, llendl, llinfos, llwarns, mHighestPacketID, mRecentlyReceivedReliablePackets, and SEC_PER_USEC.

Referenced by process_start_ping_check().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLCircuitData::dumpResendCountAndReset (  ) 

Definition at line 1180 of file llcircuit.cpp.

References llendl, llinfos, mCurrentResendCount, and mHost.

void LLCircuitData::pingTimerStart (  ) 

Definition at line 1283 of file llcircuit.cpp.

References LLMessageSystem::getMessageTimeSeconds(), mBlocked, mPingsInTransit, mPingTime, PING_START_BLOCK, and TRUE.

Referenced by updateWatchDogTimers().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLCircuitData::pingTimerStop ( const U8  ping_id  ) 

Definition at line 1250 of file llcircuit.cpp.

References FALSE, LLMessageSystem::getMessageTimeSeconds(), mBlocked, mLastPingID, mLastPingReceivedTime, mPingsInTransit, mPingTime, PING_INTERVAL, PING_RELEASE_BLOCK, S32, setPingDelay(), and TRUE.

Referenced by process_complete_ping_check().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLCircuitData::ackReliablePacket ( TPACKETID  packet_num  ) 

const LLUUID& LLCircuitData::getRemoteID (  )  const [inline]

Definition at line 104 of file llcircuit.h.

References mRemoteID.

const LLUUID& LLCircuitData::getRemoteSessionID (  )  const [inline]

Definition at line 105 of file llcircuit.h.

References mRemoteSessionID.

void LLCircuitData::setRemoteID ( const LLUUID id  )  [inline]

Definition at line 106 of file llcircuit.h.

References mRemoteID.

Referenced by LLMessageSystem::processUseCircuitCode().

Here is the caller graph for this function:

void LLCircuitData::setRemoteSessionID ( const LLUUID id  )  [inline]

Definition at line 107 of file llcircuit.h.

References mRemoteSessionID.

Referenced by LLMessageSystem::processUseCircuitCode().

Here is the caller graph for this function:

void LLCircuitData::setTrusted ( BOOL  t  ) 

Definition at line 1394 of file llcircuit.cpp.

References mTrusted.

Referenced by LLMessageSystem::enableCircuit(), and process_create_trusted_circuit().

Here is the caller graph for this function:

const LLUUID& LLCircuitData::getLocalEndPointID (  )  const [inline]

Definition at line 114 of file llcircuit.h.

References mLocalEndPointID.

Referenced by process_create_trusted_circuit(), process_deny_trusted_circuit(), and LLMessageSystem::reallySendDenyTrustedCircuit().

Here is the caller graph for this function:

U32 LLCircuitData::getPingDelay (  )  const

Definition at line 1349 of file llcircuit.cpp.

References mPingDelay.

Referenced by LLViewerObject::processUpdateMessage(), update_statistics(), and LLViewerRegion::updateNetStats().

Here is the caller graph for this function:

S32 LLCircuitData::getPingsInTransit (  )  const [inline]

Definition at line 117 of file llcircuit.h.

References mPingsInTransit.

BOOL LLCircuitData::isAlive (  )  const

Definition at line 1331 of file llcircuit.cpp.

References mbAlive.

Referenced by LLMessageSystem::checkCircuitAlive(), checkCircuitTimeout(), LLMessageSystem::findCircuit(), and LLMessageSystem::sendMessage().

Here is the caller graph for this function:

BOOL LLCircuitData::isBlocked (  )  const

Definition at line 1337 of file llcircuit.cpp.

References mBlocked.

Referenced by LLMessageSystem::checkCircuitBlocked(), and LLTransferSourceChannel::updateTransfers().

Here is the caller graph for this function:

BOOL LLCircuitData::getAllowTimeout (  )  const

Definition at line 1343 of file llcircuit.cpp.

References mbAllowTimeout.

F32 LLCircuitData::getPingDelayAveraged (  ) 

Definition at line 1382 of file llcircuit.cpp.

References getPingInTransitTime(), LL_AVERAGED_PING_MAX, llmax(), llmin(), and mPingDelayAveraged.

Referenced by LLMessageSystem::flushSemiReliable(), resendUnackedPackets(), LLMessageSystem::sendReliable(), LLMessageSystem::sendSemiReliable(), setPingDelay(), and updateWatchDogTimers().

Here is the call graph for this function:

Here is the caller graph for this function:

F32 LLCircuitData::getPingInTransitTime (  ) 

Definition at line 1355 of file llcircuit.cpp.

References LLMessageSystem::getMessageTimeSeconds(), mPingsInTransit, mPingTime, and PING_INTERVAL.

Referenced by getPingDelayAveraged().

Here is the call graph for this function:

Here is the caller graph for this function:

U32 LLCircuitData::getPacketsIn (  )  const

Definition at line 1295 of file llcircuit.cpp.

References mPacketsIn.

Referenced by LLViewerRegion::updateNetStats().

Here is the caller graph for this function:

S32 LLCircuitData::getBytesIn (  )  const

Definition at line 1301 of file llcircuit.cpp.

References mBytesIn.

Referenced by LLViewerRegion::updateNetStats().

Here is the caller graph for this function:

S32 LLCircuitData::getBytesOut (  )  const

Definition at line 1307 of file llcircuit.cpp.

References mBytesOut.

U32 LLCircuitData::getPacketsOut (  )  const

Definition at line 1313 of file llcircuit.cpp.

References mPacketsOut.

Referenced by resendUnackedPackets(), and LLViewerRegion::updateNetStats().

Here is the caller graph for this function:

U32 LLCircuitData::getPacketsLost (  )  const

Definition at line 1325 of file llcircuit.cpp.

References mPacketsLost.

Referenced by LLViewerRegion::getPacketsLost(), LLWorld::printPacketsLost(), and LLViewerRegion::updateNetStats().

Here is the caller graph for this function:

TPACKETID LLCircuitData::getPacketOutID (  )  const

Definition at line 1319 of file llcircuit.cpp.

References mPacketsOutID.

Referenced by LLMessageSystem::sendMessage(), and updateWatchDogTimers().

Here is the caller graph for this function:

BOOL LLCircuitData::getTrusted (  )  const

F32 LLCircuitData::getAgeInSeconds (  )  const

Definition at line 1399 of file llcircuit.cpp.

References LLTimer::getElapsedTimeF32(), and mExistenceTimer.

Here is the call graph for this function:

S32 LLCircuitData::getUnackedPacketCount (  )  const [inline]

Definition at line 133 of file llcircuit.h.

References mUnackedPacketCount.

Referenced by LLMessageSystem::checkMessages(), process_packet_ack(), and LLMessageSystem::sendMessage().

Here is the caller graph for this function:

S32 LLCircuitData::getUnackedPacketBytes (  )  const [inline]

Definition at line 134 of file llcircuit.h.

References mUnackedPacketBytes.

Referenced by LLCircuit::resendUnackedPackets().

Here is the caller graph for this function:

F64 LLCircuitData::getNextPingSendTime (  )  const [inline]

Definition at line 135 of file llcircuit.h.

References mNextPingSendTime.

Referenced by LLCircuitData::less::operator()().

Here is the caller graph for this function:

LLThrottleGroup& LLCircuitData::getThrottleGroup (  )  [inline]

Definition at line 137 of file llcircuit.h.

References mThrottles.

Referenced by LLTransferSourceChannel::updateTransfers().

Here is the caller graph for this function:

void LLCircuitData::checkPeriodTime (  ) 

Definition at line 522 of file llcircuit.cpp.

References LLMessageSystem::getMessageTimeSeconds(), mBytesInLastPeriod, mBytesInThisPeriod, mBytesOutLastPeriod, mBytesOutThisPeriod, mLastPeriodLength, mPeakBPSIn, mPeakBPSOut, mPeriodTime, and TARGET_PERIOD_LENGTH.

Referenced by LLCircuit::updateWatchDogTimers().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLCircuitData::getInfo ( LLSD info  )  const

Definition at line 1173 of file llcircuit.cpp.

References LLTimer::getElapsedTimeF32(), LLHost::getIPandPort(), mbAlive, mExistenceTimer, and mHost.

Here is the call graph for this function:

TPACKETID LLCircuitData::nextPacketOutID (  )  [protected]

Definition at line 1222 of file llcircuit.cpp.

References LL_MAX_OUT_PACKET_ID, mPacketsOut, mPacketsOutID, and mWrapID.

Referenced by LLMessageSystem::sendMessage().

Here is the caller graph for this function:

void LLCircuitData::setPacketInID ( TPACKETID  id  )  [protected]

Definition at line 1240 of file llcircuit.cpp.

References LL_MAX_OUT_PACKET_ID, mPacketsInID, mRecentlyReceivedReliablePackets, and mWrapID.

Referenced by checkPacketInID(), and LLMessageSystem::findCircuit().

Here is the caller graph for this function:

void LLCircuitData::checkPacketInID ( TPACKETID  id,
BOOL  receive_resent 
) [protected]

void LLCircuitData::setPingDelay ( U32  ping  )  [protected]

Definition at line 1370 of file llcircuit.cpp.

References getPingDelayAveraged(), LL_AVERAGED_PING_ALPHA, LL_AVERAGED_PING_MAX, LL_AVERAGED_PING_MIN, llclamp(), llmax(), mPingDelay, and mPingDelayAveraged.

Referenced by pingTimerStop().

Here is the call graph for this function:

Here is the caller graph for this function:

BOOL LLCircuitData::checkCircuitTimeout (  )  [protected]

Definition at line 1034 of file llcircuit.cpp.

References FALSE, LLMessageSystem::getMessageTimeSeconds(), isAlive(), llendl, llwarns, mHost, mLastPingReceivedTime, mTimeoutCallback, mTimeoutUserData, PING_INTERVAL_ALARM, PING_INTERVAL_MAX, setAlive(), and TRUE.

Referenced by updateWatchDogTimers().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLCircuitData::addBytesIn ( S32  bytes  )  [protected]

Definition at line 551 of file llcircuit.cpp.

References mBytesIn, and mBytesInThisPeriod.

Referenced by LLMessageSystem::logValidMsg().

Here is the caller graph for this function:

void LLCircuitData::addBytesOut ( S32  bytes  )  [protected]

Definition at line 558 of file llcircuit.cpp.

References mBytesOut, and mBytesOutThisPeriod.

Referenced by LLMessageSystem::sendMessage().

Here is the caller graph for this function:

U8 LLCircuitData::nextPingID (  )  [inline, protected]

Definition at line 177 of file llcircuit.h.

References mLastPingID.

Referenced by updateWatchDogTimers().

Here is the caller graph for this function:

BOOL LLCircuitData::updateWatchDogTimers ( LLMessageSystem msgsys  )  [protected]

void LLCircuitData::addReliablePacket ( S32  mSocket,
U8 buf_ptr,
S32  buf_len,
LLReliablePacketParams params 
) [protected]

BOOL LLCircuitData::isDuplicateResend ( TPACKETID  packetnum  )  [protected]

Definition at line 602 of file llcircuit.cpp.

References mRecentlyReceivedReliablePackets.

Referenced by LLMessageSystem::checkMessages().

Here is the caller graph for this function:

BOOL LLCircuitData::collectRAck ( TPACKETID  packet_num  )  [protected]

Definition at line 1064 of file llcircuit.cpp.

References gMessageSystem, mAcks, LLMessageSystem::mCircuitInfo, mHost, LLCircuit::mSendAckMap, and TRUE.

Referenced by LLMessageSystem::checkMessages().

Here is the caller graph for this function:

void LLCircuitData::setTimeoutCallback ( void(*)(const LLHost &host, void *user_data)  callback_func,
void *  user_data 
) [protected]

Definition at line 646 of file llcircuit.cpp.

References mTimeoutCallback, and mTimeoutUserData.

Referenced by LLMessageSystem::setCircuitTimeoutCallback().

Here is the caller graph for this function:

void LLCircuitData::setAlive ( BOOL  b_alive  )  [protected]

Definition at line 491 of file llcircuit.cpp.

References FALSE, LLMessageSystem::getMessageTimeSeconds(), mbAlive, mBlocked, mLastPingReceivedTime, mPacketsInID, mPacketsOutID, and mPingsInTransit.

Referenced by checkCircuitTimeout(), LLMessageSystem::enableCircuit(), LLMessageSystem::findCircuit(), and setAllowTimeout().

Here is the call graph for this function:

Here is the caller graph for this function:

void LLCircuitData::setAllowTimeout ( BOOL  allow  )  [protected]

Definition at line 508 of file llcircuit.cpp.

References mbAllowTimeout, setAlive(), and TRUE.

Referenced by LLMessageSystem::setCircuitAllowTimeout().

Here is the call graph for this function:

Here is the caller graph for this function:


Friends And Related Function Documentation

friend class LLCircuit [friend]

Definition at line 163 of file llcircuit.h.

friend class LLMessageSystem [friend]

Definition at line 164 of file llcircuit.h.

friend class LLEncodedDatagramService [friend]

Definition at line 165 of file llcircuit.h.

std::ostream& operator<< ( std::ostream &  s,
LLCircuitData circuit 
) [friend]

Definition at line 1130 of file llcircuit.cpp.

void crash_on_spaceserver_timeout ( const LLHost host,
void *   
) [friend]


Member Data Documentation

Definition at line 199 of file llcircuit.h.

Referenced by getRemoteID(), LLMessageSystem::getSenderID(), operator<<(), and setRemoteID().

Definition at line 204 of file llcircuit.h.

Referenced by checkPacketInID(), nextPacketOutID(), and setPacketInID().

Definition at line 208 of file llcircuit.h.

Referenced by getPacketOutID(), nextPacketOutID(), and setAlive().

Definition at line 209 of file llcircuit.h.

Referenced by checkPacketInID(), setAlive(), and setPacketInID().

Definition at line 210 of file llcircuit.h.

Referenced by checkPacketInID(), and clearDuplicateList().

void(* LLCircuitData::mTimeoutCallback)(const LLHost &host, void *user_data) [protected]

Definition at line 216 of file llcircuit.h.

Referenced by checkCircuitTimeout(), LLCircuitData(), and setTimeoutCallback().

Definition at line 218 of file llcircuit.h.

Referenced by getTrusted(), and setTrusted().

Definition at line 219 of file llcircuit.h.

Referenced by getAllowTimeout(), operator<<(), and setAllowTimeout().

Definition at line 223 of file llcircuit.h.

Referenced by isBlocked(), pingTimerStart(), pingTimerStop(), and setAlive().

Definition at line 226 of file llcircuit.h.

Referenced by getPingInTransitTime(), LLCircuitData(), pingTimerStart(), and pingTimerStop().

Definition at line 228 of file llcircuit.h.

Referenced by LLCircuitData(), and updateWatchDogTimers().

Definition at line 229 of file llcircuit.h.

Referenced by checkCircuitTimeout(), LLCircuitData(), pingTimerStop(), and setAlive().

Definition at line 232 of file llcircuit.h.

Referenced by nextPingID(), and pingTimerStop().

Definition at line 236 of file llcircuit.h.

Referenced by getPingDelay(), operator<<(), and setPingDelay().

Definition at line 237 of file llcircuit.h.

Referenced by getPingDelayAveraged(), operator<<(), and setPingDelay().

Definition at line 241 of file llcircuit.h.

Referenced by checkPacketInID(), and updateWatchDogTimers().

std::vector<TPACKETID> LLCircuitData::mAcks [protected]

Definition at line 243 of file llcircuit.h.

Referenced by collectRAck(), LLCircuit::sendAcks(), and LLMessageSystem::sendMessage().

Definition at line 255 of file llcircuit.h.

Referenced by getLocalEndPointID(), and LLCircuitData().

Definition at line 262 of file llcircuit.h.

Referenced by getPacketsOut(), nextPacketOutID(), and operator<<().

Definition at line 263 of file llcircuit.h.

Referenced by checkPacketInID(), getPacketsIn(), and operator<<().

Definition at line 264 of file llcircuit.h.

Referenced by getPacketsLost(), operator<<(), and updateWatchDogTimers().

Definition at line 265 of file llcircuit.h.

Referenced by addBytesIn(), getBytesIn(), and operator<<().

Definition at line 266 of file llcircuit.h.

Referenced by addBytesOut(), getBytesOut(), and operator<<().

Definition at line 268 of file llcircuit.h.

Referenced by checkPeriodTime(), and operator<<().

Definition at line 269 of file llcircuit.h.

Referenced by checkPeriodTime(), and operator<<().

Definition at line 270 of file llcircuit.h.

Referenced by checkPeriodTime(), and operator<<().

Definition at line 271 of file llcircuit.h.

Referenced by addBytesIn(), and checkPeriodTime().

Definition at line 272 of file llcircuit.h.

Referenced by addBytesOut(), and checkPeriodTime().

Definition at line 273 of file llcircuit.h.

Referenced by checkPeriodTime(), and operator<<().

Definition at line 274 of file llcircuit.h.

Referenced by checkPeriodTime(), and operator<<().

Definition at line 275 of file llcircuit.h.

Referenced by checkPeriodTime(), and LLCircuitData().

Definition at line 276 of file llcircuit.h.

Referenced by getAgeInSeconds(), getInfo(), and operator<<().

Definition at line 278 of file llcircuit.h.

Referenced by dumpResendCountAndReset(), and resendUnackedPackets().


The documentation for this class was generated from the following files:

Generated on Fri May 16 08:42:51 2008 for SecondLife by  doxygen 1.5.5