Connection pooling for DB-API connections.
Provides a number of connection pool implementations for a variety of usage scenarios and thread behavior requirements imposed by the application, DB-API or database itself.
Also provides a DB-API 2.0 connection proxying mechanism allowing regular DB-API connect() methods to be transparently managed by a SQLAlchemy connection pool.
Module | base |
Base constructs for connection pools. |
Module | events |
No module docstring; 1/1 class documented |
Module | impl |
Pool implementation classes. |
Module | dbapi_proxy |
DBAPI proxy utility. |
From __init__.py
:
Class | AssertionPool |
A _pool.Pool that allows at most one checked out connection at any given time. |
Class | NullPool |
A Pool which does not pool connections. |
Class | Pool |
Abstract base class for connection pools. |
Class | QueuePool |
A _pool.Pool that imposes a limit on the number of open connections. |
Class | SingletonThreadPool |
A Pool that maintains one connection per thread. |
Class | StaticPool |
A Pool of exactly one connection, used for all requests. |
Variable | reset_commit |
Undocumented |
Variable | reset_none |
Undocumented |
Variable | reset_rollback |
Undocumented |
Class | AsyncAdaptedQueuePool |
Undocumented |
Class | FallbackAsyncAdaptedQueuePool |
Undocumented |
Function | clear_managers |
Remove all current DB-API 2.0 managers. |
Function | manage |
Return a proxy for a DB-API module that automatically pools connections. |
Remove all current DB-API 2.0 managers.
All pools and connections are disposed.
Return a proxy for a DB-API module that automatically pools connections.
Given a DB-API 2.0 module and pool management parameters, returns a proxy for the module that will automatically pool connections, creating new connection pools for each distinct set of connection arguments sent to the decorated module's connect() function.
Parameters | |
module | a DB-API 2.0 database module |
**params | will be passed through to poolclass |
poolclass | the class used by the pool module to provide
pooling. Defaults to .QueuePool . |