Monitoring & Metrics

DevGuard exposes health endpoints for Kubernetes probes and optionally integrates with Prometheus and Grafana via the Helm chart's built-in observability stack.


Health Endpoints

Both services expose health endpoints configured as Kubernetes liveness and readiness probes:

EndpointServicePort
/api/v1/healthAPI8080
/api/healthWeb frontend3000

Distributed Tracing & Span Metrics

When api.tracing.enabled: true is set, the Helm chart injects an OTel Collector sidecar into the API pod. The sidecar runs alongside the API container and handles three things:

  1. Receives traces from the API on localhost:4317 (gRPC) — the API is automatically configured to export traces to the sidecar
  2. Generates span metrics — converts spans into Prometheus-format histogram metrics on port 8889
  3. Forwards traces to your backend (Jaeger, Grafana Tempo, or any OTLP-compatible collector)
API container  →  [localhost:4317]  →  OTel Collector sidecar  →  :8889 (Prometheus scrape)
                                                               →  otlpEndpoint (Jaeger / Tempo / ...)

Enable tracing

Add the following to your values.yaml:

For backends that require authentication, provide credentials via a secret:

Create the secret:

Sidecar image and resources

The sidecar uses otel/opentelemetry-collector-contrib. You can tune resource limits and the span metrics configuration:


Prometheus ServiceMonitor (optional)

When using the Prometheus Operator, enable ServiceMonitor resources for automatic scrape target discovery:

The PostgreSQL ServiceMonitor is created whenever observability.serviceMonitor.enabled: true, regardless of tracing. It deploys a postgres-exporter sidecar and scrapes it on port 9187.


Grafana Dashboard (optional)

A Grafana dashboard ConfigMap for the span metrics can be deployed automatically:


Checking logs

For operational visibility without a full observability stack, check the API logs directly:

Have feedback? We want to hear from you!

Fields marked with * are required