[Tilecache] RESTful WMTS implementation

Jim Groffen jim.groffen at lisasoft.com
Tue Jun 2 22:27:02 EDT 2009


Hello again,

You are right Chris, I was originally going to post a response
to the time dimension question but as someone provided a solution
that didn't involve waiting for WMTS I thought that post was no
longer relevant. Still it seemed that timing was good so I fixed
up the email to be about WMTS alone - er, except for the subject
line - I missed that bit. Sorry about the confusion. WMTS is the
acronym of the OGC standard - Web Map Tiling Service. I thought
WMS-T was an earlier term for the same thing but I'm not sure.

Guillaume:
TileCache works well when used in conjunction with HTTP proxy
caches - given appropriate configuration of the headers. I can see
reasons to downstream HTTP cache from TileCache or direct to a
WMS service, but I couldn't say one always precludes the other as
a better option.

WMTS can handle multiple styles and dimensions for a layer,
effectively duplicating the layer per unique style and
dimension-value combination which can make for some massive
disk consumption if disk caching. While there are many situations
in which a time dimension is not suitable to tiling / disk caching,
some applications with a time dimension and many applications of
other dimensions (for instance elevation) will be appropriate.

A layer can support multiple TileMatrixSets as well. TileMatrixSets
are used to define what tiles are available, Similar to the
resolution list and layer bounds in TileCache. This allows for the
definition of multiple layers that use the same tile matrix set.

A capability I like here the portability. A fully seeded WMTS disk
cache with a preconfigured WMTS client provided on a disc or as a
packaged download will work out of the box. You could provide
various styles, dimensions and projections for a layer, and overlay
other layers that share a common TileMatrixSet. While not appropriate
for very large and varied sets of data, I can think lots of
applications of this.

Regards,

Jim Groffen.


-----Original Message-----
From: tilecache-bounces at openlayers.org [mailto:tilecache-bounces at openlayers.org] On Behalf Of Guillaume Sueur
Sent: Wednesday, 3 June 2009 4:16 AM
To: Brian.Walawender at noaa.gov
Cc: tilecache at openlayers.org
Subject: Re: [Tilecache] WMS-T support

This is actually very interesting, thanks to both of you for these clear
answers.

I have a 5 minutes data set (every 5 minutes, a postgresql database is
updated with forecasts for next 5, 10, 15, 20, 30, 40, 60 minutes)
related to roads.
I haven't decided yet to cache these images or not. MapServer
generation is fast enough to assume it can go live, and the use is
rather internal to the organisation. But I may give WMS-T a shot as it
sounds promising.

Best regards,

Guillaume

