Skip to content

Testing the `prometheus_remote_write` sink

Pavlos Rontidis edited this page Aug 10, 2023 · 5 revisions

WIP

Grafana Agent with Mimir

Setup

git clone https://github.com/grafana/agent.git grafana-agent
cd /path/to/grafana-agent/example/docker-compose
docker-compose up -d

# when you are done testing, run the following command:
docker compose -f deployment/docker/docker-compose-cluster.yml stop

Config

sources:
  internal_metrics:
    scrape_interval_secs: 5
    type: internal_metrics

sinks:
  victoriametrics:
    inputs:
      - internal_metrics
    endpoint: http://localhost:9009/api/v1/push
    type: prometheus_remote_write
    request:
      concurrency: adaptive

Victoria Metrics

Setup

git clone https://github.com/VictoriaMetrics/VictoriaMetrics
cd VictoriaMetrics
docker compose -f deployment/docker/docker-compose-cluster.yml up -d

# when you are done testing, run the following command:
docker compose -f deployment/docker/docker-compose-cluster.yml stop

Config

sources:
  internal_metrics:
    scrape_interval_secs: 5
    type: internal_metrics

sinks:
  victoriametrics:
    inputs:
      - internal_metrics
    endpoint: http://localhost:8480/insert/0/prometheus
    type: prometheus_remote_write
    request:
      concurrency: adaptive