Ticket #1779 (closed bug: fixed)
Invalid WFS transaction generated
| Reported by: | adube | Owned by: | tschaub |
|---|---|---|---|
| Priority: | minor | Milestone: | 2.8 Release |
| Component: | Protocol | Version: | |
| Keywords: | Cc: | adube@… | |
| State: |
Description
I'm currently trying the Protocol.WFS new features and I'm a problem. I use TinyOWS 0.6.0 and OL 2.7.
I've followed the wfs-protocol-transactions example to reproduce the same kind of actions ( add-modify features ) Here's the post request that OL produces for my application :
<wfs:Transaction xmlns:wfs="http://www.opengis.net/wfs" service="WFS" version="1.0.0" outputFormat="GML2">
<wfs:Insert>
<feature:bdga_route_l_arc xmlns:feature="http://127.0.0.1:9999/">
<feature:the_geom>
<gml:MultiLineString xmlns:gml="http://www.opengis.net/gml" srsName="EPSG:32198">
<gml:lineStringMember>
<gml:LineString>
<gml:coordinates decimal="." cs="," ts=" ">-389909.9750701957,184819.27638712854 -390597.89136538754,183513.99931420037</gml:coordinates>
</gml:LineString>
</gml:lineStringMember>
</gml:MultiLineString>
</feature:the_geom>
</feature:bdga_route_l_arc>
</wfs:Insert>
</wfs:Transaction>
This post is very similar the the post produced by the wfs-protocol-transactions example. But, the example uses Geoserver and no error occurs. Tinyows gives 2 errors :
==> element Transaction: Schemas validity error : Element '{http://www.opengis.net/wfs}Transaction', attribute 'outputFormat': The attribute 'outputFormat' is not allowed.
==> element bdga_route_l_arc: Schemas validity error : Element '{http://127.0.0.1:9999/}bdga_route_l_arc': This element is not expected. Expected is one of ( {http://www.opengis.net/gml}_Feature, {http://www.opengis.net/wfs}FeatureCollection ).
Both means that the schema WFS-transaction is not respected... I don't know why it works with GeoServer, but I think it shouldn't. Normand ( one of my co-workers ) modified TinyOWS to make it ignore schema errors, and then it works fine. But, I think that's not a good solution. The post request should respect the schema ( see attached file ).
So far, I tried GML3 and also tried to edit OL code to change this behavior, but without success.
Alexandre

