Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support partial/resumable downloads #218

Open
tecosaur opened this issue Feb 1, 2023 · 2 comments
Open

Support partial/resumable downloads #218

tecosaur opened this issue Feb 1, 2023 · 2 comments

Comments

@tecosaur
Copy link

tecosaur commented Feb 1, 2023

When downloading something large, like an 80GB file, it's a massive pain when 70% of the way through the download the network stutters and you loose ... everything.

libcurl supports partial/resumable downloads (see https://curl.se/libcurl/c/CURLOPT_RESUME_FROM_LARGE.html), and so it would be nice if Downloads could support writing the partial download to a file/buffer and then continuing either from a manually specified point or just the size of the file/buffer so far.

Ideally, Downloads would also support automatically re-trying up to N times.

@StefanKarpinski
Copy link
Member

I think the retry would be the way. Otherwise you need to introduce a whole API for providing a potentially partially downloaded file to continue. If the retrying is internal then that can be managed transparently.

@tecosaur
Copy link
Author

tecosaur commented Feb 3, 2023

Retrying is certainly the most "simple" way in many respects, however, I'm beginning to use Julia to manage large data sets (as I type this, I'm downloading a 750GB file, but via curl so I can resume it in case something goes wrong) and I'd imagine that just "retry" would fall short in cases like this.

Would the following sound viable?

  • Add an option to dump partial output to a file
  • Add an option to resume the download from a certain point

I'd think that would be sufficient to enable partially downloaded files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants