tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Øyvind Hvamstad <oyv...@hvamstad.net>
Subject RE: Release of memory
Date Thu, 02 Jan 2003 17:56:00 GMT
> -----Original Message-----
> From: Shapira, Yoav [mailto:Yoav.Shapira@mpi.com]
> 
> It may not be another tomcat thread.  And conversely, it may be a
> different (possibly new) instance of your servlet.  Does your servlet
> implement SingleThreadModel?

No it does not! That would mean bad performance. I can not have my
clients block.

> Tomcat doesn't hold on to these objects.  Make sure nothing in your
code
> does either.   That way they will be garbage collected.

But if tomcat releases the reference to the servlet, the hole thing
should be garbage collected. The standard way of doing that is by
reference counting, right? And that should be enough, but apparently
not. How does incremental (I run 1.3) gc differ from ref counting? My
code sets variables to null before I "suggest" it to do gc.

> Have you tried any of the other garbage collection tuning parameters
> mentioned in my previous message?   It's worth trying a few runs,
> recording your results, and analyzing them.  You can get vastly
> different memory profiles with the Java runtime options previously
> mentioned.

I might try this when I start optimizing. Now am trying to get it to not
hold all my memory. Could it be a bug? Doesn't tomcat drop the reference
to the hole servlet when do_GET returns? To me it seems that it holds
every thing.

Øyvind Hvamstad


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


Mime
View raw message