mirror of https://github.com/apache/lucene.git
SOLR-9786: set filter flag for more parsers
This commit is contained in:
parent
8d7c540e2c
commit
e7aa0e4ce4
|
@ -98,6 +98,7 @@ public abstract class FacetProcessor<FacetRequestT extends FacetRequest> {
|
||||||
QParser parser = null;
|
QParser parser = null;
|
||||||
try {
|
try {
|
||||||
parser = QParser.getParser((String)rawFilter, fcontext.req);
|
parser = QParser.getParser((String)rawFilter, fcontext.req);
|
||||||
|
parser.setIsFilter(true);
|
||||||
Query symbolicFilter = parser.getQuery();
|
Query symbolicFilter = parser.getQuery();
|
||||||
qlist.add(symbolicFilter);
|
qlist.add(symbolicFilter);
|
||||||
} catch (SyntaxError syntaxError) {
|
} catch (SyntaxError syntaxError) {
|
||||||
|
@ -134,6 +135,7 @@ public abstract class FacetProcessor<FacetRequestT extends FacetRequest> {
|
||||||
QParser parser = null;
|
QParser parser = null;
|
||||||
try {
|
try {
|
||||||
parser = QParser.getParser((String) qstring, fcontext.req);
|
parser = QParser.getParser((String) qstring, fcontext.req);
|
||||||
|
parser.setIsFilter(true);
|
||||||
Query symbolicFilter = parser.getQuery();
|
Query symbolicFilter = parser.getQuery();
|
||||||
qlist.add(symbolicFilter);
|
qlist.add(symbolicFilter);
|
||||||
} catch (SyntaxError syntaxError) {
|
} catch (SyntaxError syntaxError) {
|
||||||
|
@ -237,6 +239,7 @@ public abstract class FacetProcessor<FacetRequestT extends FacetRequest> {
|
||||||
Query parentQuery;
|
Query parentQuery;
|
||||||
try {
|
try {
|
||||||
QParser parser = QParser.getParser(parentStr, fcontext.req);
|
QParser parser = QParser.getParser(parentStr, fcontext.req);
|
||||||
|
parser.setIsFilter(true);
|
||||||
parentQuery = parser.getQuery();
|
parentQuery = parser.getQuery();
|
||||||
} catch (SyntaxError err) {
|
} catch (SyntaxError err) {
|
||||||
throw new SolrException(SolrException.ErrorCode.BAD_REQUEST, "Error parsing block join parent specification: " + parentStr);
|
throw new SolrException(SolrException.ErrorCode.BAD_REQUEST, "Error parsing block join parent specification: " + parentStr);
|
||||||
|
|
|
@ -568,6 +568,7 @@ class FacetQueryParser extends FacetParser<FacetQuery> {
|
||||||
|
|
||||||
if (qstring != null) {
|
if (qstring != null) {
|
||||||
QParser parser = QParser.getParser(qstring, getSolrRequest());
|
QParser parser = QParser.getParser(qstring, getSolrRequest());
|
||||||
|
parser.setIsFilter(true);
|
||||||
facet.q = parser.getQuery();
|
facet.q = parser.getQuery();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue