Fastest method to serve dynamic java content

2009-02-16 Thread keenny

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
-- 
View this message in context: 
http://www.nabble.com/Fastest-method-to-serve-dynamic-java-content-tp22034617p22034617.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Fastest method to serve dynamic java content

2009-02-16 Thread keenny



awarnier wrote:
 
 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-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org
 
 
 

Good points. Generating responses does take some time (several hundred ms),
but this is mainly because it involves calling other services in the cluster
(not cpu-bound that is). To avoid thousands of sleeping threads asynchronous
i/o will be used (i understand tomcat 6 has support for this?). Therefore
the overall throughput will be high, but latency not that good (however
latency is not an issue due to the application characteristics). An added
equirement for my scenario is therefore that async handeling of requests
must be used.

-- 
View this message in context: 
http://www.nabble.com/Fastest-method-to-serve-dynamic-java-content-tp22034617p22035479.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: Fastest method to serve dynamic java content

2009-02-16 Thread keenny

Not in this case, but the requirements this poses on the back-end system is
similar. As explained above, the latency will be high, but so must the
throughput.


awarnier wrote:
 
 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). 
 
 Whenever I see a description like the above, my immediate thought is of 
 some drop-down box a la Google, with suggested values that change while 
 the user is typing.  Is that the kind of thing you`re talking about ?
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org
 
 
 

-- 
View this message in context: 
http://www.nabble.com/Fastest-method-to-serve-dynamic-java-content-tp22034617p22035537.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org