Expand description
The in-memory tier: a bounded, least-recently-used map from keys to replies, in front of the disk tier (ADR 0015).
A slot is either:
- on disk: its bytes were read from a verified disk entry, or were
written to one, and the slot remembers that file’s
FileStamp. The owner serves it only while the file still has that stamp, so a memory hit is always byte-identical to what the disk tier holds; or - pending: a
PUTwhose disk write is queued (write-behind). No entry file exists for the key yet. Once the write finishes the slot becomes on disk with the new file’s stamp, or is dropped if the write failed or found another entry already there.
This module only keeps the map; the daemon applies those rules.
Structs§
- Memory
Stats - Counters describing the tier’s contents.
- Memory
Tier - The in-memory tier.
- Value
- A cached reply with the effort its entry records.
Enums§
- State
- Where a slot’s bytes stand relative to disk.
Constants§
- SLOT_
OVERHEAD - Bytes charged for each slot on top of its reply.