[mapserver-dev] WFS xsi:schemaLocation & BBOX

Josef Bicik josef.bicik at de.abb.com
Thu Jul 26 09:13:15 PDT 2012


Hi Devs,

I have a test server running Apache and Mapserver 6.0.3 running under 
HTTPS on localhost on a non-standard port 8443. When I send a WFS POST 
request to the server I get a malformed XML file due to invalid characters 
in "xsi:schemaLocation". This appears to be caused by the https + port 
8443 in "ows_service_onlineresource" in the mapfile. This problem does not 
occur when I use http + port 8080. See part of the XML response below 
(strange characters after https://127.0.0.1:8443/test-wms?):

<?xml version='1.0' encoding="ISO-8859-1" ?>
<wfs:FeatureCollection
   xmlns:ms="http://mapserver.gis.umn.edu/mapserver"
   xmlns:gml="http://www.opengis.net/gml"
   xmlns:wfs="http://www.opengis.net/wfs"
   xmlns:ogc="http://www.opengis.net/ogc"
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
   xsi:schemaLocation="http://mapserver.gis.umn.edu/mapserver 
https://127.0.0.1:8443/test-wms?-â­SERVICE=WFS&VERSION=1.1.0&REQUEST=DescribeFeatureType&TYPENAME=ms:cities&OUTPUTFORMAT=text/xml;%20subtype=gml/3.1.1 
 http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.1.0/wfs.xsd">
      <gml:boundedBy>
        <gml:Envelope srsName="EPSG:3857">
                <gml:lowerCorner>-64.318558 -24.711018</gml:lowerCorner>
                <gml:upperCorner>-60.597546 -23.138828</gml:upperCorner>
        </gml:Envelope>
      </gml:boundedBy>

My mapfile is:

MAP
    NAME "sample"
    STATUS ON
    SIZE 600 400
    EXTENT -180.0000 -90.0000 180.0000 90.0000 
    IMAGECOLOR 200 200 255

  CONFIG "MS_ERRORFILE" "mserror.log"
  CONFIG "PROJ_DEBUG" "ON"
  DEBUG 5
  WEB 
    METADATA
      "ows_enable_request" "*"
      "ows_service_onlineresource" "https://127.0.0.1:8443/test-wms?"
      "ows_title" "GIS"
      "ows_abstract" ""
      "ows_srs" "EPSG:3857 EPSG:4326"
    END
  END

  PROJECTION 
    "init=epsg:4326"
  END

  SYMBOL
    NAME "circle"
    TYPE ellipse
    FILLED true
    POINTS
      1 1
    END
  END

  LAYER
    NAME cities
    TYPE POINT
    STATUS OFF
    DATA citypoints.shp

          METADATA
      ows_title "cities"
      ows_abstract "World cities"
      ows_featureid "NAME"
      "gml_include_items" "all" ## Optional (serves all attributes for 
layer) 

          END

    CLASS
      STYLE
        COLOR 255 0 0
        OUTLINECOLOR 50 50 50
        SYMBOL "circle"
        SIZE 5
      END
    END

    PROJECTION 
      "init=epsg:4326"
    END
 
  END # LAYER
END # MAP

And the POST request looks like:

<wfs:GetFeature xmlns:wfs="http://www.opengis.net/wfs" service="WFS" 
version="1.1.0" maxFeatures="5" xsi:schemaLocation="
http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.1.0/wfs.xsd" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><wfs:Query 
typeName="ms:cities" srsName="EPSG:4326"><ogc:Filter xmlns:ogc="
http://www.opengis.net/ogc
"><ogc:BBOX><ogc:PropertyName>msGeometry</ogc:PropertyName><gml:Envelope 
xmlns:gml="http://www.opengis.net/gml" 
srsName="EPSG:3857"><gml:lowerCorner>-148950696.7618 
-61443140.808204</gml:lowerCorner><gml:upperCorner>148950696.7618 
61443140.808204</gml:upperCorner></gml:Envelope></ogc:BBOX></ogc:Filter></wfs:Query></wfs:GetFeature>
Another issue, seems to be related to the bounding box (<gml:boundedBy>). 
The bounding box in the response was not correctly reprojected or it 
should be in EPSG:4326. Have I missed anything or are these potentially 
bugs and should I open ticket(s) for them? Thanks for your help.

Regards, Josef



Josef Bicik
ABB AG
ABB-PSP-PRU14
Kallstadter Straße 1
68309, Mannheim, Baden-Württemberg, GERMANY
Phone: +49 621 3812318
Telefax: +49 621 3814737
email: josef.bicik at de.abb.com

ABB AG
Sitz/Head Office: Mannheim 
Registergericht/Registry Court: Mannheim
Handelsregisternummer/Commercial Register No.: HRB 4664
Geschäftsführung/Managing Board: Peter Smits (Vorsitzender), Hans-Georg 
Krabbe, Dr. Joachim Schneider, Markus Ochsner
Vorsitzender des Aufsichtsrats/Chairman of Supervisory Board: Bernhard 
Jucker

Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte 
Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail 
irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und 
vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte 
Weitergabe dieser Mail ist nicht gestattet. 

This e-mail may contain confidential and/or privileged information. If you 
are not the intended recipient (or have received this e-mail in error) 
please notify the sender immediately and destroy this e-mail. Any 
unauthorized copying, disclosure or distribution of the material in this 
e-mail is strictly forbidden.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20120726/aa65f957/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: image/gif
Size: 441 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20120726/aa65f957/attachment.gif>


More information about the mapserver-dev mailing list