Hi Jody Thanks for reminding me about this issue. I was able to track it down. It has nothing to do with Geotools but with a wrong schema location in the GetCapabilities response:
xsi:schemaLocation="http://www.opengis.net/wms http://schemas.opengis.net/wms/1.3.0/capabilities_1_3_0.xsd http://www.opengis.net/sld http://schemas.opengis.net/sld/1.1.0/sld_capabilities.xsd http://www.qgis.org/wms http://172.21.5.48/ows/somap?SERVICE=WMS&REQUEST=GetSchemaExtension" Geotools cannot resolve 172.21.5.48 since it is an internal IP. It just runs in a timeout after 60 seconds. best regards Stefan On Mon, May 31, 2021 at 6:00 AM Jody Garnett <jody.garn...@gmail.com> wrote: > That is interesting Stefan, you are the first to report on this. The WMS > client does have some logic to look at parent layers, perhaps that is what > is making the layer group slow? > > If you look at Layer.java > <https://github.com/geotools/geotools/blob/main/modules/extension/wms/src/main/java/org/geotools/ows/wms/Layer.java> > there > are a number of caches being maintained to combine the bounds, srs list, > dimensions and so on from the parent with the current layer. > > Try using a debugger to confirm the cache is working correctly, or if it > is repeatedly calculating the bounds of the parent layer groups and root > layer. > -- > Jody Garnett > > > On Sun, 2 May 2021 at 12:44, Stefan Ziegler <stefan.ziegler...@gmail.com> > wrote: > >> Hi >> >> When using the WMSCapabilities class to retrieve the capabilities >> response I noticed that the request takes a long time for a specific >> service. This service reports 516 layers (getLayerList().size()) but has a >> lot of layer groups. Another service with approx 1200 layers (and no layer >> groups) responses very fast. >> >> Is it the layer groups that makes the request/response (the processing of >> the xml) slow? Any way to debug this? When using e.g. curl the response is >> fast. >> >> best regards >> Stefan >> _______________________________________________ >> GeoTools-GT2-Users mailing list >> GeoTools-GT2-Users@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users >> >
_______________________________________________ GeoTools-GT2-Users mailing list GeoTools-GT2-Users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users