Skip to main content

verify_repository

Function verify_repository 

Source
pub fn verify_repository(
    bones_dir: &Path,
    regenerate_missing: bool,
) -> Result<VerifyReport, VerifyError>
Expand description

Verify sealed shard manifests and parse-sanity-check the active shard.

Sealed shard policy:

  • Every sealed shard (all except latest) must have a manifest.
  • If missing and regenerate_missing is true, regenerate from shard file.
  • Existing manifests must match computed event_count, byte_len, and file_hash.

Active shard policy:

  • The active shard is not required to have a manifest.
  • Active shard content is parsed for TSJSON sanity.

ยงErrors

Returns VerifyError on filesystem access failures.