django-elasticsearch-dsl-drf icon indicating copy to clipboard operation
django-elasticsearch-dsl-drf copied to clipboard

Add support for nested aggregations

Open barseghyanartur opened this issue 7 years ago • 0 comments

Add support for nested aggregations.

Some references:

  • https://www.elastic.co/guide/en/elasticsearch/reference/5.5/search-aggregations-bucket-nested-aggregation.html
  • https://github.com/elastic/elasticsearch/issues/11749
  • https://github.com/elastic/elasticsearch/issues/12410

Update 2018-06-27

This is on-going issue. At the moment, there's a temporary solution for that (by making a custom filtering backend). See the documentation and examples:

Update 2018-08-02

https://github.com/elastic/elasticsearch-dsl-py/blob/master/elasticsearch_dsl/faceted_search.py#L161

elasticsearch-dsl version 6.x supports nested aggregations, however, since this library aims to support 2.x (not so important anymore, might as well be deprecated) and 5.x, the total switch to 6.x functionality can't be made (simple), unless we copy some of the elasticsearch-dsl functionality locally or have it supported for Elasticsearch 6.x only. Help here is appreciated. If you need this badly, either see my remarks above (2018-06-27, regarding custom nested aggregations backend) or consider making a contribution (I will assist you).

barseghyanartur avatar May 10 '18 00:05 barseghyanartur