ncr / rack-proxy

A request/response rewriting HTTP proxy. A Rack app.
MIT License
269 stars 94 forks source link

add ability to set read_timout fot Net:HTTP - resolves #43 #44

Closed jp closed 10 years ago

jp commented 10 years ago

I can now set the read_timeout attribute using the following snippet. The attribute read_timeout defaults to 60 seconds.

class AppProxy < Rack::Proxy
  def rewrite_env(env)
    env["http.read_timeout"]=300
    env
  end
end
ncr commented 10 years ago

Thanks a lot!

jp commented 10 years ago

My pleasure !

chattygk commented 10 years ago

Hello.. The read_timeout would work when streaming is set.. Should it also work when streaming is not set?