mirror of
https://github.com/apache/lucene.git
synced 2025-02-22 18:27:21 +00:00
SOLR-9800: Factor out FacetComponent.newSimpleFacets method. (Jonny Marks via Christine Poerschke)
This commit is contained in:
parent
9dcfcb6e6f
commit
ef03480743
@ -172,6 +172,8 @@ Other Changes
|
||||
SolrSuggester.build() now throws SolrCoreState.CoreIsClosedException when interrupted
|
||||
by a core reload/shutdown. (Steve Rowe)
|
||||
|
||||
* SOLR-9800: Factor out FacetComponent.newSimpleFacets method. (Jonny Marks via Christine Poerschke)
|
||||
|
||||
================== 6.4.1 ==================
|
||||
|
||||
Consult the LUCENE_CHANGES.txt file for additional, low level, changes in this release.
|
||||
|
@ -50,6 +50,7 @@ import org.apache.solr.request.SolrQueryRequest;
|
||||
import org.apache.solr.schema.FieldType;
|
||||
import org.apache.solr.schema.PointField;
|
||||
import org.apache.solr.search.QueryParsing;
|
||||
import org.apache.solr.search.DocSet;
|
||||
import org.apache.solr.search.SyntaxError;
|
||||
import org.apache.solr.search.facet.FacetDebugInfo;
|
||||
import org.apache.solr.util.RTimer;
|
||||
@ -103,6 +104,11 @@ public class FacetComponent extends SearchComponent {
|
||||
}
|
||||
}
|
||||
|
||||
/* Custom facet components can return a custom SimpleFacets object */
|
||||
protected SimpleFacets newSimpleFacets(SolrQueryRequest req, DocSet docSet, SolrParams params, ResponseBuilder rb) {
|
||||
return new SimpleFacets(req, docSet, params, rb);
|
||||
}
|
||||
|
||||
/**
|
||||
* Encapsulates facet ranges and facet queries such that their parameters
|
||||
* are parsed and cached for efficient re-use.
|
||||
@ -253,7 +259,7 @@ public class FacetComponent extends SearchComponent {
|
||||
|
||||
if (rb.doFacets) {
|
||||
SolrParams params = rb.req.getParams();
|
||||
SimpleFacets f = new SimpleFacets(rb.req, rb.getResults().docSet, params, rb);
|
||||
SimpleFacets f = newSimpleFacets(rb.req, rb.getResults().docSet, params, rb);
|
||||
|
||||
RTimer timer = null;
|
||||
FacetDebugInfo fdebug = null;
|
||||
|
Loading…
x
Reference in New Issue
Block a user