asiniy
Download - the easiest way to download files from the internet
Hey there!
I wrote a download elixir package which does exactly what its name about - an easy way to download files.
I saw solutions about how to do it with HTTPoison but these solutions have disadvantages:
- The whole response is loading to the RAM, and only after then is going to the File.write/1. You have to choose async HTTPoison request to escape high memory consumption.
- There is no restriction of the file size to download. If you handle, saying, user input and then you’re trying to download any file user provided, your server can go down for downloading a file which has 1TB size.
download depends on HTTPoison and successfully sidestep these issues.
Enjoy ![]()
Most Liked
NobbZ
This project is about downloading a single resource from the specified URL. It does not any magic to determine what the resource actually is. It gets saved as is and then you get path of the saved file.
This is in contrast to using HTTPoison without thinking about it and loading the full response into RAM.
One can get the same behaviour with HTTPosion directly though using async requests, but this package makes it a bit easier to process those.
gon782
Important to note is that with, for example, youtube-dl you also get support for downloading from Twitch and vimeo.
Eiji
@asiniy: Nice, but I have a few ideas:
- Support for POST requests, because some pages requires it
- Support for parameters (GET) and data (POST), because it’s easier to read code (parameters) + some pages requires POST with data
- Support for finders, for example:
Download.from(url, finder: Download.Finders.Video) - Support for Traditional units
Popular in Announcing
Other popular topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #supervisor
- #advent-of-code
- #elixirconf-us
- #distillery
- #processes
- #forms
- #api
- #metaprogramming
- #security
- #performance









