[MapProxy] limiting image width and height in WMS requests?
Christian Willmes
c.willmes at uni-koeln.de
Wed Mar 16 09:38:03 EDT 2011
Hello,
I'm now trying to cache an ArcGIS Server based WMS, problem is that
MapProxy requests to large images (in the given example width=2478 and
height=1184) from the server, so that the AGS wont deliver them.
See the example console log message:
127.0.0.1 - - [16/Mar/2011:14:33:09 +0200] "GET
/service?LAYERS=SFB806Basemap&FORMAT=image%2Fjpeg&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&SRS=EPSG%3A4326&BBOX=-1.99951171875,49.28466796875,11.18408203125,58.07373046875&WIDTH=600&HEIGHT=400
HTTP/1.1" 200 9511
"http://localhost:5050/demo/?wms_layer=SFB806Basemap&format=image%2Fjpeg" "Mozilla/5.0
(X11; Linux x86_64; rv:2.0b13pre) Gecko/20110224 Firefox/4.0b13pre"
2011-03-16 14:33:09,784 - INFO - 18285:mapproxy.client.http.http:_log -
134.95.150.250:8399 - - [16/Mar/2011:14:33:09 ] "GET
/arcgis/services/online/mapserver/wmsserver?styles=&format=image%2Fpng&height=1184&bbox=54.7753458594,-24.2578125,67.2040323434,1.7578125&layers=0,1,2,3,4,5,6,7,8,9,10,11&crs=EPSG%3A4326&service=WMS&request=GetMap&width=2478&version=1.3.0
HTTP/1.1" 200 436 "-" ""
2011-03-16 14:33:09,784 - WARNING -
18285:mapproxy.client.wms:_check_resp - expected image response, got:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<ServiceExceptionReport version="1.3.0"
xmlns="http://www.opengis.net/ogc"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.opengis.net/ogc
http://schemas.opengis.net/wms/1.3.0/exceptions_1_3_0.xsd">
<ServiceException code="InvalidFormat">
Parameter 'width' contains unacceptable value.
</ServiceException>
</ServiceExceptionReport>
Here are my relevant parts of the mapproxy.yaml:
layers:
AGSBasemap:
title: AGS Basemap
sources: [AGSBasemapCache]
caches:
AGSBasemapCache:
sources: [AGSBASE]
sources:
AGSBASE:
type: wms
wms_opts:
version: 1.3.0
featureinfo: true
legendgraphic: true
supported_srs: ['EPSG:4326']
req:
url:
http://134.95.150.250:8399/arcgis/services/online/mapserver/wmsserver?
layers: 0,1,2,3,4,5,6,7,8,9,10,11
Is there a possibility to limit the width and height of an MapProxy WMS
request to some defined values? Or can I configure something else on the
MapProxy side to avoid this behavior?
Thanks and regards,
Christian
--
Christian Willmes
AG GIS & Fernerkundung | GIS & RS Group
Geographisches Institut | Institute of Geography
Universität zu Köln | University of Cologne
Tel.: +49 (0)221 470 6234
Fax.: +49 (0)221 470 2280
http://www.geographie.uni-koeln.de/gis
http://www.sfb806.de
More information about the MapProxy
mailing list