httk.store.backend.sqlite.engine¶
SQLite database construction for Backend.
Functions¶
|
Build an SQLite-backed backend stored in |
Module Contents¶
- httk.store.backend.sqlite.engine.database(cls, path=None, *, degraded=False)¶
Build an SQLite-backed backend stored in
path, or in memory whenpathis None.The in-memory variant is configured (via a static connection pool with a shared, thread-unrestricted connection) so that every connection drawn from the engine sees the one and same database; file-backed databases use SQLAlchemy’s default pooling.
- Parameters:
path (str | os.PathLike[str] | None) – The database file path, or
Nonefor an in-memory database.degraded (bool) – Open with autocommit isolation for degraded-mode access (recovery and inspection) instead of the default transactional isolation.
- Returns:
The configured backend wrapper.
- Return type: