Re: [Tomcat] Can I see if 'maxThreads' is exceeded?

2010-11-30 Thread Mark Thomas
On 29/11/2010 22:21, Sylvain Laurent wrote:
 
 On 29 nov. 2010, at 15:01, Mark Thomas wrote:
 
 On 29/11/2010 13:57, sol myr wrote:
 Hi,

 I'm new to Tomcat management, and would appreciate help on the 'maxThreads' 
 property of the Http Connector:

 1) Please tell if I understood correctly:
 Suppose I configure 'maxThreads=100', and 130 users try to simultaneously 
 access my Tomcat - then 100 users will be served immediately, and the other 
 30 will be put on hold? 
 Is this correct?

 Yes.

 2) Is there a way to monitor how many users are 'put on hold' (e.g. 50 on 
 the above example)?

 No. It happens too low down the network stack for Tomcat to be able to
 get this information.
 
 Mark, correct me if I'm wrong, but I believe that actually with an Executor, 
 the acceptor thread still accepts requests and enqueues them in a queue which 
 is unbounded by default. You can monitor the size of this queue with JMX 
 (attribute queueSize on the Executor's thread pool).
 What you refered to is when the acceptor thread does not keepup, the OS 
 enqueues new TCP connections attempts up to a maximum (100 by default for the 
 http basic IO connector).

Executors aren't used by default. I was referring to the tcp backlog.

Mark

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



Re: [Tomcat] Can I see if 'maxThreads' is exceeded?

2010-11-29 Thread sol myr
Sorry, correction: on section 2, I meant to say e.g. 30 on the above example 
(wrote '50' by mistake). Thanks again.

--- On Mon, 11/29/10, sol myr solmy...@yahoo.com wrote:

From: sol myr solmy...@yahoo.com
Subject: [Tomcat] Can I see if 'maxThreads' is exceeded?
To: users@tomcat.apache.org
Date: Monday, November 29, 2010, 5:57 AM

Hi,

I'm new to Tomcat management, and would appreciate help on the 'maxThreads' 
property of the Http Connector:

1) Please tell if I understood correctly:
Suppose I configure 'maxThreads=100', and 130 users try to simultaneously 
access my Tomcat - then 100 users will be served immediately, and the other 30 
will be put on hold? 
Is this correct?

2) Is there a way to monitor how many users are 'put on hold' (e.g. 50 on the 
above example)?
Can I ask tomcat log this information?
Or is this information exposed on the 'manager'? Or via JConsole?

Thanks.



      


  

Re: [Tomcat] Can I see if 'maxThreads' is exceeded?

2010-11-29 Thread Mark Thomas
On 29/11/2010 13:57, sol myr wrote:
 Hi,
 
 I'm new to Tomcat management, and would appreciate help on the 'maxThreads' 
 property of the Http Connector:
 
 1) Please tell if I understood correctly:
 Suppose I configure 'maxThreads=100', and 130 users try to simultaneously 
 access my Tomcat - then 100 users will be served immediately, and the other 
 30 will be put on hold? 
 Is this correct?

Yes.

 2) Is there a way to monitor how many users are 'put on hold' (e.g. 50 on the 
 above example)?

No. It happens too low down the network stack for Tomcat to be able to
get this information.

 Can I ask tomcat log this information?

No.

 Or is this information exposed on the 'manager'? Or via JConsole?

No. No.

Mark

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



Re: [Tomcat] Can I see if 'maxThreads' is exceeded?

2010-11-29 Thread André Warnier

Mark Thomas wrote:

On 29/11/2010 13:57, sol myr wrote:

Hi,

I'm new to Tomcat management, and would appreciate help on the 'maxThreads' 
property of the Http Connector:

1) Please tell if I understood correctly:
Suppose I configure 'maxThreads=100', and 130 users try to simultaneously access my Tomcat - then 100 users will be served immediately, and the other 30 will be put on hold? 
Is this correct?


Yes.


2) Is there a way to monitor how many users are 'put on hold' (e.g. 50 on the 
above example)?


No. It happens too low down the network stack for Tomcat to be able to
get this information.



If you search Google for tcp listen queue size or tcp accept queue size (or 
SOMAXCONN), you will find more information about this.
Depending on your O.S., there may exist utility programs allowing to display the current 
state for a given port/socket.



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



Re: [Tomcat] Can I see if 'maxThreads' is exceeded?

2010-11-29 Thread sol myr
André and Mark - thanks very much for the quick replies.

--- On Mon, 11/29/10, André Warnier a...@ice-sa.com wrote:

From: André Warnier a...@ice-sa.com
Subject: Re: [Tomcat] Can I see if 'maxThreads' is exceeded?
To: Tomcat Users List users@tomcat.apache.org
Date: Monday, November 29, 2010, 6:21 AM

Mark Thomas wrote:
 On 29/11/2010 13:57, sol myr wrote:
 Hi,
 
 I'm new to Tomcat management, and would appreciate help on the 'maxThreads' 
 property of the Http Connector:
 
 1) Please tell if I understood correctly:
 Suppose I configure 'maxThreads=100', and 130 users try to simultaneously 
 access my Tomcat - then 100 users will be served immediately, and the other 
 30 will be put on hold? Is this correct?
 
 Yes.
 
 2) Is there a way to monitor how many users are 'put on hold' (e.g. 50 on 
 the above example)?
 
 No. It happens too low down the network stack for Tomcat to be able to
 get this information.
 

If you search Google for tcp listen queue size or tcp accept queue size (or 
SOMAXCONN), you will find more information about this.
Depending on your O.S., there may exist utility programs allowing to display 
the current state for a given port/socket.


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




  

Re: [Tomcat] Can I see if 'maxThreads' is exceeded?

2010-11-29 Thread Sylvain Laurent

On 29 nov. 2010, at 15:01, Mark Thomas wrote:

 On 29/11/2010 13:57, sol myr wrote:
 Hi,
 
 I'm new to Tomcat management, and would appreciate help on the 'maxThreads' 
 property of the Http Connector:
 
 1) Please tell if I understood correctly:
 Suppose I configure 'maxThreads=100', and 130 users try to simultaneously 
 access my Tomcat - then 100 users will be served immediately, and the other 
 30 will be put on hold? 
 Is this correct?
 
 Yes.
 
 2) Is there a way to monitor how many users are 'put on hold' (e.g. 50 on 
 the above example)?
 
 No. It happens too low down the network stack for Tomcat to be able to
 get this information.

Mark, correct me if I'm wrong, but I believe that actually with an Executor, 
the acceptor thread still accepts requests and enqueues them in a queue which 
is unbounded by default. You can monitor the size of this queue with JMX 
(attribute queueSize on the Executor's thread pool).
What you refered to is when the acceptor thread does not keepup, the OS 
enqueues new TCP connections attempts up to a maximum (100 by default for the 
http basic IO connector).


 Can I ask tomcat log this information?
 
 No.
 
 Or is this information exposed on the 'manager'? Or via JConsole?
 
 No. No.
No. yes (executor queueSize)

Sylvain


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