Skip to content

Search Query Categorization (Phase 1) #10250

@deshsidd

Description

@deshsidd

Is your feature request related to a problem? Please describe.
Today OpenSearch customers have limited very visibility into the query workload running on a cluster. There is also no easy way to identify patterns in the queries being executed upon an index. This imposes a huge gap while debugging performance issues, tracking changes in data access patterns, or when targeting new feature improvements.

The Query Classification feature in OpenSearch aims to enhance the platform's capabilities by providing a mechanism to identify patterns, latencies and resource utilization breakdown for the queries being executed upon an index. This will empower users and administrators to optimize query performance and identify query types for better resource allocation and index management.

The primary objective of this proposal is to implement a query classification mechanism within OpenSearch that can categorize and analyze the queries being executed on an index.

Describe the solution you'd like
Instrument the Query Builder logic in OpenSearch to recognize and categorize queries based on their patterns, such as search queries, aggregation queries, filtering queries, etc. This will provide insights into the types and frequencies of queries being executed on the index.

Use metric counters to record this information using Metric Framework : #10241

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Example query classification information:
total_queries
total_nested_queries
total_aggs
total_nested_aggs
match
multi_match
bool
nested_bool
wildcard
regexp
match_phrase_prefix
query_string
term
range
function_score

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementEnhancement or improvement to existing feature or requestv2.12.0Issues and PRs related to version 2.12.0

    Type

    No type

    Projects

    Status

    Done

    Status

    2.12.0 (Launched)

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions