On 4/25/06, Stefano Bagnara <[EMAIL PROTECTED]> wrote:
> AFAIK dnsjava should use weakreferences for its cache. So your
> OutOfMemory should not be related to dnsjava itself.

The YourKit memory snapshots do not include weak and soft references
(unless you do something special when you started the JVM), so the
44MB I'm seeing allocated are strong references.  Also looking at the
changelog, the CacheCleaner thread in dnsjava uses weak references,
but the cache itself does not use weak references.

Actually, it gets a bit worse.  Out of my 52MB heap that is not
gc'able, here is what I see:
- 44MB in an xbill cache held by Lookup code that is held by an avalon
policy class holder.
- 3.2MB in an xbill cache held by DNS server
- 1.7MB in a cache behind java.net.InetAddress

So 49MB or 52MB heap that is not gc'able are from DNS cache entries. :)

Here's a link to some HTML reports:

http://www.lokitech.com/~sergek/james/dnsleak/

--
Serge Knystautas
Lokitech >> software . strategy . design >> http://www.lokitech.com
p. 301.656.5501
e. [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to