Engine architecture
The BoutiqueDB engine is a Rust rewrite of SQLite. It keeps the SQLite file format and SQL dialect but replaces the query execution, storage, and I/O layers with Rust code.High-level components
Compilation pipeline
I/O model
The engine supports pluggable I/O backends:syscall— generic blocking file I/O.io_uring— Linux kernel-queued async I/O.experimental_win_iocp— Windows I/O completion ports.
async_io enabled, the engine returns TURSO_IO from step() and expects the caller to drive run_io() until the operation completes.
Storage compatibility
- Page size defaults to 4096 bytes.
- The on-disk format is SQLite-compatible for standard tables and indexes.
- Turso-only features (custom index methods, generated columns, materialized views, custom types) may write extra state that SQLite does not understand.
docs/agent-guides/ and docs/internals/mvcc/.
