Fly.ioAnnouncement
Litestream v0.5.0 is Here
Summary
Litestream v0.5.0 updates the SQLite backup and restore tool with faster operation and efficient point-in-time recovery (PITR). It replaces WAL segment generations with LTX files, an interchange format for ordered page ranges that supports compaction and monotonically incrementing transaction IDs. Hierarchical compaction combines changes across 30-second, five-minute, and hourly levels, allowing restoration to any point in time using only about a dozen files on average and performance limited by I/O throughput. The release keeps old v0.3.x WAL files intact and preserves configuration compatibility, but permits only one replica destination per database and renames litestream wal to litestream ltx. It also adds per-page compression and indexing, removes CGO through modernc.org/sqlite, supports NATS JetStream replicas, updates cloud-storage clients, and previews a VFS for read replicas that can fetch pages from S3 while hydration continues.
Context
Litestream's earlier WAL-based backup model archived whole changed pages and used generations when a process missed WAL continuity. Restoring could require applying many small page changes individually, with each change potentially requiring an object-storage fetch.
Approach / What changed
Version 0.5.0 uses LTX files to represent ordered page ranges and builds a hierarchy of compactions across 30-second, five-minute, and hourly windows. It removes generations in favor of monotonically incrementing transaction IDs, adds per-page compression and an index, limits each database to one replica destination, and introduces NATS JetStream support alongside updated storage clients.
Takeaways
LTX compaction creates 30-second, five-minute, and hourly levels, so restoration to a point in time typically uses only about a dozen files.
The upgrade preserves old v0.3.x WAL files and keeps the configuration format backwards compatible, but a database may now have only one replica destination.
LTX files now use per-page compression and an end-of-file index, enabling page-granular access within large files and supporting future point-in-time queries without downloading the whole database.
Source and freshness
- Source
- fly.io
- Published
- Added to Yomu
- Last updated
Summaries are generated from the original by a language model. Check the original before relying on it.
Keep reading
Related reading
The Good Stuff
Paid picks we use ourselves. Links carry a referral code — a subscription through one earns us a commission at no extra cost to you.
The best engineering reads, once a week
One useful email. Unsubscribe anytime.