Thank you very much for your answer! I have a better understanding now
about the new servers. :)

Currently ruby enterprise edition is in 1.8.7 and I prefer to use
1.9.2. My problem with the passenger is with the slow initial server
response time. I have tried many things (including all the
recommendations from here
http://stackoverflow.com/questions/853532/slow-initial-server-startup-when-using-phusion-passenger-and-rails),
but I didn't see any significant difference.

That is basically the main issue with the passenger which I don't know
how to fix it and made me thinking of other solutions. If I use nginx
instead of apache, will this help with the problem?


On 31 Μάϊος, 11:22, Peter De Berdt <peter.de.be...@pandora.be> wrote:
> On 30 May 2011, at 20:12, Yiannis wrote:
>
> > I bought a new server and I was wondering what application server is
> > the best choice for a typical web application with rails.
>
> > I've thought for a long time that the best choice was apache/nginx and
> > phusion passenger but nowadays I am hearing a lot about thin and
> > unicorn. I have used passenger a lot and to be honest, even though
> > passenger is very easy to setup, wasn't so great. What is your
> > suggestions?
>
> What was "not so great" about Passenger? For us it's serving high  
> volumes with great ease and performance.
>
> For your typical Rails application, Passenger will be the best choice  
> (with ruby enterprise edition). It's easy to setup, it spawns new  
> instances when it needs to, kills them when they have been idle for a  
> while.
>
> Both Thin and Unicorn work behind a load balancer (whether that's  
> Apache's or HAProxy or ... doesn't really matter all too much). It's up  
> to you to decide beforehand how many instances you expect to be needed  
> to run and they will all be running all the time.
>
> Now, there are valid scenarios where you could consider using Thin or  
> Unicorn over Passenger.
> Thin, being an evented server, is simply so much better than Passenger  
> when you're using gems like EventMachine. Not that it can't be done  
> with Passenger, but you'll need to be very careful with spinning down  
> the reactor on despawn, firing it back up again on every new instance  
> spawn and spawning a new instance usually takes a bit longer too.
> Unicorn is great for fast clients, but falls dead in the water with  
> slow clients (Rainbow claims to solve this more or less). So when  
> using Unicorn, you need to be 100% sure you will be dealing with low  
> latency clients (i.e. no mobile, no keepalive sockets etc). It really  
> should be: request, response, spit it out.
>
> The gist of this whole reply is that you should determine for your  
> application which application will suit it best and what your personal  
> preference is (yeah, that also comes into play quite often :-)). We  
> use Passenger for just about everything, but also have one or two Thin  
> servers running for legacy apps that run under a different Ruby version.
>
> Best regards
>
> Peter De Berdt

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to