Hi,
on the builds server we have intermittent test failures
for the GWCIntegrationTest that I cannot reproduce locally.
Looking at the logs I gathered two things:
- the test tries to make sure the integration when cascading
and caching a png request works, but it gets back a image/html
instead
- my local build, working, reports the following in the logs:
5-mag-2010 12.50.38 it.geosolutions.imageio.gdalframework.GDALUtilities loadGDAL
AVVERTENZA: Native library load failed.java.lang.UnsatisfiedLinkError: no gdaljni in java.library.path
05 mag 12:50:41 ERROR [config.XMLConfiguration] - Configuration file cannot be read or does not exist!
05 mag 12:50:41 ERROR [layer.TileLayerDispatcher] - Configuration /home/aaime/devel/git-gs/src/gwc/null/../resources contained no layers.
05 mag 12:50:41 ERROR [layer.TileLayerDispatcher] - Error reading service information from /home/aaime/devel/git-gs/src/gwc/null/../resources: Error parsing file /home/aaime/devel/git-gs/src/gwc/null/../resources/geowebcache.xml
However, the build server has this instead:
Running org.geoserver.gwc.GWCCatalogListenerTest
May 5, 2010 6:28:37 AM it.geosolutions.imageio.gdalframework.GDALUtilities loadGDAL
WARNING: Native library load failed.java.lang.UnsatisfiedLinkError: no gdaljni in java.library.path
05 May 06:28:39 ERROR [config.XMLConfiguration] - Configuration file cannot be read or does not exist!
05 May 06:28:39 ERROR [layer.TileLayerDispatcher] - Configuration /home/tomcat/.hudson/jobs/geoserver-trunk/workspace/geoserver/gwc/null/../resources contained no layers.
05 May 06:28:39 ERROR [layer.TileLayerDispatcher] - Error reading service information from /home/tomcat/.hudson/jobs/geoserver-trunk/workspace/geoserver/gwc/null/../resources: Error parsing file /home/tomcat/.hudson/jobs/geoserver-trunk/workspace/geoserver/gwc/null/../resources/geowebcache.xml
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 7.662 sec
Running org.geoserver.gwc.GWCIntegrationTest
java.lang.NullPointerException
at org.geowebcache.layer.TileLayerDispatcher.getTileLayer(TileLayerDispatcher.java:69)
at org.geowebcache.service.wmts.WMTSService.getTile(WMTSService.java:108)
at org.geowebcache.service.wmts.WMTSService.getConveyor(WMTSService.java:79)
at org.geowebcache.GeoWebCacheDispatcher.handleServiceRequest(GeoWebCacheDispatcher.java:333)
at org.geowebcache.GeoWebCacheDispatcher.handleRequestInternal(GeoWebCacheDispatcher.java:252)
at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:48)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:875)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:809)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:571)
at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:501)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.geoserver.test.GeoServerAbstractTestSupport.dispatch(GeoServerAbstractTestSupport.java:1089)
at org.geoserver.test.GeoServerAbstractTestSupport.dispatch(GeoServerAbstractTestSupport.java:1056)
at org.geoserver.test.GeoServerAbstractTestSupport.getAsServletResponse(GeoServerAbstractTestSupport.java:463)
at org.geoserver.gwc.GWCIntegrationTest.testPngIntegration(GWCIntegrationTest.java:12)
Rings any bell?
Cheers
Andrea
--
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.
Uh, which one of the very many builds ? 
Both 2.0.x and trunk have been pegged to 1.2.2 and not changed in 2 months (except for the KML superoverlays patch, which I dont think has anything to do with it). So it doesn't ring any bells unless those intermittent failues have been going on for that long. But there is a null in the resource path that I don't think should be there.
-Arne
ps. new email address
Andrea Aime wrote:
Hi,
on the builds server we have intermittent test failures
for the GWCIntegrationTest that I cannot reproduce locally.
Looking at the logs I gathered two things:
- the test tries to make sure the integration when cascading
and caching a png request works, but it gets back a image/html
instead
- my local build, working, reports the following in the logs:
5-mag-2010 12.50.38 it.geosolutions.imageio.gdalframework.GDALUtilities loadGDAL
AVVERTENZA: Native library load failed.java.lang.UnsatisfiedLinkError: no gdaljni in java.library.path
05 mag 12:50:41 ERROR [config.XMLConfiguration] - Configuration file cannot be read or does not exist!
05 mag 12:50:41 ERROR [layer.TileLayerDispatcher] - Configuration /home/aaime/devel/git-gs/src/gwc/null/../resources contained no layers.
05 mag 12:50:41 ERROR [layer.TileLayerDispatcher] - Error reading service information from /home/aaime/devel/git-gs/src/gwc/null/../resources: Error parsing file /home/aaime/devel/git-gs/src/gwc/null/../resources/geowebcache.xml
However, the build server has this instead:
Running org.geoserver.gwc.GWCCatalogListenerTest
May 5, 2010 6:28:37 AM it.geosolutions.imageio.gdalframework.GDALUtilities loadGDAL
WARNING: Native library load failed.java.lang.UnsatisfiedLinkError: no gdaljni in java.library.path
05 May 06:28:39 ERROR [config.XMLConfiguration] - Configuration file cannot be read or does not exist!
05 May 06:28:39 ERROR [layer.TileLayerDispatcher] - Configuration /home/tomcat/.hudson/jobs/geoserver-trunk/workspace/geoserver/gwc/null/../resources contained no layers.
05 May 06:28:39 ERROR [layer.TileLayerDispatcher] - Error reading service information from /home/tomcat/.hudson/jobs/geoserver-trunk/workspace/geoserver/gwc/null/../resources: Error parsing file /home/tomcat/.hudson/jobs/geoserver-trunk/workspace/geoserver/gwc/null/../resources/geowebcache.xml
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 7.662 sec
Running org.geoserver.gwc.GWCIntegrationTest
java.lang.NullPointerException
at org.geowebcache.layer.TileLayerDispatcher.getTileLayer(TileLayerDispatcher.java:69)
at org.geowebcache.service.wmts.WMTSService.getTile(WMTSService.java:108)
at org.geowebcache.service.wmts.WMTSService.getConveyor(WMTSService.java:79)
at org.geowebcache.GeoWebCacheDispatcher.handleServiceRequest(GeoWebCacheDispatcher.java:333)
at org.geowebcache.GeoWebCacheDispatcher.handleRequestInternal(GeoWebCacheDispatcher.java:252)
at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:48)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:875)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:809)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:571)
at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:501)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at org.geoserver.test.GeoServerAbstractTestSupport.dispatch(GeoServerAbstractTestSupport.java:1089)
at org.geoserver.test.GeoServerAbstractTestSupport.dispatch(GeoServerAbstractTestSupport.java:1056)
at org.geoserver.test.GeoServerAbstractTestSupport.getAsServletResponse(GeoServerAbstractTestSupport.java:463)
at org.geoserver.gwc.GWCIntegrationTest.testPngIntegration(GWCIntegrationTest.java:12)
Rings any bell?
Cheers
Andrea
Arne Kepp ha scritto:
Uh, which one of the very many builds ? 
Both 2.0.x and trunk have been pegged to 1.2.2 and not changed in 2 months (except for the KML superoverlays patch, which I dont think has anything to do with it). So it doesn't ring any bells unless those intermittent failues have been going on for that long.
They have been on and off for quite a bit of time but I'm not sure
if it's happening only on trunk or also on 2.0.x (for sure this
build failed on trunk).
But there is a null in the resource path that I don't think should be there.
Scratch scratch... maybe it's due to the mock test setup?
How is that path determined?
Cheers
Andrea
--
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.
Hi Gabriel, I think this is related to some interaction between GWC and the MockTest stuff that I don't understand well enough.
As stated below, the exception happens because TileLayerDispatcher doesnt have a table of available layers yet. What normally happens is that Spring creates the beans that represent configuration sources and hands them through the constructor to TileLayerDispatcher. The sources are not queried immediately, in case they live in the same container. Instead, a thread is launched that immediately acquires a lock and then waits for a specified number of seconds, all requests are blocked until this thread completes.
Normally this works fine, since the servlet shouldnt be accessible until Spring is done loading, but I guess the MockTest circumvents this and does the getLayer before before the thread acquires the lock.
I think the clean solution is to use an explicit lock object and acquire that during the construction of TileLayerDispatcher, then have the thread release it. But I don't have capacity to do a 1.2.2a release early this week, so I am thinking we should introduce a 10 second delay (apologies) in the GS test and hope that solves the issue for now, and then we remove that delay as soon as GS gets pegged to the next GWC release.
But that assumes that the mock stuff has no clever tricks to deal with these problems, any thoughts?
-Arne
Quoting Andrea Aime <aaime@anonymised.com>:
Arne Kepp ha scritto:
Uh, which one of the very many builds ? 
Both 2.0.x and trunk have been pegged to 1.2.2 and not changed in 2 months (except for the KML superoverlays patch, which I dont think has anything to do with it). So it doesn't ring any bells unless those intermittent failues have been going on for that long.
They have been on and off for quite a bit of time but I'm not sure
if it's happening only on trunk or also on 2.0.x (for sure this
build failed on trunk).
But there is a null in the resource path that I don't think should be there.
Scratch scratch... maybe it's due to the mock test setup?
How is that path determined?
Cheers
Andrea
--
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.