Jeroen Frijters wrote:
> There are several places in our codebase were we need/want to cache
> stuff that is associated with a class or class loader. Currently these
> places retain a strong reference to the class loader, which is not
> correct, because the class loader should be garbage collectable.
> 
> I cooked up proposal for an API to use for this and implemented it in
> the three places I could think of off the top my head (serialization,
> proxy and resource bundle).
> 
> This is just a first stab, so no documentation and no change log entry
> yet. Please comment on the idea and/or the API.

Dumb question.. why wouldn't it work to just use a WeakHashMap instead
of a HashMap in all those places?

-Archie

__________________________________________________________________________
Archie Cobbs      *        CTO, Awarix        *      http://www.awarix.com

Reply via email to