Skip to main content

Metrics

The manager registers these series through Micrometer. They are emitted to whichever sink is active (QOD_METRICS_SINK); under the default Prometheus sink they appear at GET :20900/metrics. For how to scrape, push to a cloud monitor, or import the Grafana dashboard, see Observability.

Application metrics

MetricTypeLabelsMeaning
statements_totalcountertenant, pool, statusStatements executed, partitioned by outcome status. Drives QPS and error-rate panels.
statement_duration_secondshistogramtenant, poolStatement execution latency; the source of the p50/p95/p99 percentiles.
flightsql_sessions_activegauge(none)Currently open FlightSQL sessions.
pool_nodesgaugetenant, pool, roleNode count per pool, broken down by node role.
node_healthygaugetenant, pool, node_id, role1 when the node is healthy, 0 otherwise.
node_draininggaugetenant, pool, node_id, role1 when the node is draining in-flight work before shutdown.
node_in_flightgaugetenant, pool, node_id, roleStatements currently executing on the node.
node_ewma_latency_secondsgaugetenant, pool, node_id, roleEWMA of completed-statement latency, the signal the router uses to pick the least-loaded node.

Routing metrics

Emitted per routed statement by the cache-aware placement layer. The locality series (routing_tables_total, routing_placements_total) run on any routing policy and stay populated even with QOD_ROUTING_CACHE_AWARE=false; the decision and load series describe placement outcomes.

MetricTypeLabelsMeaning
routing_tables_totalcountertenant, pool, resultTable references seen, split into new (first time this table is routed) and repeat (seen before). A low repeat rate means locality has little to exploit.
routing_placements_totalcountertenant, pool, resultRepeat-table routings by whether the table stayed on its last node or switched to another. The switch rate is the locality-loss (scatter) signal: high means placement is being destroyed.
routing_decisions_totalcountertenant, pool, outcomePlacement decisions by outcome: claim, sticky-fresh, sticky-stale, overflow-new-home, overflow-evict-home, pinned-sticky, pinned-move, no-refs-fallback, not-eligible, flag-off. Frequent overflow-evict-home on a pool means three homes are not enough for its hottest tables. pinned-sticky / pinned-move mark statements a transaction pin or soft preferredNode placed rather than the scorer, so they are excluded from the overflow signal.
routing_load_ratiosummarytenant, poolChosen-node in-flight count over the pool average. Should stay under routing.loadCapFactor; a sustained excess means the load cap is not binding.

Maintenance metrics

Emitted per finished managed-maintenance run. These series carry the qod_ prefix; the legacy series above predate the prefix convention.

MetricTypeLabelsMeaning
qod_maint_runs_totalcountertenant, tenant_db, resultMaintenance runs by outcome (succeeded, failed, partial). A rising partial count usually means the pinned-file guard is firing.
qod_maint_bytes_reclaimed_totalcountertenant, tenant_dbCatalog bytes released by runs (physical deletion lags by the cleanup grace window).
qod_maint_files_compacted_totalcountertenant, tenant_dbFiles touched by the merge and rewrite steps.
qod_maint_snapshots_expired_totalcountertenant, tenant_dbSnapshots expired (pinned snapshots are skipped, never counted here).
qod_maint_duration_secondstimertenant, tenant_dbEnd-to-end run duration, including maintenance-node spawn time.

DuckDB engine metrics

Scraped from each node's DuckDB engine (duckdb_memory(), duckdb_temporary_files()) by the background health probe, one extra round-trip per node per QOD_HEALTH_CHECK_INTERVAL_SEC tick. A node that has never been scraped successfully publishes no row (rather than a misleading zero); a failed scrape keeps the previous sample until the next tick.

MetricTypeLabelsMeaning
node_duckdb_memory_used_bytesgaugetenant, pool, node_id, roleBuffer-manager memory in use, summed across all consumers (base tables, hash tables, parquet readers, ...). Compare against the node's memory_limit to spot memory pressure before latency degrades.
node_duckdb_temp_storage_bytesgaugetenant, pool, node_id, roleBytes the buffer manager has moved to temporary storage.
node_duckdb_spill_filesgaugetenant, pool, node_id, roleLive spill-to-disk files. Non-zero means queries are exceeding the memory budget and spilling.
node_duckdb_spill_bytesgaugetenant, pool, node_id, roleTotal size of live spill files.

JVM and process metrics

Registered by the Micrometer JVM and process binders:

MetricTypeMeaning
jvm_memory_used_bytesgaugeHeap and non-heap memory in use.
jvm_gc_pause_seconds_sumcounterCumulative GC pause time.
jvm_threads_live_threadsgaugeLive thread count.
process_uptime_secondsgaugeProcess uptime since manager start.

Common labels

Every series can carry static deployment labels when these are set, useful for separating environments in a shared Grafana:

VariableLabelExample
QOD_METRICS_DEPLOYMENTdeploymentprod-eu
QOD_METRICS_REGIONregioneu-west-1