OpenSearch/docs/reference/cat/count.asciidoc

42 lines
1.2 KiB
Plaintext
Raw Normal View History

2013-11-14 20:14:39 -05:00
[[cat-count]]
== cat count
2013-11-14 20:14:39 -05:00
`count` provides quick access to the document count of the entire
cluster, or individual indices.
[source,js]
2013-11-14 20:14:39 -05:00
--------------------------------------------------
GET /_cat/count?v
--------------------------------------------------
// CONSOLE
// TEST[setup:big_twitter]
// TEST[s/^/POST test\/test\?refresh\n{"test": "test"}\n/]
Looks like:
[source,txt]
--------------------------------------------------
epoch timestamp count
1475868259 15:24:19 121
--------------------------------------------------
// TESTRESPONSE[s/1475868259 15:24:19/\\d+ \\d+:\\d+:\\d+/ _cat]
Or for a single index:
[source,js]
2013-11-14 20:14:39 -05:00
--------------------------------------------------
GET /_cat/count/twitter?v
--------------------------------------------------
// CONSOLE
// TEST[continued]
[source,txt]
--------------------------------------------------
epoch timestamp count
1475868259 15:24:20 120
--------------------------------------------------
// TESTRESPONSE[s/1475868259 15:24:20/\\d+ \\d+:\\d+:\\d+/ _cat]
NOTE: The document count indicates the number of live documents and does not include deleted documents which have not yet been cleaned up by the merge process.