Skip to content

Commit 9d3d683

Browse files
committed
Update GET top N api documentation
Signed-off-by: David Zane <[email protected]>
1 parent 67682f2 commit 9d3d683

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

_observing-your-data/query-insights/top-n-queries.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,15 +72,13 @@ PUT _cluster/settings
7272

7373
## Monitoring the top N queries
7474

75-
You can use the Insights API endpoint to obtain the top N queries for all metric types:
75+
You can use the Insights API endpoint to obtain the top N queries. Specify the `type` parameter to get top N results for each metric type. Calling this API without `type` returns top N `latency` results by default.
7676

7777
```json
7878
GET /_insights/top_queries
7979
```
8080
{% include copy-curl.html %}
8181

82-
Specify a metric type to filter the response:
83-
8482
```json
8583
GET /_insights/top_queries?type=latency
8684
```
@@ -96,6 +94,9 @@ GET /_insights/top_queries?type=memory
9694
```
9795
{% include copy-curl.html %}
9896

97+
If you are not seeing results, verify top N is enabled for the target metric type and ensure search requests were sent during the current time window.
98+
{: .important}
99+
99100
## Exporting top N query data
100101

101102
You can configure your desired exporter to export top N query data to different sinks, allowing for better monitoring and analysis of your OpenSearch queries. Currently, the following exporters are supported:

0 commit comments

Comments
 (0)