[Geoserver-users] Mapinfo data and Geoserver

Hi,
thanks to Pathbloke who sent me a sample dataset I think I have
traced down the issue with MapInfo data not working with Geoserver.

In the sample there are a ton of multilinestring made of a single
point. In Geoserver we do use JTS to manage geometries, and the
JTS LineString class throws an exception stating that a linestring
with a single point is invalid.

To work around this, the data stores would have to be modified
to recognize broken coordinate sequences and replace them
with one with two identical points, what would be valid for LineString.

The fix is needed in both postgres and oracle afaik, and we
don't have time to work on it now. You may want to provide the
fix yourself, or contract some paid work to have it fixed soon.

The fix for Postgis consists in fixing the WKBReader in order
to spot erroneous coordinate sequences and build a new one with
two coincident points instead, before trying to build the linestring.
On Geoserver 1.5 the fix is even harder, because the WKBReader is
part of JTS, so a fix on that library is needed...

For Oracle, I guess the issue is similar, but haven't checked since
I have no test data.

Cheers
Andrea Aime