prometheus/scrape
xjewer 0d1a69353e scrape: Add global jitter for HA server (#5181)
* scrape: Add global jitter for HA server

Covers issue in https://github.com/prometheus/prometheus/pull/4926#issuecomment-449039848
where the HA setup become a problem for targets unable to be scraped simultaneously.
The new jitter per server relies on the hostname and external labels which necessarily to be uniq.

As before, scrape offset will be calculated with regard the absolute time, so even
restart/reload doesn't change scrape time per scrape target + prometheus instance.

Use fqdn if possible, otherwise fall back to the hostname. It adds extra random seed
to calculate server hash to be distinguish on machines with the same hostname, but
different DC.

Signed-off-by: Aleksei Semiglazov <xjewer@gmail.com>
2019-03-12 10:46:15 +00:00
..
testdata rename package retrieve to scrape 2018-02-01 09:55:07 +00:00
helpers_test.go rename package retrieve to scrape 2018-02-01 09:55:07 +00:00
manager.go scrape: Add global jitter for HA server (#5181) 2019-03-12 10:46:15 +00:00
manager_test.go scrape: Add global jitter for HA server (#5181) 2019-03-12 10:46:15 +00:00
scrape.go scrape: Add global jitter for HA server (#5181) 2019-03-12 10:46:15 +00:00
scrape_test.go scrape: Add global jitter for HA server (#5181) 2019-03-12 10:46:15 +00:00
target.go scrape: Add global jitter for HA server (#5181) 2019-03-12 10:46:15 +00:00
target_test.go scrape: Add global jitter for HA server (#5181) 2019-03-12 10:46:15 +00:00