[Geoserver-devel] [jira] (GEOS-4946) WFS insert transaction returns incorrect feature id

Ray Merkert created GEOS-4946:
---------------------------------

             Summary: WFS insert transaction returns incorrect feature id
                 Key: GEOS-4946
                 URL: https://jira.codehaus.org/browse/GEOS-4946
             Project: GeoServer
          Issue Type: Bug
            Reporter: Ray Merkert
            Assignee: Andrea Aime

I've a got simple setup with a propertyfile store. When I insert a feature into the store, the feature is properly added, but with an automatically assigned id. It's completely ignoring the id I provide in my request:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?><Transaction xmlns="http://www.opengis.net/wfs&quot; xmlns:ns2="http://www.opengis.net/gml&quot; xmlns:ns3="http://www.w3.org/1999/xlink&quot; xmlns:ns4="http://www.w3.org/2001/SMIL20/&quot; xmlns:ns5="http://www.opengis.net/ogc&quot; xmlns:ns6="http://www.opengis.net/ows&quot; xmlns:ns7="http://dkkn.raytheon.com" xmlns:ns8="http://www.w3.org/2001/SMIL20/Language&quot; service="WFS" version="1.1.0"><Insert idgen="UseExisting"><ns7:PointFeature ns2:id="PointFeature.123456789"><ns7:featureName>Boston-WFS</ns7:featureName><ns7:point ns3:type="simple"><ns2:Point srsName="http://www.opengis.net/gml/srs/epsg\.xml\#4326&quot;&gt;&lt;ns2:coordinates&gt;10,10&lt;/ns2:coordinates&gt;&lt;/ns2:Point&gt;&lt;/ns7:point&gt;&lt;/ns7:PointFeature&gt;&lt;/Insert&gt;&lt;/Transaction&gt;

Normally, I could deal with this if the response contained the correct feature id: Here is what I get, though:
<?xml version="1.0" encoding="UTF-8"?>
<wfs:TransactionResponse version="1.1.0" xsi:schemaLocation="http://www.opengis.net/wfs http://localhost:8080/geoserver/schemas/wfs/1.1.0/wfs.xsd&quot; xmlns:sf="http://www.openplans.org/spearfish&quot; xmlns:ogc="http://www.opengis.net/ogc&quot; xmlns:gml="http://www.opengis.net/gml&quot; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance&quot; xmlns:xlink="http://www.w3.org/1999/xlink&quot; xmlns:ows="http://www.opengis.net/ows&quot; xmlns:wfs="http://www.opengis.net/wfs&quot;&gt;&lt;wfs:TransactionSummary&gt;&lt;wfs:totalInserted&gt;1&lt;/wfs:totalInserted&gt;&lt;wfs:totalUpdated&gt;0&lt;/wfs:totalUpdated&gt;&lt;wfs:totalDeleted&gt;0&lt;/wfs:totalDeleted&gt;&lt;/wfs:TransactionSummary&gt;&lt;wfs:TransactionResults/&gt;&lt;wfs:InsertResults&gt;&lt;wfs:Feature&gt;&lt;ogc:FeatureId fid="new0"/></wfs:Feature></wfs:InsertResults></wfs:TransactionResponse>

You can see that it returns new0 as the feature id. Unfortunately, the propertyfile has a completely different id:
_=featureName:String,point:Point:srid=4326
dkknstore.:PointFeature.1328126922861=Boston-WFS|POINT (10 10)

Initially I had thought that geotools was buggy, but now I'm thinking it's the geoserver. I can provide some source code if that helps.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira