Range filter and max_clause_count


#1

Hi,

I am having trouble with a use-case where I need to filter the content of an index based on multiple x-coordinate ranges. The number of ranges can go up to 500 000 distinct intervals (dynamically defined by the end-user). Obviously I ran into the max_clause_count error when using the ranges in query context. From reading the docs I was given to understand the underlying Lucene engine does not run into that limitation when running a large number of clauses in filter context.

I have tried as follows, however I am still running into the max_clause_count error:

"query": {
    "bool": {
        "filter": [
            {"bool": {
                  "should": <an array of 500 000 range expressions>
            }}
        ]
    }
}

Is this the right way to use a range expression in filter context?


(system) #2

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.