Skip to main content

write

Function write 

Source
pub fn write(
    repository: &impl Repository,
    selection: Selection<'_>,
    cache: &mut impl PackCache,
    buffers: Buffers<'_>,
    output: &mut impl Write,
) -> Result<Outcome>
Expand description

Key/preflight errors, backend errors and corruption propagate with no output. A miss is encoded and verified before insertion. Sink errors may leave partial output and a valid inserted entry; discard that output and retry. Key/integrity work is O(pack bytes + n log n), with n caller ID slots; graph selection and authorization happen separately before this function.