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

[Kibana][Visualization][Bug & feature request] Kibana vertical bar doesn't show extended bounds correctly when use 2 depth aggs (histogram -> terms) with empty bucket settings #23914

Closed
kunisen opened this issue Oct 9, 2018 · 5 comments
Labels
blocked bug Fixes for quality problems that affect the customer experience Feature:XYAxis XY-Axis charts (bar, area, line) impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. Team:Visualizations Visualization editors, elastic-charts and infrastructure :VisEditors:fix-it-week

Comments

@kunisen
Copy link
Contributor

kunisen commented Oct 9, 2018

Kibana version:
5.5.0 ~ 6.4

Elasticsearch version:
5.5.0 ~ 6.4

Server OS version:
Major OS

Browser version:
Major browser

Browser OS version:
Latest ver

Original install method (e.g. download page, yum, from source, etc.):
Zip install

Describe the bug:
Kibana vertical bar doesn't show extended bounds correctly when use 2 depth aggs (histogram -> terms) with empty bucket settings.
We can see empty buckets returned from visualization spy - response.
So it is considered that Kibana didn't draw those empty buckets in such kind of situation.

Steps to reproduce:
[1] Download and install Elasticsearch and Kibana 5.5.0

[2] Bulk insert the following data

POST _bulk
{"index":{"_index":"test_index","_type":"logs","_id":"5"}}
{"score":35,"model":"XX-2000"}
{"index":{"_index":"test_index","_type":"logs","_id":"8"}}
{"score":49,"model":"XX-3000"}
{"index":{"_index":"test_index","_type":"logs","_id":"9"}}
{"score":51,"model":"XX-3000"}
{"index":{"_index":"test_index","_type":"logs","_id":"10"}}
{"score":67,"model":"XX-3000"}
{"index":{"_index":"test_index","_type":"logs","_id":"2"}}
{"score":50,"model":"XX-2000"}
{"index":{"_index":"test_index","_type":"logs","_id":"4"}}
{"score":30,"model":"XX-2000"}
{"index":{"_index":"test_index","_type":"logs","_id":"6"}}
{"score":32,"model":"XX-3000"}
{"index":{"_index":"test_index","_type":"logs","_id":"1"}}
{"score":60,"model":"XX-2000"}
{"index":{"_index":"test_index","_type":"logs","_id":"7"}}
{"score":38,"model":"XX-3000"}
{"index":{"_index":"test_index","_type":"logs","_id":"3"}}
{"score":44,"model":"XX-2000"}

[3] Create index-pattern, visualization in Kibana

image

Expected behavior:

image

As we can see the empty bucket response returned from visualization spy response.

image

Actual behavior:

No extended bounds shown here.
image

Errors in browser console (if relevant):

No errors.

Any additional context:

If we drag and drop the order of Split Series - Terms aggs higher than Historgram, then we can get the extended bounds correctly displayed.

image

@kunisen kunisen added Feature:Visualizations Generic visualization features (in case no more specific feature label is available) bug Fixes for quality problems that affect the customer experience labels Oct 9, 2018
@AlonaNadler AlonaNadler added the Team:Visualizations Visualization editors, elastic-charts and infrastructure label Oct 10, 2018
@gchaps gchaps added Feature:XYAxis XY-Axis charts (bar, area, line) and removed Feature:Visualizations Generic visualization features (in case no more specific feature label is available) labels Oct 10, 2018
@kunisen
Copy link
Contributor Author

kunisen commented Oct 17, 2019

any updates here?

@kunisen kunisen changed the title [Kibana][Visualization] Kibana vertical bar doesn't show extended bounds correctly when use 2 depth aggs (histogram -> terms) with empty bucket settings [Kibana][Visualization][Bug & feature request] Kibana vertical bar doesn't show extended bounds correctly when use 2 depth aggs (histogram -> terms) with empty bucket settings Oct 17, 2019
@lposani
Copy link

lposani commented Jul 15, 2021

Would be nice to have updates on this.

@stratoula stratoula added the impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. label Jul 26, 2021
@flash1293 flash1293 added impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. and removed impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. labels Oct 12, 2021
@flash1293
Copy link
Contributor

This is still a valid problem caused by the way we turn the Elasticsearch response into a table - in case of bucketing by terms first, there are buckets with 0 doc count for the extended bounds of the histogram, but if histogram is done first, the "extended buckets" of the histogram agg are completely empty (because the terms agg doesn't have any documents to operate on).

I traced this back and it should be fixable by adding the extended bounds of a histogram dimension to the params here along with the interval:

(dimensions.x.params as HistogramParams).interval = output.params.interval;

Then use it to define the x domain here:

@flash1293
Copy link
Contributor

Blocked on #119474

@flash1293
Copy link
Contributor

Fixed by #134020 - it's now possible to specify the extents of the x axis in this scenario in Lens to keep it stable independently of the data

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked bug Fixes for quality problems that affect the customer experience Feature:XYAxis XY-Axis charts (bar, area, line) impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. Team:Visualizations Visualization editors, elastic-charts and infrastructure :VisEditors:fix-it-week
Projects
None yet
Development

No branches or pull requests

6 participants