It appears to me a problem with geoserver 1.4.0 stable, regarding configuring FeatureType with custom schema.xml file.
I follow the procedure explained in the documentation, in page "Geoserver config files": I have a PostGIS table in my datastore, I don't create the FeatureType with the web admin but create a directory with the proper name in the data directory, then put into it the info.xml and schema.xml files (handwritten), with a custom GML Schema. Then I open Geoserver's web admin and hit "Load". All works fine: it loads the new configuration, I can see the new feature type and the WFS DescribeFeatureType request returns the right schema. I tested the WMS and WFS interfaces on these datas and all works perfectly, so I'm confident my info.xml and schema.xml files are correct.
Then I use the web admin to edit another already existent feature type (I change a trivial parameter, like the bounding box), hit "Apply", then "Save". Geoserver takes the new parameter correctly, but my custom schema.xml file is rewritten. If I repeat the DescribeFeatureType request I still get the correct result, but only because Geoserver has it in some cache: if I hit "Load" or restart Tomcat, the response gets corrupted.
I searched through the issue tracker and found something related, particularly http://jira.codehaus.org/browse/GEOS-510 which is still open, but it's related to the web admin itself, not a custom schema.xml file.
Have I to fill a bug report for this or is it a duplicate (in which case I apologize: I searched extensively through Jira but I was unable to find it)?
The issue you have found is related to the existing one, but a little different and needs to be addressed separately. So yeh go ahead and file a bug report.
Thanks for finding the issue Fabio!
Brent Owens
(The Open Planning Project)
Fabio Da Soghe wrote:
Hello list.
It appears to me a problem with geoserver 1.4.0 stable, regarding configuring FeatureType with custom schema.xml file.
I follow the procedure explained in the documentation, in page "Geoserver config files": I have a PostGIS table in my datastore, I don't create the FeatureType with the web admin but create a directory with the proper name in the data directory, then put into it the info.xml and schema.xml files (handwritten), with a custom GML Schema. Then I open Geoserver's web admin and hit "Load". All works fine: it loads the new configuration, I can see the new feature type and the WFS DescribeFeatureType request returns the right schema. I tested the WMS and WFS interfaces on these datas and all works perfectly, so I'm confident my info.xml and schema.xml files are correct.
Then I use the web admin to edit another already existent feature type (I change a trivial parameter, like the bounding box), hit "Apply", then "Save". Geoserver takes the new parameter correctly, but my custom schema.xml file is rewritten. If I repeat the DescribeFeatureType request I still get the correct result, but only because Geoserver has it in some cache: if I hit "Load" or restart Tomcat, the response gets corrupted.
I searched through the issue tracker and found something related, particularly http://jira.codehaus.org/browse/GEOS-510 which is still open, but it's related to the web admin itself, not a custom schema.xml file.
Have I to fill a bug report for this or is it a duplicate (in which case I apologize: I searched extensively through Jira but I was unable to find it)?