Skip to main content
LanceDB emits internal metrics (currently object store request counts, bytes transferred, request latency, retryable errors, and throttles) and can bridge them into any OpenTelemetry backend. Use this to watch how your application interacts with S3, GCS, Azure Blob, or the local filesystem in production: spot latency regressions, catch retry storms, and size your storage tier from real workload data. The bridge is available in the Python and TypeScript SDKs. It is a thin wrapper over LanceDB’s metrics recorder; your application supplies and configures the OpenTelemetry SDK.
This page covers LanceDB Embedded instrumentation. LanceDB Enterprise clusters emit their own metrics from the server side. See Enterprise monitoring below.

Available metrics

Once instrumented, LanceDB registers one observable instrument per metric on your MeterProvider. The current catalog covers the object store layer: The recorder is process-global and pull-based: your configured MetricReader collects on its own schedule, so there is no hot-path overhead beyond the atomic aggregation that LanceDB does anyway.
Histograms are exported Prometheus-style. OpenTelemetry has no asynchronous histogram instrument, so each histogram surfaces as three observable counters: <name>_bucket (with an le attribute per bucket boundary, including +Inf), <name>_count, and <name>_sum. Only _sum carries the histogram’s unit; _bucket and _count are cumulative sample counts.

Python

Install LanceDB with the otel extra to pull in the OpenTelemetry API, plus an OpenTelemetry SDK of your choice. The SDK is intentionally not bundled, so you configure it and its readers and exporters however your platform expects.
Call instrument_lancedb_metrics() once at startup, before opening any tables. It returns True when the recorder is installed and instruments are registered.
If you omit meter_provider, LanceDB uses the global provider returned by opentelemetry.metrics.get_meter_provider().
instrument_lancedb_metrics() returns False and emits a warning if another metrics-crate recorder is already installed in the process. Only one global recorder is permitted, so instrument LanceDB before any other library that installs its own recorder.

TypeScript

Install the OpenTelemetry SDK and exporter in your application:
instrumentLanceDbMetrics() also accepts no arguments, in which case it uses the global provider from @opentelemetry/api. Calling it more than once is safe: instruments are created only on the first successful call.

Build dashboards and alerts

A few starting points for dashboards and alerts:
  • Request rate by operation: rate(lance_object_store_requests_total[1m]) broken down by operation shows read vs. write pressure and helps size ingestion and serving traffic separately.
  • Tail latency: histogram quantiles over lance_object_store_request_duration_seconds_bucket catch object store slowdowns before they surface as query timeouts.
  • Retryable responses: a rising lance_object_store_retryable_responses_total typically means you are being throttled and should back off or shard writes.
  • In-flight requests: a growing lance_object_store_in_flight_requests gauge without a matching rise in throughput indicates queueing.

Enterprise monitoring

Enterprise A deployment emits its own metrics from the server side, using Prometheus for collection and OpenTelemetry (OTel) to export them with data enrichment. No client-side instrumentation is needed. Contact support for the comprehensive metric list and help integrating them with your monitoring dashboard.

Related guides

Performance tips

Tune ingestion, indexing, and query patterns once metrics highlight a hot spot.

Object storage

Configure the object store backends whose requests these metrics measure.