I'm trying to undestand what is happening with GeoServer/GeoWebCache integration.

Anyone has experienced GeoWebCache spending so much more time than WMS request to generate tile ?

In a simple test in my environment using embedded GWC in GeoServer, I also tested GWC in standalone mode, when I call a tile in GeoServer direct using WMS service the tile is returned in 18s, this same tile passing by GWC is spending more than 1min and return an error "400: ImageIO.read(InputStream) returned null. Unable to read image" because my WMS limit is 1min. In this specific case the tile has average of30.000 features. In other cases with less features GWC works well and return tiles without problems.

I thought that GWC just call GeoServer WMS service save the image returned and return the same to the client, so in this case if GeoServer spent 17s to return image to GWC, why the GWC can´t process this image in less than a minute ?

Something strange is that calling WMS Service directly the image is returned in 17s but using GWC the same request exceeds the WMS time limit that is 1min in this case and a error is throw in GeoServer log.

I'm using GeoServer 2.9.2 with GWC 1.9.1 and has tested GWC 1.9.2 standalone with the same results.

Anyone have any idea about it ?

  • 1
    GWC with not preseeded cache is asking a bigger metatile from WMS, for example 3x3 tiles. 9x17 seconds=152 seconds so timeout is not a surprise. Your service is exceptionally slow. – user30184 Nov 30 '16 at 22:09
  • Well remembered!!! Thank you so much for remember me of metatiles, I'm using Informix database that is not so good fetching geometries. This time of 17s is to fetch about 39.000 linestrings from database and apply a long SLD, with default metatiles this can be increased to approximatly 351.000 features. I'll try adjust here to know more in detail the behaviour of GWC and I'll return with results. Thank you. – Carlos Lacerda Dec 1 '16 at 0:56
  • After configure 1x1 for metatile the time now is very close to WMS Service as expected, the old configuration was 4x4. Now I need to optimize the service because the response times are too slow. Thank you – Carlos Lacerda Dec 1 '16 at 15:56
  • Without metatiles you will loose more labels if you have such. It is compromising. – user30184 Dec 1 '16 at 15:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.