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

Improve performance #9

Closed
MarcoTomasRodriguez opened this issue Aug 19, 2020 · 1 comment
Closed

Improve performance #9

MarcoTomasRodriguez opened this issue Aug 19, 2020 · 1 comment

Comments

@MarcoTomasRodriguez
Copy link
Owner

MarcoTomasRodriguez commented Aug 19, 2020

wget is, in some cases, faster than hget.

For example, https://storage.googleapis.com/golang/go1.6.3.darwin-amd64.pkg
wget: 25 secs
hget (1 thread): 23 secs
hget (8 threads): 26 secs

Reference: huydx/hget#18

@MarcoTomasRodriguez
Copy link
Owner Author

This is completely understandable because creating multiple threads has its overhead. hget with parallelism enabled is only faster when the bottleneck is in the server, not in the user. The Google servers are powerful and well optimized, so the bottleneck is probably always in the user; for these cases, it is not recommended to use parallelism, rather use a single thread.
In the future, it would be useful to let the program decide which strategy should it use.

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

No branches or pull requests

1 participant