Expand description
WAL frame shipper — continuously reads new WAL frames and uploads them to object storage as segments.
§Sync loop
The run() method loops forever:
- Open the WAL file, find new frames since last sync
- Read frame data into a segment, upload to bucket
- Update the manifest with the new shipped frame count
- Check for manifest conflicts (remote ahead) — fatal if found
§Backoff
On error, exponential backoff from 0.1s to 30s max.
ManifestConflict is fatal — the shipper breaks the loop and the
tokio task exits. The process must restart after re-restore.
§Conflict resolution
Last-write-wins (no consensus). Two concurrent writers can both update the manifest; the later write overwrites the earlier. This is safe when only one node writes at a time (the typical embedded use case).