typhoeus/typhoeus — pull request #339 by spraints (2013-12-10 16:10:56+00:00)
Title: Add the ability to stream responses

Add streaming to ethon and typhoeus. This change requires #TBD.

For example, if you're downloading a large file with Typhoeus, you might do something like this to avoid allocating a large amount of RAM:

```ruby
File.open('ubuntu.iso', 'wb') do |f|
req = Typhoeus::Request.new('http://some-mirror.example.com/releases/precise/ubuntu-12.04.3-desktop-amd64.iso')
req.on_headers do |response|
if response.code != 200
raise 'request failed'
end
end
req.on_body do |chunk|
f.write(chunk)
end
req.run
end
```

I saw that this had been [discussed](https://groups.google.com/d/topic/typhoeus/5ZUy5ZU--l0/discussion), but it didn't look like anyone actually added streaming to Typhoeus.