The Prometheus monitoring system and time series database.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
prometheus/prompb
Bartlomiej Plotka cefefc6897
prw2: Move Remote Write 2.0 CT to be per Sample; Rename to ST (start timestamp) (#17411)
2 months ago
..
io/prometheus prw2: Move Remote Write 2.0 CT to be per Sample; Rename to ST (start timestamp) (#17411) 2 months ago
rwcommon Handle error gracefully for the `desymbolizeLabels` function in prompb/io/prometheus/write/v2/symbols.go (#17160) 4 months ago
README.md Improve prompb/readme.md (#17037) 3 months ago
buf.gen.yaml feat(proto): add buf configuration and update dependencies for code generation (#16239) 10 months ago
buf.lock feat(proto): add buf configuration and update dependencies for code generation (#16239) 10 months ago
buf.yaml prompb: add lint ignores for metrics.proto 4 years ago
codec.go Apply analyzer "modernize" to the whole codebase 4 months ago
custom.go [PRW 2.0] Merging `remote-write-2.0` feature branch to main (PRW 2.0 support + metadata in WAL) (#14395) 2 years ago
remote.pb.go prompb: Add histograms to remote write/read protobufs 4 years ago
remote.proto prompb: Add histograms to remote write/read protobufs 4 years ago
types.pb.go Optionally translate OTel histograms to NHCB (#15850) 10 months ago
types.proto Optionally translate OTel histograms to NHCB (#15850) 10 months ago

README.md

This directory contains Protocol Buffer (protobuf) definitions for Prometheus' remote read and write protocols. These definitions are used to serialize and deserialize time series data, such as metrics, labels, samples, and queries, for network communication to Prometheus.

The files here are synced to buf.build, a public protobuf schema registry, from the main branch of the Prometheus repository.

What This Package/Directory Hosts

Protobuf messages and services for:

  • Remote Write: Sending time series data to Prometheus (e.g., WriteRequest, TimeSeries).
  • Remote Read: Querying data from Prometheus (e.g., ReadRequest, Query, ChunkedReadResponse).
  • Core types: Shared definitions like Label, MetricMetadata, and exemplars.

Key files include:

  • remote.proto: Defines the remote read/write services and messages.
  • types.proto: Common types used across protocols.
  • io/prometheus/client/metrics.proto: Client metrics definitions.
  • io/prometheus/write/v2/types.proto: Remote Write v2 protocol types.

Stability Guarantees

These protobuf definitions follow the stability policies of the Prometheus project. Backward-compatible changes may occur in minor releases, but breaking changes are reserved for major versions (e.g., Prometheus 3.0). Experimental or unstable features are clearly marked in the documentation.

How to Change or Contribute

To modify these definitions, view and edit the source in the Prometheus GitHub repository: https://github.com/prometheus/prometheus/tree/main/prompb.

How to Use

Steps

  • Run make proto in the root directory to regenerate the compiled protobuf code.
  • The compiled Go code is version-controlled in the repository, so you typically don't need to re-generate unless making changes.