From 72a315441937f9e0531112f2b7080da39ca6064d Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Thu, 30 Dec 2010 08:32:24 +0000 Subject: simplify per-client keepalive state checks This lets us simplify repetitive checks worry less about properly maintaining/closing client connections for each concurrency model we support. --- lib/rainbows/http_parser.rb | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 lib/rainbows/http_parser.rb (limited to 'lib/rainbows/http_parser.rb') diff --git a/lib/rainbows/http_parser.rb b/lib/rainbows/http_parser.rb new file mode 100644 index 0000000..ec55fe9 --- /dev/null +++ b/lib/rainbows/http_parser.rb @@ -0,0 +1,12 @@ +# -*- encoding: binary -*- +# :enddoc: +# avoid modifying Unicorn::HttpParser +class Rainbows::HttpParser < Unicorn::HttpParser + def self.quit + alias_method :next?, :never! + end + + def never! + false + end +end -- cgit v1.2.3-24-ge0c7