Friday, August 10, 2018

Sending a huge file to many receivers simultaneously in a fixed speed would be most efficient if most receivers won't get first part first

Everyone gets the same part in the same fixed speed. Sender reads continuously the file from begin to end in a loop while sending the part it reads to 10 or 100 receivers. When a new receiver starts download, random part comes first, then every part in order until the loop is complete when previous to first-received part comes.

If the server is sending only one file, then spinning drive seeks only at end of file. Even if sending 100 files to 1000 users, seeking is reduced.

If receiver's speed is not enough, every n th part is received and loop is repeated n times. File gets fragmented, unless big write buffer is used.

Multiple senders streaming different parts of the file in different speeds would help.

This has distant resemblance with the BitTorrent protocol.

This is easier on CPU, RAM and disks.

OS could help make this more efficient on both sides.



No comments:

Post a Comment