Even though there is no hard upper limit, I believe after some number of clauses it would be super slow regardless of your hardware
If you need to filter a large amount of items that has docValues, check out https://solr.apache.org/guide/8_1/other-parsers.html#terms-query-parser with docValuesTermsFilter. — Ufuk Yilmaz — > On Apr 20, 2024, at 3:38, Walter Underwood <wun...@wunderwood.org> wrote: > > Well, looking at the Lucene source code, I don’t see a limit check, so I > guess the answer is “No”. > > <lucene.png> > lucene/lucene/core/src/java/org/apache/lucene/search/IndexSearcher.java at > 3024e66e4aba942b039fcad7daf958aa4c90b8bf · apache/lucene > github.com > > > wunder > Walter Underwood > wun...@wunderwood.org > http://observer.wunderwood.org/ (my blog) > >> On Apr 17, 2024, at 3:29 PM, Walter Underwood <wun...@wunderwood.org> wrote: >> >> I know about both of those user-specified limits. They are documented, as is >> the change in counting clauses in 9.0. >> >> I’ll ask again, is there a hard upper limit on the value of >> maxBooleanClauses? >> >> wunder >> >>> On Apr 17, 2024, at 2:33 PM, Chris Hostetter <hossman_luc...@fucit.org> >>> wrote: >>> >>> >>> >>> : Is there a hard upper limit for maxBooleanClauses? We have someone >>> hitting a limit at 64k clauses after upgrading to 9.x. >>> >>> There are two limits, one per-collection in solrconfig.xml that applies >>> to query parsing, and one global in solr.xml that applies to every query >>> including query expansion that hapens during query rewrite -- but those >>> have both existed since at least 8.1 >>> >>> What did change in 9.0 is that the global limit now enforced recursively >>> (by Lucene's index searcher) ... >>> >>> https://solr.apache.org/guide/solr/latest/upgrade-notes/major-changes-in-solr-9.html#querying-and-indexing-2 >>> https://solr.apache.org/guide/solr/latest/configuration-guide/configuring-solr-xml.html#global-maxbooleanclauses >>> https://solr.apache.org/guide/solr/latest/configuration-guide/caches-warming.html#maxbooleanclauses-element >>> >>> >>> >>> -Hoss >>> http://www.lucidworks.com/ >> >