Skip to main content

Module sqlite

Module sqlite 

Source
Expand description

SQLite implementations of UserStore and SessionStore.

Tables live in the attached auth database (engine boot ATTACHes data/auth.db AS auth before crate::schema::migrate_sqlite creates them). Queries are schema-qualified (auth.users, …) so the syntax matches the PG store exactly — the auth. prefix resolves against the ATTACH alias on SQLite and against the schema on PG.

Structs§

SqliteSessionStore
Session store backed by auth.sessions. Independent struct from SqliteUserStore because they’re independently mockable in tests and the engine may swap one without the other.
SqliteUserStore
User store backed by a shared SqlitePool. Mirrors super::postgres::PostgresUserStore in shape so callers swap one for the other based on the engine’s selected backend.