[mapserver-users] How retrieve the maxsize information with anhttprequest

Rahkonen Jukka Jukka.Rahkonen at mmmtike.fi
Wed Jan 30 03:02:12 PST 2013


I forgot to think about these lines in the original question by Andrea Peri:

"But to use it efficiently is necessary to know the
maxsize value applied in the mapfile of the wms server."

I do not quite agree.  We support maxsize=10000 mainly for users who are downloading images in native resolution through WCS.  However, it is not most efficient to download such big images. Better total throughput is achieved by downloading several smaller images, for example 2000x2000 pixel sized ones.   I would say that it would be enough for a tiling client to check the multiplies of 256 the maximum being 1280x1280. 

- Does server support 1280x1280 pixels? If yes, stop, if no:
- Does server support 1280x1024 pixels? If yes, stop, if no:
- Does server support 1024x1024 pixels? If yes, stop, if no:
- Does server support 1024x768 pixels? If yes, stop, if no:-
- Does server support 768x768  pixels? If yes, stop, if no, call the WMS admin and ask kindly to make it support.

-Jukka Rahkonen-

Rahkonen Jukka wrote:
 
> Hi,
> 
> I am a WMS server admin myself and I would not be worried about such use.
> They are just GetMaps and 20 or 100 GetMaps more in not an attack for my
> mind.  Think about any OpenLayers application sending tiled GetMaps for a
> WMS server.  They typically send more than 50 requests per every pan or
> zoom.  Naturally when searching for the maximum image size there would be
> a few rather big WIDTHs and HEIGTHs but it would be enough to do the
> scanning once per session or even better, save the values on your computer
> for future needs.  If the result is that WMS client caches some data it would
> mean less new GetMaps for our server later and that would be fine.
> 
> -Jukka Rahkonen-
> 
> Eichner, Andreas wrote:
> 
> 
> > Although this would work you definitely will loose some friends out
> > there if you go and set there server under attack :( Lets say you
> > start with 400px and the server sets a limit of 4096px then you will
> > request 400px, 800px, 1600px, 3200px 6400px, 4800px, 4000px, 4400px,
> > 4200px, 4100px, 4050px, 4075px... to get an accuracy of <32px. And in
> > general limits on width and height are indepenent of each other and
> > should be discovered separatly. Now consider that on a server that's
> > already under load. You can go with it but you won't be a nice guy
> anymore...
> >
> > > How about making an utility that captures the layer bounds from
> > > GetCapabilities, takes the centre point of the bounds, checks the
> > > min/max scale limits from the GetCapabilities and then calculates a
> > > reasonable BBOX and makes a GetMap query with WIDTH=400  and
> > > HEIGTH=400.  By increasing the outputsize incrementally the server
> > > sooner or later sends back something else than a valid image and
> > > that was it.
> > >
> > > -Jukka Rahkonen-
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users


More information about the mapserver-users mailing list