Skip to content

Define good heuristics to use collect_mode: breadth_first #9825

@jpountz

Description

@jpountz

breadth_first does not work when sub aggregations require scores, which is why we never use it by default today. However, we recently added the ability to know whether an aggregator requires scores or not (for now it just assumes that if a script is used then scripts are needed but we can improve it in the future, for instance I think we could have the information with lucene-expressions at least).

This means that we could now use breadth_first by default, we just need to figure out a good heuristic of when this is going to make the terms agg faster and/or more memory-efficient.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions