tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Eggers <>
Subject Re: Fw: Tomcat 6 query
Date Sun, 04 Nov 2012 18:16:16 GMT
Comments in line (warning - this is done before coffee):

On 11/3/2012 8:59 PM, vicky wrote:
> Thanks christopher.
> I am using Probe application for monitoring the Tomcat application , in that
> everything is getting displyed fine except the  "Min Spare Threads" & " Max
> Spare thread"
> Ques1 :
> ======
> Both attributes have the value as Zero. As you said in below post that *Max
> Spare Threads* is not anymore so Zero valus is expected for this but why the
> "Min Spare Thread" value is zero. As per below documentation , default value is
> 25 for *Min Spare threads*, Any thoughts why is it like that.
> for your reference i am enclosing the server.xml & Probe application screenshot

Normally attachments get stripped by the mailing list. I suspect that 
the reason I received them is because we're both on Yahoo.

Your server.xml is not using Executors, and the Probe screen shot shows 
the normal HTTP and AJP connector pools as expected.

If you uncomment the Executor element in server.xml and use it in one or 
more connectors, you'll see the Executor thread pool in Probe. The name 
will be the name that you gave it in server.xml

Min Spare Threads shows up as it is configured in server.xml. Max Spare 
Threads appears to follow largestPoolSize (according to VisualVM). This 
appears to be a Probe issue.

If you mix and match (for example, using Executors for HTTP/HTTPS and a 
private pool for AJP), then you'll see the appropriate thread pools in 

> Ques 2:
> ======
> As MaxThreads & MinThreads are in executor now  ,does that mean whatever i
> threads count i define here will get shared across Http,Https,Ajp protocol ?

You can mix and match. You can define some Connectors to use the 
Executor thread pool, and others to use a private thread pool. You can 
define multiple Executor thread pools for sharing between different 
groups of Connectors.

If you don't configure a Connector to use an Executor, then it won't.

So in order to use an Executor, you need to configure two items.

1. The Executor

One or more, depending on your use case.

2. The Connector

Every Connector that should use an Executor needs to be configured to 
use one explicitly. There are examples in the supplied server.xml

> ques3
> ====
> how i can achieve Protocol based (http/Ajp) thread allocation in case if i dont
> want it to use it from executor

I don't think you can without using an Executor.

> /Thanks/
> /Vicky/
> *From:* Christopher Schultz <
> <>>
> *To:* Tomcat Users List < <>>
> *Sent:* Friday, 2 November 2012 11:05 PM
> *Subject:* Re: Tomcat 6 query
> Hash: SHA1
> Vicky,
> On 11/2/12 4:40 AM,
> <> wrote:
>   > Thanks mark.
>   >
>   > I concern why the  minSpareThreads" & "maxSpareThreads" attributes
>   > dont exist at the below URL anymore
>   >
>   >>
>   >
>   > As in tomcat 5 , i am able to locate http connector
> This stuff isn't in the <Connector> anymore: it's in the <Executor>.
> So, configure your Tomcat 6 connector to use an executor, then use
> minSpareThreads on it. There is no maxSpareThreads anymore, only
> maxThreads.
> Again:
> - -chris

. . . just my two cents.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message