We're updating the issue view to help you get more done. 

Allow to set the minimum number of should clauses required to match for boolean predicates in the DSL

Description

See org.apache.lucene.search.BooleanQuery.Builder#setMinimumNumberShouldMatch and https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-minimum-should-match.html

We might want to allow either an absolute number of clauses (what the Lucene APIs offer) or a percentage (what both Solr and Elasticsearch offer, as an alternative).

We should probably backport this to 5.10, since the lack of such a feature must be really annoying when using the Elasticsearch integration: you basically have to write the whole boolean query and its subqueries as JSON if you want to set a minimum number of should clauses required to match. This means in particular no field bridge, and having to serialize filter parameters to JSON yourself.

Environment

None

Status

Assignee

Yoann Rodière

Reporter

Yoann Rodière

Labels

None

Suitable for new contributors

None

Feedback Requested

None

Priority

Major