Skip to main content

Crate mbx_cache_store

Crate mbx_cache_store 

Source
Expand description

Store inspection and garbage collection.

The store holds six trees: cas/v1 for content-addressed objects, action-results/v1 for the results that reference them, task-manifests/v1 for the prediction index, checkouts/v1 for the checkouts that have built each identity, build-receipts/v1 for exact completed build closures, and sessions/v1 for per-build event streams. Only the first two are collected for size; manifests and receipts are small, checkout records expire with their checkout claims, and session streams are bounded by age and count because they are history rather than cache content.

Structs§

GcOutcome
LargestEntry
ProjectUsage
RemoveProjectOutcome
StoreStats
TransferOutcome
VerifyOutcome

Functions§

checkout_is_live
Whether the checkout a record names is still on disk.
claim_sweep
Atomically stamp a due sweep before its callers perform coordinated GC.
export_checkout
Export the complete local cache closure of this checkout’s most recent build.
export_group
Export the union of every completed build recorded under one CI group.
gc
Evict objects until the store fits within max_bytes.
gc_dry_run
Describe the collection gc would perform without changing the store.
import_archive
Validate a cache export in isolation, then publish its objects and actions.
largest
Return the largest blobs and action-result records in descending order.
projects
Attribute cache and target bytes to each recorded workspace.
record_build_receipt
Record an exact completed build for checkout and grouped exports.
record_checkout
Record that workspace_root built identity.
remove_project
Remove checkout claims belonging to exactly one workspace.
stats
Summarize what the store currently holds.
sweep_if_due
Sweep the store if interval has passed since the last attempt.
verify
Verify every addressable CAS object and action-result record.