The C++ framework for developing highly scalable, high performance servers on Windows platforms.

IMonitorStreamSocketFlowControl.h File Reference


Namespaces

namespace  JetByteTools
namespace  JetByteTools::IO
namespace  JetByteTools::Socket

Classes

class  IMonitorStreamSocketFlowControl
 An interface to allow a class to monitor the operation of a class that implements flow control for stream socket connections. The design of the interface assumes that only buffers that are affected by flow control are noted by the monitor. The effects of flow control on a buffer that is being sent on a connection are as follows: delayed, sent or discarded. A buffer that is delayed is being held for a while until it can be sent. A buffer that has been sent is a buffer that was previously delayed and that has now been written to the connection. A buffer that is discarded can either be a new buffer that is being discarded rather than delayed or an existing delayed buffer that will now never be sent. Incrementing a counter when OnBufferDelayed() is called and decrementing it when OnBufferSent() is called, OR when 'wasDelayed' is true and OnBufferDiscarded() is called will give you a count of buffers that are currently delayed. Incrementing a counter when OnBufferDiscarded() is called will give you a count of all the buffers that were discarded. You can use the 'id' value as a way of maintaining these counts on a per-connection basis. The Id that you return from a call to OnConnectionEstablished() will be passed with every call to the other monitor functions. Note that if all you require is a unique id per connection then you can simply cast the address of the supplied socket to a ConnectionId in OnConnectionEstablished() and return that. More...


Generated on Sun Sep 12 19:06:43 2021 for The Server Framework - v7.4 by doxygen 1.5.3