Prometheus & PromQL — Care Intel stack

Reference for operators using the workbench. Prometheus UI is opened from Workbench → Prometheus (separate tab). This page is printable and shareable.

Why the UI is not embedded

Prometheus ships a single-page app that loads JavaScript as ES modules from its own origin. Browsers block cross-origin module scripts without permissive CORS, so embedding https://api.care-intel.com:9090 inside an iframe would fail with module load errors. Opening Prometheus in its own tab is the supported path for queries, graphs, alerting, and target health.

Access & ports

Production convention (adjust if your deployment differs):

Local development: use the host and ports from your docker-compose or Laragon reverse proxy; the workbench patches “Open Prometheus” from VITE_API_ORIGIN / services base URL.

Getting started in the UI

  1. Open Prometheus in a new tab from the workbench.
  2. Use the Query box; choose Table or Graph as needed.
  3. Click Execute (or use the keyboard shortcut shown in the UI).
  4. The expression browser stays empty until you run a valid query.

Starter PromQL

Examples aligned with a typical Care Intel stack (node exporter, MinIO, monitoring-api).

API up

up{job="monitoring-api"}

Node disk used % (root mount)

100 - ((node_filesystem_avail_bytes{mountpoint="/",fstype!="rootfs"} * 100) / node_filesystem_size_bytes{mountpoint="/",fstype!="rootfs"})

MinIO cluster capacity (if MinIO job is scraped)

minio_cluster_capacity_usable_free_bytes

Care Intel HTTP request rate

sum(rate(care_intel_requests_total[5m]))

CPU usage (5m rate, example)

100 - (avg by (instance) (rate(node_cpu_seconds_total{mode="idle"}[5m])) * 100)

Memory available ratio

node_memory_MemAvailable_bytes / node_memory_MemTotal_bytes

Care Intel application metrics

The Monitor API may expose counters such as care_intel_requests_total for HTTP traffic. Use rate() or increase() over a range (e.g. [5m]) for meaningful rates. Explore labels with a bare selector filtered by job, e.g. {job="monitoring-api"} in the UI’s metric autocomplete.

Node exporter

Host-level metrics: CPU, memory, disk, network. Mount points and filesystem labels vary by OS; filter mountpoint and fstype to avoid pseudo filesystems.

MinIO

If the MinIO scrape job is enabled, object-storage metrics (capacity, healing, replication) appear with the minio_ prefix. If a query returns no series, confirm targets in Status → Targets.

Alerting & targets

Use Status → Targets to see scrape health. Rules live under Alerts / Rules depending on version; Alertmanager is usually a separate service for routing notifications.