tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Leon Rosenberg" <rosenberg.l...@googlemail.com>
Subject [OT] A question on garbage collecting
Date Mon, 31 Jul 2006 12:08:53 GMT
Hi,

I have a question regarding a weird behaviour of the garbage
collector, maybe someone here, has more experience with it, and can
answer the question. Otherwise sorry for the OT.

We have a cache for caching 1000.000 user objects along with many
(some hundred thousand) not existing objects (negative cachingto
prevent db requests). The cache is an array of softreferences to the
objects. We used softreferences to prevent oome in case we don'T have
enough ram. However now we do have enough ram - 6 Gb assigned to the
java process, and System.freeMemory is always above 1 gig.

However, I see that through the cache isn't full yet, and there is
plenty of free memory, 500.000 objects have been garbage collected.

Could it be that softreference are collected independent of available
memory? If true, isn't it weird? ;-(

regards
Leon

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


Mime
View raw message