connetion are not disconntected when set pool_size=0 (documentation)

Issue #1164 resolved
Anonymous created an issue

version tested: SQLAlchemy 0.5.0rc1

I use engine like this, I set pool_size=0,

engine = create_engine('mysql://root:password@localhost/test', pool_size=0, max_overflow=2, echo=True)

I like the behavior will be: establish a connection with mysql when I need it and release all connections when I close all sessions. I don't need the pool to keep "sleeping" connetions.

but it sames that all the two connections don't release at all.

If I set pool_size >= 1, the pool works correctly.

Is it a bug or not?


Comments (6)

  1. Anonymous
    • removed status
    • changed status to open

    I think the special meaning of pool_size=0 is a deficiency of the documentation; patch attached.

  2. Log in to comment