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

Shawn Heisey commented on SOLR-4586:
------------------------------------

Even before someone was crazy enough to make me a committer, I developed a lot 
of respect for Robert, watching the dev list in general and Jira in particular. 
 He knows most of this code backwards and forwards, and often keeps the rest of 
us from doing things we'll regret later.  Is this one of those things?  I can't 
tell.

My gut tells me that we need to increase the value and take the choice away 
from non-savvy users.  MAX_INT seems too high.  Even the default I've proposed 
is probably too high, but what value will work?  I haven't done any 
experimenting to know when performance becomes unacceptable.  Would 16K be 
better?  32K?  256K?  IMHO, if we choose a value low enough that pathological 
user code will easily result in a "too many clauses" exception, there will be a 
significant subset of Solr users that will legitimately need more.  We've got 
potential support issues either way.  Perhaps my 4x solution needs to be left 
in place long-term, and we need a little more discussion about the default 
value.

bq. if the BooleanQuery instead logged a one-time warning if it gets used with 
> 1024 clauses?  And if assertions are enabled then fail.  The idea here is to 
try and alert the developer that they are most likely using BooleanQuery 
incorrectly, and suggest TermsFilter might be suitable instead.

For Lucene, choosing TermsFilter is probably a viable solution much of the 
time, but this issue is for Solr.  It's linked to a similar issue for Lucene.  
My Lucene knowledge is very pitiful, I know enough to be dangerous but not 
useful.  In my head, I imagine that reworking Solr to eliminate/reduce the use 
of BooleanQuery is a monumental task.  Am I right about that?

                
> Increase default maxBooleanClauses
> ----------------------------------
>
>                 Key: SOLR-4586
>                 URL: https://issues.apache.org/jira/browse/SOLR-4586
>             Project: Solr
>          Issue Type: Improvement
>    Affects Versions: 4.2
>         Environment: 4.3-SNAPSHOT 1456767M - ncindex - 2013-03-15 13:11:50
>            Reporter: Shawn Heisey
>         Attachments: SOLR-4586.patch, SOLR-4586.patch, SOLR-4586.patch, 
> SOLR-4586.patch
>
>
> In the #solr IRC channel, I mentioned the maxBooleanClauses limitation to 
> someone asking a question about queries.  Mark Miller told me that 
> maxBooleanClauses no longer applies, that the limitation was removed from 
> Lucene sometime in the 3.x series.  The config still shows up in the example 
> even in the just-released 4.2.
> Checking through the source code, I found that the config option is parsed 
> and the value stored in objects, but does not actually seem to be used by 
> anything.  I removed every trace of it that I could find, and all tests still 
> pass.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to