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

Torsten Bøgh Köster commented on SOLR-6256:
-------------------------------------------

This seems to be fixed in branch_4x. Will this be in release 4.10.2?

https://github.com/apache/lucene-solr/blob/branch_4x/solr/core/src/java/org/apache/solr/search/ReRankQParserPlugin.java#L284

> ReRankCollector.topDocs throws ArrayIndexOutOfBoundsException if there are no 
> hits (V4.9)
> -----------------------------------------------------------------------------------------
>
>                 Key: SOLR-6256
>                 URL: https://issues.apache.org/jira/browse/SOLR-6256
>             Project: Solr
>          Issue Type: Bug
>            Reporter: Peter Keegan
>
> The exception occurs if the main query returns 0 hits. Simple fix:
> TopDocs mainDocs = mainCollector.topDocs(0, reRankDocs);
> if (mainDocs.totalHits == 0) {
>     return mainDocs; // nothing to do.
> }



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

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

Reply via email to