@@ -40,6 +40,10 @@ If a node does not respond before its timeout expires, the response does not inc
40
40
However, timed out nodes are included in the response's `_nodes.failed` property.
41
41
Defaults to no timeout.
42
42
43
+ `include_remotes`::
44
+ (Optional, Boolean) If `true`, includes remote cluster information in the response.
45
+ Defaults to `false`, so no remote cluster information is returned.
46
+
43
47
[role="child_attributes"]
44
48
[[cluster-stats-api-response-body]]
45
49
==== {api-response-body-title}
@@ -183,12 +187,11 @@ This number is based on documents in Lucene segments and may include documents f
183
187
This number is based on documents in Lucene segments. {es} reclaims the disk space of deleted Lucene documents when a segment is merged.
184
188
185
189
`total_size_in_bytes`::
186
- (integer)
187
- Total size in bytes across all primary shards assigned to selected nodes.
190
+ (integer) Total size in bytes across all primary shards assigned to selected nodes.
188
191
189
192
`total_size`::
190
- (string)
191
- Total size across all primary shards assigned to selected nodes, as a human-readable string.
193
+ (string) Total size across all primary shards assigned to selected nodes, as a human-readable string.
194
+
192
195
=====
193
196
194
197
`store`::
@@ -1285,8 +1288,7 @@ They are included here for expert users, but should otherwise be ignored.
1285
1288
====
1286
1289
1287
1290
`repositories`::
1288
- (object) Contains statistics about the <<snapshot-restore,snapshot>> repositories defined in the cluster, broken down
1289
- by repository type.
1291
+ (object) Contains statistics about the <<snapshot-restore,snapshot>> repositories defined in the cluster, broken down by repository type.
1290
1292
+
1291
1293
.Properties of `repositories`
1292
1294
[%collapsible%open]
@@ -1314,13 +1316,74 @@ Each repository type may also include other statistics about the repositories of
1314
1316
[%collapsible%open]
1315
1317
=====
1316
1318
1319
+ `clusters`:::
1320
+ (object) Contains remote cluster settings and metrics collected from them.
1321
+ The keys are cluster names, and the values are per-cluster data.
1322
+ Only present if `include_remotes` option is set to `true`.
1323
+
1324
+ +
1325
+ .Properties of `clusters`
1326
+ [%collapsible%open]
1327
+ ======
1328
+
1329
+ `cluster_uuid`:::
1330
+ (string) The UUID of the remote cluster.
1331
+
1332
+ `mode`:::
1333
+ (string) The <<sniff-proxy-modes, connection mode>> used to communicate with the remote cluster.
1334
+
1335
+ `skip_unavailable`:::
1336
+ (Boolean) The `skip_unavailable` <<skip-unavailable-clusters, setting>> used for this remote cluster.
1337
+
1338
+ `transport.compress`:::
1339
+ (string) Transport compression setting used for this remote cluster.
1340
+
1341
+ `version`:::
1342
+ (array of strings) The list of {es} versions used by the nodes on the remote cluster.
1343
+
1344
+ `status`:::
1345
+ include::{es-ref-dir}/rest-api/common-parms.asciidoc[tag=cluster-health-status]
1346
+ +
1347
+ See <<cluster-health>>.
1348
+
1349
+ `nodes_count`:::
1350
+ (integer) The total count of nodes in the remote cluster.
1351
+
1352
+ `shards_count`:::
1353
+ (integer) The total number of shards in the remote cluster.
1354
+
1355
+ `indices_count`:::
1356
+ (integer) The total number of indices in the remote cluster.
1357
+
1358
+ `indices_total_size_in_bytes`:::
1359
+ (integer) Total data set size, in bytes, of all shards assigned to selected nodes.
1360
+
1361
+ `indices_total_size`:::
1362
+ (string) Total data set size, in bytes, of all shards assigned to selected nodes, as a human-readable string.
1363
+
1364
+ `max_heap_in_bytes`:::
1365
+ (integer) Maximum amount of memory, in bytes, available for use by the heap across the nodes of the remote cluster.
1366
+
1367
+ `max_heap`:::
1368
+ (string) Maximum amount of memory, in bytes, available for use by the heap across the nodes of the remote cluster,
1369
+ as a human-readable string.
1370
+
1371
+ `mem_total_in_bytes`:::
1372
+ (integer) Total amount, in bytes, of physical memory across the nodes of the remote cluster.
1373
+
1374
+ `mem_total`:::
1375
+ (string) Total amount, in bytes, of physical memory across the nodes of the remote cluster, as a human-readable string.
1376
+
1377
+ ======
1378
+
1317
1379
1318
1380
`_search`:::
1319
- (object) Contains the telemetry information about the <<modules-cross-cluster-search, {ccs}>> usage in the cluster.
1381
+ (object) Contains the information about the <<modules-cross-cluster-search, {ccs}>> usage in the cluster.
1320
1382
+
1321
1383
.Properties of `_search`
1322
1384
[%collapsible%open]
1323
1385
======
1386
+
1324
1387
`total`:::
1325
1388
(integer) The total number of {ccs} requests that have been executed by the cluster.
1326
1389
@@ -1336,6 +1399,7 @@ Each repository type may also include other statistics about the repositories of
1336
1399
.Properties of `took`
1337
1400
[%collapsible%open]
1338
1401
=======
1402
+
1339
1403
`max`:::
1340
1404
(integer) The maximum time taken to execute a {ccs} request, in milliseconds.
1341
1405
@@ -1344,6 +1408,7 @@ Each repository type may also include other statistics about the repositories of
1344
1408
1345
1409
`p90`:::
1346
1410
(integer) The 90th percentile of the time taken to execute {ccs} requests, in milliseconds.
1411
+
1347
1412
=======
1348
1413
1349
1414
`took_mrt_true`::
@@ -1361,6 +1426,7 @@ Each repository type may also include other statistics about the repositories of
1361
1426
1362
1427
`p90`:::
1363
1428
(integer) The 90th percentile of the time taken to execute {ccs} requests, in milliseconds.
1429
+
1364
1430
=======
1365
1431
1366
1432
`took_mrt_false`::
@@ -1378,6 +1444,7 @@ Each repository type may also include other statistics about the repositories of
1378
1444
1379
1445
`p90`:::
1380
1446
(integer) The 90th percentile of the time taken to execute {ccs} requests, in milliseconds.
1447
+
1381
1448
=======
1382
1449
1383
1450
`remotes_per_search_max`::
@@ -1391,9 +1458,10 @@ Each repository type may also include other statistics about the repositories of
1391
1458
The keys are the failure reason names and the values are the number of requests that failed for that reason.
1392
1459
1393
1460
`features`::
1394
- (object) Contains statistics about the features used in {ccs} requests. The keys are the names of the search feature,
1395
- and the values are the number of requests that used that feature. Single request can use more than one feature
1396
- (e.g. both `async` and `wildcard`). Known features are:
1461
+ (object) Contains statistics about the features used in {ccs} requests.
1462
+ The keys are the names of the search feature, and the values are the number of requests that used that feature.
1463
+ Single request can use more than one feature (e.g. both `async` and `wildcard`).
1464
+ Known features are:
1397
1465
1398
1466
* `async` - <<async-search, Async search>>
1399
1467
@@ -1427,6 +1495,7 @@ This may include requests where partial results were returned, but not requests
1427
1495
.Properties of `took`
1428
1496
[%collapsible%open]
1429
1497
========
1498
+
1430
1499
`max`:::
1431
1500
(integer) The maximum time taken to execute a {ccs} request, in milliseconds.
1432
1501
@@ -1435,6 +1504,7 @@ This may include requests where partial results were returned, but not requests
1435
1504
1436
1505
`p90`:::
1437
1506
(integer) The 90th percentile of the time taken to execute {ccs} requests, in milliseconds.
1507
+
1438
1508
========
1439
1509
1440
1510
=======
@@ -1812,3 +1882,37 @@ This API can be restricted to a subset of the nodes using <<cluster-nodes,node f
1812
1882
--------------------------------------------------
1813
1883
GET /_cluster/stats/nodes/node1,node*,master:false
1814
1884
--------------------------------------------------
1885
+
1886
+ This API call will return data about the remote clusters if any are configured:
1887
+
1888
+ [source,console]
1889
+ --------------------------------------------------
1890
+ GET /_cluster/stats?include_remotes=true
1891
+ --------------------------------------------------
1892
+
1893
+ The resulting response will contain the `ccs` object with information about the remote clusters:
1894
+
1895
+ [source,js]
1896
+ --------------------------------------------------
1897
+ {
1898
+ "ccs": {
1899
+ "clusters": {
1900
+ "remote_cluster": {
1901
+ "cluster_uuid": "YjAvIhsCQ9CbjWZb2qJw3Q",
1902
+ "mode": "sniff",
1903
+ "skip_unavailable": false,
1904
+ "transport.compress": "true",
1905
+ "version": ["8.16.0"],
1906
+ "status": "green",
1907
+ "nodes_count": 10,
1908
+ "shards_count": 420,
1909
+ "indices_count": 10,
1910
+ "indices_total_size_in_bytes": 6232658362,
1911
+ "max_heap_in_bytes": 1037959168,
1912
+ "mem_total_in_bytes": 137438953472
1913
+ }
1914
+ }
1915
+ }
1916
+ }
1917
+ --------------------------------------------------
1918
+ // TESTRESPONSE[skip:TODO]
0 commit comments