ClausesCheckVisitor fails to throw TooManyClauses exception when the clauses in a query exceeds the limit by 1 [LUCENE-9299]
Open
affects-version:9.0
legacy-jira-priority:Trivial
type:bug
- Dominant language
- Java
- Stars
- 3.6k
- Forks
- 1.4k
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 88
Description
The visitor that was introduced in #9855 (obtained by IndexSearcher#getNumClausesCheckVisitor) that checks that the number of clauses in query does not exceed a certain limit (defined by org.apache.lucene.search.IndexSearcher#setMaxClauseCount) misses the case where the clauses/terms in the query exceed the limit by one.
---
Migrated from [LUCENE-9299](https://issues.apache.org/jira/browse/LUCENE-9299) by Stamatis Zampetakis (@zabetak)
Attachments: [LUCENE-9299.patch](https://apache.github.io/lucene-jira-archive/attachments/LUCENE-9299/LUCENE-9299.patch)
Contributor guide
Assessment
This issue has not been assessed yet.