Skip to main content

write_file_atomic

Function write_file_atomic 

Source
pub fn write_file_atomic(path: &Path, data: &[u8]) -> Result<(), String>
Expand description

data into path, atomically — the sidecars of a sparse shard (vectors.bin, dims.bin), which fs::write truncated in place just like the postings did. Their bytes are unchanged: no footer, no header, the same bincode a previous version wrote and reads.