Created
November 12, 2012 14:31
NullPointerException with prefix query
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
See https://groups.google.com/d/topic/elasticsearch/OA4rlKL5DNg/discussion for context. | |
The query : | |
{ | |
"query": { | |
"prefix": { | |
"field^2": "pre" | |
} | |
} | |
} | |
The stack trace: | |
[2012-11-12 15:22:22,931][DEBUG][action.search.type ] [hyperion] [media01][0], node[UzKHSvvvQUavbkV2Y_PdZw], [P], s[STARTED]: Failed to execute [org.elasticsearch.action.search.SearchRequest@fb5c4d9] | |
org.elasticsearch.search.query.QueryPhaseExecutionException: [media01][0]: query[filtered(field^2:pre*)->cache(org.elasticsearch.index.search.nested.NonNestedDocsFilter@a2a5984b)],from[0],size[10]: Query Failed [Failed to execute main query] | |
at org.elasticsearch.search.query.QueryPhase.execute(QueryPhase.java:182) | |
at org.elasticsearch.search.SearchService.executeQueryPhase(SearchService.java:234) | |
at org.elasticsearch.search.action.SearchServiceTransportAction.sendExecuteQuery(SearchServiceTransportAction.java:140) | |
at org.elasticsearch.action.search.type.TransportSearchQueryThenFetchAction$AsyncAction.sendExecuteFirstPhase(TransportSearchQueryThenFetchAction.java:80) | |
at org.elasticsearch.action.search.type.TransportSearchTypeAction$BaseAsyncAction.performFirstPhase(TransportSearchTypeAction.java:205) | |
at org.elasticsearch.action.search.type.TransportSearchTypeAction$BaseAsyncAction.performFirstPhase(TransportSearchTypeAction.java:192) | |
at org.elasticsearch.action.search.type.TransportSearchTypeAction$BaseAsyncAction$2.run(TransportSearchTypeAction.java:178) | |
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) | |
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) | |
at java.lang.Thread.run(Thread.java:636) | |
Caused by: java.lang.NullPointerException | |
at org.apache.lucene.search.MultiTermQuery.rewrite(MultiTermQuery.java:312) | |
at org.apache.lucene.search.FilteredQuery.rewrite(FilteredQuery.java:219) | |
at org.apache.lucene.search.IndexSearcher.rewrite(IndexSearcher.java:592) | |
at org.elasticsearch.search.internal.ContextIndexSearcher.rewrite(ContextIndexSearcher.java:119) | |
at org.apache.lucene.search.Searcher.createNormalizedWeight(Searcher.java:167) | |
at org.apache.lucene.search.IndexSearcher.createNormalizedWeight(IndexSearcher.java:664) | |
at org.elasticsearch.search.internal.ContextIndexSearcher.createNormalizedWeight(ContextIndexSearcher.java:133) | |
at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:342) | |
at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:330) | |
at org.elasticsearch.search.query.QueryPhase.execute(QueryPhase.java:178) | |
... 9 more |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Linked message in elasticsearch ML : https://groups.google.com/d/topic/elasticsearch/OA4rlKL5DNg/discussion