I am bit confused with document counts for selected index in elastic search, below is the snippet of index
GET /_cat/indices/zipkin-span-2020-07-30?v
health status index uuid pri rep docs.count docs.deleted store.size pri.store.size
yellow open zipkin-span-2020-07-30 STcY29kkT3W7Y0XybbfVTQ 1 1 264996 0 88.9mb 88.9mb
It is showing document count is 264996 whereas it show very few records (MAX 20 records) when i hit the below request
GET /zipkin-span-2020-07-30/_search
{"took":774,"timed_out":false,"_shards":{"total":1,"successful":1,"skipped":0,"failed":0},
"hits":{"total":{"value":10000,"relation":"gte"},"max_score":1.0,"hits":[{.... records.....}]}}
Note - I also tried with scroll api but still showing the same output. Question -
- Does this issue related with duplicate records?
- Does this count consider replica records as well?