From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eric Wong Newsgroups: gmane.comp.lang.ruby.mongrel.devel Subject: Unicorn - Gossamer Fork: With Threads Date: Sun, 26 Apr 2009 13:38:35 -0700 Message-ID: <20090426203834.GA9854@dcvr.yhbt.net> Reply-To: mongrel-development-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1240830146 24969 80.91.229.12 (27 Apr 2009 11:02:26 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 27 Apr 2009 11:02:26 +0000 (UTC) To: mongrel-development-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Original-X-From: mongrel-development-bounces-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Mon Apr 27 13:02:17 2009 Return-path: Envelope-to: gclrmd-mongrel-development@m.gmane.org Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) X-BeenThere: mongrel-development-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: mongrel-development-bounces-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Errors-To: mongrel-development-bounces-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Xref: news.gmane.org gmane.comp.lang.ruby.mongrel.devel:116 Archived-At: Received: from rubyforge.org ([205.234.109.19]) by lo.gmane.org with esmtp (Exim 4.50) id 1LyBCO-0006qg-EG for gclrmd-mongrel-development@m.gmane.org; Sun, 26 Apr 2009 22:43:40 +0200 Received: from rubyforge.org (rubyforge.org [127.0.0.1]) by rubyforge.org (Postfix) with ESMTP id 1F4E518580E3; Sun, 26 Apr 2009 16:40:04 -0400 (EDT) Received: from dcvr.yhbt.net (unknown [64.71.152.64]) by rubyforge.org (Postfix) with ESMTP id 70A0718580F9 for ; Sun, 26 Apr 2009 16:39:13 -0400 (EDT) Received: from localhost (unknown [127.0.2.5]) by dcvr.yhbt.net (Postfix) with ESMTP id 3B5AB1F5D0; Sun, 26 Apr 2009 20:38:35 +0000 (UTC) List-Post: Hi all, I've pushed out a new branch of Unicorn named "gossamer" to my git repo that uses threads. It's mainly to ease integration of Unicorn code into Mongrel, but may even be useful to someone today. Like Unicorn, it only runs on Unix-like systems. I'm not planning on making any release packages for this myself. Here's a snippet of the README: -------------------------- 8< ------------------------- == Unicorn for the masochists that use threads * An experimental fork of Unicorn for deployments where using threads may make some sense: 3rd-party API calls, long-polling, Comet... * This is primarily intended as a staging area for reintegrating Unicorn code into Mongrel. * Both processes and threads are used, each process spawns a predetermined number of worker threads. The total number of concurrent clients is worker_processes * worker_threads. === Differences from Unicorn * Log rotation happens immediately instead of being deferred to happening in-between requests. This means multiline log messages can be split between log rotations. * Threads are used. Meaning all the headaches (and rare benefits) of using them will be exposed to your application code. === Differences from Mongrel * Worker threads are pre-spawned instead of being spawned for every request. This makes memory usage more predictable and should theoretically perform better with native threads under Ruby 1.9. Each worker thread does non-blocking accept on shared sockets. * Everything else that's different from Mongrel in Unicorn... -------------------------- 8< ------------------------- -- Eric Wong