Hi all!
I've been checking the nectdfsubset for a couple of grids with
2-dimensional coordinate axis values and everything seems to work fine
but the latitudes and longitudes in the responses are wrong.
I first sent an opendap request to the server to get the lat and the
lon for a grid point:
http://mandeo.meteogalicia.es/thredds/dodsC/modelos/SWAN/artabro/20101110/artabro_20101110.nc.ascii?lon[39][62],lat[39][62],hs[0][39][62]
then with the lat, lon values from the opendap response in a
netcdfsubset request I got the same values for the variables but
different lat and lon:
http://mandeo.meteogalicia.es/thredds/ncss/grid/modelos/SWAN/artabro/20101110/artabro_20101110.nc?var=hs&latitude=43.47266&longitude=-8.487085&time_start=2010-11-10T12%3A00%3A00Z&time_end=2010-11-14T00%3A00%3A00Z&temporal=point&time=2010-11-10T12%3A00%3A00Z&vertCoord=&accept=xml&point=true
The problem, I think, is somehow in the netcdfsubset the order of the
indexes of the dimensions is changed because if I change the order of
the indexes in the opendap request I get the same lat and the lon in the
nectdfsubset response:
http://mandeo.meteogalicia.es/thredds/dodsC/modelos/SWAN/artabro/20101110/artabro_20101110.nc.ascii?lon[62][39],lat[62][39]
and if the point is outside of the square delimited by the smaller
dimension you get a 500 server error response and an
ArrayIndexOutOfBoundsException:
2010-11-11T19:57:03.248 +0100 [ 6187513][ 1043] ERROR -
thredds.server.ncSubset.GridServlet - GridServlet.processGridAsPoint
java.lang.ArrayIndexOutOfBoundsException
at ucar.ma2.Index2D.setDirect(Index2D.java:135)
at ucar.ma2.ArrayDouble$D2.get(ArrayDouble.java:295)
at
ucar.nc2.dataset.CoordinateAxis2D.getCoordValue(CoordinateAxis2D.java:76)
at ucar.nc2.dt.grid.GridCoordSys.getLatLon(GridCoordSys.java:1170)
at
ucar.nc2.dt.grid.GridAsPointDataset.readData(GridAsPointDataset.java:100)
at
thredds.server.ncSubset.GridPointWriter.write(GridPointWriter.java:255)
at
thredds.server.ncSubset.GridServlet.processGridAsPoint(GridServlet.java:271)
at thredds.server.ncSubset.GridServlet.doGet(GridServlet.java:183)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at
thredds.servlet.filter.RequestQueryFilter.doFilter(RequestQueryFilter.java:121)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at
thredds.servlet.filter.RequestPathFilter.doFilter(RequestPathFilter.java:105)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190)
at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:283)
at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:767)
at
org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:697)
at
org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:889)
at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690)
at java.lang.Thread.run(Thread.java:619)
I'm working with the 4.2.20101001.2254 - 20101001.2254 version.
Cheers!!