SOLR-3518: Include final 'hits' in log information when aggregating a distibuted request

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1382209 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Chris M. Hostetter 2012-09-07 23:45:37 +00:00
parent ee0bf2549b
commit 76059449d1
2 changed files with 6 additions and 2 deletions

View File

@ -137,6 +137,8 @@ Bug Fixes
* SOLR-3699: Fixed some Directory leaks when there were errors during SolrCore
or SolrIndexWriter initialization. (hossman)
* SOLR-3518: Include final 'hits' in log information when aggregating a
distibuted request (Markus Jelsma via hossman)
Other Changes
----------------------

View File

@ -863,8 +863,7 @@ public class QueryComponent extends SearchComponent
queue.insertWithOverflow(shardDoc);
} // end for-each-doc-in-response
} // end for-each-response
// The queue now has 0 -> queuesize docs, where queuesize <= start + rows
// So we want to pop the last documents off the queue to get
// the docs offset -> queuesize
@ -880,6 +879,9 @@ public class QueryComponent extends SearchComponent
resultIds.put(shardDoc.id.toString(), shardDoc);
}
// Add hits for distributed requests
// https://issues.apache.org/jira/browse/SOLR-3518
rb.rsp.addToLog("hits", numFound);
SolrDocumentList responseDocs = new SolrDocumentList();
if (maxScore!=null) responseDocs.setMaxScore(maxScore);