Expand description
Object-store trait (put/get/head/delete/list_prefix + conditional put_if)
shared by scryer’s long-tier Parquet shard storage, the cloud reconciler’s
R2 mirror publish, turso-backup’s WAL→R2 sink, and the yah cloud bucket
CLI + data-tab bucket viewer.
Lifted from scryer::long_tier in R498-F1. R2ObjectStore landed in F2.
put_if / etag (linearizable compare-and-swap on a single object) added
for the W243 global tenant→cell pointer — see .yah/docs/working/ W243-multi-cell-tenant-mobility.md.
@yah:ticket(R498-F1, “lift ObjectStore trait + InMemoryObjectStore into crates/yah/object-store/”) @yah:at(2026-06-09T03:37:49Z) @yah:status(review) @yah:parent(R498) @yah:handoff(“Lifted ObjectStore trait + InMemoryObjectStore from scryer::long_tier into new crates/yah/object-store/ crate (yah-object-store package, yah_object_store lib). Trait gained head() with default impl over get(), and delete() (idempotent). Generic Error enum (NotFound/Io/Auth/Backend) replaces the old LongTierError::ObjectStore(String) error path. scryer/long_tier.rs now does pub use yah_object_store::{Error as ObjectStoreError, InMemoryObjectStore, ObjectStore} — every existing call site keeps working unchanged. LongTierError gained #[from] ObjectStoreError variant. cargo check –workspace exit 0; 5/5 object-store unit tests pass. NOTE: scryer’s full lib test target was already broken on main (pre-existing missing-.await calls in adapters/journald.rs, adapters/containerd_logs.rs, service.rs — touching 20+ sites) — those are NOT introduced by F1; isolated long_tier tests cannot be run until that gets cleaned up separately.”)
Re-exports§
pub use http_ro::HttpReadOnlyObjectStore;pub use r2::ObjectMeta;pub use r2::R2ObjectStore;
Modules§
- http_ro
- Unauthenticated, read-only object store over plain HTTPS (R599-T5).
- r2
- Cloudflare R2 implementation of
ObjectStoreover S3-compat SigV4.
Structs§
- InMemory
Object Store - In-memory object store for tests and local development.
Enums§
- Error
- Errors a backend may raise.
- Precondition
- Precondition for a conditional write (
ObjectStore::put_if).
Constants§
- CACHE_
CONTROL_ IMMUTABLE - Re-exported so a caller choosing a directive for
ObjectStore::put_cachednever has to retype the string — two publishers spellingno-cache, max-age=0slightly differently is a difference no test catches and every CDN honours.Cache-Controlfor immutable, versioned, content-addressed objects. Matches what.github/workflows/release.ymltags them with, so an object published by the CLI is indistinguishable from one published by CI. - CACHE_
CONTROL_ NO_ CACHE - Re-exported so a caller choosing a directive for
ObjectStore::put_cachednever has to retype the string — two publishers spellingno-cache, max-age=0slightly differently is a difference no test catches and every CDN honours.Cache-Controlfor a mutable pointer at a fixed key —latest.json, a release manifest, an index. Also matchesrelease.yml.
Traits§
- Object
Store - Minimal synchronous object-store surface.