[index patterns] improve index pattern cache#83368
Merged
mattkime merged 5 commits intoelastic:masterfrom Nov 19, 2020
Merged
Conversation
Contributor
|
Pinging @elastic/kibana-app-arch (Team:AppArch) |
Dosant
reviewed
Nov 16, 2020
Contributor
Dosant
left a comment
There was a problem hiding this comment.
I think there is an edge case that we can cache rejected promise and then there is no way to actually retry the request.
Probably we should also clear the rejected promise from cache
Other then that looks good to me
Contributor
💚 Build SucceededMetrics [docs]Page load bundle
History
To update your PR or re-run it, just comment with: |
Dosant
approved these changes
Nov 19, 2020
Contributor
Dosant
left a comment
There was a problem hiding this comment.
LGTM 🚀
Checked that no excessive index pattern objects fetches on a dashboard
mattkime
added a commit
to mattkime/kibana
that referenced
this pull request
Nov 19, 2020
* cache index pattern promise, not index pattern
mattkime
added a commit
that referenced
this pull request
Nov 19, 2020
gmmorris
added a commit
to gmmorris/kibana
that referenced
this pull request
Nov 19, 2020
* master: skip "Dashboards linked by a drilldown are both copied to a space" (elastic#83824) [alerts] adds action group and date to mustache template variables for actions (elastic#83195) skip flaky suite (elastic#79389) [DOCS] Reallocates limitations to point-of-use (elastic#79582) [Enterprise Search] Engine overview layout stub (elastic#83756) Disable exporting/importing of templates. Optimize pitch images a bit (elastic#83098) [DOCS] Consolidates plugins (elastic#83712) [ML] Space management UI (elastic#83320) test just part of the message to avoid updates (elastic#83703) [Data Table] Remove extra column in split mode (elastic#83193) Improve snapshot error messages (elastic#83785) skip flaky suite (elastic#83773) skip flaky suite (elastic#83771) skip flaky suite (elastic#65278) skip flaky suite (elastic#83793) [Task Manager] Ensures retries are inferred from the schedule of recurring tasks (elastic#83682) [index patterns] improve index pattern cache (elastic#83368) [Fleet] Rename ingestManager plugin ID fleet (elastic#83200) fixed pagination in connectors list (elastic#83638)
chrisronline
pushed a commit
to chrisronline/kibana
that referenced
this pull request
Nov 19, 2020
* cache index pattern promise, not index pattern
This was referenced Oct 5, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Index pattern cache now stores a promise for an index pattern rather than the index pattern itself. This way we can create a cache entry at the start of the request rather than at the very end. One request is performed instead of several.
Dashboard loading is a particular example where a single index pattern can be requested many times.
Checklist
For maintainers