Expand description
Shared-memory live metrics registry for microsandbox.
Replaces continuous sandbox_metric inserts into the catalog SQLite
database with a single POSIX shared-memory region. Every running sandbox
owns one fixed slot; readers scan the region to produce typed metrics
responses without per-sandbox RPC or per-sample writes.
Structs§
- Activate
Slot - Caller-supplied data used to transition a reservation to active.
- Live
Metric - Coherent live sample read from a single registry slot.
- Metrics
Registry - Shared-memory registry.
- Metrics
Slot Writer - Per-slot writer handle held by the runtime process.
- Reserve
Slot - Caller-supplied data used to reserve a slot.
- Sample
Write - Sample bytes to write into a slot.
- Sandbox
Metric Snapshot - Metrics plus shared-memory identity metadata for one active sandbox slot.
- Sandbox
Metrics - Point-in-time metrics for a running sandbox (no identity fields).
- Slot
Reservation - Reservation token returned by
MetricsRegistry::reserve.
Enums§
- Live
Metric State - Slot state observed when a
LiveMetricwas read. - Metrics
Error - Errors produced by the metrics registry.
- Release
Mode - Mode passed to
MetricsRegistry::release.
Constants§
- REGISTRY_
ABI_ VERSION - Maximum bytes reserved for a sandbox name inside a fixed metrics slot. Current shared-memory registry ABI version.
- SLOT_
NAME_ BYTES - Maximum bytes reserved for a sandbox name inside a fixed metrics slot. Maximum bytes reserved for the sandbox name inside a slot.
Functions§
- default_
capacity - Default capacity used by the host launcher when creating a registry.
Type Aliases§
- Metrics
Result - Result alias for metrics operations.