Skip to main content

Observability Overview

Proxima Console implements the three pillars of observability: logs, traces, and metrics. All three signals share correlation fields (request_id, trace_id) that allow operators to jump between signals when troubleshooting.

Architecture

                     +-----------+
| Browser |
+-----+-----+
|
+-----v-----+
| Nginx |
+-----+-----+
|
+-----v-----+
| Backend |---> stdout (structured JSON)
+--+--+--+--+ |
| | | |
+---------+ | +------+ | (Docker JSON log driver)
| | | |
+----v----+ +---v---+ +--v--+ | +------------+
| DB | | NATS | | VM | +---->| Vector |
+----+----+ +---+---+ +-----+ +-----+------+
| | |
| | +-----v---------+
| +----v----+ | VictoriaLogs |
| | Workers | | :9428 |
| +---------+ +---------------+
|
(OTel SDK)
|
+----v----+
| Tempo |
| :3200 |
+---------+
note

The diagram and the Signal Destinations table below depict the local-dev (Docker Compose) topology. In production (Kubernetes via ArgoCD), pod stdout is handled by the cluster's logging stack and the backend ships agent logs directly to VictoriaLogs — there is no Vector or Docker JSON log driver. See Logs for details.

Signal Destinations

SignalSourceDestinationPortProtocol
LogsDocker stdout (JSON)VictoriaLogs (via Vector)9428HTTP jsonline
TracesOTel SDK (gRPC)Tempo4317OTLP gRPC
Metrics (backend)/metrics endpointvmagent → VictoriaMetrics8080Prometheus scrape
Metrics (agents)Agent → NATS → BackendVictoriaMetrics8480HTTP import

Signal Map

ComponentLogsTracesMetrics
Backend HTTP handlersslog JSON to stdoutOTel spans (otelhttp + manual)proxima_http_requests_total, proxima_http_request_duration_seconds
Auth middlewareslog JSON (ErrorContext)auth.validate_token, auth.resolve_access, auth.check_permissionproxima_auth_login_total, proxima_auth_mfa_verification_total, etc.
NATS workersslog JSON (ErrorContext)process.registration, process.heartbeat, process.inventoryproxima_nats_messages_total
Credential operationsslog JSON (ErrorContext)api.CreateCredential, api.TestCredential, vault.transit.*proxima_credential_operations_total, proxima_credential_encrypt_total, etc.
Config syncslog JSON (ErrorContext)configsync.resolve, configsync.resolve_all, configsync.resolve_credentialsproxima_configsync_push_total, proxima_configsync_apply_total, etc.
Healthcheckslog JSON (ErrorContext)worker.HealthcheckProcess, healthcheck.score.*, healthcheck.triggerproxima_healthcheck_runs_processed_total, proxima_healthcheck_score_calculated
Log collectionslog JSON (ErrorContext)logs.process, logs.query, logs.proxyproxima_logs_entries_processed_total, proxima_logs_query_total
Change detectionslog JSON (ErrorContext)worker.ChangesProcessproxima_changes_processed_total, proxima_file_versions_created_total
Stale detectorslog JSON (ErrorContext)--proxima_stale_hosts_marked_offline_total
Agentslog JSON to stdoutOTel spansHost system metrics (CPU, memory, disk, network)

Correlation Fields

These fields connect signals across the three pillars:

FieldWhere it appearsHow to search
request_idLog fields, OTel span attributes, HTTP X-Request-ID headerLogsQL: "request_id":"abc123" / Grafana Explore (Tempo): tag request_id=abc123
trace_idLog fields (via TraceHandler), OTel spansLogsQL: "trace_id":"abc..." / Grafana Explore (Tempo): by trace ID directly
span_idLog fields, OTel spansLogsQL: "span_id":"abc..."
correlation_idNATS message headersLogsQL: "correlation_id":"abc123"
host_idLog fields, metric labels, DB recordsLogsQL: "host_id":"uuid" / MetricsQL: {host_id="uuid"}

Cross-Signal Correlation Workflow

User report / alert
|
v
Metrics (error rate spike?)
|
v
Logs (request_id → error details + trace_id)
|
v
Grafana/Tempo (trace_id → full span tree)
|
v
Root cause identified
  1. Start with a symptom (error alert, user report, or metrics anomaly)
  2. Find request_id from logs or the X-Request-ID response header
  3. Search logs by request_id to get full request context + trace_id
  4. Open the trace in Grafana Explore (Tempo datasource) to see the span waterfall and pinpoint errors
  5. Check metrics for broader patterns (error rate spikes, latency increases)

Dev vs Production

In local development:

  • When running with go run, logs go to the terminal only, so VictoriaLogs will not capture them
  • Only Docker container logs (backend/frontend running in Docker Compose) are captured by the Vector container-log pipeline, which ships them to VictoriaLogs. Vector and the Docker JSON log driver are a local-dev concept only

In production (Kubernetes via ArgoCD):

  • The backend ships agent logs (the LogsWorker pipeline) to VictoriaLogs over PROXIMA_VICTORIALOGS_URL
  • Pod/container stdout is handled by the cluster's own logging stack — there is no Vector or Docker JSON log driver in production

See Logs for the full production-vs-local-dev breakdown.

Quick Reference

ServiceURLPurpose
Grafana (Tempo)http://localhost:3004Trace visualization and search (via Tempo datasource)
VictoriaLogshttp://localhost:9428Log storage and LogsQL queries
Prometheus metricshttp://localhost:8080/metricsBackend metrics endpoint
Grafanahttp://localhost:3004Metrics dashboards (Executive Overview + Backend Observability + Agent Resources)
NATS monitoringhttp://localhost:8222JetStream stats, connections