Skip to main content
cd ../lexicon
sys/docs/lexicon/prometheus.md
Lexicon
Prometheus

Prometheus

Prometheus is a monitoring and alerting system that collects time-series metrics and evaluates them against queries and rules. Operate it as a bounded workflow: verify target discovery, metric ingestion and rule results, and preserve a known-good configuration for recovery.
Difficulty: Introductory
5 min read
Updated 2026-08-27

In plain English

Plain definition

Prometheus is a monitoring and alerting system that collects time-series metrics and evaluates them against queries and rules. Operate it as a bounded workflow: verify target discovery, metric ingestion and rule results, and preserve a known-good configuration for recovery.

Technical definition

Prometheus collects time-series data, commonly by retrieving metrics from configured endpoints. Each series is identified by a metric name and labels, while each sample associates a value with a time. Prometheus stores the resulting data and provides a query language for selecting and aggregating series. Rules can evaluate queries to create derived series or alert states.

The precise configuration surface and supported behaviour can vary by release. Confirm the deployed version against the official documentation before relying on version-sensitive syntax or defaults.

Operational relevance

A bounded Prometheus workflow starts with one known test target and one expected metric. Practitioners can then observe each stage: the target is discovered, collection succeeds, samples become queryable and any associated rule produces the expected state. This narrow scope separates collection faults from query or rule faults and limits the effect of a mistake.

Observable success means that the intended target appears in discovery, its collection health is successful, a query returns recent expected samples and relevant rules evaluate without reported errors. A successful query alone is insufficient if its data is stale, unexpectedly labelled or collected from the wrong target.

Common failure modes include an unreachable metrics endpoint, a discovery or label mismatch, malformed configuration, rule-evaluation errors and unexpected gaps in samples. High-cardinality labels can also increase operational cost and complicate queries; acceptable limits depend on the environment and require local capacity evidence.

Architecture relationship

Prometheus sits between instrumented or exporting systems and consumers of monitoring results. Targets expose metrics; discovery and collection logic determine what Prometheus retrieves; storage retains samples; queries and rules interpret them; alert states may then be sent to a separate alert-handling component. Dashboards or other clients can query Prometheus but do not prove that collection is complete or correct.

This architecture creates security boundaries. Metrics endpoints can reveal operational details, and access to configuration or rule management can alter monitoring outcomes. Use least privilege, restrict network reachability appropriately and avoid placing secrets in labels or metric values. Residual risks include incomplete instrumentation, stale data, excessive series growth and alerts that technically evaluate but do not represent user impact.

Example

Suppose a non-production HTTP service exposes a request counter. The operator defines success before making any change: the single test target must be discovered, collection must succeed, a query for the counter must return a recent sample with the expected labels, and a test rule must evaluate without error.

  1. Record the confirmed Prometheus version, test target, expected metric name and current known-good configuration.
  2. Have an authorised human review the proposed target and rule against documentation for that version.
  3. Apply the reviewed change only through the organisation’s established reversible process; no generic change command is supplied here because the source record does not verify a deployment method.
  4. Inspect target discovery and collection health, then query the metric and inspect rule evaluation.
  5. Stop if the configuration is rejected, the target is unexpected, collection fails, labels differ materially or existing checks regress.

Recovery means restoring the recorded known-good configuration through the same controlled process, validating that the prior targets and rules return to their baseline state, and escalating if restoration does not recover that state. Do not delete stored data merely to clear a symptom.

Misunderstanding

A common misunderstanding is that installing Prometheus automatically provides complete observability. Prometheus can only collect metrics that targets expose and that its discovery and collection configuration reaches. Useful monitoring also depends on meaningful instrumentation, stable labels, queries, rules, capacity planning and an operational response path.

Another misunderstanding is that an active alert proves a service failure. An alert is the result of a rule evaluated over available data. Practitioners should distinguish that fact from the inference that users are affected, then corroborate it with service-level evidence.

  • Metric: a named numerical measurement represented over time.
  • Time series: samples associated with a metric identity and labels across time.
  • Label: a key-value dimension used to distinguish and select series.
  • Target: an endpoint or monitored instance from which metrics are collected.
  • Query: an expression used to select, transform or aggregate time-series data.
  • Recording rule: a rule that evaluates an expression and stores its result as a new series.
  • Alerting rule: a rule that evaluates conditions and produces an alert state.

Further reading

Consult the Prometheus documentation for canonical concepts and the instructions matching the deployed release. Before approving a workflow, a human reviewer should confirm the product version, permissions, deployment method and version-specific validation interfaces.

The next safe decision is to proceed only when the test scope, baseline and recovery owner are recorded. If discovery, ingestion, query freshness or rule evaluation cannot be verified independently, retain the existing configuration and escalate rather than broadening the change.