From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on dcvr.yhbt.net X-Spam-Level: * X-Spam-ASN: AS14383 205.234.109.0/24 X-Spam-Status: No, score=1.0 required=3.0 tests=AWL,HK_RANDOM_FROM, MSGID_FROM_MTA_HEADER shortcircuit=no autolearn=no version=3.3.2 Path: news.gmane.org!not-for-mail From: Eric Wong Newsgroups: gmane.comp.lang.ruby.rainbows.general Subject: Re: [ANN] Rainbows! 4.0.0 - MOAR concurrency for MOAR COARS Date: Wed, 29 Jun 2011 07:19:05 +0000 Message-ID: <20110629071905.GA6838@dcvr.yhbt.net> References: <20110627094517.GA27156@dcvr.yhbt.net> <20110629071101.GA8110@dcvr.yhbt.net> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1309333586 1274 80.91.229.12 (29 Jun 2011 07:46:26 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 29 Jun 2011 07:46:26 +0000 (UTC) To: Rainbows! list Original-X-From: rainbows-talk-bounces-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Wed Jun 29 09:46:23 2011 Return-path: Envelope-to: gclrrg-rainbows-talk@m.gmane.org X-Original-To: rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Delivered-To: rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Content-Disposition: inline In-Reply-To: <20110629071101.GA8110-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org> User-Agent: Mutt/1.5.20 (2009-06-14) X-BeenThere: rainbows-talk-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: rainbows-talk-bounces-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Errors-To: rainbows-talk-bounces-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Xref: news.gmane.org gmane.comp.lang.ruby.rainbows.general:276 Archived-At: Received: from rubyforge.org ([205.234.109.19]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QbpTZ-0000cP-Tq for gclrrg-rainbows-talk@m.gmane.org; Wed, 29 Jun 2011 09:46:22 +0200 Received: from rubyforge.org (rubyforge.org [127.0.0.1]) by rubyforge.org (Postfix) with ESMTP id 58F701858361; Wed, 29 Jun 2011 03:46:21 -0400 (EDT) Received: from dcvr.yhbt.net (dcvr.yhbt.net [64.71.152.64]) by rubyforge.org (Postfix) with ESMTP id A061D185834E for ; Wed, 29 Jun 2011 03:19:06 -0400 (EDT) Received: from localhost (dcvr.yhbt.net [127.0.0.1]) by dcvr.yhbt.net (Postfix) with ESMTP id 2A5281F78C; Wed, 29 Jun 2011 07:19:06 +0000 (UTC) Eric Wong wrote: > ghazel-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org wrote: > > I can't seem to upgrade from rainbows-3.4.0 to rainbows-4.0.0. I see: > > > > # > > That's odd, what configuration options and Ruby version are you > using? Are you using a per-worker listen socket? This should fix it, the test case for this was broken, too :< diff --git a/lib/unicorn/http_server.rb b/lib/unicorn/http_server.rb index 02ba965..78d80b4 100644 --- a/lib/unicorn/http_server.rb +++ b/lib/unicorn/http_server.rb @@ -453,7 +453,7 @@ class Unicorn::HttpServer def after_fork_internal @ready_pipe.close if @ready_pipe Unicorn::Configurator::RACKUP.clear - @ready_pipe = @init_listeners = @config = @before_exec = @before_fork = nil + @ready_pipe = @init_listeners = @before_exec = @before_fork = nil srand # http://redmine.ruby-lang.org/issues/4338 @@ -545,6 +545,7 @@ class Unicorn::HttpServer after_fork.call(self, worker) # can drop perms worker.user(*user) if user.kind_of?(Array) && ! worker.switched self.timeout /= 2.0 # halve it for select() + @config = nil build_app! unless preload_app end diff --git a/test/exec/test_exec.rb b/test/exec/test_exec.rb index 0f6b083..8c33457 100644 --- a/test/exec/test_exec.rb +++ b/test/exec/test_exec.rb @@ -516,7 +516,7 @@ EOF File.unlink(tmp.path) ucfg = Tempfile.new('unicorn_test_config') ucfg.syswrite("listen '#@addr:#@port'\n") - ucfg.syswrite("before_fork { |s,w|\n") + ucfg.syswrite("after_fork { |s,w|\n") ucfg.syswrite(" s.listen('#{tmp.path}', :backlog => 5, :sndbuf => 8192)\n") ucfg.syswrite(" s.listen('#@addr:#{port2}', :rcvbuf => 8192)\n") ucfg.syswrite("\n}\n") -- Eric Wong _______________________________________________ Rainbows! mailing list - rainbows-talk-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org http://rubyforge.org/mailman/listinfo/rainbows-talk Do not quote signatures (like this one) or top post when replying