mirror of
https://github.com/prometheus/prometheus.git
synced 2026-02-11 19:01:03 +01:00
By running `make update-all-go-deps`. `hashicorp/consul/api` must be held at v1.32.1 because later versions require Go 1.25 and we choose to ensure that Promethes builds with the last two versions of Go. Also: fix compilation errors in remote-write example. Signed-off-by: Bryan Boreham <bjboreham@gmail.com>
Remote Write Adapter Example
This is a simple example of how to write a server to receive samples from the remote storage output.
To use it:
go build
./example_write_adapter
...and then add the following to your prometheus.yml:
remote_write:
- url: "http://localhost:1234/receive"
protobuf_message: "io.prometheus.write.v2.Request"
or for the eventually deprecated Remote Write 1.0 message:
remote_write:
- url: "http://localhost:1234/receive"
protobuf_message: "prometheus.WriteRequest"
Then start Prometheus (in separate terminal):
./prometheus --enable-feature=metadata-wal-records