mirage / irmin

Irmin is a distributed database that follows the same design principles as Git
https://irmin.org
ISC License
1.85k stars 157 forks source link

irmin-pack: improve control file's atomic write properties #2181

Closed metanivek closed 1 year ago

metanivek commented 1 year ago

Currently, we assume that writes are atomic because the control file is small enough to fit within a page. We could improve this by using a known mechanism for atomic updates, like writing to a temporary file and renaming it.

Context https://github.com/mirage/irmin/pull/2180/files/7b9e971b221b577c26dd533f9f8853bf77967325#r1090672123

metanivek commented 1 year ago

Implemented in #2206