The interned tokens the writes applied since the last drain changed —
label ids, relationship-type ids and property-key ids, one dense
append-only id space (crate::store::interner) — plus whether a schema
op landed among them.
One clause operator’s PROFILE metrics, reported to the sink (ADR-0344
phase 2 + the metric-fields phase): the position key (stage, part, clause) — the same walk the plan tree construction uses — beside the
operator’s actuals. Bundled so the sink signature stays at one
argument however many metrics a later phase adds.
One committed index as the facade’s open tail hands it to the DDL
home (ADR-0649 §6): the catalog row’s identity, its typed detail,
and its evaluated options — borrowed from the codec’s carrier, so
no second owned spelling of the carrier exists.
A catalog entry’s replacement (CIP-157’s deprecatedBy): the display
text SHOW FUNCTIONS/SHOW PROCEDURES render and the replacement’s
syntactic form. The form keeps a function/procedure identifier apart
from a Cypher clause, so a notification remedy can name each one for
what it is instead of guessing from the string.
The plan, parameters, source text, and authenticated principal shared by
every execution entry point. query_text is the source text of the
statement (exposed as SHOW TRANSACTIONS’ currentQuery column); the
statement’s CIP-150 version preamble rides on the plan. principal is the
connection’s authenticated principal (ADR-0273), read by
dbms.showCurrentUser; None reports the documented placeholder.
Copy: every field is a reference (or an optional reference) — the
commit path reuses the caller’s request with its own batch-commit
sink attached, without rebuilding the bundle field by field.
The frontier family’s run counters (ADR-0478), one clause’s sum over
its per-seed BFS runs: the edge visits (the work the walk budget
caps), the completed levels, the accepted endpoints, and the NFA
rung’s own PROFILE facts — the (node, state) cells the runs created,
the re-arrival work spent, the rule memo’s hits and misses, and the
admission asks by verdict. Zero on every clause the frontier
declined — levels > 0 is the engagement marker (a run always
completes its level 0).
One execution’s plan-grade probe (ADR-0687 decision 6): the store-read
counters armed and snapshotted at Self::begin, the reading taken at
Self::finish. Dropping an unfinished probe restores the counters’ arm
flag and nothing else — an execution that never finished grades nothing,
and the counters it left armed never extend past the run.
Construction goes through GraphStats::new (the ADR-0218 one-
construction idiom the sibling plan-time stats impls use), so an
inline build cannot drift from it.
The typed, serde-serializable form of a parsed
GraphTypeBody (CIP-176/178/180). Graph-type redo ops
(RedoOp::PutGraphType / RedoOp::SetCurrentGraphType) carry this
model and TheaterData stores it: parsing happens once at
DDL-execution time (GraphTypeSpec::from_body), and redo replay
converts back with GraphTypeSpec::to_body – an infallible,
mechanical conversion, never a re-parse of Cypher text.
The CALL { … } IN TRANSACTIONS batch facts one CallSubquery
operator reports to PROFILE (REL8-2047): the batch counters — how many
batches ran, how many committed, how many rolled back under the ON ERROR policy — and the per-batch maxima: the input batch’s retained
row bytes, the installed output’s, the scratch the batch created
(entities, adjacency and property state — the redo log excluded, its
bytes are the WAL figure), and the redo log’s reserved bytes at commit,
the WAL payload the batch wrote. The counters are arm-local (not global
counter snapshots): the batch loop notes each finished batch into the
shared cell the clause’s record reads once its consumer drains the
stream. All-zero on every other clause, and on an unprofiled run.
Typed payload of RedoOp::CatalogIndexDetail: the catalog facts of
a CREATE INDEX, captured once at DDL-execution time from the parsed
clause. apply_redo stores it verbatim – it never formats a CREATE
INDEX string and re-parses it.
One index’s typed facts as every reader resolves them, through the fixed
precedence the SHOW INDEXES row and the 00NA0 note share: the index’s
IndexDetailSpec, then the owning constraint (a constraint-backed
index), then the legacy IndexDef encoding. No reader re-spells the
chain, so a new detail field lands in every rendering at once.
The expression-memo counters of one operator or statement (ADR-0654,
ADR-0640): the per-memo facts summed over the memos the unit ran,
read once when each memo finishes — a memo’s increments are the
ones already on its path, so collecting them adds none. Zero on
every unit that probed no memo.
The clause’s inclusive phase times (LABS-448): the elapsed time spent
resolving node candidates (the seek — the store work behind the
Nodes kind) and following relationships (the walk — the store work
behind the Rels/Degree kinds); the per-candidate admission checks
and the arm’s binding/cloning stay unattributed. Inclusive of the nesting
a compound operator performs: a walk that triggers nested seeks counts
both, like the table’s Total column. Merged across one streamed
stage’s PROFILE windows (profile_chain.rs), the store-read mix’s
shape.
A read admitted at a caller-pinned timestamp: the graph, the pinned
snapshot_ts, and the schema captured together with that pin under the
publication read guard, plus the request to run and its optional
cooperative cancellation token (ADR-0111; None is never cancelled).
Catalog facts captured alongside an entity pin at read admission. The
caller serializes capture with commit publication; execution needs no
publication lock and never consults newer named schema.
Rollback image of a WriteScratch: its two state halves — the per-batch
state (via the one embedded capture) and the statement-spanning state
([StatementState]: counters and applied count as of the capture) — plus
the redo log’s positional cursor. Cloning the maps is shallow once node and
relationship payloads are Arcs; the redo ops stay with the live log, and
the id allocators are not captured (they never roll back).
The pipelined write batch’s pre-statement rollback image
(WriteScratch::mark_statement): the redo cursor and the
statement-spanning state as of the statement’s entry. Opaque to the facade,
which marks once per batched statement and rolls back when it fails.
The statement-level memo facts (ADR-0654 §3): the constructor memos
live in the query overlay and serve any expression, so they report once
for the whole statement, attached at the plan root — the counters
summed over them and the memo types that were probed.
The store-read mix a clause’s arm performed (LABS-369): the kinds the
single Db Hits total blends. A Rows=103 operator that spent 300k
relationship hops and 0 node reads is a different animal from one that
read 103 nodes — the one-glance diagnosis for the scan-turned-traversal
family. Merged across one streamed stage’s PROFILE windows
(profile_chain.rs): the stage’s record is the checked sum over
its batches, minus the immediate downstream stage’s sum.
The engine-side handle a statement carries for its consumer: wraps the
caller’s RowConsumer with whether it has been engaged (columns were
announced), so the boundary can tell a statement whose rows streamed
from one whose result still sits in its QueryResult — the materialized
forms (writes, EXPLAIN, catalog commands, UNION folds, breakers)
replay their rows through the same sink after the run.
How a MATCH walk chose its start element (LABS-369): the fact the
opaque Expand hid. A displaced start — a cheap index seek that became
a 135k-relationship backward traversal — is named here instead of
showing up only as a large Db Hits total.
What the consumer wants after a batch: the next one, or the end of the
walk. Stop is RowStream::stop for the statement: the terminal stops
its input stream and the statement fails with Error::Cancelled
("query cancelled"), exactly as a cancelled token ends it.
Provenance of a plan-time CONTAINS candidate count (LABS-643): the
TEXT index stays the one exact measurement, and without one the count
comes from a bounded sample scan of the label’s nodes — exact when the
label fits inside the sampler’s bound, an extrapolation beyond it. The
variant, never a bare number, says which: no consumer can mistake the
extrapolation for the measurement, and the sampled form carries the
whole-label scan rows the unseekable filter still pays — the floor the
compound start estimate (ADR-0474) maxes with the
sampled output.
Every plan-time gate’s decline, typed so a test or plan dump names the
gate that kept the DFS. The decline is always safe: the per-row DFS
answers identically. Every gate decides before a single walk — the
rung’s run-time declines are their own type (FrontierRunDecline:
the re-arrival budget and the table ceiling). The PROFILE record
carries either one as a FrontierDeclineReason.
Why a clause’s frontier rung did not serve it, as the PROFILE record
carries it (ADR-0516, extended): either a plan-time gate kept the
clause off the rung before a single walk (FrontierDecline), or the
rung engaged, ran, and fell through (FrontierRunDecline, its
counters recorded beside). One typed sum, so the record’s one field
names the first reason whichever half decided; the wire spells the
same names (plan_keys::DECLINE_REASONS).
The frontier rung’s run-time declines (ADR-0516): the reasons a rung
that engaged and ran still falls through, typed so the PROFILE record
names the one that kept the DFS. The plan-time gates’ own
vocabulary (FrontierDecline) is the other half of the record’s
FrontierDeclineReason — every one of those decides before a
single walk. The rider wiring records it and the metric record
carries it. The variants below are the vocabulary’s single source
(the macro derives ALL and as_str from them); a later run-time
decline adds its variant and its wire name there.
Which rung served one MATCH clause (LABS-1117): the fact EXPLAIN
could not show, because the rungs are runtime choices inside an
operator, not plan nodes. The ladder records it per clause; the
PROFILE record carries it. Walker is the per-row
walker, the rung every decline’s home — the batch scan/filter chain
is its own fact (BatchFacts::ran), never a rung here.
Typed view of a store-level ontology document op (ADR-0120 §3), the
classification RedoOp::ontology_op returns: Set borrows the
verbatim document, Drop carries nothing. Consumers match this once
instead of re-matching the redo variants.
Which pattern engine serves a clause (ADR-0519): a diagnostic-only
switch for the pattern-engine spike — never Cypher syntax, no
query-level spelling, and no stability promise. It dies with the old
engines it switches between.
Rows per result batch (ADR-0555’s batch bound): the terminal’s consumer
deliveries and the materialized path’s replay chunking share the one
bound the inter-clause stream already batches by.
Per-batch commit sink for CALL { … } IN TRANSACTIONS (ADR-0210).
Called by the executor after each successful batch with the batch’s
drained redo ops and the snapshot timestamp they were built against;
the implementation commits them durably (WAL + apply) before the next
batch starts, so live scratch state stays bounded by one batch.
Returns the commit timestamp the batch was applied at — the caller
rebases its scratch onto it, so only the sink (which owns the commit)
ever reads the base graph’s clock.
Per-clause PROFILE metrics sink (ADR-0344 phase 2): the dispatch loop
reports each statement-level clause operator’s metrics once it
finishes, keyed (stage, part, clause) — the same walk the plan tree
construction uses, so the collected entries stamp onto the PROFILE
result’s plan tree without a second mapping.
The caller-supplied sink for a streaming statement’s result (ADR-0682).
The engine calls RowConsumer::columns exactly once, before the first
batch (a RETURN * learns its columns only at its first batch, so the
columns may arrive together with it), then RowConsumer::batch once
per bounded batch of result rows, in row order. The consumer runs on the
statement’s own thread — the connection’s query worker, or the caller’s
thread where the statement itself runs inline — never concurrently with
the pull that produced the batch.
Whether an IN TRANSACTIONS body takes the batch pass (ADR-0669):
one clause-engine pass per batch instead of one nested invocation
per row. Plan-time over the body’s IR, so the plan node renders the
execution strategy in its details.
Whether an IN TRANSACTIONS body takes the batch pass (ADR-0669): a
single flat part, no NEXT stage, non-projecting, with no WITH and
no schema/admin DDL among its own clauses. Everything else about the
body runs in the pass exactly as its clause list would in a plain
statement over the batch’s seed rows — MATCH, procedure CALL,
nested CALL { … }, conditionals, graph-reading expressions
included: pipeline order, one clause-engine invocation and one
nested-budget tick per batch, the per-row statement-engine loop
never entered. The batch commits per batch either way (ADR-0210);
what the pass removes is the per-row invocation, which is pure
overhead — the caller already named the batch.
The replacement when name resolves to a deprecated built-in function,
None otherwise. One typed lookup over the same table SHOW FUNCTIONS
renders, so no caller keeps a second list of deprecated names. A name’s
arity rows share one deprecated_by (the lockstep test below), so the
first row that carries a replacement speaks for every sibling.
The replacement when name resolves to a deprecated built-in procedure,
None otherwise; the procedure-side twin of
crate::function_registry::builtin_function_deprecation and the one
lookup the query-notification detector reads. The registry’s
deprecated_by field is the whole deprecation fact — None means not
deprecated — so the lookup is a field read, never a bridge between two
flags.
Looks up a built-in procedure signature by name, case-sensitively.
Casing sensitivity: built-in function names are
case-insensitive, but built-in procedure names are case-sensitive –
CALL DB.LABELS() is an UnknownProcedure error, only the exact declared
casing (CALL db.labels()) resolves. The validator must agree.
Whether CALL namecould write — the namespace gate’s question: a
store-registered procedure or a built-in flagged writes in the
canonical signature registry (ADR-0116 §4). The gate must never admit a
callable to a read view, so registration alone counts.
The store’s whole-catalog DDL statements (ADR-0481 §3): one CREATE INDEX / CREATE CONSTRAINT statement per named catalog entry, in the
order the checkpoint manifest persists the catalog
(Graph::named_indexes then Graph::named_constraints — the
name-keyed catalog’s order; the catalog keeps no creation sequence).
Every statement is the SHOW INDEXES / SHOW CONSTRAINTScreateStatement rendering — the dialect’s full form, since a schema
mirror must recreate, not hide.
An entry whose renderer returns None — exactly the rows where the
SHOW column is NULL (a legacy detail-less index row, a
graph-type-managed dependent constraint, a kind with no standalone
CREATE form) — is absent: its schema is already carried by the graph
type’s canonical text or the manifest, never a fabricated statement.
The registry-driven explicit-arity check — one half of the runtime
CALL contract ([CallSpec::check_contract]), which every dispatch
path (the generic registry path, the ontology divert, the vector and
fulltext scans) reads: an explicit call passes between required
and total arguments. (The facade’s compile-time validate_calls
already enforces the same contract.)
The passing-mode backstop — the other half of the runtime CALL
contract ([CallSpec::check_contract]): an in-query implicit
call — a CALL with a YIELD, in a clause pipeline — cannot pass
arguments; the procedure’s arguments resolve only in a standalone unit
call. required_args is the caller’s registry truth: the number of
declared parameters without a default (LABS-389: a procedure whose
parameters all carry defaults is callable implicitly). (The facade’s
compile-time validate_calls enforces the same contract before
execution; this is the executor-side backstop.)
The committed schema’s catalog redo group (ADR-0649 §6) — the DDL
home’s own construction, so the catalog policy (the op order, the
detail shape, the option resolution, the held-row retirement) has
one compiler-linked home with CREATE INDEX: a new index kind,
WITH-property rule, or op order added to DDL reaches the store’s
open path through this function, never through a parallel
assembly. Each committed index first retires every catalog row held
under its name or its indexed pair (the committed file is the
source and wins, ADR-0649 decision 2 — a file edit that retargets
or renames an index overrides the machine’s stale row the way any
later commit would, instead of failing the open on the catalog’s
duplicate rules), then records the row and its typed detail in the
DDL path’s own order; the group ends at the current graph type.
The schema-DDL notifications one IR clause raises at EXPLAIN time: the
catalog passthrough’s parsed clause and the IR’s own compact legacy
CreateIndex/DropIndex shapes all dispatch here, so the statement
walker never re-assembles a clause shape across the crate boundary. A
non-DDL clause raises none.
Execute a write-capable plan, then validate the constraints against what
it wrote (ADR-0172). Each call starts a fresh CSV memo even when graph
is reused across statements.
Execute a read-only plan at the caller-pinned timestamp in admission
without repinning. The caller must keep its Graph::pin_now() guard alive
through this call so version GC cannot discard rows visible at
snapshot_ts, and must capture schema alongside that pin while
serializing with graph publication.
execute_read_at with the statement’s batch consumer attached
(ADR-0682): a streaming statement’s terminal RETURN hands each bounded
batch to the sink as it is produced (see [streamable_part]); every
other read shape runs materialized as ever and its result replays
through the same sink — columns once, then bounded batches — before the
call returns. Either way the returned QueryResult carries the
statement’s columns, stats and effect but no rows: the consumer has
them. A consumer answering BatchFlow::Stop ends
the walk and cancels the statement (Error::Cancelled).
Whether name names one of the db.ontology.* procedures (ADR-0121 as
amended by ADR-0227). Derived from the one table so the facade’s
compile-time gates (no-mixed-writes, transaction-mixing, target
namespace) and the executor’s CALL dispatch cannot drift apart.
Whether name names a store-level ontology op (db.ontology.set /
db.ontology.drop, ADR-0120 §3) as opposed to the in-overlay apply
write or the get read. Derived from the one table the way
is_ontology_write_procedure is: the procedure’s signature is flagged
ProcSignature::store_level.
Whether name names a db.ontology.* write procedure (set, drop,
apply — ADR-0121 as amended by ADR-0227): registered with the
prefix AND flagged writes, both read from the one table.
Whether the procedure behind name declares no return columns — the one
void-procedure fact, so the CALL contract validator and the
redundant-OPTIONAL notification detector cannot drift.
Encode an IndexDef.property in the legacy {property}#{KIND}#{name}
format — the encoder half of split_legacy_property_encoding, which
decodes the result back to (property, Some(kind)).
The preview feature gating procedure name (ADR-0378):
Some(PreviewFeature::Ontology) when name resolves to one of the
built-in db.ontology.* registry signatures, None for every other
name. The lookup is by name against the built-in registry only and never
consults the host procedure registry, so a user-registered procedure is
not gated — a host db.ontology.custom, for example, resolves to no
built-in signature and stays ungated.
The committed-schema path’s per-kind index options resolution
(ADR-0649 §6): the same per-kind ConfigPolicy a CREATE INDEX
runs, over the flat option payload a committed ontology envelope
carries. Nests the payload under indexConfig (the one key the
engine’s stored readers navigate), validates the kind’s vocabulary
and values — refusing what a CREATE would reject — and completes
the kind’s defaults, returning the resolved options map the
catalog detail records. Public for the facade’s open-tail
application (relate::committed), the one external consumer: the
committed file is untrusted input, and its option payloads get the
DDL path’s own validation rather than a parallel one.
Decode a legacy IndexDef.property string: split the value catalog_create_index
(and the constraint-backed index
path) into its props head and index kind. A bare property name (no
#) is its own head with no kind. The single decoder for this
format — every reader of IndexDef.property goes through here.
Whether a value satisfies a procedure argument type string (STRING,
INTEGER, LIST<FLOAT>, …). ANY, an empty type, a nullable ?
suffix, and a null value match everything; the accepted type vocabulary
is explicit and fails closed, so an unknown (typo’d or unmodelled) type
name matches nothing. The precise element-type check of a list happens
in the procedure body itself. The canonical home is here, beside the
type strings this registry declares — the facade’s compile-time
validate_calls and the executor’s per-row binder read the one
spelling, so the two cannot drift.