pub async fn read_filesystem<ObjectID: FsVerityHashValue>(
dirfd: OwnedFd,
path: PathBuf,
repo: Option<Arc<Repository<ObjectID>>>,
) -> Result<FileSystem<ObjectID>>Expand description
Load a filesystem tree from the given path, parallelizing verity computation and object storage across available cores.
The directory scan and verity computation run concurrently: as the scan discovers large files, they are immediately dispatched for verity hashing on the async runtime while the scan continues.
Hard links are deduplicated — each unique inode is processed only once.
If repo is Some, file objects are stored in the repository.
If None, fsverity digests are computed without writing to disk.
An optional semaphore can be provided to override the default concurrency
control. When None, the semaphore is derived from the repository (if any)
or from available_parallelism.