Using Geoserver 2.1.2, I ran into a silly situation when looking at WFS
data in ArcGIS. /SOME/ of the polygons in the dataset have their
coordinate axes reversed, while others don't. It's only a problem with
GML3, it is WGS84 data, yadda yadda yadda.
I managed to track down the difference in this case: The table is
identified by PostGIS and Geoserver as MULTIPOLYGON, although
geometrytype(shape) returns POLYGON for some features and MULTIPOLYGON
for others. Polygons that have multiple parts are exclusively drawn in
ArcGIS with reversed axes, while single-part polygons plot in the right
place.
If you look at a WFS response from Geoserver containing one poly and one
multi-part poly, and look at the shape attributes. Both are
<gml:MultiSurface> and that element has a defined srsName attribute
using the URN scheme. However, for single-part features, the
<gml:Polygon> is also given an srsName, this time giving the CRS
definition by reference (http://www.opengis.net/...). Multi-part
polygons don't have this extra srsName attribute on each <gml:Polygon>,
and then the features end up reversed in ArcGIS.
Here's a WFS Query to look at it:
http://services.azgs.az.gov/geoserver/ows?outputFormat=GML3&request=GetFeature&service=WFS&version=1.1.0&typename=gsmlp:GeologicUnitView&filter=%3CFilter%20xmlns=%22http://www.opengis.net/ogc%22%3E%3COr%3E%3CPropertyIsEqualTo%3E%3CPropertyName%3Egsmlp:objectid%3C/PropertyName%3E%3CLiteral%3E12230%3C/Literal%3E%3C/PropertyIsEqualTo%3E%3CPropertyIsEqualTo%3E%3CPropertyName%3Egsmlp:objectid%3C/PropertyName%3E%3CLiteral%3E7321%3C/Literal%3E%3C/PropertyIsEqualTo%3E%3C/Or%3E%3C/Filter%3E
<http://services.azgs.az.gov/geoserver/ows?outputFormat=GML3&request=GetFeature&service=WFS&version=1.1.0&typename=gsmlp:GeologicUnitView&filter=%3CFilter%20xmlns=%22http://www.opengis.net/ogc%22%3E%3COr%3E%3CPropertyIsEqualTo%3E%3CPropertyName%3Egsmlp:objectid%3C/PropertyName%3E%3CLiteral%3E12230%3C/Literal%3E%3C/PropertyIsEqualTo%3E%3CPropertyIsEqualTo%3E%3CPropertyName%3Egsmlp:objectid%3C/PropertyName%3E%3CLiteral%3E7321%3C/Literal%3E%3C/PropertyIsEqualTo%3E%3C/Or%3E%3C/Filter%3E>
I've read up on all the documentation I can find about
Geoserver/Geotools and CRS definitions, and I'm aware of the OGC
coordinate snafus. Putting aside anything that ArcGIS might be doing
wrong, three questions about Geoserver's behavior:
1. Why do single-part features get an extra srsName defined for them
that multi-part features don't seem to get?
2. Even when the "XML" CRS definition is present (single-part
polygons), the coordinates are presented as y/x -- is that how it
should be? It seems backwards according to
http://docs.geoserver.org/stable/en/user/webadmin/services/WFS.html#gml
3. On the WFS configuration page there are options to set the SRS Style
for GML2 and GML3. I've played around with them, but I haven't seen
any changes in the WFS GetCapabilities or GetFeature responses. What
do these configurations do? I found an almost year-old post by
Justin Deoliveira pointing out the issue (
http://osgeo-org.1803224.n2.nabble.com/Problem-with-WFS-GML-SRS-Style-tt6107591.html#a6107595),
but I couldn't find an issue about it on JIRA.
Thank you,
Ryan
------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure
contains a definitive record of customers, application performance,
security threats, fraudulent activity, and more. Splunk takes this
data and makes sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-novd2d
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users