Skip to main content
BoutiqueDB provides low-latency database operations powered by the Rust Turso engine. Follow these tuning techniques to maximize performance in high-throughput applications.

Indexing & Query Latency

Ensure columns used in WHERE, ORDER BY, or JOIN clauses have supporting indexes.
Indexes.swift
Index Verification: Run EXPLAIN QUERY PLAN on complex queries during development to verify index usage and eliminate full-table scans.

Write Performance & Busy Retries

When multiple background tasks perform concurrent database writes, configure TursoOpenOptions to optimize write queueing:

Multi-Process WAL Optimization

For apps utilizing App Extensions (e.g. Share Extensions, WidgetKit, or Background Tasks), enable Multi-Process WAL mode:
MultiProcess.swift
App Group Location: Multi-Process WAL databases must reside within a shared App Group container URL so both the main app and extensions can access the shared memory .shm and .wal files.