[MS4W-Users] MapServer SOS

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[MS4W-Users] MapServer SOS

mepa1363
I tried to set up MapServer SOS and could run GetCapabilities and DecsribeSensor perfectly. But I faced a problem regarding to GetObservation: the SOS doesn't return anything. You may see the map file I have created below: 


    MAP  
      NAME "SOS_DEMO"   
      STATUS ON   
      SIZE 400 300   
      EXTENT -180 -90 180 90   
      UNITS METERS   
      SHAPEPATH "C:\ms4w\apps\tutorial\data"   
      IMAGECOLOR 255 255 255   
    
      WEB   
        IMAGEPATH "C:\ms4w\apps\tutorial\templates"   
        IMAGEURL "C:\ms4w\apps\tutorial\images"   
        METADATA   
          "sos_onlineresource" "http://127.0.0.1:8282/cgi-bin/mapserv.exe?map=c:/ms4w/mysos.map?"   
          "sos_title"          "My SOS Demo Server"   
          "sos_srs"            "EPSG:4326"   
          "sos_enable_request" "*"   
        END   
      END   

      PROJECTION   
        "init=epsg:4326"   
      END   

      LAYER   
        NAME "sos_point"   
        METADATA   
          "sos_procedure"  "ifgi-sensor-1"   
          "sos_offering_id" "WQ1289"   
          "sos_observedproperty_id" "Water Quality"   
          "sos_describesensor_url" "http://127.0.0.1:8181/DescribeSensor.xml"   
        END   
    
        TYPE POINT   
        STATUS ON   
        DATA 'sospoint'   
        PROJECTION   
          "init=epsg:4326"   
        END   
        CLASS   
          NAME 'sospoint'   
          STYLE   
            COLOR 255 128 128   
          END   
        END   
      END    
    END   


As you see, I tried to retrieve sensor data from a shapefile. The message returned by the SOS is: 

    <om:ObservationCollection xmlns:gml="http://www.opengis.net/gml" xmlns:ows="http://www.opengis.net/ows/1.1" xmlns:swe="http://www.opengis.net/swe/1.0.1" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:sos="http://www.opengis.net/sos/1.0" xmlns:ms="http://mapserver.gis.umn.edu/mapserver" xmlns:om="http://www.opengis.net/om/1.0" gml:id="WQ1289" xsi:schemaLocation="http://www.opengis.net/om/1.0 http://schemas.opengis.net/om/1.0.0/om.xsd http://mapserver.gis.umn.edu/mapserver http://127.0.0.1:8282/cgi-bin/mapserv.exe?map=c:/ms4w/mysos.map?service=WFS&version=1.1.0&request=DescribeFeatureType&typename=sos_point">  
    <om:member>
    <om:Observation>
    <om:procedure xlink:href="urn:ogc:def:procedure:ifgi-sensor-1"/>
    <om:observedProperty>
    <swe:CompositePhenomenon gml:id="Water Quality" dimension="3">
    <swe:component xlink:href="urn:ogc:def:property:OGC-SWE:1:Id"/>
    <swe:component xlink:href="urn:ogc:def:property:OGC-SWE:1:sensor_nam"/>
    <swe:component xlink:href="urn:ogc:def:property:OGC-SWE:1:sensor_val"/>
    </swe:CompositePhenomenon>
    </om:observedProperty>
    <om:resultDefinition>
    <swe:DataBlockDefinition>
    <swe:components>
    <swe:DataRecord/>
    </swe:components>
    <swe:encoding>
    <swe:TextBlock tokenSeparator="," blockSeparator=" " decimalSeparator="."/>
    </swe:encoding>
    </swe:DataBlockDefinition>
    </om:resultDefinition>
    <om:result></om:result>
    </om:Observation>
    </om:member>
    </om:ObservationCollection>


Although I put 6 observations into the shapefile but the SOS doesn't return any. I have also tested it by retrieving data from PostGIS and it did not work. Would you please let me know what I should do to resolve the problem?! 

Thanks, 
Ebrahim

_______________________________________________
MS4W-Users mailing list
[hidden email]
http://lists.maptools.org/mailman/listinfo/ms4w-users