datasweet / kibana-datasweet-formula

This Kibana plugin allows calculated metrics on any standard kibana visualizations.
Apache License 2.0
121 stars 34 forks source link

Updated To Kibana 6.5.1 #35

Closed anomaliyao closed 5 years ago

anomaliyao commented 5 years ago

After updating the kibana on 6.5.1, an error occurred in the plug-in. The error is that when hidden aggregation metrics the formula does not work. image

When metrics are not hidden image

Help please solve this problem? Now it is very important for our project.

pchakour commented 5 years ago

Hello @anomaliyao ! This not a PullRequest but an issue here ! Kibana 6.5.1 is not supported yet by the official team. If you want fix this bug you have to replace the line 10 of the file kibana-datasweet-formula/public/decorators/lib/apply_hidden.js with the following line : table.rows = reject(table.rows, (r, i) => includes(hiddenCols, i));

anomaliyao commented 5 years ago

Made code changes. Now, trying to hide the aggregation, it works successfully, if only to hide the aggregation using the plugin datasweet. If hide a custom aggregation (Sum), the formula stops working and nothing is shown. image

pchakour commented 5 years ago

Weird ! I did the same thing and it's working. Are you sure that you have data in your time range ?

anomaliyao commented 5 years ago

The time interval is the same for all screenshots. Screenshot when metrics are not hidden image When I hide the metric image

pchakour commented 5 years ago

Ok, I found the problem. On the new version of kibana, if the metric is hidden and if there is no bucket, kibana return no data for the metric. So, you have to create a bucket to make this work. In the following screenshot, I use a filter bucket.

capture du 2018-12-17 10-49-20

anomaliyao commented 5 years ago

This is very similar to the fact that by adding such a hack, the loading time of the metric increases over a long time interval. Maybe can fix it somehow or create issue?

pchakour commented 5 years ago

Maybe can fix it somehow or create issue?

I let the team decide :) But the team needs time so you have to work with this tips until the new release

anomaliyao commented 5 years ago

Is it not a kibana bug? Are you from the datasweet formula plugin team?

pchakour commented 5 years ago

Is it not a kibana bug?

I don't think, it's a new response format from kibana

Are you from the datasweet formula plugin team?

No, I'm a user like you ;)

charlotth commented 5 years ago

Try last release