You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Use a post_filter only if you need to differentially filter search results and aggregations. Sometimes people will use post_filter for regular searches.
Don’t do this! The nature of the post_filter means it runs after the query, so any performance benefit of filtering (such as caches) is lost completely.
The post_filter should be used only in combination with aggregations, and only when you need differential filtering.
And i have noticed that the Query builder is setting the filters in the post_filter parent.
i have followed some of the related issues on this topic but still im confused about the implementation of this class.
should we use filtered queries instead of Query in order to follow the performance advice ?
The text was updated successfully, but these errors were encountered:
Hi @idhard , when u say "And i have noticed that the Query builder is setting the filters in the post_filter parent." where exactly QueryBuilder is setting filters in the post_filters ? can u show me some code ?
According to the documentation :
https://www.elastic.co/guide/en/elasticsearch/guide/current/_post_filter.html
And i have noticed that the Query builder is setting the filters in the post_filter parent.
i have followed some of the related issues on this topic but still im confused about the implementation of this class.
should we use filtered queries instead of Query in order to follow the performance advice ?
The text was updated successfully, but these errors were encountered: