mirror of https://github.com/apache/lucene.git
SOLR-5616: Simplifies grouping code to use ResponseBuilder.needDocList() to determine if it needs to generate a doc list for grouped results.
This commit is contained in:
parent
e3b785a906
commit
fecdec6c85
|
@ -76,6 +76,9 @@ Other Changes
|
||||||
permission name.
The APIs are also modified to ue 'index' as the unique identifier instead of name.
|
permission name.
The APIs are also modified to ue 'index' as the unique identifier instead of name.
|
||||||
Name is an optional attribute
now and only to be used when specifying well-known permissions (noble)
|
Name is an optional attribute
now and only to be used when specifying well-known permissions (noble)
|
||||||
|
|
||||||
|
* SOLR-5616: Simplifies grouping code to use ResponseBuilder.needDocList() to determine if it needs to
|
||||||
|
generate a doc list for grouped results. (Steven Bower, Keith Laban, Dennis Gove)
|
||||||
|
|
||||||
================== 6.0.0 ==================
|
================== 6.0.0 ==================
|
||||||
|
|
||||||
Consult the LUCENE_CHANGES.txt file for additional, low level, changes in this release
|
Consult the LUCENE_CHANGES.txt file for additional, low level, changes in this release
|
||||||
|
|
|
@ -82,6 +82,7 @@ public class DebugComponent extends SearchComponent
|
||||||
public void prepare(ResponseBuilder rb) throws IOException
|
public void prepare(ResponseBuilder rb) throws IOException
|
||||||
{
|
{
|
||||||
if(rb.isDebugTrack() && rb.isDistrib) {
|
if(rb.isDebugTrack() && rb.isDistrib) {
|
||||||
|
rb.setNeedDocList(true);
|
||||||
doDebugTrack(rb);
|
doDebugTrack(rb);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,6 +70,7 @@ public class HighlightComponent extends SearchComponent implements PluginInfoIni
|
||||||
SolrParams params = rb.req.getParams();
|
SolrParams params = rb.req.getParams();
|
||||||
rb.doHighlights = highlighter.isHighlightingEnabled(params);
|
rb.doHighlights = highlighter.isHighlightingEnabled(params);
|
||||||
if(rb.doHighlights){
|
if(rb.doHighlights){
|
||||||
|
rb.setNeedDocList(true);
|
||||||
String hlq = params.get(HighlightParams.Q);
|
String hlq = params.get(HighlightParams.Q);
|
||||||
String hlparser = Objects.firstNonNull(params.get(HighlightParams.QPARSER),
|
String hlparser = Objects.firstNonNull(params.get(HighlightParams.QPARSER),
|
||||||
params.get(QueryParsing.DEFTYPE, QParserPlugin.DEFAULT_QTYPE));
|
params.get(QueryParsing.DEFTYPE, QParserPlugin.DEFAULT_QTYPE));
|
||||||
|
|
|
@ -64,6 +64,9 @@ public class MoreLikeThisComponent extends SearchComponent {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void prepare(ResponseBuilder rb) throws IOException {
|
public void prepare(ResponseBuilder rb) throws IOException {
|
||||||
|
if (rb.req.getParams().getBool(MoreLikeThisParams.MLT, false)) {
|
||||||
|
rb.setNeedDocList(true);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -497,7 +497,7 @@ public class QueryComponent extends SearchComponent
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rb.doHighlights || rb.isDebug() || params.getBool(MoreLikeThisParams.MLT, false)) {
|
if( rb.isNeedDocList() || rb.isDebug() ){
|
||||||
// we need a single list of the returned docs
|
// we need a single list of the returned docs
|
||||||
cmd.setFlags(SolrIndexSearcher.GET_DOCLIST);
|
cmd.setFlags(SolrIndexSearcher.GET_DOCLIST);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue