-
-
Notifications
You must be signed in to change notification settings - Fork 9.7k
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
Tracking Issue: Concurrent Downloads #18278
Comments
Thanks for the write-up @reitermarkus! Makes sense to me. Please focus on getting #17756 merged ASAP.
We can't/won't do this. Things as basic as "download a release from a private GitHub repository" require this. Instead we should expect to provide suboptimal/poor/no progress reporting, graceful cancellation for these strategies. |
Thoughts so far:
|
If it's that basic, we should support it using an official download strategy. In any case, we don't want to maintain two different types of download strategies. |
@reitermarkus We historically supported many more types of download strategies that we didn't use e.g. those for private resources. Problem is: when we don't actually use and rely on them ourselves, they end up bitrotting. In general: even if we were to support them: I'd rather not break an existing, public (implicit or not) API for people for new functionality if we can just degrade to not support that functionality there instead. |
This will probably be easier to discuss with a demonstration of what exactly needs changing in download strategies that would be a breaking change. |
Worth noting that download strategies already need to support Ctrl+C |
Concurrent Downloads
Implement MVP of concurrent downloads for
brew fetch
.Implemented in Implement concurrent downloads in
brew fetch
. #17756.Improve output logic.
For simplicity, the output currently only uses at most terminal height - 1 lines due to a trailing newline.
Deprecate custom download strategies.
In order to implement the following parts, custom download strategies need to be deprecated. Their API surface is too big since they depend on many private methods from their superclass, making changes here practically impossible without breaking things.
Implement progress bar.
Every download strategy needs to support progress reporting.
Implement graceful cancellation of downloads.
Currently, cancelling downloads can only be done by killing the whole thread pool, i.e. the sledgehammer approach. Proper cancellation based on https://ruby-concurrency.github.io/concurrent-ruby/master/Concurrent/Cancellation.html should be implemented, making it possible to neatly show successful, failed and cancelled downloads.
Implement concurrent downloads for
brew install
,brew reinstall
etc.Enable concurrent downloads by default.
The text was updated successfully, but these errors were encountered: