I was wondering how size in a scan and scroll request works? In the latest documentation, it specifies
The
sizeparameter allows you to configure the maximum number of hits to be returned with each batch of results.
Looking at some older documentation I found the below
Although we specified a
sizeof 1,000, we get back many more documents. When scanning, thesizeis applied to each shard, so you will get back a maximum ofsize * number_of_primary_shardsdocuments in each batch.
Is the above statement still true?
If true, does it aggregate all the results from each shard and return the results in batches of 1,000 on every scroll?