Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

15. System collections

Collections whose name starts with _ are reserved. Some are virtual (computed on read from the engine’s live state), some are stored and written only by ogd. All are read with the full language; writes to them are refused or limited to their own operations.

15.1 Engine state (virtual)

CollectionContent
_memoryOne global row (profile, limits, current and peak bytes, pressure state, RSS, spill and external-group counters) and one row per memory class
_query_memoryQuery admission: a global row and one row per running operation
_memory_eventsRecent memory reservations and releases (a bounded ring)
_index_observationsPer query shape: fingerprint, access path, executions, scanned, returned, elapsed and average µs
on _memory | where scope == "global" | select profile, current_bytes, peak_bytes, pressure_state
on _query_memory | where scope != "global"
on _index_observations | where collection == "orders" | sort executions desc | limit 10

15.2 Modeling

CollectionContentWritten by
_viewsEvery version of every view (chapter 11)define view, undefine view
_cacheOne entry per materialized view and scope (chapter 12)og-core
_cache.v<key>s<slot>The rows of a materialized view in a scopeog-core
_values.v<hash>The rows of a literal values […] sourceog-core, once

15.3 Platform

CollectionContent
_appsInstalled Apps and their definitions
_placesPlaces
_identities, _devicesIdentities and their devices
_permissionsAccess grants
_pools, _policiesCommercial pools and policies (policy enrollment mode)
_event_outboxDurable events waiting for delivery

These are managed by ogd operations and protected by authorization; a Place reads only what concerns it.

15.4 Scope fields

FieldWritten onMeaning
_placeEvery row written in a PlaceThe Place
_app_instanceEvery row written by an App instanceThe App instance

A request in a Place reads only rows carrying its _place (and _app_instance when it names one). Do not write these fields yourself: the Core stamps them.