ruflin / Elastica

Elastica is a PHP client for elasticsearch
http://elastica.io/
MIT License
2.26k stars 734 forks source link

Does Elastica support partitions? #1629

Open elshobokshy opened 5 years ago

elshobokshy commented 5 years ago

As the title says, can I filter aggregations using partitions? (as the scroll API doesn't work with aggregations)

https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-bucket-terms-aggregation.html#_filtering_values_with_partitions

ruflin commented 5 years ago

You should be able to use setParams on the Terms aggregation for this: https://github.com/ruflin/Elastica/blob/master/lib/Elastica/Aggregation/Terms.php But I haven't tested it. Would be great to also have a native mapping for it in Elastica.