3 ms·
HTTP is great. Another common "How does it know" is resuming downloads: that's done by the Range header. Curl supports it by using `--continue-at- -` (the dash
by alganet 4y ago
HTTP is great. Another common "How does it know" is resuming downloads: that's done by the Range header. Curl supports it by using `--continue-at- -` (the dash means "figure out where it stopped", you can also use a byte range).
- jayknight 4y agoAnd byte ranges is how those download managers from the 90s downloaded your file in several parallel chunks to make it go faster.
- treeman79 4y agoAlso loved the software that cut clock speed in half, so your download speed was 2x.
- kaladin-jasnah 4y agoIs this how JDownloader2 works?
- leni536 4y agoaria2 is a CLI tool do the same.
- blueflow 4y agoExcept resumed downloads are broken when used in conjunction with compression, because its not clear whether the byte range refers to the compressed or uncompressed resource. The HTTP spec solved this problem elegantly, it had the concept of the identity of a resource, and gave two headers to declare compression: Content-Encoding (=the resource is always compressed, like an tar.gz, byte range refers to compressed) and Transfer-Encoding (=the resource is compressed only for transfer, the uncompressed is the real thing). As of 2023, this has not been implemented and the Content-Encoding header is used for both semantics. So resuming downloads over a proxy has a good chance of corrupting your file, i also had source tarballs being decompressed on the fly and failing their checksums.