>From your earlier post:
> a_session.close()
> sa_Session.close_all()
> sa_engine.dispose()
....
> del sa_engine
> but it does not close the connection!
Here's Engine.dispose (line 1152, engine/base.py)
def dispose(self):
self.pool.dispose()
self.pool = self.pool.recreate()
..and here's QueuePool.dispose (the default pool, line 646, pool.py)
def dispose(self):
while True:
try:
conn = self._pool.get(False)
conn.close()
except Queue.Empty:
break
self._overflow = 0 - self.size()
if self._should_log_info:
self.log("Pool disposed. " + self.status())
So the normal path would be to indeed close the connection (but not
necessarily to delete the connection itself, it just falls out of scope).
Can you trace into the dispose() call and verify that these are being run?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---