[Zope-DB] Closing idle DCoracle2 Connections?
dieter at handshake.de
Sat Oct 22 14:07:28 EDT 2005
Matthew T. Kromer wrote at 2005-10-21 20:39 -0400:
>What happens with Zope and DCOracle2 I think is when the DA
>connection object is ghosted, it doesn't know about it, and thus
>doesn't close its connection.
When the DA instance is ghosted, the "db" object is deleted
(last reference released).
In an optimal world, the deletion of the "db" object would release
the last reference to the DCOracle connection and this
would close the connection to Oracle before the memory
>The close is implicit when the
>connection object is destroyed, but usually there's so much stuff
>loaded that *someone* has a reference to the connection.
That's the bug.
There should be no references to DCOracle resources outside
the "db" object (at least, Zope's DA/ZSQL do not require
such references outside). Thus, when the "db" object goes away,
the "DCOracle" resources should, too.
>However, the code is still geared around OCI8 and some Oracle 9 code,
>its due for some refactoring in a big way to deal with the profusion
>of handle-driven objects now much more prevalent in Oracle 10.
More information about the Zope-DB