HELLO ,
I was using elasticsearch 6.1 before and i was able to query geo_shape LINESTRING using circle intersects . recently updated to 6.6 and unable to query the Same , How do I search for line string which is near to a point , below is my query
GET way/_search
{
"query":
{
"bool": {
"must":
{
"match_all":{}
}
,"filter": {
"geo_shape": {
"geometry": {
"shape": {
"type": "circle",
"coordinates": [25.292679,55.4118288],
"radius":10
}
}
}
}
}
}
}
it gives error like below,
{
"error": {
"root_cause": [
{
"type": "query_shard_exception",
"reason": "failed to create query: {\n "bool" : {\n "must" : [\n {\n "match_all" : {\n "boost" : 1.0\n }\n }\n ],\n "filter" : [\n {\n "geo_shape" : {\n "geometry" : {\n "shape" : {\n "type" : "circle",\n "radius" : "10.0m",\n "coordinates" : [\n 25.292679,\n 55.4118288\n ]\n },\n "relation" : "intersects"\n },\n "ignore_unmapped" : false,\n "boost" : 1.0\n }\n }\n ],\n "adjust_pure_negative" : true,\n "boost" : 1.0\n }\n}",
"index_uuid": "7kFB6PsbR0CPtnXsgOLO6Q",
"index": "way"
}
],
"type": "search_phase_execution_exception",
"reason": "all shards failed",
"phase": "query",
"grouped": true,
"failed_shards": [
{
"shard": 0,
"index": "way",
"node": "7x3HJTAjSPukxRwfrtuLZQ",
"reason": {
"type": "query_shard_exception",
"reason": "failed to create query: {\n "bool" : {\n "must" : [\n {\n "match_all" : {\n "boost" : 1.0\n }\n }\n ],\n "filter" : [\n {\n "geo_shape" : {\n "geometry" : {\n "shape" : {\n "type" : "circle",\n "radius" : "10.0m",\n "coordinates" : [\n 25.292679,\n 55.4118288\n ]\n },\n "relation" : "intersects"\n },\n "ignore_unmapped" : false,\n "boost" : 1.0\n }\n }\n ],\n "adjust_pure_negative" : true,\n "boost" : 1.0\n }\n}",
"index_uuid": "7kFB6PsbR0CPtnXsgOLO6Q",
"index": "way",
"caused_by": {
"type": "unsupported_operation_exception",
"reason": "CIRCLE geometry is not supported"
}
}
}
]
},
"status": 400
}
what will be the solution , i cannot see any doc says this CIRCLE SEARCH is obsolute.
Please help,