403 Matching Annotations
- Mar 2018
-
docs.sqlalchemy.org docs.sqlalchemy.org
-
Session = sessionmaker(bind=some_engine)
A session is bound to the engine and therefore it's resources. When a session is created it grabs a connection from the existing pool of resources bound to the engine.
-
-
github.com github.com
-
if session_factory is None: session_factory = _get_session
I'm pretty sure we have multiple code challenges on this. It doesn't do what you think it does! And regardless it wouldn't do that anyway because the engine and pool are created outside of this statement.
-
_get_session
This is the function that creates a connection pool.
-