On 7 Apr 2006 at 19:00, Michael Bayer wrote:

> the moral of the story is, if "del object" takes the reference count
> down to zero, but Jython is still not going to call __del__ despite
> this, then the connection pooling in SA needs some major changes to
> explicitly count checkouts within the same thread, since the current
> engine implementation relies upon this (i.e. it cant call close()
> flat-out without a checkout counter because the connection might still
> be in use in an enclosing stack frame).
> 
> can we confirm that this is the case ?

Referring to : http://itmaurer.com/jython/htdocs/presentation.html

it says:

Differences between CPython and Jython
Some examples:

    * __del__ is not reliable because the Java garbage collector is used

In other words, __del__ should not be used with Jython, since java garbage 
collection is used and with the JVM, actual collection can be a loonngg time 
coming.

I do not think this is going to change in later versions of Jython.

I believe I've read a number of times that relying on __del__ for "resource 
release" is not recommended. 




-- 
Brad Clements,                [EMAIL PROTECTED]    (315)268-1000
http://www.murkworks.com                          
AOL-IM or SKYPE: BKClements




-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Sqlalchemy-users mailing list
Sqlalchemy-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sqlalchemy-users

Reply via email to