Haiku could include a dedicated API and an additional server who's task would be to manage and optimise simultaneous downloads on a global level.
Details
In order to optimise downloads from a Haiku system it is proposed that all mass downloads be conducted using a dedicated download kit. Any software which wanted to download large files should use the download kit API to queue the download, query it's progress and other management tasks. Classes such as 'BFTP' would be required.
The server would be composed of a basic driver which loads multiple add-on components described in more detail below (Note that the following categories are arbitrary and used only to ease discussion). It's tasks would be restricted to managing the host machine, taking action in the event of low disk space, prioritisation, etc.
Protocol Add-ons
The server would be composed of a basic driver which loads multiple add-on components for each supported download protocol. Protocols include both P2P (Such as bittorrent) and direct client-server downloads (FTP downloads). Each add-on would be required to implement, at minimum, the ability to:
- Download a specified object to a location on local storage
- Reference distinct downloads
- Query progress of downloads
- Assign speed limits / priorities
The management of downloads could thus benefit the user in the following ways,
- Increased accuracy of 'time remaining' estimates
- Efficiently manage limited bandwidth in order to retrieve urgent files first
Management Add-ons
Additional add-ons could be used in order to automatically ration the bandwidth according to particular needs or perform other such housekeeping tasks. A theoretical example includes a remote identification algorithm automatically prioritising friend's downloads above the general population's.
Issues
- Is it acceptable to utilise resources for a dedicated server? Could it be implemented as load-on-demand?
- Would it be better implemented as a library set, rather than a server? Is there enough demand to manage this many downloads at once?






I am planning to implement something like this to go along with my Haiku web browser. I do not know if it will get included in the core Haiku, though I'm sure it would be included on most "distros" or whatever we will call them.
If the original author of this RFC has any more input, let me know.
Of course if anyone else has input as well, please post :)
I have also been in discussion with "anarchos" in the #haiku IRC channel. He is going to write up some of the features he would be interested in, though we all seem to be on one page in regards to the core features (download_server to handle all downloads, add-ons for protocols, BitTorrent support, bandwidth throttling, etc.)