Reading-eScience-Centre / edal-java

Environmental Data Abstraction Layer libraries
Other
39 stars 30 forks source link

dynamic service not working with latest ncWMS2.war #31

Closed cehbrecht closed 8 years ago

cehbrecht commented 8 years ago

Hi *,

i'm using ncWMS2.war in tomcat7 and want to use the "dynamic service" configuration. But when i've configured the dynamic service (like in the example) my getcapabilities request always fails rendering the xml document:

XML Parsing Error: no element found
Location: http://localhost:8080/ncWMS2/wms?SERVICE=WMS&REQUEST=GetCapabilities&  VERSION=1.3.0&DATASET=local/mymodel/may_2014.nc
Line Number 87, Column 24:                <Title>
-----------------------^

The error message in the log says:

Caused by: java.lang.NullPointerException
    at uk.ac.rdg.resc.edal.ncwms.NcwmsCatalogue.getDatasetTitle(NcwmsCatalogue.java:260)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:497)
    at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:395)
    at org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:384)
    at org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:173)

When i configure the same netcdf file as "Dataset" then it works.

Can you help?

Cheers, Carsten

guygriffiths commented 8 years ago

Looks like a bug - I'm currently at a meeting abroad, but I'll be back Friday morning. I would expect that I'll be able to fix it and create a bugfix release by the end of Friday.

guygriffiths commented 8 years ago

Got round to this a little quicker than expected. I replicated the bug and fixed it in the latest release

cehbrecht commented 8 years ago

Thanks, it works :)