Skip to content

jfr2102/fetch-prom-metrics

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fetch-prom-metrics

Fetch List of Prometheus Metrics into and save as csv with help of: parides

prerequisites:

Install parides

pip install parides

usage

  • Include List of Tuples of format ("QUERYNAME", "PROM_QUERY") in querylist.py:
queries = [("QUERYNAME", "PROM_QUERY"),
           ("QUERYNAME", "PROM_QUERY")
]
  • configure resolutiom, start + end time and url in config.py:
resolution  = "10s"
start_time  = (dt.utcnow() - timedelta(minutes=5))
end_time    = dt.utcnow()
url         = "http://PROM_HOST:9090"
  • run e.g. bash python3 fetch.py -> All queries are executed and results stored in prom-metrics/EXECUTIONTIME/QUERYNAME.csv

About

Save list of Prometheus Metrics to file

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages