prometheus: Prometheus 3: Performance of target list is bad
What did you do?
- Go to
/targets - Select All pools
What did you expect to see?
Seeing all pools, being able to search, being able to see failing scrape targets, …
What did you see instead? Under which circumstances?
The page loads forever, then becomes unusable and slow. In Prometheus 2 I could easily open all out targets in this view, now I the page barely works.
When I inspect the HTML I see that each target pool with one target (HTML element with class mantine-Stack-root) consists of roughly 600 lines of HTML code.
When there’s two targets it’s already 1600 lines, and so on.
System information
Linux 6.1.128-136.201.amzn2023.x86_64 x86_64
Prometheus version
prometheus, version 3.2.1 (branch: HEAD, revision: 804c49d58f3f3784c77c9c8ec17c9062092cae27)
build user: root@42fd9529152a
build date: 20250226-09:19:49
go version: go1.23.6
platform: linux/amd64
tags: netgo,builtinassets,stringlabels
Browser and System
Some more information about my system:
Browser: Vivaldi 7.2.3621.67
Computer: MacBook Pro 2023 with M2 Max Chip and 32GB RAM
OS Version: 15.3.2 (24D81)
About this issue
- Original URL
- State: open
- Created 2 years ago
- Reactions: 4
- Comments: 15 (11 by maintainers)
Commits related to this issue
- Remove raw target labels from DOM when collapsed Should help a bit with https://github.com/prometheus/prometheus/issues/16308 Signed-off-by: Julius Volz <julius.volz@gmail.com> — committed to prometheus/prometheus by juliusv 2 years ago
- Hide empty target pools and alert groups by default Also change the SD page setting for this to be in localStorage, as on the other pages. Should help a tiny bit with https://github.com/prometheus/p... — committed to prometheus/prometheus by juliusv 2 years ago
- Implement simpler custom badges for label displays Should help a little bit with https://github.com/prometheus/prometheus/issues/16308 Signed-off-by: Julius Volz <julius.volz@gmail.com> — committed to prometheus/prometheus by juliusv 2 years ago
- Implement simpler custom badges for label displays Should help a little bit with https://github.com/prometheus/prometheus/issues/16308 Signed-off-by: Julius Volz <julius.volz@gmail.com> — committed to prometheus/prometheus by juliusv 2 years ago
- Remove raw target labels from DOM when collapsed (#16342) Should help a bit with https://github.com/prometheus/prometheus/issues/16308 Signed-off-by: Julius Volz <julius.volz@gmail.com> — committed to prometheus/prometheus by juliusv 2 years ago
- Hide empty target pools and alert groups by default (#16341) Also change the SD page setting for this to be in localStorage, as on the other pages. Should help a tiny bit with https://github.com/pro... — committed to prometheus/prometheus by juliusv 2 years ago
- Implement simpler custom badges for label displays Should help a little bit with https://github.com/prometheus/prometheus/issues/16308 Signed-off-by: Julius Volz <julius.volz@gmail.com> — committed to prometheus/prometheus by juliusv 2 years ago
- Implement simpler custom badges for label displays (#16343) * Implement simpler custom badges for label displays Should help a little bit with https://github.com/prometheus/prometheus/issues/16308 ... — committed to prometheus/prometheus by juliusv 2 years ago
@Nexucis I’d say let’s keep this issue for discussing the original question and not unnecessarily feed obvious trolls 😃
Here are a few PRs that hopefully help at least a little:
Thanks for bringing this to my attention again. Yeah, the other issue probably shouldn’t have been fully closed, but let’s just continue here then, since this one is open and the other one is closed 😃
@KevinGimbel In the previous issue + PRs I focused on the “many targets in not that many pools” use case by virtualizing the scrolling within a pool, and that seemed to work fairly well for that problematic case. However for you, you have the use case of many pools with potentially just 1 target each, but still wanting to show all pools at once (instead of the default single pool when your Prometheus has more than 20 pools).
A couple of thoughts:
I’m looking into a few of those right now. Maybe there’s some other possible improvements as well that help even further, happy to hear ideas.
Similar issue occurs to me. It’s the /service-discovery page that loads very slow which can make the Chrome crash. The version is also v3.2.1.