Skip to content
No description or website provided.
Find file
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
test Clean up the pipeline code to make it possible to customize
.gitignore Initial commit of net-http gem. Tests pass on 1.8 and 1.9 except for …
Gemfile Initial commit of net-http gem. Tests pass on 1.8 and 1.9 except for …
README.markdown Add a document explaining design choices and patch potential
Rakefile Initial commit of net-http gem. Tests pass on 1.8 and 1.9 except for …
net-http.gemspec Restructure files to avoid one huge file


This repo contains a number of experimental modifications to the version of Net::HTTP that ships with Ruby 1.9. TODOs:

  • Porting the code to work on Ruby 1.8
  • Fixed gzip in GET requests when using a block as iterator
  • Support for gzip and deflate responses from any request
  • Support for incremental gzip and deflate with chunked encoding
  • Support for leaving the socket open when making a request, so it's possible to make requests that do not block on the body being returned
  • Cleaned up tests so that it's possible to combine tests for features, instead of using brittle checks for specific classes
  • Support for Net::HTTP.get(path), instead of needing to pass a URI or deconstruct the URL yourself
  • In keepalive situations, make sure to read any remaining body from the socket before initiating a new connection.
  • Support for partial reads from the response
  • Clean up the semantics of when #body can be called after a request. Specifically, if a block form is used, decide whether to buffer the outputted String and make it available as #body or to leave it up to the consumer to store a String if they want one. Either way, fomalize and document the semantics.
  • The body method should never return an Adapter. It should either return a String or nil (if well-defined semantics justify a nil)
  • Support for read_nonblock to BufferedIO. This simply proxies to the underlying read_nonblock and make it easy to support HTTP-level read_nonblock
  • Support for read_nonblock on Net2::HTTP::Response
  • Other features as I think of them
Something went wrong with that request. Please try again.