RE: [mapserver-users] Mapserver as a WMS Client - problems working with a 'remote' Tilecache service

2011-05-10 Thread Andrew Cowie
Hi Jukka,

Many thanks for the suggestion however we've decided to take another route - 
which basically entails publishing a OGC standards compliant Mapserver WMS 
alongside a WMTS enabled Tilecache service.

Cheers

Andrew

-Original Message-
From: Rahkonen Jukka [mailto:jukka.rahko...@mmmtike.fi]
Sent: Friday, 6 May 2011 4:10 p.m.
To: Andrew Cowie; mapserver-users@lists.osgeo.org
Subject: Re: [mapserver-users] Mapserver as a WMS Client - problems working 
with a 'remote' Tilecache service

Hi,

I have never tried myself but I would guess that you need to prepare a xml file 
for defining a gdal-wms datasource and refer to that xml file in your mapfile. 
Read http://gdal.org/frmt_wms.html

-Jukka Rahkonen-

Andrew Cowie wrote:


 Hello List,

 We are currently setting up a cascading WMS using Mapserver as a client to 
 request maps from another Mapserver and from a Tilecache. We have read that 
 Mapserver can be configured to do this but we are running into problems when 
 using Mapserver as a client to Tlecache. Specifically, how do we publish 
 metadata in the MapSever Client capabilities document about the correct 
 resolutions / bounding box of a Tilecache service.

 More details...

 Here's a snippet of our 'top level' Mapserver mapfile, which will sit on our 
 public server:


   LAYER
  NAME 'lcr_basemap_cache_wgs84'
  TYPE RASTER
  CONNECTIONTYPE WMS
  CONNECTION http://ourserver/tilecache/wms-c/tilecache.py?;
  PROCESSING CLOSE_CONNECTION=DEFER

  METADATA
 wms_name  lcr_basemap_cache_wgs84
 wms_title Baselayer - Cached
 wms_server_version1.1.1
 wms_formatimage/png
 wms_srs   EPSG:4326
 wms_extent165 -48 179.5 -33
 wms_abstract  Cached via Tilcache
  END
   END

This pulls a layer from our Tilecache (a snippet from our tilecache config 
file):

[lcr_basemap_cache_wgs84]
type=WMSLayer
layers=coastpoly,veg,urban_grp,contours,water,coast_feats,height_pnts,tracks,rail,all_roads,railway_station,text
srs=EPSG:4326
bbox=165,-48,179.5,-33
resolutions=0.025398253504337,0.012699126752168,0.006349563376084,0.003174781688042,0.001587390844021,0.000793695422011,0.000317478168804,0.000158739084402,0.79369542201,0.31747816880,0.15873908440,0.06349563376,0.03174781688
url=http://ourserver/cgi-bin/mapserv?map=/path/to/ourmapfile.maptransparent=true;
extent_type=loose
metaBuffer=10
metasize=6,6
metaTile=true

(As you can see, Tilecache is pointing to another Mapserver which generates the 
maps.)

We have had some success in connecting to the Tilecache via the Mapserver 
Client using an Openlayers client to view the 'top level' WMS layers ** BUT ** 
this only works because we configured Openlayers to use the correct resolutions 
/ bounding box etc. What we are really trying to achieve with this is a public 
WMS for which other people/clients can use, e.g. Openlayers / QGIS, by just 
reading the Capabilities document provided by the MapServer client.

So far, we have yet to find a way to advertise (via the capabilities document) 
these underlying Tilecache resolutions as metadata in the cascading level 
Mapserver. Is this possible?

If it is not possible, does anybody have recommendations as to how to go about 
this in a standards compliant way?

Many thanks,

Andy



Please consider the environment before printing this email
Warning: This electronic message together with any attachments is confidential. 
If you receive it in error: (i) you must not read, use, disclose, copy or 
retain it; (ii) please contact the sender immediately by reply email and then 
delete the emails.
The views expressed in this email may not be those of Landcare Research New 
Zealand Limited. http://www.landcareresearch.co.nz


