docs(server): note whole-file rewrite deviation from save spec
This commit is contained in:
parent
3a634c717d
commit
fa99b6dcea
|
|
@ -158,6 +158,8 @@ impl RegionFile {
|
|||
}
|
||||
|
||||
/// Builds the complete on-disk file image: the encoded index followed by every record.
|
||||
// * NOTE: this is a whole-file rewrite. The right way to do it for large saves is to append changed records into free space and rewriting only the header table, so save cost scales with chunks modified rather than total file size. The free list and absolute offsets already on disk support that switch without a format change.
|
||||
// TODO: incremental save.
|
||||
fn serialize(&mut self) -> Result<Vec<u8>, SaveError> {
|
||||
let index_len = self.index.encode()?.len();
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue