0

I set up a monitoring system to track our Jenkins pipelines using Prometheus and Grafana (see Jenkins Prometheus Plugin). I am building some dashboards and while doing so I tried to create a table graph that displays the 5 slowest pipelines. This is the Prometheus query I used: topk (5, max by (jenkins_job) (default_jenkins_builds_last_build_duration_milliseconds / 60000))

Grafana Table Visual

1

However, instead of displaying 5 lines, the table shows numerous timestamps for every pipeline. Does anybody have an idea how to solve this? I tried numerous attemps discribed on stackoverflow (e.g. this), without success. Thanks in advance!

5 slowest Jenkins pipelines, one record each

vimuth
  • 5,064
  • 33
  • 79
  • 116
hillhomes
  • 1
  • 1
  • Check options under where you typed the query, ensure the type is "instant" if you want only most recent data. – anemyte Feb 16 '23 at 15:26

0 Answers0