tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chris Brown" <>
Subject Re: Memory leak with ThreadGroups -> and other stuff
Date Fri, 24 Jan 2003 09:54:38 GMT
Quick follow-on question for Craig...

If you put a JDBC driver in your webapp's /WEB-INF/lib directory, then as
that gets registered with DriverManager, what happens when you reload a
context?  If the DriverManager maintains a reference to the Driver loaded
with the webapp classloader, that must surely cause a few problems for
cleaning up the classloader...

Should this sort of problem disappear with
"DriverManager.deregisterDriver()" ?  Are there other pitfalls of this sort
in the standard Java APIs (I'm thinking of some classes with factory methods
and "helpful" internal caching of instances created via such factory

- Chris

----- Original Message -----
From: "Craig R. McClanahan" <>
Sent: Friday, January 24, 2003 1:49 AM
Subject: RE: Memory leak with ThreadGroups

> If your application is well behaved (i.e. it doesn't have classes in
> common/lib or shared/lib that maintain references to things loaded from
> the webapp), then this will cause the entire webapp to become garbage.  If
> *any* references to *any* classes inside the webapp still exist, though,
> then essentially nothing from your webapp can be collected.

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message