Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upFreeze on graph page when working with a large amount of metrics due to no upper limit on insertable metric dropdown. #5421
Comments
SpencerMalone
changed the title
UI has length page freeze on load / touching the expression text box after 2.8.0 upgrade
UI has lengthy page freeze on load / touching the expression text box after 2.8.0 upgrade
Mar 29, 2019
This comment has been minimized.
This comment has been minimized.
|
I'm thinking this has something to do with https://github.com/prometheus/prometheus/blob/master/web/ui/static/js/graph/index.js#L262 or the typeahead, but am having trouble reliably profiling exactly what is causing the pain. I found a small improvement in using a doc fragment for creating options, but nothing huge yet. |
simonpasquier
added
the
component/ui
label
Apr 5, 2019
This comment has been minimized.
This comment has been minimized.
|
OK, I am pretty confident that this is the insertable metric selector. I'm gonna update the title. Note that we fixed this for our instance, the tl;dr is that we had a cardinality explosion involving someone putting templated data into a metric name with a high cardinality, after fixing the problem and deleting the data, we were unaware that tombstone cleaning was required to remove the entries from the API method being called by the UI. Cleaning those fixed us up, BUT, I still think it's worth having an upper limit on the "insert metrics" dropdown selection. |
SpencerMalone
changed the title
UI has lengthy page freeze on load / touching the expression text box after 2.8.0 upgrade
Freeze page when working with a large amount of metrics due to no upper limit on insertable metric dropdown.
Apr 10, 2019
SpencerMalone
changed the title
Freeze page when working with a large amount of metrics due to no upper limit on insertable metric dropdown.
Freeze on graph page when working with a large amount of metrics due to no upper limit on insertable metric dropdown.
Apr 10, 2019
This comment has been minimized.
This comment has been minimized.
|
We already have a 10k limit as of 2.8, are you sure you're running at least that? |
This comment has been minimized.
This comment has been minimized.
|
My understanding is that 2.8 limit was for the lookahead stuff, correct? These heavy pauses lined up with the amount of dom nodes inserted in the code block...
at https://github.com/prometheus/prometheus/blob/master/web/ui/static/js/graph/index.js#L274 for the When I used the chrome debugger to artificially limit the amount of data allowed in that loop, the pause decreased dramatically. The hardest thing is communicating that the amount of metrics populated into that dropdown has been limited. I was looking at something like...
But that totally disables that functionality when this occurs. Is that OK? |


SpencerMalone commentedMar 29, 2019
•
edited
Bug Report
What did you do?
After upgrading from 2.6.1 -> 2.8.0, we start seeing large page freezes just after page load. It's like... Page load, click around for a moment, interact with the expression bar, then there's a heavy loading pause (10 seconds?), then it goes to normal with some brief pauses afterwards. We have seen this across all of our instances of 2.8.0, but be aware that we do have pretty beefy deployments.Once it finishes loading, it's often OK, but that into chug is painful.Read below, but this turned out to be a coincidence, the problem was a large increase in metric labels that caused the DOM node population on the insertable metric dropdown to cause heavy slowdowns. We should have an upper limit on the amount of DOM nodes we create in https://github.com/prometheus/prometheus/blob/master/web/ui/static/js/graph/index.js#L276
What did you expect to see?
Not the spinning loading wheel.
What did you see instead? Under which circumstances?
An inability to interact with the GUI
Environment
System information:
Linux 4.4.161-1.el7.elrepo.x86_64 x86_64Prometheus version:
There's no JS errors logging, but here is a gif of the behavior. What are you are looking at is the lengthy freeze where the text cursor stops blinking, and the expression bar stays highlighted.