Expire tiles and update new after Postgres DB update using mapcache

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Expire tiles and update new after Postgres DB update using mapcache

parsis presswala
I have developed the map using MapServer and pre-generated tile using mapcache. Now I have an idea to update the database every day. As changes apply in the database only those parts should be re-render and new tile should be generated. As changes are very small and rendering all ties from start is difficult to process.

I got expiry list of tiles by following osm2pgsql:

osm2pgsql --append --slim --cache 1000 --multi-geometry /home/parsis/diff_file_minute.xml --number-processes 2 --hstore -d testdemo -r xml -e6-11 -o /home/parsis/expire.list

Got list something like this:

 - 11/329/713
 - 8/40/91
 - 10/164/357
 - 7/29/47

I find another approach using render_expired, but don't know how to use it with mapcache.

How is it possible using mapcache_seed?


_______________________________________________
mapserver-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/mapserver-dev
Reply | Threaded
Open this post in threaded view
|

Re: Expire tiles and update new after Postgres DB update using mapcache

Seth G-2
Hi,

If you know the list of tiles that have expired, can't you script deleting these, and then regenerate the cache?
mapcache_seed should skip generating any existing tiles. I'm unaware of any inbuilt way of doing this.
There is a RFC at https://mapserver.org/development/rfc/ms-rfc-122.html that may be of interest/relevance to you in the future.

Seth



--
web:http://geographika.co.uk
twitter: @geographika


On Sat, Jul 27, 2019, at 6:52 AM, parsis presswala wrote:
I have developed the map using MapServer and pre-generated tile using mapcache. Now I have an idea to update the database every day. As changes apply in the database only those parts should be re-render and new tile should be generated. As changes are very small and rendering all ties from start is difficult to process.

I got expiry list of tiles by following osm2pgsql:

osm2pgsql --append --slim --cache 1000 --multi-geometry /home/parsis/diff_file_minute.xml --number-processes 2 --hstore -d testdemo -r xml -e6-11 -o /home/parsis/expire.list

Got list something like this:

 - 11/329/713
 - 8/40/91
 - 10/164/357
 - 7/29/47

I find another approach using render_expired, but don't know how to use it with mapcache.

How is it possible using mapcache_seed?

_______________________________________________
mapserver-dev mailing list
https://lists.osgeo.org/mailman/listinfo/mapserver-dev


_______________________________________________
mapserver-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/mapserver-dev