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

Repeated requests are being made to load the config saved-object when using search source client #192170

Open
mikecote opened this issue Sep 5, 2024 · 2 comments
Assignees
Labels
Feature:Search Querying infrastructure in Kibana impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. loe:medium Medium Level of Effort performance Team:DataDiscovery Discover, search (e.g. data plugin and KQL), data views, saved searches. For ES|QL, use Team:ES|QL.

Comments

@mikecote
Copy link
Contributor

mikecote commented Sep 5, 2024

After running some performance tests for Kibana Alerting, I noticed in the APM traces that whenever we create a search source client (await dataPlugin.search.searchSource.asScoped), it performs four sets of requests to the following endpoints:

  • POST /_security/user/has_privileges
  • GET /.kibana_8.16.0/_doc/config%3A8.16.0

The alerting framework use to create a search source client and data view object before running each alerting rule, regardless if it was used or not. Whenever we run at a scale of 32,000 alerting rule runs per minute, it correlated to 128k requests to has_privileges and 128k requests to config each minute for the search source service and ~32k for data view service. We’ve now moved to lazy load these components but figured I’d share the findings for the search source client. It may still be a high num of requests for users running alerting rules that use search source / data views.

Preferably the optimizations work well when there are a large number of search source and data view instances created.

APM trace:
Image

@botelastic botelastic bot added the needs-team Issues missing a team label label Sep 5, 2024
@davismcphee davismcphee added Feature:Search Querying infrastructure in Kibana Team:DataDiscovery Discover, search (e.g. data plugin and KQL), data views, saved searches. For ES|QL, use Team:ES|QL. and removed needs-team Issues missing a team label labels Sep 5, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-data-discovery (Team:DataDiscovery)

@lukasolson
Copy link
Member

Related to #84923.

@lukasolson lukasolson added performance loe:medium Medium Level of Effort impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. and removed triage_needed labels Sep 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:Search Querying infrastructure in Kibana impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. loe:medium Medium Level of Effort performance Team:DataDiscovery Discover, search (e.g. data plugin and KQL), data views, saved searches. For ES|QL, use Team:ES|QL.
Projects
None yet
Development

No branches or pull requests

5 participants