3

I have GWC layer on my GeoServer. Now I want to print this layer using GeoServer print module but don't know how to do this.

When I try WMS layer all works fine. But how to print the GWC layer?

MORE INFO

In client side I have a GXP and try to print using gxp_print plugin. My problem is that I can't set URL to the GWC layer.

I read this and this: so I try this URL:

layer.setUrl("/geoserver/gwc/service/wms?BBOX=7637927.0361051%2C6845332.4516735%2C7750900.9638949%2C6971453.5483265&HEIGHT=256&WIDTH=256&TRANSPARENT=true&map_resolution=305.74811309814453&VERSION=1.1.1&FORMAT=image%2Fpng&TILED=true&SERVICE=WMS&format_options=dpi%3A100&LAYERS=gisurfo:atd&REQUEST=GetMap&STYLES=&SRS=EPSG%3A900913&");

But GeoServer returns me error:

400: Requested horizontal resolution: 441.30440542890574 , best match: 
305.74811309814453 exceeds 10% threshold. Perhaps the client is configured with an 
incorrect set of scales (resolutions), or the DPI setting is off compared to the one in GWC ?

This same like in links above. So how to print GWC?

UPDATE

Good news. I changed scales in my config.yaml file to scales that I get from the GWC layer (but I get only left part of each scale). Now I try to print GWC layer but it not printing. In GeoServer log I found Bad Request:

java.io.IOException: Error (status=400) while reading the image from 
http://geourfo.ru:9091/geoserver/gwc/service/wms?BBOX=6866019.0%2C7636631.0%2C6950767.0%2C7752196.5    &HEIGHT=625&WIDTH=458&VERSION=1.1.1&FORMAT=image%2Fpng&SERVICE=WMS&
format_options=dpi%3A75&LAYERS=gisurfo%3Aatd&REQUEST=GetMap&STYLES=&SRS=EPSG%3A900913
: Bad Request

After I change width and height to 256/256 and get my tile!

So question: why iprint plugin take tiles with HEIGHT=625 and WIDTH=458 but not with 256x256?

1
  • Any solution so far? I´m going throught the same problem at the moment Apr 30, 2013 at 12:00

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.