You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Tommaso Teofili (JIRA)" <ji...@apache.org> on 2018/05/28 11:17:00 UTC

[jira] [Created] (OAK-7513) Possible NPE in exact size calculation for SolrQueryIndex

Tommaso Teofili created OAK-7513:
------------------------------------

             Summary: Possible NPE in exact size calculation for SolrQueryIndex
                 Key: OAK-7513
                 URL: https://issues.apache.org/jira/browse/OAK-7513
             Project: Jackrabbit Oak
          Issue Type: Bug
          Components: solr
            Reporter: Tommaso Teofili
            Assignee: Tommaso Teofili
             Fix For: 1.10


SolrQueryIndex suffers of possible NPE when running exact query calculation method.

 
{code:java}
@Override
public long getSize(SizePrecision precision, long max) {
    long estimate = -1;
    switch (precision) {
        case EXACT:
            // query solr
            SolrQuery countQuery = FilterQueryParser.getQuery(plan.getFilter(), null, this.configuration);
        ...
}{code}
 

The problem is the _plan_ being null causes _plan.getSortPlan()_ in FilterQueryParser throw an NPE.

 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)