[mapserver-users] Getcapabilities extremely slow in version 6.4.1

James Klassen klassen.js at gmail.com
Fri Mar 6 07:55:16 PST 2015


Unofficial benchmark: 255 layers in 58 nested groups (using
wms_layer_group) takes less than 200ms on Linux Kernel 3.5.0, Intel(R)
Xeon(R) CPU E5-2630 @ 2.30GHz.

(It takes the terminal longer to print the 234 kB response XML than it
takes MapServer in CGI mode to return the result.)

All layers in wms.map are of the form:

  LAYER
    NAME 'L119_all'

    STATUS ON
    TYPE RASTER

    CONNECTIONTYPE WMS
    CONNECTION "http://gis/datasets/ADDRESS/ADDRESS_RANGE/address_range.map
?"

    PROJECTION
      "init=epsg:26915"
    END

    METADATA
      # WMS client connection options (input)
      "wms_name" "all"
      "wms_srs" "EPSG:26915"
      "wms_server_version" "1.1.1"
      "wms_format" "image/png"

      # WMS Server options (output)
      "wms_enable_request" "GetCapabilities GetMap GetFeatureInfo
GetLegendGraphic"
      "wms_title" "Address Ranges"
      "wms_layer_group" "/Address"
      #"wms_opaque" "0"
      "wms_formatlist" "image/png, image/jpeg"
      "wms_extent" "477594.70 4924010.29 497206.99 4941936.31"
      "gml_include_items" "all"
     END

     TEMPLATE "dummy"
     PROCESSING "RESAMPLE=AVERAGE"
  END


<!-- MapServer version 6.4.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=KML
SUPPORTS=PROJ SUPPORTS=GD SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=CAIRO
SUPPORTS=SVG_SYMBOLS SUPPORTS=RSVG SUPPORTS=ICONV SUPPORTS=FRIBIDI
SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER
SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER
SUPPORTS=THREADS SUPPORTS=GEOS INPUT=JPEG INPUT=POSTGIS INPUT=ORACLESPATIAL
INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE -->

time curl "
http://gis/datasets/wms.map?SERVICE=WMS&VERSION=1.3.0&REQUEST=GetCapabilities"
| grep 'queryable="1"' | wc
    255    1020   13728

real    0m0.151s
user    0m0.000s
sys    0m0.008s


On Thu, Mar 5, 2015 at 3:58 PM, Jim Klassen <klassen.js at gmail.com> wrote:

>  I work with a mapfile designed to be a WMS proxy to organize all our WMS
> sources (typically other mapfiles) into one point of access.  It has many
> layers makes extensive use of groups.  In general testing with curl and use
> with QGIS, I have not noticed the GetCapabilites (or any other aspect of
> the configuration) to be slow.  I am away from the machine at the moment,
> but will run benchmarks tomorrow.
>
> The upstream sources and the proxy mapfile run under MapServer 6.4.1 (with
> some minimal patching).
>
>
> On 03/05/2015 12:33 PM, thomas bonfort wrote:
>
> IIRC, this happened when we introduced advanced layer groupings along with
> inspire support in 6.2, and has to do with multiple passes through layers
> to determine which ones to activate or not. I'd suspect the cost is
> proportional to nlayers² which is why it comes up for folks with many
> layers in their mapfiles.
>
> Thomas.
> On Mar 5, 2015 7:26 PM, "Lime, Steve D (MNIT)" <Steve.Lime at state.mn.us> <Steve.Lime at state.mn.us>
> wrote:
>
>
>  This is something I’d really like to see fixed. Any chance a test mapfile
> could be developed and attached to a new ticket on github? Ideally I'd
> start against 7.0 and then back-port if possible.
>
> Steve
>
> -----Original Message-----
> From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Rahkonen Jukka (MML)
> Sent: Wednesday, March 04, 2015 2:34 AM
> To: aabhayas; mapserver-users at lists.osgeo.org
> Subject: Re: [mapserver-users] Getcapabilities extremely slow in version
> 6.4.1
>
> Hi,
>
> I have been wondering also why GetCapabilities response is so slow for us
> nowadays and I have indeed added lots of groups to some services.
> +1 from me for having a look at this issue.
>
> We just installed 7.0-beta on our test server and GetCapabilities comes
> slowly from that too. There are about 40 layers in the test service and
> response time is about 8 seconds.
>
> Sometimes I have been wondering if GetCapabilities could be cached and
> controlled by some new CONFIG key. Cached GetCapabilities could be set to
> be refreshed for example once per week/day/hour if there is a need to react
> on changes in the data, and each time after the mapfile has been edited and
> saved with a new timestamp.
>
> -Jukka Rahkonen-
>
> aabhayas wrote:
>
>
>  Hi
>
>   Following up on my previous post we still want to use “OWS_LAYER_GROUP”
>
>  in our map files. We have large number of layers in our map file ( nearly
> 800).
>
>
>  Currently we are in the process of migrating our MapServer 5.4.2
>
>  environment in to MapServer 6.4.1.
>
>
>  In MapServer 6.4.1 GetCapabilities request takes more than 1 minute
>
>  compared
> 5 second in version 5.4.2. This makes the new environment unusable by our
> clients.
>
>
>  Is there a possibility where someone in the MapServer development team
>
>  looks in to this and fix this issue.
>
>
>  Thanks
>
>
>
>
> --
> View this message in context:http://osgeo-org.1560.x6.nabble.com/Getcapabilities-extremely-slow-in-version-6-4-1-tp5189325p5191328.html
> Sent from the Mapserver - User mailing list archive at Nabble.com.
> _______________________________________________
> mapserver-users mailing listmapserver-users at lists.osgeo.orghttp://lists.osgeo.org/mailman/listinfo/mapserver-users
> _______________________________________________
> mapserver-users mailing listmapserver-users at lists.osgeo.orghttp://lists.osgeo.org/mailman/listinfo/mapserver-users
> _______________________________________________
> mapserver-users mailing listmapserver-users at lists.osgeo.orghttp://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
>
> _______________________________________________
> mapserver-users mailing listmapserver-users at lists.osgeo.orghttp://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20150306/10277be3/attachment.html>


More information about the mapserver-users mailing list