mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-12-04 10:07:28 +01:00
a4de2484f9c0d82b2fe725e28bbbdb4e4a082191
Restore is Fork recorded with Origin restore (same claim semantics: live until the target has a HEAD). Every reader of the fork record accepts OriginRestore; a replay onto a volume of the other origin is refused. MarkIndependent writes the write-once RESTORE-INDEPENDENT entry only when the resolved HEAD holds no ref to another volume (ForeignRefs: owner-qualified keys whose owner is not the volume). Tests: restore records origin/fork record and attaches; replay and origin mismatch; marker refused while foreign refs remain, write-once replay; source snapshot and source volume deleted mid-restore (attach, replay and finish stay normal); GC keeps every chunk the restored HEAD names with the snapshot and the source gone; a restore without a live HEAD never attaches. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Languages
Go
84.5%
Rust
7.9%
Shell
2.7%
templ
1.6%
Java
1%
Other
2%