[p2p-hackers] Re: Control network file transfer rate
Sam Berlin
sberlin at gmail.com
Thu Feb 23 17:10:00 UTC 2006
You may also want to take a look at http://tinyurl.com/la4aj . It's
similar to Raphael's global bandwidth scheduler, but implemented in
Java and designed for non-blocking I/O. LimeWire uses it for Gnutella
upload traffic bandwidth throttling (whereas the classes Greg
described earlier are used for file upload/download bandwidth
throttling, since they have not switched to NIO yet).
Sam
On 23 Feb 2006 16:53:25 GMT, Raphael Manfredi
<Raphael_Manfredi at pobox.com> wrote:
> Quoting Greg Bildson <gbildson at limepeer.com> from ml.p2p.hackers:
> :You might want to look at our BandwidthThrottle, ThrottledOutputStream
> :classes and the use of BandwidthThrottle elsewhere (HTTPDownloader,
> :NormalUploadState, etc). We built off of some earlier FreeNet techniques.
> :There is some added complexity along the way but I believe we handle things
> :elegantly overall.
>
> Doing b/w allocation on a per-stream basis is sub-optimal and may lead
> to non-full utilization of the configured total b/w.
>
> If you can read C, thre's a more complex bandwidth scheduler at:
>
> http://tinyurl.com/q3toe
>
> Start with bsched_heartbeat(). The idea is the scheduler knows
> the whole set of file descriptors that want to emit. But not all
> can emit at some time (kernel buffers full or flow-controlled), so
> the b/w is more evenly distributed among the other files.
>
> Also, from the application layer, you can control how much you
> write, but you have really no control on what TCP will do (retransmits,
> ACKs, etc...). So all you can do is try to emit *on average* what
> the user has configured.
>
> Hence the use of EMA in the code trying to balance things to absorb
> peaks.
>
> Raphael
> _______________________________________________
> p2p-hackers mailing list
> p2p-hackers at zgp.org
> http://zgp.org/mailman/listinfo/p2p-hackers
> _______________________________________________
> Here is a web page listing P2P Conferences:
> http://www.neurogrid.net/twiki/bin/view/Main/PeerToPeerConferences
>
More information about the P2p-hackers
mailing list