[ 
https://issues.apache.org/jira/browse/LUCENE-7880?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16055443#comment-16055443
 ] 

Alan Woodward commented on LUCENE-7880:
---------------------------------------

I've run into the limit when building classifier queries, which are often a 
combination of many-leaved disjunction queries and a fairly complex exclusion.  
It seems to be a bit of a blunt instrument.  If it's there to avoid users 
building massive slow queries when they ought to be using a TermsInSetQuery 
instead, could we not deal with that case in rewrite()?  If the query is a pure 
disjunction, then collect all the TermQuery leaves and build them into a 
TermsInSetQuery.  You could even try and do this only for unique terms, so that 
scoring isn't effected?

> Make boolean query clause limit configurable per-query
> ------------------------------------------------------
>
>                 Key: LUCENE-7880
>                 URL: https://issues.apache.org/jira/browse/LUCENE-7880
>             Project: Lucene - Core
>          Issue Type: Improvement
>            Reporter: Yonik Seeley
>
> As we know, the magic BooleanQuery.maxClauseCount has bitten many people over 
> time.
> It's also a static, which really hurts multi-tenancy (i.e. we can't have 
> different settings for different users, clients, or use-cases).
> If we want to keep this static as a default, then at least we should allow it 
> to be overridden on a per-query basis when we know it is the desired behavior 
> and not a bug.
> Perhaps the simplest way to achieve this would be a setter on 
> BooleanQuery.Builder that configures the limit for that instance only?



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to