elasticsearch-php
elasticsearch-php copied to clipboard
Support for iteration over composite aggregation responses
There doesn't seem to be an automatic way to iterate over composite aggregation responses: https://www.elastic.co/guide/en/elasticsearch/reference/7.6/search-aggregations-bucket-composite-aggregation.html
This is done by taking the after_key field and then feeding it back to the next request via the after parameter - much like the scroll API.
Would be a very useful feature to have this rather than having to manually pass these around and keep making queries.
We're having the same issue, it would be good to be able to do this without creating something external to Elasticsearch, which would defeat the purpose of using Watcher.