ExStorageService.Storage.Manifest (ex_storage_service v0.6.2)

Copy Markdown View Source

Immutable, content-addressed manifests describing multipart objects.

A manifest lists the CAS part blobs a multipart object was assembled from. It is stored twice: a canonical JSON file at {data_root}/cas/manifests/sha256/{p2}/{rest} (the content the hash addresses) and a manifest:sha256:{hash} Concord record for fast reads.

Serving does not use manifests (completed multipart objects are materialized as whole CAS blobs so Content-Length/Range/sendfile semantics are preserved); manifests exist for audit, repair, and future replication/pack phases.

The canonical form is a JSON array — arrays are order-stable, Elixir map key order is not:

["ess-manifest-v1", etag, total_size, [[number, hash, size, etag], ...]]

Summary

Functions

create_manifest(parts, total_size, etag)

get_manifest(manifest_hash)

manifest_path(manifest_hash)