Skip to content

Commit

Permalink
Use Thin instead of Mongrel
Browse files Browse the repository at this point in the history
Mongrel is deprecated.
  • Loading branch information
kuroda committed Dec 27, 2011
1 parent 2f06008 commit b487f02
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/rack/handler.rb
@@ -1,7 +1,7 @@
module Rack module Rack
# *Handlers* connect web servers with Rack. # *Handlers* connect web servers with Rack.
# #
# Rack includes Handlers for Mongrel, WEBrick, FastCGI, CGI, SCGI # Rack includes Handlers for Thin, WEBrick, FastCGI, CGI, SCGI
# and LiteSpeed. # and LiteSpeed.
# #
# Handlers usually are activated by calling <tt>MyHandler.run(myapp)</tt>. # Handlers usually are activated by calling <tt>MyHandler.run(myapp)</tt>.
Expand Down Expand Up @@ -38,7 +38,7 @@ def self.default(options = {})
Rack::Handler::CGI Rack::Handler::CGI
else else
begin begin
Rack::Handler::Mongrel Rack::Handler::Thin
rescue LoadError rescue LoadError
Rack::Handler::WEBrick Rack::Handler::WEBrick
end end
Expand Down

2 comments on commit b487f02

@kuroda
Copy link
Contributor Author

@kuroda kuroda commented on b487f02 Dec 27, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a temporary measure to provide users a way to suppress annoying warning messages that WEBrick emits:

WARN  Could not determine content-length of response body.
Set content-length of the response or set Response#chunked = true

This message is issued when we use WEBrick on Ruby 1.9. You can suppress it if you put gem "thin" into your Gemfile.

Note that Mongrel is declared as deprecated on its Github page. See https://github.com/evan/mongrel

@raggi
Copy link
Member

@raggi raggi commented on b487f02 Dec 28, 2011

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This actually needs to get submitted back to ruby-core. They shouldn't emit this message if the response header Transfer-Encoding is set to 'chunked'.

I think that variable being set like that on response is kinda silly actually.

Please sign in to comment.