Brian Walawender a écrit :
> Guillaume,
>
> We are using the tilecache to serve radar data ( http://radar.srh.noaa.gov/
> ).  Typically a radar image is updated every five minutes.  We have about
> 130 radars across the US with each radar offering about 10 different
> products (layers).  On a busy day, we our static image pages will get nearly
> 100 million hits.  Typically those hits will be focused on the radars that
> have storms.  For the most part an individual radar layer cache would be in
> use for about an hour, so even though we are constantly rolling through the
> cache directories, I think we are taking a tremendous load off our WMS
> server with the tilecache.
>
> The WMS-T is much more attractive than our current method which is very I/O
> intensive because we are rotating the base images and (attempting) to rotate
> the cache directories as a new image arrives.
>
> bw
>
> -----Original Message-----
> From: tilecache-bounces at openlayers.org
> [mailto:tilecache-bounces at openlayers.org] On Behalf Of Christopher Schmidt
> Sent: Tuesday, June 02, 2009 6:33 AM
> To: Guillaume Sueur
> Cc: tilecache at openlayers.org
> Subject: Re: [Tilecache] WMS-T support
>
> On Tue, Jun 02, 2009 at 11:21:10AM +0200, Guillaume Sueur wrote:
>> Hi,
>>
>> I'm only thinking loud here, because the subject interests my own
>> projects. Do you think that a Tilecache approach is the best for dealing
>> with time data ? Doesn't this aim to build many cache dirs which will be
>> rarely used and maybe never again ?
>
> The Disk cache is not the only cache that TileCache has. memcached would
> be an ideal candidate for this type of data, allowing you to set up a
> host/number of hosts with memcached, and depend on memcache's LRU
> behavior to clean up your cache for you.
>
>> More widely, when the parametric set of the request can have many
>> different values, is it wise to build a cache for each requested ? IMHO
>> a standard proxy (squid or whatever) could be more appropriate and
>> easier to maintain on a disk size or time basis. Am I wrong ?
>
> Only if you're assuming that the cache isn't already cleaning up based
> on LRU rules, which isn't neccesarily true.
>
>> Best regards,
>>
>> Guillaume
>>
>>
>> Jim Groffen a écrit :
>>> Hello,
>>>
>>> I've finished the work on the WMTS implementation in
>>> TileCache, but I need to:
>>>
>>> - update it to the main trunk version
>>> - improve the docs and maybe add more doctests
>>> - incorporate any feedback to get it contributed
>>>
>>> The work was done for OWS-6 and is a RESTful implementation,
>>> I haven't implemented the KVP interface.
>>>
>>> A major difference is The way you define the coverage of
>>> your tiles, this needs some nice documentation to make it
>>> as easy as possible.
>>>
>>> There are only a couple of concerns I can see with my
>>> solution and its impact on TileCache. One of which is how
>>> I had to extend the config file reading. It's backwards
>>> compatible, but adds complication. In short the normal
>>> behavior of TileCache is to treat all sections as a layer
>>> definition except for an options section. My change added
>>> an option to the options section that allows you to list
>>> config sections that are to be treated as TileMatrixSets
>>> and not layers. This has no impact on existing config
>>> files but the changes are in Server.py and not small. I
>>> tried to have as few changes impact files besides the
>>> wmts.py layer and service files as possible.
>>>
>>> I'll hopefully have a patch prepared some-time next week,
>>> so I can get some feedback.
>>>
>>> Regards,
>>>
>>> Jim Groffen.
>>>
>>> -----Original Message-----
>>> From: tilecache-bounces at openlayers.org
> [mailto:tilecache-bounces at openlayers.org] On Behalf Of Christopher Schmidt
>>> Sent: Tuesday, 2 June 2009 6:51 AM
>>> To: Brian Walawender
>>> Cc: tilecache at openlayers.org
>>> Subject: Re: [Tilecache] WMS-T support
>>>
>>> On Mon, Jun 01, 2009 at 03:38:48PM -0500, Brian Walawender wrote:
>>>> Hello,
>>>>
>>>> Can I make WMS-T requests to tilecache?   My WMS requests look like:
>>>>
>>>> radar =  new OpenLayers.Layer.WMS( "TWX",
>>>>         "http://
>>>>
> 216.38.80.111/cgi-bin/mapserv?map=/usr/local/mapserver_config/TWX_time.map",
>>>>         {
>>>>                layers: 'TWX_N0R',
>>>>                transparent: true,
>>>>                time: '2009-06-01T15:55',
>>>>                format: 'image/png'
>>>>         }, {
>>>>                singleTile: true,
>>>>                isBaseLayer: false,
>>>>                opacity: 0.9
>>>>         }
>>>> );
>>>>
>>>> My tilecache requests would look like:
>>>>
>>>> tc_url = ['http://radarcache.srh.noaa.gov/tilecache/tilecache.py'];
>>>>
>>>> radar = new OpenLayers.Layer.WMS( "State Borders", tc_url,
>>>>         {
>>>>                layers: 'TWX_N0R',
>>>>                transparent: true,
>>>>                format: 'image/png'
>>>>        }, {
>>>>                singleTile: false,
>>>>                isBaseLayer: false,
>>>>                opacity: 1.0
>>>>        }
>>>> );
>>>>
>>>> Is time a recognized param for tilecache?
>>> No.
>>>
>>> I feel like fredj wrote a patch that would allow you to create different
>>> cache directories based on a specific parameter in the URL. However, I
>>> don't remember ever integrating it, so there's a good chance that it got
>>> lost in mailing list traffic. I would say that this would be the place
>>> to look -- either in the code or in the mailing list for such a thing.
>>> (Perhaps fredj can find it more easily, if he's listening.)
>>>
>>>
>>> Regards,
>>> --
>>> Christopher Schmidt
>>> MetaCarta
>>> _______________________________________________
>>> Tilecache mailing list
>>> Tilecache at openlayers.org
>>> http://openlayers.org/mailman/listinfo/tilecache
>>>
>>> The contents of this email are confidential and may be subject to legal
> or professional privilege and copyright. No representation is made that this
> email is free of viruses or other defects. If you have received this
> communication in error, you may not copy or distribute any part of it or
> otherwise disclose its contents to anyone. Please advise the sender of your
> incorrect receipt of this correspondence.
>>> _______________________________________________
>>> Tilecache mailing list
>>> Tilecache at openlayers.org
>>> http://openlayers.org/mailman/listinfo/tilecache
>>>
>>>
>> _______________________________________________
>> Tilecache mailing list
>> Tilecache at openlayers.org
>> http://openlayers.org/mailman/listinfo/tilecache
>
_______________________________________________
Tilecache mailing list
Tilecache at openlayers.org
http://openlayers.org/mailman/listinfo/tilecache

The contents of this email are confidential and may be subject to legal or professional privilege and copyright. No representation is made that this email is free of viruses or other defects. If you have received this communication in error, you may not copy or distribute any part of it or otherwise disclose its contents to anyone. Please advise the sender of your incorrect receipt of this correspondence.



More information about the Tilecache mailing list