Update Mapnik XML file and render tiles based on user parameters

31 views
Skip to first unread message

Cody Cummings

unread,
Oct 17, 2017, 3:22:17 PM10/17/17
to mapnik

I am attempting to allow users to view a map and use UI components, such as checkboxes, to toggle certain layers of data on or off. Each time a user toggles a layer on, it should send a request to my tile server with the layers that should be visible (LayerX status="on", LayerY status="on").


The default for all of my layers in the Mapnik XML style file is status="off". Is there currently a method of passing these parameters to the renderd service and dynamically changing the XML file before rendering the tiles? Is there currently a way of setting these values to be variable? such as status="[layer_1_status]"?


Since each request has the possibility to generate a new version of a tile, I would not like to cache each request. How can I turn off mod_tile's caching abilities to prevent tiles with the wrong data being returned the the client?


From what I have noticed, after every change to the XML file, renderd is required to be restarted. Is it possible to not restart renderd, but modify the XML file to display different layers?

Reply all
Reply to author
Forward
0 new messages