tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Adamczyk, Bartosz" <Bartosz.Adamc...@scansoft.com>
Subject RE: Avg CPU usage growth
Date Wed, 19 May 2004 15:27:43 GMT
Hi Peter,

	Thank you for the input.  This was something that I thought might be
occurring as well, but I wasn't to sure since the session timeout was set to
30 minutes I thought it would simply be invalidated by itself.  I will try
invalidating the session explicitly.

	Thank you,

	Bart

-----Original Message-----
From: Peter Lin [mailto:tcw00lfel@yahoo.com] 
Sent: Wednesday, May 19, 2004 11:21 AM
To: Tomcat Users List
Subject: Re: Avg CPU usage growth

 
I've seen this kind of behavior happen in the past because the HttpSessions
are not getting garbaged correctly, which results in ever increasing heap.
this leads to the GC taking more and more time to mark/sweep the heap.
 
in my case, the HttpSessions were set to expire in 1 week, so over several
hours the memory usage grew steadily. The other thing I've seen is when a
server is under constant load and HttpSession is used to store complex
objects, the VM delays GC which resuls in the heap growing.  The solution to
this particular problem is to explicitly invalidate the session and to clear
all the objects. In my case, the objects stored in the HttpSession has
collections and were hierarchical, so there was lots of circular references.
Once I explicitly invalidate the session and clear the objects, the VM GC-ed
the objects immediately.
 
the problem you see may not be applicable, but hopefully it helps track down
the problem.
 
peter


"Adamczyk, Bartosz" <Bartosz.Adamczyk@scansoft.com> wrote:
Hi everyone,



I have a web application that I am running on Tomcat 4.1.24.
This web application consists of some JSPs, some Servlets and some Tag
Libraries. I did some testing using Jmeter where I logged the results with
PerfMon in Windows XP. I noticed that the average CPU usage grows linearly
as time goes by. For example, if I let the test run for about 16 hours, the
avg CPU goes from 10% to about 40%. I also notice that the Page file bytes
increases with time. All the other counters that I logged look ok.



The web application that I am using uses the httpsession to
store information. I know that the session timeout is 30 minutes on the
Tomcat server that I am running. Is it possible that this might be causing
this increase in average CPU? Can anyone suggest any reasons why this might
be happening? I've never seen the average CPU to grow before so I am
baffled by this.



Any help would be greatly appreciated.



Thank you,



Bart


		
---------------------------------
Do you Yahoo!?
SBC Yahoo! - Internet access at a great low price.

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


Mime
View raw message