> For the complete documentation index, see [llms.txt](https://docs.deltastream.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.deltastream.io/reference/metrics/built-in-metrics.md).

# Built-In Metrics

Queries in DeltaStream are long-lived and continuous. While DeltaStream provides its own tools to notify and alert you if your queries are misbehaving, you may want also to monitor queries from their own observability stacks. This document lists the built-in metrics that DeltaStream exposes so you can monitor your queries.

See [`CREATE METRICS INTEGRATION`](/reference/sql-syntax/ddl/create-metrics-integration.md) for consuming the metrics in this document.

<table><thead><tr><th width="440">Metric Name</th><th width="127">Value Type</th><th>Description</th></tr></thead><tbody><tr><td><code>deltastream_query_consumerRecordsLagMax</code></td><td>Integer</td><td>Reports the Kafka Consumer lag in number of records that are currently behind.</td></tr><tr><td><code>deltastream_query_numRecordsInPerSecond</code></td><td>Integer</td><td>Reports current number of records being processed in per second.</td></tr><tr><td><code>deltastream_query_numRecordsOutPerSecond</code></td><td>Integer</td><td>Reports current number of records being processed out per second.</td></tr><tr><td><code>deltastream_query_numBytesInPerSecond</code></td><td>Integer</td><td>Reports current size of records being processed in per second. Values returned as binary bytes unit.</td></tr><tr><td><code>deltastream_query_numBytesOutPerSecond</code></td><td>Integer</td><td>Reports current size of records being processed out per second. Values returned as binary bytes unit.</td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.deltastream.io/reference/metrics/built-in-metrics.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
