Return-Path: Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: (qmail 33117 invoked from network); 16 Feb 2009 10:37:42 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 16 Feb 2009 10:37:42 -0000 Received: (qmail 35983 invoked by uid 500); 16 Feb 2009 10:37:29 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 35964 invoked by uid 500); 16 Feb 2009 10:37:29 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 35953 invoked by uid 99); 16 Feb 2009 10:37:29 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 16 Feb 2009 02:37:29 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of aw@ice-sa.com designates 212.85.38.174 as permitted sender) Received: from [212.85.38.174] (HELO popeye.combios.es) (212.85.38.174) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 16 Feb 2009 10:37:21 +0000 Received: from [192.168.245.129] (p549EB2C6.dip0.t-ipconnect.de [84.158.178.198]) (authenticated bits=0) by popeye.combios.es (8.13.8/8.13.8/Debian-3) with ESMTP id n1GAal6t014693 for ; Mon, 16 Feb 2009 11:36:50 +0100 Message-ID: <499940AB.7070101@ice-sa.com> Date: Mon, 16 Feb 2009 11:32:11 +0100 From: =?ISO-8859-1?Q?Andr=E9_Warnier?= User-Agent: Thunderbird 2.0.0.16 (Windows/20080708) MIME-Version: 1.0 To: Tomcat Users List Subject: Re: Fastest method to serve dynamic java content References: <22034617.post@talk.nabble.com> In-Reply-To: <22034617.post@talk.nabble.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV 0.92.1/8993/Sun Feb 15 06:53:41 2009 on popeye.combios.es X-Virus-Status: Clean X-Virus-Checked: Checked by ClamAV on apache.org keenny wrote: > Hello all, > > I'm currently working on a system that must be able to serve thousands of > requests per sec. The requests/responses contains only small amounts of data > (ajax XMLHTTPRequests) and are not long lived (connection keep). I'm using > java to generate the responses. Static content are served separately (by > lighttpd). I was just wondering if anybody has any opinions as to how this > can be done most effectively (highest throughput, low cpu consumption etc). > Some alternatives being: > > lighttpd -> mod_proxy -> tomcat -> application code > lighttpd -> fastcgi -> application code > tomcat -> application code > asyncweb/mina -> application code I would think that a key factor not mentioned above is : once your java application gets the actual request, how long does it take it to generate the response (however small the response actually is) ? To be more explicit : you mention thousands of requests per second. To server these, if generating each response takes 1 second, you would need thousands of processes in order just to keep up. There is also a question of bandwidth of course, even for small amounts of data, thousands of requests amount to quite a bit, so to speak. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org