With the goal of making this happen, in 2007 Christian Neukirchen released Rack, what he then referred to as "a modular Ruby webserver interface". Today it is adapted by numerous web servers and web application development frameworks such as Espresso, Mack, Ruby on Rails, Sinatra etc.
Despite the naming conventions and assorted explanations across [programming] languages and domains, specifications for interfacing [applications] are very similar, if not homologous (although unlike Python's WSGI -- an inspiration to Rack and others, Rack here is not only a specification but -- perhaps a little confusingly -- a middleware application as well).
Rack middleware (gem), implementing the Rack specification, works by dividing incoming HTTP requests into different pipelined stages and handles them in pieces until it sends back a response coming from your web application (controller). It has two distinct components: a Handler and an Adapter, used for communicating with web servers and applications (frameworks) respectively.
It is capable of handling slow clients. Requests and responses with Passenger are fully buffered, rendering itself immune to such attacks targeting to clog systems' resources.
Passenger is highly popular and used widely in many [production] scenarios. It is therefore possible to reach out and find experts and also have your issues addressed in online communities. It also has a dedicated company developing the product, which offers efficient commercial support for those interested.
Its open-source version has a multi-process single-threaded operation mode, whilst the Enterprise version can be configured to work either single-threaded or multi-threaded.
For enterprise users, Passenger provides some further "advanced" features such as: concurrency and multithreading, deployment en masse, resource control and limiting, et al.
To learn more about Passenger, you can visit its official website located at https://www.phusionpassenger.com/. For Passenger Enterprise, please visit enterprise section on the same page.
Puma has several working modes: it allows you to set the amount of minimum and maximum threads it can use to do its job and also works in a clustered mode whereby you can use forked processes to handle requests concurrently.
It is based on Mongrel's parser -- and a lot of rewrites of its codebase.
Despite being designed as "the go-to server" for Rubinius, it also works well with JRuby.
It comes with a simple, yet significant configuration option set to adapt the web server both for production and development needs in many ways.
Although Puma does not directly support hosting multiple applications out-of-the-box, it has Jungle: a (Puma as a service) tool to help with the production needs of multiple applications.
To learn more about Puma, you can visit its official code repository located at https://github.com/puma/puma where you can also find instructions to configure and get started.
Being an Event / Machine based application server, Thin is capable of handling long running requests unlike some other choices without the help of a front facing reverse-proxy solution.
To learn more about Thin, you can visit its official website located at http://code.macournoyer.com/thin/.
As mentioned above, one of the areas in which Unicorn delegates tasks is using the operating system for load balancing. This allows the requests not to pile up against busy workers spawned.
Much like NGINX, with Unicorn you can perform and deploy your applications (think of updates/upgrades) without dropping alive connections and clients.
Some of its other advanced features:
All workers run within a given isolated address space, serving one request at a time.
before_fork and after_fork hooks for dealing with forked processes.
Ability to be used with copy-on-write friendly memory management to save memory.
Ability to listen to multiple interfaces.
To learn more about Unicorn and its great features, you can visit its official website located at http://unicorn.bogomips.org/.
Article ID: 232
Created On: Mon, Dec 30, 2013 at 2:21 AM
Last Updated On: Mon, Dec 30, 2013 at 2:21 AM
Authored by: ASPHostServer Administrator [email@example.com]
Online URL: http://faq.asphosthelpdesk.com/article.php?id=232