Maintenance • Self-Healing
Database Corruption Recovery
If the local SQLite database is corrupted — an ungraceful shutdown, a disk fault — the engine isolates the damaged file and salvages what it can into a fresh database automatically, with no manual step required. Available now
1. What Happens Automatically
- Integrity check on open: run every time the store is opened, detecting SQLite corruption versus an ordinary transient error (a distinct fix in the recovery code, since misclassifying a timeout as corruption would delete a perfectly good database).
- Corrupted backup isolation (`CorruptedBackupManager`): damaged database files are moved aside into a dedicated backup directory rather than overwritten in place.
- Stream salvage (`SqliteRecoveryEngine`): scans the damaged file for recoverable account configurations and NSQL filter rules, and restores what it can into a fresh database.
No Manual Trigger Needed
This recovery path runs as part of opening the store, not as a CLI command you invoke — there is no separate "run a recovery" step to remember. After a corrupted-and-recovered database, remote mail accounts simply re-sync from the server to rebuild the local cache.