-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
enable execution_context by default #119932
Merged
Merged
Conversation
This file contains 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
mshustov
added
chore
Team:Core
Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc
release_note:plugin_api_changes
Contains a Plugin API changes section for the breaking plugin API changes section.
backport:skip
This commit does not require backporting
labels
Nov 30, 2021
@elasticmachine merge upstream |
Pinging @elastic/kibana-core (Team:Core) |
💚 Build Succeeded
Metrics [docs]
History
To update your PR or re-run it, just comment with: |
afharo
approved these changes
Dec 1, 2021
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! 🎉
TinLe
pushed a commit
to TinLe/kibana
that referenced
this pull request
Dec 22, 2021
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
gbamparop
pushed a commit
to gbamparop/kibana
that referenced
this pull request
Jan 12, 2022
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
backport:skip
This commit does not require backporting
chore
release_note:plugin_api_changes
Contains a Plugin API changes section for the breaking plugin API changes section.
Team:Core
Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc
v8.1.0
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
Closes #102706
Since the last time @dmlemeshko conducted load testing, Kibana has made several changes that have a significant impact on
execution_context
performance: upgrade nodejs to v16 and enable async_hooks by defaultSo the new testing is necessary. We want to enable
execution_context
by default to provide the best UX with Kibana query source propagation to the Elasticsearch server.Benchmarks
I use the standard DemoJourney scenario from https://github.com/elastic/kibana-load-testing
95pt of the response time shows the difference within the statistical error.
main branch
PR brach
Plugin API changes
It might be hard in the distributed environment to understand what Kibana entity initiated a request to the Elasticsearch server. To overcome this problem we introduced a content of
execution_context
to attach domain-specific metadata to every request.execution_context
propagates specified metadata from the Kibana browser app or Kibana server to the Elasticsearch server viax-opaque-id
header emitted to the Elasticsearch slow logs. For further details check a troubleshooting guide here.Execution context has the following interface:
Kibana plugin can attach request specific metadata to an outbound HTTP request on the client side as
and on the server-side you need to wrap any async operation with
withContext
helper:Then, in Elasticsearch
slow logs
you might find a hint that a request was initiated bymy-plugin-ui-feature
feature ofmy-app
application and proxied throughmy-plugin-server-feature
features ofmy-app-server
app:Checklist
Risk Matrix
Delete this section if it is not applicable to this PR.
Before closing this PR, invite QA, stakeholders, and other developers to identify risks that should be tested prior to the change/feature release.
When forming the risk matrix, consider some of the following examples and how they may potentially impact the change:
execution context
tracking might be higher than anticipated.For maintainers