maxIdleTime + Tomcat 6.0.23

2013-05-10 Thread Jose María Zaragoza
Hello:


I'm using Tomcat 6.0.23 and I'm looking info about threads created by
Tomcat HTTP Connector for processing requests.

I've seen that

- I cannot define a minSpareThread in Connector , in server.xml . And
default value is 0
I have to create a Executor to be able to define a minSpareThread

am I right ? why ?

- There isn't a property like maxIdleTime in Connector , so idle threads
remain forever
Why isn's there a default value ?

Again , I have to create a Executor to be able to define a maxIdleTime

am I right ? why ?


Thanks and regars


Re: maxIdleTime + Tomcat 6.0.23

2013-05-10 Thread Mark Thomas
On 10/05/2013 20:13, Jose María Zaragoza wrote:
 Hello:
 
 
 I'm using Tomcat 6.0.23 and I'm looking info about threads created by
 Tomcat HTTP Connector for processing requests.
 
 I've seen that
 
 - I cannot define a minSpareThread in Connector , in server.xml . And
 default value is 0
 I have to create a Executor to be able to define a minSpareThread
 
 am I right ?

Yes.

 why ?

Generally, leaving threads idle isn't very expensive. Creating and
destroying threads is expensive. Also, not using an executor allows for
simpler, faster code.

Because the general case by its very nature won't be perfect for
everybody, there are advanced options but that requires an Executor to
implement the more complex thread management that most users don't need.

 - There isn't a property like maxIdleTime in Connector , so idle threads
 remain forever
 Why isn's there a default value ?

There is no property so there can't be a default value.

 Again , I have to create a Executor to be able to define a maxIdleTime
 
 am I right ?

Yes.

 why ?

See above.

Mark


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