elasticsearch/elasticsearch — pull request #8475 by nknize (2014-11-13 18:02:52+00:00)
Title: [GEO] Fix for ArithmeticException[/ by zero] when parsing a polygon

While this commit is primariy a fix for issue/8433 it adds more rigor to ShapeBuilder for parsing against the GeoJSON specification. Specifically, this adds LinearRing and LineString validity checks as defined in http://geojson.org/geojson-spec.html to ensure valid polygons are specified. The benefit of this fix is to provide a gate check at parse time to avoid any further processing if an invalid GeoJSON is provided. More parse checks like these will be necessary going forward to ensure full compliance with the GeoJSON specification.

Closes #8433