This issue tracks potential ways to speed up downloads.
[x] Request pipelining. Done to a basic extent (fixed pipeline size).
[x] Self-adjusting request queue size. We should always keep the download pipeline at capacity to ensure we don't waste bandwidth.
[x] TCP like slow-start to reach optimal request queue size as fast as possible. The problem here is that if we linearly increment the request queue size, for fast links we would waste performance instead of ramping up the download rate exponentially.
[x] Batch disk writes. This is done for the most part but configurability and maybe self-adjustment would be great.
[x] Request timeouts, which are important when there are multiple peers with the same piece. If a peer has it but times out, we can try to download it from another peer faster. (#18)
[x] Share downloads. This way, a piece may be completed faster if downloaded from multiple peers, resulting in fewer unfinished pieces overall. It's also important for end game mode. (#45)
[x] End game mode: here for the last n pieces (for a small n, possibly n = 1), we request all blocks from all peers (that have it), so that we're not stalled on a single peer to finish the download. If we receive a block, we send a cancel request to other peers. (#70)
This issue tracks potential ways to speed up downloads.