asascience-open / ncWMS

A Web Map Service for geospatial data that are stored in CF-compliant NetCDF files
http://www.resc.rdg.ac.uk/trac/ncWMS/
13 stars 7 forks source link

Deploying ncWMS war and jar #1

Closed jllodra closed 12 years ago

jllodra commented 12 years ago

Hi,

we've been trying to deploy your ncWMS jar for thredds without luck from your branch named "asa". Our steps were building with "ant jar-for-THREDDS" and then replacing current ncwms.jar from thredds' lib with the new one.

Error in logs starts with:

May 2, 2012 10:11:33 AM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Allocate exception for servlet wms
java.lang.NoClassDefFoundError: uk/ac/rdg/resc/ncwms/util/Ranges

Any hint or guide to deploy it on a thredds server?

We have also tried to deploy the war version, and it fails as well:

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'config' defined in ServletContext resource [/WEB-INF/WMS-servlet.xml]: Instantiation of bean failed; 
nested exception is org.springframework.beans.factory.BeanDefinitionStoreException: Factory method [public static uk.ac.rdg.resc.ncwms.config.Config 
uk.ac.rdg.resc.ncwms.config.Config.readConfig(java.io.File) throws java.lang.Exception] threw exception; 
nested exception is org.simpleframework.xml.core.AttributeException: Attribute 'nearestTime' does not have a match in class uk.ac.rdg.resc.ncwms.config.Dataset at line 3
kwilcox commented 12 years ago

Which version of THREDDS are you running?

jllodra commented 12 years ago

TDS version is: 4.2.20110517.1318

too old? :)

kwilcox commented 12 years ago

THREDDS uses an older version of NcWMS before it went through a major refactor. TDS 4.3 may support the newer NcWMS, but that has not been finalized.

For now, you will have to use the standalone WAR. Standalone should work just fine, the config error you are getting is related to the 'nearestTime' paramerer being in NcWMS's config file (usually in ~/.ncWMS/config.xml). Search for 'nearestTime' and delete all of the entries. 'nearestTime' support is now on the 'nearestTime' branch.

jllodra commented 12 years ago

Thanks Kyle, worked like a charm