Integrated WMS caching without the tiled parameter might result in deep recursion
Description
When the meta-tile request happens to create another valid tiled request, and the “tiled=true” parameter has been made non mandatory, then it’s possible to make GWC recurse over itself.
In order to reproduce:
Configure GWC with WMS direct integration, and make the TILED parameter non required
Set up a tile cache for topp:states, with meta-tiling factors 1 and 1 (the meta-tile is the tile)
would take a few seconds (rather than a few tens of milliseconds)
the logs report a long stack trace showing recursion (attached)
Environment
None
Attachments
1
Activity
Andrea Aime
September 10, 2022 at 10:50 AM
@Jody Garnett Neither, just a silly bug
Jody Garnett
September 9, 2022 at 5:13 PM
Is this behaviour that should change or documentation that should be clarified?
Andrea Aime
July 21, 2022 at 1:49 PM
This also affects usage of vector tiles, as the meta-tiling factor is imposed to be 1x1 on them, regardless of the configuration, as the vector tiles producer cannot compute a meta-tile and then slice in sub-tiles anyways.
When the meta-tile request happens to create another valid tiled request, and the “tiled=true” parameter has been made non mandatory, then it’s possible to make GWC recurse over itself.
In order to reproduce:
Configure GWC with WMS direct integration, and make the TILED parameter non required
Set up a tile cache for topp:states, with meta-tiling factors 1 and 1 (the meta-tile is the tile)
Make a WMS request matching a tile, e.g:
http://localhost:8080/geoserver/topp/wms?service=WMS&version=1.1.0&request=GetMap&layers=topp%3Atileloop&bbox=-180,-90,0,90&width=256&height=256&srs=EPSG%3A4326&styles=&format=image/png
The tile will eventually be produced but:
would take a few seconds (rather than a few tens of milliseconds)
the logs report a long stack trace showing recursion (attached)