Skip to main content

Module residual

Module residual 

Source
Expand description

Residual streams.

A residual is the difference between an expectation a SQL engine had about something and what actually happened — almost every modern engine computes residuals internally and then logs only shallow summaries of them (paneldiscussion.txt in the paperstack lists six families). This module defines the canonical typed residual stream that the DSFB observer and the motif grammar consume.

Residual construction is engine-specific (see the per-class submodules below); residual interpretation is engine-agnostic (see grammar).

Modules§

cache_io
Cache / buffer collapse residuals.
cardinality
Cardinality-mismatch residuals.
contention
Contention residuals.
plan_regression
Plan-regression residuals.
workload_phase
Workload phase residuals.

Structs§

ResidualSample
A single residual sample. t is logical time (seconds since stream start). value is the residual quantity in the class-specific natural units (the units are documented per class in the paper’s Table 2).
ResidualStream
A typed, time-ordered stream of residuals from a single source (one dataset, one engine, one observation window). Construction is the adapter’s responsibility; the stream is otherwise immutable.

Enums§

ResidualClass
The five residual classes emitted by SQL engines that DSFB-Database structures. Names and definitions match Section 3 (Residual Taxonomy) of the paper.