LUCENE-9068: Solr query handling code catches FuzzyTermsException

This commit is contained in:
Alan Woodward 2020-01-16 09:46:46 +00:00
parent 543505470c
commit 7ea7ed72ac
1 changed files with 2 additions and 7 deletions

View File

@ -215,7 +215,7 @@ public class QueryComponent extends SearchComponent
rb.setFilters( filters );
}
}
} catch (SyntaxError e) {
} catch (SyntaxError | FuzzyTermsEnum.FuzzyTermsException e) {
throw new SolrException(SolrException.ErrorCode.BAD_REQUEST, e);
}
@ -1484,12 +1484,7 @@ public class QueryComponent extends SearchComponent
SolrQueryResponse rsp = rb.rsp;
SolrIndexSearcher searcher = req.getSearcher();
try {
searcher.search(result, cmd);
} catch (FuzzyTermsEnum.FuzzyTermsException e) {
throw new SolrException(SolrException.ErrorCode.BAD_REQUEST, e);
}
searcher.search(result, cmd);
rb.setResult(result);
ResultContext ctx = new BasicResultContext(rb);