[Geoserver-users] Problems with EPSG lookup

I'm here again.

On Geoserver 1.5.0-RC1 there seems to be something strange with EPSG management.

When I create a new Coverage (or edit an existing FeatureType) I'm not able to insert my preferred EPSG code.

In the FeatureType Editor page I insert my EPSG code (in my case, 3003) and press the "Lookup SRS" button. After a (strange) while I get the number 3003 overwritten with "UNKNOWN" and the SRS WKT is: "Could not find a definition for: EPSG:UNKNOWN".

In the Tomcat log I find:

^@3935919 [MOLTO FINE] org.vfny.geoserver.global.DataStoreInfo - in string url
^@3935921 [FINE] org.geotools.data.property.PropertyDataStoreFactory - can't process parameters
java.io.IOException: Parameter directory is required:Directory containting property files
        at org.geotools.data.DataStoreFactorySpi$Param.lookUp(DataStoreFactorySpi.java:390)
        at org.geotools.data.property.PropertyDataStoreFactory.directoryLookup(PropertyDataStoreFactory.java:185)
        at org.geotools.data.property.PropertyDataStoreFactory.canProcess(PropertyDataStoreFactory.java:154)
        at org.geotools.data.DataStoreFinder.getDataStore(DataStoreFinder.java:94)
        at org.vfny.geoserver.util.DataStoreUtils.acquireDataStore(DataStoreUtils.java:40)
        at org.vfny.geoserver.config.DataStoreConfig.findDataStore(DataStoreConfig.java:330)
        at org.vfny.geoserver.form.data.TypesEditorForm.reset(TypesEditorForm.java:267)
        at org.apache.struts.action.RequestProcessor.processPopulate(RequestProcessor.java:809)
        [...]

Maybe is it not finding the EPSG definition file?

When creating a new Coverage (Coverage Editor page), when I insert my EPSG number (3003) and press "Lookup SRS", it gest immediately overwritten with "EPSG:4326". Does that mean the only SRS supported for rasters is 4326?

Thanks in advance,

Fabio Da Soghe

Fabio Da Soghe ha scritto:

I'm here again.

On Geoserver 1.5.0-RC1 there seems to be something strange with EPSG
management.

When I create a new Coverage (or edit an existing FeatureType) I'm
not able to insert my preferred EPSG code.

In the FeatureType Editor page I insert my EPSG code (in my case,
3003) and press the "Lookup SRS" button. After a (strange) while I
get the number 3003 overwritten with "UNKNOWN" and the SRS WKT is:
"Could not find a definition for: EPSG:UNKNOWN".

Nope, the lookup SRS button is there to make Geoserver compare
native data SRS information (if there is any) against the
EPSG database and find a matching EPSG number.
This is not done automatically because it requires several
seconds to match native CRS parameters ata

If your data does not have native information, or if it's not
found, you'll get UNKNOWN.
Nothing prevents you from setting your own, just don't re-repress
"lookup SRS" after that :slight_smile:
Yet, if you set 3003 and lookup srs returns 4326, it means your
coverage contains 4326 as native CRS, not 3003.
Geoserver won't allow you to force a different SRS, if you provide
a different one, data will be reprojected from the native one to the declared one, from 4326 to 3003, in your case. This behaviour is
needed to handle data whose native CRS is not matched at all in the EPSG
database.
The declared CRS will be "forced" only if your data does not have one,
in that case we'll assume data has the same CRS as the declared one.

It's a tricky issue, as a general approach we decided to trust more
the data than the user since most of the users around do not even know
what an EPSG code is, let alone WKT, Bursa Worlf parameters and the like. I guess those who know should be able to fix their data, should
it contain wrong SRS information.

Hope this helps
Cheers
Andrea