Skip to content

Commit a0f8ec9

Browse files
gargharsh3134Harsh Garg
authored andcommitted
Making _cat/allocation API use indexLevelStats (opensearch-project#15292)
Signed-off-by: Harsh Garg <gkharsh@amazon.com> Co-authored-by: Harsh Garg <gkharsh@amazon.com>
1 parent 00201d6 commit a0f8ec9

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
5454
- Reset DiscoveryNodes in all transport node actions request ([#15131](https://github.com/opensearch-project/OpenSearch/pull/15131))
5555
- Relax the join validation for Remote State publication ([#15471](https://github.com/opensearch-project/OpenSearch/pull/15471))
5656
- MultiTermQueries in keyword fields now default to `indexed` approach and gated behind cluster setting ([#15637](https://github.com/opensearch-project/OpenSearch/pull/15637))
57+
- Making _cat/allocation API use indexLevelStats ([#15292](https://github.com/opensearch-project/OpenSearch/pull/15292))
5758

5859
### Dependencies
5960
- Bump `netty` from 4.1.111.Final to 4.1.112.Final ([#15081](https://github.com/opensearch-project/OpenSearch/pull/15081))

server/src/main/java/org/opensearch/rest/action/cat/RestAllocationAction.java

+1
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,7 @@ public void processResponse(final ClusterStateResponse state) {
101101
statsRequest.clear()
102102
.addMetric(NodesStatsRequest.Metric.FS.metricName())
103103
.indices(new CommonStatsFlags(CommonStatsFlags.Flag.Store));
104+
statsRequest.indices().setIncludeIndicesStatsByLevel(true);
104105

105106
client.admin().cluster().nodesStats(statsRequest, new RestResponseListener<NodesStatsResponse>(channel) {
106107
@Override

0 commit comments

Comments
 (0)