unicorn Ruby/Rack server user+dev discussion/patches/pulls/bugs/help
 help / color / mirror / code / Atom feed
From: Eric Wong <normalperson@yhbt.net>
To: unicorn list <mongrel-unicorn@rubyforge.org>
Subject: Re: Unicorn for Rails development mode?
Date: Sun, 28 Aug 2011 23:14:34 +0000	[thread overview]
Message-ID: <20110828231434.GA9021@dcvr.yhbt.net> (raw)
In-Reply-To: <CAKS1d-vFB4VXo4kR4Bp16+Qyny2hhqFR5eyqE_j-F0t+Jc+z6w@mail.gmail.com>

Jay Levitt <jlevitt@tiptap.com> wrote:
> I'm tired of the bugginess of Webrick, so I want to upgrade to
> something modern for developing Rails apps on my Mac, and I'm a bit
> out of the loop.  Is Unicorn a drop-in replacement these days in
> development mode? Does it have advantages or disadvantages compared to
> Thin?  I don't even know what capabilities I should care about, but
> some obvious ones are:

unicorn should be a drop-in replacement, you shouldn't need a
unicorn-specific config file for development.

The "unicorn_rails"[1] command was designed Rails 1.x/2.x users, while
"unicorn" is a better fit for Rails 3 (and all Rack frameworks),
but either works for Rails 3

Thin is a great server and I've had no issues with Webrick for
development, either.

You don't have to worry about slow clients hitting Unicorn in
development, so you can forgo nginx for development.

> - Doesn't stop logging after a while (hi, Webrick)

This is not a problem I've heard of with either server.  It /may/ be an
issue with the Rails buffered logger implementation, though.  The Ruby
standard library Logger used by Unicorn does no buffering.

> - Logs to STDOUT or STDERR

This is the default, and Unicorn explicitly disables output buffering
on both of these.

> - Reloads everything that ought to be reloaded on each request

Set RAILS_ENV=development in your environment.

> - Works well with 1.9.2

Yes, I regularly test against 1.8.7, 1.9.2, 1.9.3dev and trunk.

> Any advice? I'd think this would be a FAQ, but I haven't found any
> discussions on the topic.

I don't do much Rails development, but everything /should/ work fine.  I
will never officially support non-Free systems, but from what I've heard
it works fine on the ones names after fruits.

Others on this list can hopefully chime in, too.



[1] - There's some confusion that was the result of "unicorn_rails"
      being an automatic compatibility layer for old Rails.  If I
      could to do it all over again, I'd leave "unicorn_rails" out
      and force folks to setup the compatibility layer themselves
      to learn how Rack works.

-- 
Eric Wong
_______________________________________________
Unicorn mailing list - mongrel-unicorn@rubyforge.org
http://rubyforge.org/mailman/listinfo/mongrel-unicorn
Do not quote signatures (like this one) or top post when replying


      reply	other threads:[~2011-08-29  1:25 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-28 13:35 Unicorn for Rails development mode? Jay Levitt
2011-08-28 23:14 ` Eric Wong [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://yhbt.net/unicorn/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110828231434.GA9021@dcvr.yhbt.net \
    --to=normalperson@yhbt.net \
    --cc=mongrel-unicorn@rubyforge.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://yhbt.net/unicorn.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).