NullPointerException using "has_child" filter after upgrade to v0.90.5


(Ankush Jhalani) #1

After upgrading from v0.90.1 -> v0.90.5, we noticed that some of our
has_child filter queries started to fail on some shards. Following is the
request -
curl -x '' -s -XPOST
'http://localhost:9201/data_index_20131011/vendor/_search?from=0&size=2' -d
'
{
"filter" : {
"has_child" : {
"query" : {
"match" : {
"set_aside_descriptions" : {
"query" : "No set aside used."
}
}
},
"type" : "transaction"
}
}
}
'

And the error trace from logs -
[2013-10-24 08:54:07,330][TRACE][search ] [mach2.node]
Query phase failed
org.elasticsearch.search.query.QueryPhaseExecutionException:
[data_index_20131011][0]:
query[ConstantScore(cache(_type:vendor))],from[0],size[2]: Query Failed
[Failed to execute main query]
at
org.elasticsearch.search.query.QueryPhase.execute(QueryPhase.java:138)
at
org.elasticsearch.search.SearchService.executeQueryPhase(SearchService.java:219)
at
org.elasticsearch.search.action.SearchServiceTransportAction$SearchQueryTransportHandler.messageReceived(SearchServiceTransportAction.java:623)
at
org.elasticsearch.search.action.SearchServiceTransportAction$SearchQueryTransportHandler.messageReceived(SearchServiceTransportAction.java:612)
at
org.elasticsearch.transport.netty.MessageChannelHandler$RequestHandler.run(MessageChannelHandler.java:269)
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:722)
Caused by: java.lang.NullPointerException
at
org.elasticsearch.common.lucene.docset.MatchDocIdSet.shortCircuit(MatchDocIdSet.java:82)
at
org.elasticsearch.index.search.child.HasChildFilter$ParentDocSet.matchDoc(HasChildFilter.java:174)
at
org.elasticsearch.common.lucene.docset.MatchDocIdSet.get(MatchDocIdSet.java:69)
at
org.elasticsearch.common.lucene.search.FilteredCollector.collect(FilteredCollector.java:61)
at org.apache.lucene.search.Scorer.score(Scorer.java:65)
at
org.apache.lucene.search.ConstantScoreQuery$ConstantScorer.score(ConstantScoreQuery.java:245)
at
org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:624)
at
org.elasticsearch.search.internal.ContextIndexSearcher.search(ContextIndexSearcher.java:162)
at
org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:488)
at
org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:444)
at
org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:281)
at
org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:269)
at
org.elasticsearch.search.query.QueryPhase.execute(QueryPhase.java:134)
... 7 more

The same query works fine in v0.90.1. It's tough to provide a gist to
replicate because the error is data dependent, it only happens for some
queries. For e.g. "query" : "blah blah" works fine but "query" : "No set
aside used." fails. Also the whole index data size is more than a GB.

This is blocking our upgrade to v0.90.5 so any help would be much
appreciated. Thanks in advance!!

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


(Clinton Gormley) #2

Hi Ankush

Please open this as an issue. You should never get NPEs.

thanks

clint

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


(system) #3