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: AS33070 50.56.128.0/17 X-Spam-Status: No, score=1.0 required=3.0 tests=AWL,HK_RANDOM_FROM, MSGID_FROM_MTA_HEADER,NORMAL_HTTP_TO_IP,TVD_RCVD_IP,WEIRD_PORT 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: rainbows slower? Date: Fri, 8 Jun 2012 16:31:31 -0700 Message-ID: <20120608233131.GB6086@dcvr.yhbt.net> References: <20120608173920.GA20100@dcvr.yhbt.net> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1339199184 32681 80.91.229.3 (8 Jun 2012 23:46:24 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 8 Jun 2012 23:46:24 +0000 (UTC) Cc: Joseph McDonald To: Rainbows! list Original-X-From: rainbows-talk-bounces-GrnCvJ7WPxnNLxjTenLetw@public.gmane.org Sat Jun 09 01:46:19 2012 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: <20120608173920.GA20100-yBiyF41qdooeIZ0/mPfg9Q@public.gmane.org> User-Agent: Mutt/1.5.21 (2010-09-15) 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:358 Archived-At: Received: from 50-56-192-79.static.cloud-ips.com ([50.56.192.79] helo=rubyforge.org) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Sd8sg-00064k-VF for gclrrg-rainbows-talk@m.gmane.org; Sat, 09 Jun 2012 01:46:15 +0200 Received: from localhost.localdomain (localhost [127.0.0.1]) by rubyforge.org (Postfix) with ESMTP id 01FA03AFF9; Fri, 8 Jun 2012 23:46:13 +0000 (UTC) Received: from dcvr.yhbt.net (dcvr.yhbt.net [64.71.152.64]) by rubyforge.org (Postfix) with ESMTP id 9764F3AFF9 for ; Fri, 8 Jun 2012 23:31:32 +0000 (UTC) Received: from localhost (dcvr.yhbt.net [127.0.0.1]) by dcvr.yhbt.net (Postfix) with ESMTP id A81A41F5A5; Fri, 8 Jun 2012 23:31:31 +0000 (UTC) Eric Wong wrote: > What is your RACK_ENV set to? I'm not sure how Thin sets it or defaults > to, but you can pass the "-E" switch to Rainbows!: > > rainbows -E none ... > > (or use the RACK_ENV environment variable) I suspect it's RACK_ENV being "development" by default and slowing things down heavily (Rack::Lint). I wasn't able to reproduce the drastic differences between thin and Rainbows with RACK_ENV=none on Rack::Lobster. Not a real app I know, but in the absence of a real one, it's all I've got. I used the following config.ru ------------------------------ require "rack/lobster" use Rack::ContentLength use Rack::ContentType run Rack::Lobster.new ------------------------------ and my rainbows.conf.rb ------------------------------ worker_processes 2 # only 2 cores on this machine, I also tried with 1 Rainbows! do use :EventMachine worker_connections 1024 end ------------------------------ thin 1.3.1 rainbows 4.3.1 rack 1.4.1 Ruby 1.9.3-p194 Linux 3.4.1 on x86-64 Commands used: ab -n 1000 -c 100 -k http://127.0.0.1:3000/ RACK_ENV=none thin start -R config.ru RACK_ENV=none rainbows -c rainbows.conf.rb config.ru -p 3000 I tested without keepalives (-k), too but again, it's too close to say one server is faster than another based on Rack::Lobster. For "hello world"-type apps, Rainbows! will use worker_processes more effectively with keepalives. _______________________________________________ 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