Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for multi-target exporter scraping #487

Closed
SuperQ opened this issue Mar 1, 2021 · 4 comments · Fixed by #618
Closed

Add support for multi-target exporter scraping #487

SuperQ opened this issue Mar 1, 2021 · 4 comments · Fixed by #618

Comments

@SuperQ
Copy link
Contributor

SuperQ commented Mar 1, 2021

We should deprecate supporting multiple targets in the exporter with the multi-target exporter pattern.

This follows Prometheus best practices better.

@tpoindessous
Copy link

Hi !

You can see another example here : https://github.com/oliver006/redis_exporter

thanks !

@SuperQ
Copy link
Contributor Author

SuperQ commented Apr 29, 2021

@tpoindessous Care to make an implementation? The other PR author seems to have vanished.

@zerthimon
Copy link

Also interested in this feature. Currently I have to run separate prometheus-postgres-exporter process for every master and replicas.

@zerthimon
Copy link

zerthimon commented May 31, 2022

While at it ) it would be nice if this could be configured in a prometheus job, to work with discovery, etc. This is implemented in redis-exporter:

- job_name: redis_exporter
   static_configs:
     - targets:
       - redis://redis1:6379
       - redis://redis2:6379
       - redis://redis-etc:6379
   metrics_path: /scrape
   relabel_configs:
     - source_labels: [__address__]
       target_label: __param_target
     - source_labels: [__param_target]
       target_label: instance
     - target_label: __address__
       replacement: prometheus-redis-exporter:9121

The redis-exporter is then answers on URIs like this http://prometheus-redis-exporter:9121/scrape?target=redis://redis1:6379

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants