• Start

Observability (metrics and Prometheus)

Unified OpenTelemetry metrics, `GET /metrics`, scraper authentication, naming, migration, and behaviour common to Community and Enterprise.

For server log output (stderr, files, JSON, sockets, slow-query lines), see Logging.

Use the tabs below depending on your server version. For OTLP (push), process intervals, and legacy SemConv instruments on the wire, see Telemetry (OTLP). For SurrealDS metrics, audit and slow-query file sinks, and OTLP log export opt-ins, see Enterprise observability.

Prior to SurrealDB 3.1, operators often saw overlapping metric paths: built-in Prometheus exposition could run alongside a separate OpenTelemetry pipeline oriented around HTTP/RPC semantic conventions. The same request could therefore be reflected more than once, under different scopes and label keys (for example http.server.* / rpc.server.* versus surrealdb.*-style families).

Many deployments also emitted parallel families for the same logical signal — aggregate counters or histograms plus higher-cardinality “dimensional” variants (names with a *_dim_* segment, or separate *_errors_total series). Dashboards and alerts had to choose which family to query, and mixing them could double-count.

Edition (community vs enterprise) could appear on meter scope identifiers (for example in otel_scope_name after export to Prometheus). That tied dashboards to build flavour at the scope level and made renames risky.

Tenant context (namespace, database, user, and similar) could be attached to labels in more ad hoc ways across recording sites, so you should treat unauthenticated /metrics scrapes as potentially sensitive in multi-tenant layouts unless you had a deliberate proxy or allowlist in front of the endpoint.

For the OTLP side of the same era (push interval, http.server.* / rpc.server.* instruments, deprecated variables), use the Before SurrealDB 3.1 tab on Telemetry (OTLP).

When you upgrade to 3.1 or later, replan dashboards and alerts using the migration material in doc/OBSERVABILITY.md in the open-source repository (and the Enterprise companion, if you run SurrealDB Enterprise).

Was this page helpful?