Skip to main content

record_projected

Function record_projected 

Source
pub(crate) fn record_projected(
    fs: &FileStore,
    agent_uid: &str,
    dir_id: &str,
    file: &str,
    version: &str,
    expected_previous: Option<&str>,
) -> Result<bool, StoreError>
Expand description

Record that dir_id now holds version of file, if its projection is still expected_previous (None: never projected there). Appended only after the file write it describes succeeded. Returns false, writing nothing, when another srv projected meanwhile — the caller re-reads.