When does hierarchical federation still make sense?
IntermediateProductionScaling Prometheus, Long-Term Storage & HA
Answer
When a global Prometheus only needs a small set of pre-aggregated series from each cluster: recording rules like job:http_requests:rate5m. It is cheap and simple.
- job_name: federate
honor_labels: true
metrics_path: /federate
params:
'match[]': ['{__name__=~"job:.*"}']
static_configs:
- targets: ['prom-eu-1:9090', 'prom-us-1:9090']
It breaks down for raw data, long retention or many clusters: big /federate scrapes time out and there is no HA. That is when remote_write or Thanos comes in.
More on Scaling Prometheus, Long-Term Storage & HA
What are the practical limits of a single Prometheus server?IntermediateHow do you shard Prometheus scraping, and what do you lose?AdvancedCompare Thanos, Grafana Mimir and VictoriaMetrics.AdvancedThanos sidecar versus Thanos Receive: how do you choose?AdvancedWhat is Prometheus agent mode and when do you use it?IntermediateHow do you tune `remote_write` for high throughput?Advanced