about summary refs log tree commit homepage
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2011-06-10 22:39:01 -0700
committerEric Wong <normalperson@yhbt.net>2011-06-10 22:42:36 -0700
commitd01c5df960546462e8f5f458131d78689342d6aa (patch)
tree67730c048cab71dd72958b1d2067b345d150c3bb
parentb065cab4fa5ca25302220c20563398a57069ae08 (diff)
Yes, this concurrency model is our strangest yet.
-rw-r--r--lib/rainbows/stream_response_epoll.rb11
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/rainbows/stream_response_epoll.rb b/lib/rainbows/stream_response_epoll.rb
index 9ded810..ed13c05 100644
--- a/lib/rainbows/stream_response_epoll.rb
+++ b/lib/rainbows/stream_response_epoll.rb
@@ -2,12 +2,13 @@
 require "sleepy_penguin"
 require "raindrops"
 
-# Like \Unicorn itself, this concurrency model is only intended for use
-# behind nginx and completely unsupported otherwise.
+# Like Unicorn itself, this concurrency model is only intended for use
+# behind nginx and completely unsupported otherwise.  Even further from
+# Unicorn, this isn't even a good idea with normal LAN clients, only nginx!
 #
 # It does NOT require a thread-safe Rack application at any point, but
-# allows streaming data asynchronously via nginx (using the the
-# "X-Accel-Buffering: no" header).
+# allows streaming data asynchronously via nginx (using the
+# "X-Accel-Buffering: no" header to disable buffering).
 #
 # Unlike Rainbows::Base, this does NOT support persistent
 # connections or pipelining.  All \Rainbows! specific configuration
@@ -28,6 +29,8 @@ module Rainbows::StreamResponseEpoll
     ep_client = false
 
     if headers
+      # don't set extra headers here, this is only intended for
+      # consuming by nginx.
       buf = "HTTP/1.0 #{status}\r\nStatus: #{status}\r\n"
       headers.each do |key, value|
         if value =~ /\n/