Hi Edmund

On Mon, 28 Oct 2002, Edmund Lian wrote:
> >Could the problem of leaking DB connections be at all related to how DBPool.py
> >doesn't actually close connections on being deleted? I'm actually using
> >multiple instances of a refactored version of DBPool.py to maintain multiple
> >pools. The code doesn't actually close the connections when the instance is
> >deleted.
>
> OK, I've educated myself--sort of... I added code to close connections, and
> called the code from __del__ definitions. It doesn't help since the restart
> doesn't seem to call __del__ at all. A real shutdown of the app server does
> cause __del__ to be called. Why is this (just asking to understand what's
> going on)?

The actual __del__ will only be called when the object which contains
the __del__ method is garbage-collected, i. e. when there are no more
references to the object. It seems that the exec doesn't affect the
existing references which is in line with the observations that
started this discussion.

Stefan



-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Webware-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/webware-devel

Reply via email to