Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
80 changes: 80 additions & 0 deletions _observing-your-data/query-insights/query-insights-dashboard.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
- [Top N queries](#top-n-queries): Displays the query metrics and details for the top queries.
- [Query details](#query-details): Displays details for individual queries and query groups.
- [Configuration](#configuration): Customizes all monitoring and data retention settings for the query insights feature.
- [Live queries](#live-queries): Monitors currently running queries in real time.


## Top N queries
Expand Down Expand Up @@ -182,6 +183,85 @@
- When setting data retention periods, consider shorter retention periods that save storage but reduce the number of long-term insights.
- Enable metrics based on your monitoring needs. Monitoring fewer metrics prevents system overload.

## Live queries

The **Live queries** page provides real-time visibility into search queries currently running in your OpenSearch cluster. It enables active monitoring, fast debugging, and insight into how a query's load is distributed across nodes and indexes.

The following image shows the live queries view.

![Live Queries Dashboard]({{site.url}}{{site.baseurl}}/images/Query-Insights/Live_Queries.png)

### Metrics overview

The top panel in the live queries view displays the following key real-time metrics.

| Panel | Description |
| :--- | :--- |
| **Active queries** | The total number of currently executing queries. |
| **Avg. elapsed time** | The average execution time of live queries. |
| **Longest running query**| The duration and ID of the longest currently executing query. |
| **Total CPU time** | The cumulative CPU time used by all active queries. |
| **Total memory usage** | The total memory consumed by live queries. |

### Breakdown charts

Two visual charts provide breakdowns of query load:

- **By node** – Shows how many queries are running on each node.
- **By index** – Displays how many queries are targeting each index.

![Live Queries visual charts]({{site.url}}{{site.baseurl}}/images/Query-Insights/Live_queries_visuailization.png)

You can toggle between **Donut** and **Bar** chart formats using the chart type switch.

Check failure on line 215 in _observing-your-data/query-insights/query-insights-dashboard.md

View workflow job for this annotation

GitHub Actions / style-job

[vale] reported by reviewdog 🐶 [OpenSearch.Spelling] Error: Donut. If you are referencing a setting, variable, format, function, or repository, surround it with tic marks. Raw Output: {"message": "[OpenSearch.Spelling] Error: Donut. If you are referencing a setting, variable, format, function, or repository, surround it with tic marks.", "location": {"path": "_observing-your-data/query-insights/query-insights-dashboard.md", "range": {"start": {"line": 215, "column": 26}}}, "severity": "ERROR"}

Only the top 9 items are displayed individually in the chart; additional values are grouped under the **Others** category.

### Live queries table

The live queries table lists the following information for each live query.


| Column | Description |
| :--- | :--- |
| **Timestamp** | The time at which the query started running. |
| **Task ID** | The unique identifier for the search task. |
| **Index** | The index or indexes the query is targeting. |
| **Node** | The node currently running the query. |
| **Time elapsed** | The execution time for the query so far (formatted). |
| **CPU usage** | The cumulative CPU time used by the query. |
| **Memory usage** | The amount of memory consumed by the query so far. |
| **Search type** | The search execution method, such as `query_then_fetch`. |
| **Coordinator node** | The node that coordinated the query. |
| **Status** | The status of the query task. Can be either `running` or `cancelled`. |
| **Actions** | The available controls, such as canceling the query. |

You can use the filter bar to search for queries by text or specific field values---such as node ID, index name, or task ID---and paginate the table to better analyze specific queries. The following image shows the live queries table view.

![Live Queries Table]({{site.url}}{{site.baseurl}}/images/Query-Insights/Live_Queries_Table.png)

The live queries table provides the following real-time monitoring controls:
- **Auto-refresh toggle** – Enable or disable periodic data refresh.
- **Refresh interval** – Choose the refresh frequency. This option is available only when **Auto-refresh** is enabled.
- **Manual refresh** – Select the **Refresh** button to update immediately.

### Canceling live queries

The live queries table provides direct controls for canceling queries that are currently running in the cluster. This allows you to immediately stop problematic or resource-intensive searches without waiting for them to finish. You can cancel live queries in the following ways:

1. Cancel an individual query:
- In the **Actions** column for the query you want to stop, select the trash can icon.
- When prompted, confirm the cancellation.
Once the cancellation succeeds, the query status changes to `Cancelled`.

2. Cancel multiple queries in bulk:
- To select multiple queries, use the checkboxes to the left of the table. To select all queries, use the **Select all** checkbox in the table header.
- Select the **Cancel selected** button above the table.
- Confirm the cancellation for all selected queries.
All selected queries are stopped and their statuses updated.







Expand Down
Binary file added images/Query-Insights/Live_Queries.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/Query-Insights/Live_Queries_Table.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading