Closed estin closed 9 years ago
Hi @colings86 - please could you take a look at this one too.
Exception logged on server is listed below. This is strange as it seems that the top hits aggregator is being run on the 'scroll next' call when it should only be run on the initial scan.
org.elasticsearch.search.query.QueryPhaseExecutionException: [places][0]: query[ConstantScore(cache(_type:place))],from[2],size[2]: Query Failed [Failed to execute main query]
at org.elasticsearch.search.query.QueryPhase.execute(QueryPhase.java:163)
at org.elasticsearch.search.SearchService.executeQueryPhase(SearchService.java:314)
at org.elasticsearch.search.action.SearchServiceTransportAction$9.call(SearchServiceTransportAction.java:299)
at org.elasticsearch.search.action.SearchServiceTransportAction$9.call(SearchServiceTransportAction.java:1)
at org.elasticsearch.search.action.SearchServiceTransportAction$23.run(SearchServiceTransportAction.java:559)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.NullPointerException
at org.apache.lucene.search.TopFieldCollector$OutOfOrderOneComparatorNonScoringCollector.collect(TopFieldCollector.java:134)
at org.elasticsearch.search.aggregations.metrics.tophits.TopHitsAggregator.collect(TopHitsAggregator.java:118)
at org.elasticsearch.search.aggregations.bucket.BucketsAggregator.collectBucketNoCounts(BucketsAggregator.java:74)
at org.elasticsearch.search.aggregations.bucket.BucketsAggregator.collectExistingBucket(BucketsAggregator.java:63)
at org.elasticsearch.search.aggregations.bucket.geogrid.GeoHashGridAggregator.collect(GeoHashGridAggregator.java:83)
at org.elasticsearch.search.aggregations.AggregationPhase$AggregationsCollector.collect(AggregationPhase.java:161)
at org.elasticsearch.common.lucene.MultiCollector.collect(MultiCollector.java:60)
at org.apache.lucene.search.Weight$DefaultBulkScorer.scoreAll(Weight.java:193)
at org.apache.lucene.search.Weight$DefaultBulkScorer.score(Weight.java:163)
at org.apache.lucene.search.BulkScorer.score(BulkScorer.java:35)
at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:621)
at org.elasticsearch.search.internal.ContextIndexSearcher.search(ContextIndexSearcher.java:191)
at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:491)
at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:448)
at org.apache.lucene.search.IndexSearcher.searchAfter(IndexSearcher.java:243)
at org.elasticsearch.search.query.QueryPhase.execute(QueryPhase.java:136)
... 7 more
The issue can be reproduced on the 1.4 branch but not on the master branch. I haven't checked any other versions.
@estin could you confirm which version of Elasticsearch you are running?
1.4.4
docker image - https://github.com/dockerfile/elasticsearch
curl -XGET 'http://localhost:9200
version
{
"cluster_name": "elasticsearch",
"name": "Fever Pitch",
"status": 200,
"tagline": "You Know, for Search",
"version": {
"build_hash": "c88f77ffc81301dfa9dfd81ca2232f09588bd512",
"build_snapshot": false,
"build_timestamp": "2015-02-19T13:05:36Z",
"lucene_version": "4.10.3",
"number": "1.4.4"
}
}
1.5.0 have this bug - NullPointerException, but error message changed compared to 1.4.4
{
"error": "SearchPhaseExecutionException[Failed to execute phase [query], all shards failed; shardFailures {[AJziGR-zRralfguZOlUAfw][places][0]: QueryPhaseExecutionException[[places][0]: query[filtered(ConstantScore(+GeoBoundingBoxFilter(location, [41.11, 41.09], [41.1, 41.108])))->cache(_type:place)],from[2],size[2],sort[<score>,<custom:\"id\": org.elasticsearch.index.fielddata.fieldcomparator.LongValuesComparatorSource@714de5ce>!]: Query Failed [Failed to execute main query]]; nested: NullPointerException; }{[AJziGR-zRralfguZOlUAfw][places][1]: QueryPhaseExecutionException[[places][1]: query[filtered(ConstantScore(+GeoBoundingBoxFilter(location, [41.11, 41.09], [41.1, 41.108])))->cache(_type:place)],from[2],size[2],sort[<score>,<custom:\"id\": org.elasticsearch.index.fielddata.fieldcomparator.LongValuesComparatorSource@7bac1fe0>!]: Query Failed [Failed to execute main query]]; nested: NullPointerException; }{[AJziGR-zRralfguZOlUAfw][places][2]: QueryPhaseExecutionException[[places][2]: query[filtered(ConstantScore(+GeoBoundingBoxFilter(location, [41.11, 41.09], [41.1, 41.108])))->cache(_type:place)],from[2],size[2],sort[<score>,<custom:\"id\": org.elasticsearch.index.fielddata.fieldcomparator.LongValuesComparatorSource@27e2ed3>!]: Query Failed [Failed to execute main query]]; nested: NullPointerException; }{[AJziGR-zRralfguZOlUAfw][places][3]: QueryPhaseExecutionException[[places][3]: query[filtered(ConstantScore(+GeoBoundingBoxFilter(location, [41.11, 41.09], [41.1, 41.108])))->cache(_type:place)],from[2],size[2],sort[<score>,<custom:\"id\": org.elasticsearch.index.fielddata.fieldcomparator.LongValuesComparatorSource@e3d27fc>!]: Query Failed [Failed to execute main query]]; nested: NullPointerException; }{[AJziGR-zRralfguZOlUAfw][places][4]: QueryPhaseExecutionException[[places][4]: query[filtered(ConstantScore(+GeoBoundingBoxFilter(location, [41.11, 41.09], [41.1, 41.108])))->cache(_type:place)],from[2],size[2],sort[<score>,<custom:\"id\": org.elasticsearch.index.fielddata.fieldcomparator.LongValuesComparatorSource@63735262>!]: Query Failed [Failed to execute main query]]; nested: NullPointerException; }]",
"status": 500
}
[2015-03-27 07:12:24,639][DEBUG][action.search.type ] [Kang the Conqueror] [327] Failed to execute query phase
org.elasticsearch.search.query.QueryPhaseExecutionException: [places][2]: query[filtered(ConstantScore(+GeoBoundingBoxFilter(location, [41.11, 41.09], [41.1, 41.108])))->cache(_type:place)],from[2],size[2],sort[<score>,<custom:"id": org.elasticsearch.index.fielddata.fieldcomparator.LongValuesComparatorSource@27e2ed3>!]: Query Failed [Failed to execute main query]
at org.elasticsearch.search.query.QueryPhase.execute(QueryPhase.java:163)
at org.elasticsearch.search.SearchService.executeQueryPhase(SearchService.java:328)
at org.elasticsearch.search.action.SearchServiceTransportAction$9.call(SearchServiceTransportAction.java:299)
at org.elasticsearch.search.action.SearchServiceTransportAction$9.call(SearchServiceTransportAction.java:296)
at org.elasticsearch.search.action.SearchServiceTransportAction$23.run(SearchServiceTransportAction.java:559)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.NullPointerException
at org.apache.lucene.search.TopFieldCollector$OutOfOrderOneComparatorNonScoringCollector.collect(TopFieldCollector.java:134)
at org.elasticsearch.search.aggregations.metrics.tophits.TopHitsAggregator.collect(TopHitsAggregator.java:116)
at org.elasticsearch.search.aggregations.bucket.BucketsAggregator.collectBucketNoCounts(BucketsAggregator.java:74)
at org.elasticsearch.search.aggregations.bucket.BucketsAggregator.collectExistingBucket(BucketsAggregator.java:63)
at org.elasticsearch.search.aggregations.bucket.geogrid.GeoHashGridAggregator.collect(GeoHashGridAggregator.java:83)
at org.elasticsearch.search.aggregations.AggregationPhase$AggregationsCollector.collect(AggregationPhase.java:161)
at org.elasticsearch.common.lucene.MultiCollector.collect(MultiCollector.java:60)
at org.apache.lucene.search.Weight$DefaultBulkScorer.scoreAll(Weight.java:193)
at org.apache.lucene.search.Weight$DefaultBulkScorer.score(Weight.java:163)
at org.apache.lucene.search.BulkScorer.score(BulkScorer.java:35)
at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:621)
at org.elasticsearch.search.internal.ContextIndexSearcher.search(ContextIndexSearcher.java:191)
at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:581)
at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:533)
at org.apache.lucene.search.IndexSearcher.searchAfter(IndexSearcher.java:424)
at org.elasticsearch.search.query.QueryPhase.execute(QueryPhase.java:127)
... 7 more
on 1.6.0
[2015-07-02 19:54:45,895][DEBUG][action.search.type ] [Crimson Dynamo V] [28140] Failed to execute query phase
org.elasticsearch.search.query.QueryPhaseExecutionException: [places][3]: query[filtered(ConstantScore(+GeoBoundingBoxFilter(location, [41.1
1, 41.09], [41.1, 41.108])))->cache(_type:place)],from[2],size[2],sort[<score>,<custom:"id": org.elasticsearch.index.fielddata.fieldcomparat
or.LongValuesComparatorSource@392631ef>!]: Query Failed [Failed to execute main query]
at org.elasticsearch.search.query.QueryPhase.execute(QueryPhase.java:163)
at org.elasticsearch.search.SearchService.executeQueryPhase(SearchService.java:331)
at org.elasticsearch.search.action.SearchServiceTransportAction$9.call(SearchServiceTransportAction.java:299)
at org.elasticsearch.search.action.SearchServiceTransportAction$9.call(SearchServiceTransportAction.java:296)
at org.elasticsearch.search.action.SearchServiceTransportAction$23.run(SearchServiceTransportAction.java:559)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.NullPointerException
Fixed in master. Closing
start elasticsearch in docker
check elasticsearch version in output
script
output
Sorry for my poor English