aspose file tools
The moose likes Tomcat and the fly likes Limit the number of requests Tomcat can accept Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Reply Bookmark "Limit the number of requests Tomcat can accept" Watch "Limit the number of requests Tomcat can accept" New topic
Author

Limit the number of requests Tomcat can accept

Mike Anna
Ranch Hand

Joined: Jul 08, 2007
Posts: 112
Hi,

I was wondering if some one could please let me know if there is a way I can limit tomcat from accepting the number of requests it can cater ?

I did google for it and it gave me replies where apache was guarding tomcat and that the number of requests can be limited easily on apache. However I am looking to do this on tomcat.

thanks
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35232
    
    7
Yes, that's possible. Check the conf/server.xml file - it has maxThreads attributes for each Connector. Those limit the number of request processing threads Tomcat will spawn, and thus the maximum number of simultaneous requests Tomcat will work on.


Android appsImageJ pluginsJava web charts
Mike Anna
Ranch Hand

Joined: Jul 08, 2007
Posts: 112
Thanks Ulf for your reply
the maximum number of simultaneous requests


I know that it means the maximum no. of requests it can process at a time. That would also mean, that, THAT is the maximum no. of requests it will accept anytime right ?

thanks again
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35232
    
    7
I'm not sure if connections beyond the max are rejected, or put into a queue for eventual servicing. You'd have to consult the source for that.
 
I agree. Here's the link: http://zeroturnaround.com/jrebel/download
 
subject: Limit the number of requests Tomcat can accept
 
Similar Threads
How does Apache Tomcat server handle the HTTPrequests?
Error when requesting servlet pages after hosting but not on jsp pages
(104)Connection reset by peer: Info in Apache error log
number of users that can access site parally
singlethreadmodel