Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Able to crash web browser with bad choice of histogram interval #2908

Closed
jimmyjones2 opened this issue Feb 6, 2015 · 5 comments
Closed

Able to crash web browser with bad choice of histogram interval #2908

jimmyjones2 opened this issue Feb 6, 2015 · 5 comments
Labels
bug Fixes for quality problems that affect the customer experience Feature:Visualizations Generic visualization features (in case no more specific feature label is available) high hanging fruit PR sent

Comments

@jimmyjones2
Copy link
Contributor

I've got a field with a maximum value of around 5,000,000. If I do a histogram agg with an interval of 1 my web browser dies (ES returns the data fine as there are only a handful of documents)

@rashidkpc rashidkpc added the bug Fixes for quality problems that affect the customer experience label Feb 6, 2015
@rashidkpc
Copy link
Contributor

This is tough to handle, elasticsearch can return really huge JSON responses, and we don't really know how big its going to be. We could possibly check the content-length and bail before trying to JSON parse it.

@jimmyjones2
Copy link
Contributor Author

In this case, elasticsearch wasn't returning much data at all, so I think it was the code trying to draw all the bars, but this is probably an unusual scenario. Is it worth getting elasticsearch to calculate the max and min first, then can figure out how many buckets it'll end up creating and if that's over a threshold, refuse? Date histogram already does this, but I guess it can figure it out without having to go to elasticsearch.

@aaronleesmith
Copy link

Why not try and solve this at the Kibana ES proxy layer? You could watch the content-length there and refuse to send the client the response if it's too large.

@Hossrod
Copy link

Hossrod commented Jul 19, 2016

I've run into this a few times due to an occasional bad value of a single record getting into the system. I don't have control of data coming in. I started a discussion about this on elastic search site and they suggested to update this issue. https://discuss.elastic.co/t/add-some-safety-around-out-of-control-graphs/55202

As @jimmyjones2 says, I believe this is an issue with graph rendering and not size of query results.

Maybe a configurable timeout for graph generation would be good. As it stands now, when this happens, it breaks entire dashboards that make use of that graph. I can't even try to edit the graph or dashboard because they hang just trying to load them to edit.

@epixa
Copy link
Contributor

epixa commented Sep 21, 2016

Just an update to say that this is still happening on the latest master.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fixes for quality problems that affect the customer experience Feature:Visualizations Generic visualization features (in case no more specific feature label is available) high hanging fruit PR sent
Projects
None yet
Development

No branches or pull requests

7 participants