I am interested in executing an Elasticsearch search query with 5000+ terms across 5 different fields which leads to 25K+ clauses. According to documentation default max_clause_count
limit is set to 1024
and updating this limit to 30K doesn't work as expected.
Can anyone please suggest an efficient alternative to execute this query?
Thanks.
Sample query:
"query":{
"bool":{
"should":[
{
"match_phrase_prefix":{
"field_1": "term_1"
}
}
.
.
.
{
"match_phrase_prefix":{
"field_1": "term_5000"
}
},
{
"match_phrase_prefix":{
"field_2": "term_1"
}
}
.
.
.
{
"match_phrase_prefix":{
"field_2": "term_5000"
}
}
.
.
.
]
}
}