tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <ch...@christopherschultz.net>
Subject Re: MaxPermSize / Threads
Date Tue, 18 May 2010 12:46:01 GMT
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Ozgur,

On 5/17/2010 5:28 AM, Ozgur Ozdemircili wrote:
> I have the default server.conf file with :
> 
>  <Connector port="8080" protocol="HTTP/1.1"
>                maxThreads="250"
>                connectionTimeout="20000"
>                redirectPort="8443" />
> 
> I do not have any Executor.

<Executor>s are smart enough to close-down inactive request processor
threads after a certain amount of inactivity: regular <Connector>s are
too dumb: once a thread is created, it lives until the <Connector> is
shut down (usually only as the server is being stopped).

If you have 186 active request processor threads, that indicates that
the maximum load you experienced since the last TC startup was 186
simultaneous requests: congratulations! You probably have a
correctly-sized request processor pool for your webapp.

> Just wondering is it normal to have that much open threads waiting?

Not necessarily a problem, but if you were monitoring your webapp
closely, you might want those threads to expire so you could better
track the usage of your webapp during certain periods of time (like,
"nobody uses our app at 0300 but we get a lot of activity at 0500...
maybe we ought to move our backups from 0500 to 0300" or something like
that.

Since you're getting OOMEs, you might want to think about your webapp
and answer this question: what am I doing that can take-up a lot of
memory? XML processing using the DOM API is often a killer, as is any
kind of graphical image manipulation. Another culprit is storing too
much information in user sessions: if each session needs 100MiB and you
need to support 20 users, there's your 2GiB heap.

There are a lot of things that can take up a lot of memory when you
start getting a whole bunch of users together into memory.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkvyjAkACgkQ9CaO5/Lv0PDEuACaA9pKP5bE8imCwHqyAVGjBAfi
vGwAnj+B/Fq47LvEoyQp9dRzspUYfnZZ
=RDuC
-----END PGP SIGNATURE-----

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


Mime
View raw message