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

[Data] Update esaggs function to use count aggregation by default #110095

Merged
merged 3 commits into from
Aug 30, 2021

Conversation

dokmic
Copy link
Contributor

@dokmic dokmic commented Aug 25, 2021

Summary

This pull-request resolves #67525 by providing the default value for the aggs argument. Apart from that, it fixes the data table element in canvas to use column id instead of the column name since the name and id returned by the esaggs function are different.

Previously, the esaggs function didn't work without providing at least one value in the aggs argument. That bug was caused by an incorrect default value which was an empty array. The updated default value should not break any of the existing expressions since that wasn't working before.

The change can be tested in canvas using the following expression:

esaggs index={indexPatternLoad id="..."}
| render

Checklist

For maintainers

@dokmic dokmic added review Feature:Aggregations Aggregation infrastructure (AggConfig, esaggs, ...) v8.0.0 Team:AppServices release_note:skip Skip the PR/issue when compiling release notes Feature:Canvas v7.16.0 labels Aug 25, 2021
@dokmic dokmic marked this pull request as ready for review August 26, 2021 06:40
@dokmic dokmic requested review from a team as code owners August 26, 2021 06:40
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app-services (Team:AppServices)

@kibanamachine kibanamachine added the Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas label Aug 26, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-presentation (Team:Presentation)

@dokmic dokmic requested a review from ppisljar August 26, 2021 06:40
@dokmic dokmic added impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. loe:medium Medium Level of Effort labels Aug 26, 2021
Copy link
Member

@ppisljar ppisljar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

code LGTM

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
canvas 1.6MB 1.6MB +25.0B

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
data 775.6KB 775.8KB +265.0B

History

  • 💚 Build #148690 succeeded f8a6803fd1929cc4c90d295c45f78b3391570218
  • 💔 Build #148639 failed bf8caa32b15c84b51f6a5f4de190e9ed220a0dac

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

Copy link
Contributor

@poffdeluxe poffdeluxe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes on Canvas LGTM

@dokmic dokmic merged commit 57dc0c1 into elastic:master Aug 30, 2021
@dokmic dokmic deleted the feature/67525 branch August 30, 2021 15:10
dokmic added a commit that referenced this pull request Aug 30, 2021
…10095) (#110491)

* Update default value of the aggs argument to use count aggregation
* Fix datatable canvas element to use column id instead of name
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:Aggregations Aggregation infrastructure (AggConfig, esaggs, ...) Feature:Canvas impact:low Addressing this issue will have a low level of impact on the quality/strength of our product. loe:medium Medium Level of Effort release_note:skip Skip the PR/issue when compiling release notes review Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas v7.16.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[esaggs] Bucket aggregation without a metric should be supported
5 participants