Expand description
Segment Manager
Manages the lifecycle of unified segments: creation, sealing, consolidation, and archival. Coordinates writes to growing segments and queries across all segments.
§Responsibilities
- Route writes to the active growing segment
- Auto-seal segments when thresholds are met
- Coordinate queries across multiple segments
- Paced consolidation of sealed segments (ADR 0073 §5)
- Archive old segments to cold storage
Structs§
- Consolidation
Stats - Consolidation counters for one collection (ADR 0073 §5).
- Manager
Config - Configuration for the segment manager
- Manager
Stats - Manager statistics
- Paged
Entity Cursor - Frozen base/overlay cursor for a lazy query source. The source generation remains pinned through the owned page cursor, not a manager topology lock.
- Segment
Manager - Segment manager for a collection
- Segment
Scan Stats
Enums§
- Lifecycle
Event - Lifecycle events for monitoring
Constants§
- CONSOLIDATION_
ENTITIES_ PER_ TICK - Entities copied into the merged segment per maintenance tick.
- CONSOLIDATION_
FRAGMENTATION_ RATIO - Fraction of a collection’s sealed bytes that consolidation would return to
the budget (dead entity payloads plus the tombstone sets that bury them)
before consolidation is worth its cost. See
CONSOLIDATION_TOMBSTONE_RATIOon tunability. - CONSOLIDATION_
TOMBSTONE_ RATIO - Fraction of a collection’s sealed entities that must be tombstoned before consolidation is worth its cost.