Prometheus: Difference between revisions

From Halfface
Jump to navigation Jump to search
(Created page with "=prometheus info= =configure scraping= /etc/prometheus/prometheus.yml scrape_configs: # The job name is added as a label `job=<job_name>` to any timeseries scraped from this config. - job_name: "prometheus" # metrics_path defaults to '/metrics' # scheme defaults to 'http'. static_configs: - targets: ["localhost:9090"] - job_name: 'kafka' static_configs: - targets: ["localhost:9091"] # JMX Exporter endpoint for Kafka...")
 
(No difference)

Latest revision as of 09:08, 27 June 2024

prometheus info

configure scraping

/etc/prometheus/prometheus.yml
scrape_configs:
  # The job name is added as a label `job=<job_name>` to any timeseries scraped from this config.
  - job_name: "prometheus"

    # metrics_path defaults to '/metrics'
    # scheme defaults to 'http'.   

    static_configs:
      - targets: ["localhost:9090"]

  - job_name: 'kafka'
    static_configs:
      - targets: ["localhost:9091"]  # JMX Exporter endpoint for Kafka metrics