olivere / elastic

Deprecated: Use the official Elasticsearch client for Go at https://github.com/elastic/go-elasticsearch
https://olivere.github.io/elastic/
MIT License
7.41k stars 1.15k forks source link

Size does not match with len(searchResult.Hits.Hits) #1654

Closed trannhutle closed 2 years ago

trannhutle commented 2 years ago

Which version of Elastic are you using?

[ x] elastic.v7 (for Elasticsearch 7.x) [ ] elastic.v6 (for Elasticsearch 6.x) [ ] elastic.v5 (for Elasticsearch 5.x) [ ] elastic.v3 (for Elasticsearch 2.x) [ ] elastic.v2 (for Elasticsearch 1.x)

Please describe the expected behavior

The size match with the length of the len(searchResult.Hits.Hits)

Please describe the actual behavior

I always receive 10 hits although I change the Size. The size that I set is always smaller than the TotalHits image

Any steps to reproduce the behavior?

Please lemme know if I am doing anything wrong. Thank you so much!