Field fieldName found and unsupported shape LinearRing – How to solve this Elasticsearch exception

Opster Team

August-23, Version: 7-7.6

Briefly, this error occurs when Elasticsearch encounters a field with a shape type that it doesn’t support, in this case, a LinearRing. Elasticsearch supports various shapes for geospatial data, but LinearRing is not one of them. To resolve this issue, you can either convert the LinearRing to a supported shape type like Polygon or MultiPolygon, or remove the field if it’s not necessary. Alternatively, you can use a different method to index your geospatial data that doesn’t involve unsupported shape types.

This guide will help you check for common problems that cause the log ” Field [” + fieldName + “] found and unsupported shape LinearRing ” to appear. To understand the issues related to this log, read the explanation below about the following Elasticsearch concepts: index, query.

Log Context

Log “Field [” + fieldName + “] found and unsupported shape LinearRing” class name is We extracted the following from Elasticsearch source code for those seeking an in-depth context :

 return LatLonShape.newLineQuery(fieldName; relation.getLuceneRelation(); new Line(line.getY(); line.getX()));
 }  @Override
 public Query visit(LinearRing ring) {
 throw new QueryShardException(context; "Field [" + fieldName + "] found and unsupported shape LinearRing");
 }  @Override
 public Query visit(MultiLine multiLine) {