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

[Lens] Cache avilable operations meta data #95034

Merged
merged 6 commits into from
Mar 24, 2021

Conversation

flash1293
Copy link
Contributor

@flash1293 flash1293 commented Mar 22, 2021

Fixes #95033

This is a "low hanging fruit" optimization because it's very easy to get rid of a bunch of cpu cycles per update. #89690 should allow to roll out this kind of caching more consistently for all parts of Lens.

Before
Screenshot 2021-03-22 at 09 39 41

After
Screenshot 2021-03-22 at 09 39 07

@flash1293 flash1293 added Team:Visualizations Visualization editors, elastic-charts and infrastructure v8.0.0 Feature:Lens v7.13.0 auto-backport Deprecated - use backport:version if exact versions are needed v7.12.1 labels Mar 22, 2021
@flash1293 flash1293 marked this pull request as ready for review March 22, 2021 12:42
@flash1293 flash1293 requested a review from a team March 22, 2021 12:42
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app (Team:KibanaApp)

@flash1293 flash1293 added the release_note:skip Skip the PR/issue when compiling release notes label Mar 22, 2021
@flash1293
Copy link
Contributor Author

I realized the memoize cache isn’t cleared correctly, I will provide a fix

@flash1293
Copy link
Contributor Author

OK, cache should always be consistent now

@flash1293
Copy link
Contributor Author

@elasticmachine merge upstream

Copy link
Contributor

@dej611 dej611 left a comment

Choose a reason for hiding this comment

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

LGTM 👍

Reviewing this PR actually made me find a bug (not related to this), where reference operations are not cleaned up on datasource switch in a layer:

Kapture 2021-03-24 at 10 37 28

@flash1293
Copy link
Contributor Author

Great catch, @dej611 ! Can you create an issue for this?

@dej611
Copy link
Contributor

dej611 commented Mar 24, 2021

Sure: #95278

@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
lens 902.9KB 903.1KB +231.0B

History

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

@flash1293 flash1293 merged commit 6295ae7 into elastic:master Mar 24, 2021
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Mar 24, 2021
@kibanamachine
Copy link
Contributor

💔 Backport failed

❌ 7.12: Commit could not be cherrypicked due to conflicts
7.x / #95300

Successful backport PRs will be merged automatically after passing CI.

To backport manually run:
node scripts/backport --pr 95034

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Deprecated - use backport:version if exact versions are needed Feature:Lens release_note:skip Skip the PR/issue when compiling release notes Team:Visualizations Visualization editors, elastic-charts and infrastructure v7.12.1 v7.13.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Lens] Performance bottleneck with lots of fields
4 participants