Please consider the environment before printing this email
Warning:  This electronic message together with any attachments is 
confidential. If you receive it in error: (i) you must not read, use, disclose, 
copy or retain it; (ii) please contact the sender immediately by reply email 
and then delete the emails.
The views expressed in this email may not be those of Landcare Research New 
Zealand Limited. http://www.landcareresearch.co.nz
___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Mapserver as a WMS Client - problems working with a 'remote' Tilecache service

2011-05-05 Thread Rahkonen Jukka
Hi,

I have never tried myself but I would guess that you need to prepare a xml file 
for defining a gdal-wms datasource and refer to that xml file in your mapfile. 
Read http://gdal.org/frmt_wms.html

-Jukka Rahkonen-

Andrew Cowie wrote:

 
 Hello List,

 We are currently setting up a cascading WMS using Mapserver as a client to 
 request maps from another Mapserver and from a Tilecache. We have read that 
 Mapserver can be configured to do this but we are running into problems when 
 using Mapserver as a client to Tlecache. Specifically, how do we publish 
 metadata in the MapSever Client capabilities document about the correct 
 resolutions / bounding box of a Tilecache service.

 More details...

 Here's a snippet of our 'top level' Mapserver mapfile, which will sit on our 
 public server:


   LAYER
  NAME 'lcr_basemap_cache_wgs84'
  TYPE RASTER
  CONNECTIONTYPE WMS
  CONNECTION http://ourserver/tilecache/wms-c/tilecache.py?;
  PROCESSING CLOSE_CONNECTION=DEFER

  METADATA
 wms_name  lcr_basemap_cache_wgs84
 wms_title Baselayer - Cached
 wms_server_version1.1.1
 wms_formatimage/png
 wms_srs   EPSG:4326
 wms_extent165 -48 179.5 -33
 wms_abstract  Cached via Tilcache
  END
   END

This pulls a layer from our Tilecache (a snippet from our tilecache config 
file):

[lcr_basemap_cache_wgs84]
type=WMSLayer
layers=coastpoly,veg,urban_grp,contours,water,coast_feats,height_pnts,tracks,rail,all_roads,railway_station,text
srs=EPSG:4326
bbox=165,-48,179.5,-33
resolutions=0.025398253504337,0.012699126752168,0.006349563376084,0.003174781688042,0.001587390844021,0.000793695422011,0.000317478168804,0.000158739084402,0.79369542201,0.31747816880,0.15873908440,0.06349563376,0.03174781688
url=http://ourserver/cgi-bin/mapserv?map=/path/to/ourmapfile.maptransparent=true;
extent_type=loose
metaBuffer=10
metasize=6,6
metaTile=true

(As you can see, Tilecache is pointing to another Mapserver which generates the 
maps.)

We have had some success in connecting to the Tilecache via the Mapserver 
Client using an Openlayers client to view the 'top level' WMS layers ** BUT ** 
this only works because we configured Openlayers to use the correct resolutions 
/ bounding box etc. What we are really trying to achieve with this is a public 
WMS for which other people/clients can use, e.g. Openlayers / QGIS, by just 
reading the Capabilities document provided by the MapServer client.

So far, we have yet to find a way to advertise (via the capabilities document) 
these underlying Tilecache resolutions as metadata in the cascading level 
Mapserver. Is this possible?

If it is not possible, does anybody have recommendations as to how to go about 
this in a standards compliant way?

Many thanks,

Andy



Please consider the environment before printing this email
Warning: This electronic message together with any attachments is confidential. 
If you receive it in error: (i) you must not read, use, disclose, copy or 
retain it; (ii) please contact the sender immediately by reply email and then 
delete the emails.
The views expressed in this email may not be those of Landcare Research New 
Zealand Limited. http://www.landcareresearch.co.nz

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users