pub trait PlanMetricsSink {
// Required methods
fn record_clause(&self, record: ClauseMetricsRecord);
fn record_statement_memos(&self, record: StatementMemoRecord);
}Expand description
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.
Required Methods§
Sourcefn record_clause(&self, record: ClauseMetricsRecord)
fn record_clause(&self, record: ClauseMetricsRecord)
The record’s stage is the NEXT-chain position (1-based, matching
the tree’s stage numbering): each NEXT stage restarts its part
indices at 0, so the stage keeps the keys disjoint — without it a
chained statement’s later stage overwrites the earlier stage’s
entries.
Sourcefn record_statement_memos(&self, record: StatementMemoRecord)
fn record_statement_memos(&self, record: StatementMemoRecord)
The statement’s constructor-memo facts, reported once when the statement finished (ADR-0654 §3): they belong to no one operator, so the consumer attaches them at the plan root.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".