Configuring Traffic Throttling in IPWorks Components
Network applications may require limiting bandwidth usage to control performance or comply with network constraints. /n software components provide a simple way to throttle outgoing traffic using a configuration setting.
The MaxTransferRate configuration setting controls the rate of outbound TCP data by specifying the number of bytes sent per second. It is supported by TCP-based components such as TCPClient and TCPServer.
For example, the following example limits the transfer rate of a TCPServer component to 1 KB per second.
tcpserver.Config("MaxTransferRate=1024");
Note that this setting applies only to outbound data and does not affect incoming traffic.
We appreciate your feedback. If you have any questions, comments, or suggestions about this article please contact our support team at support@nsoftware.com.