If my rails port and tile server built on two different hosts, called s1 and s2. Now i make an edit at the openstreetmap database on s1, can i use the render_expired command on the s1 host to updata tiles on the s2 host? If it is feasible, how to set the config to make render_expired command renderd the specifiled host and database?

asked 30 Dec '16, 13:36

yuyy's gravatar image

yuyy
236222431
accept rate: 20%

edited 03 Jan '17, 02:42


You'd need to write some code to do that, I think. The usual mechanism (with a rendering server consuming diffs from OSM.org) is:

  1. You change some data on osm.org
  2. That change is written to a diff
  3. Your rendering server periodically runs "openstreetmap-tiles-update-expire"
  4. That consumes pending diffs, generates a list of changed tiles and calls render_expired

That process means that data that has changed on the rails port is used to update the rendering server database and the rendering server can choose to expire (or rerender) the affected tiles.

Given that the rails port and rendering server are separate databases anyway, and you'll need to do something to get changed data from one into the other (such as processing diffs) why not just use those diffs to drive rerendering? I'm sure it would be technically possible to link rerendering to editing instead, but it doesn't actually achieve anything different in the long run.

If it helps, I have variations on tile expiry scripts here and here that have a few more comments explaining tile expiry usage.

permanent link

answered 30 Dec '16, 16:34

SomeoneElse's gravatar image

SomeoneElse ♦
31.7k63324736
accept rate: 15%

Sorry, i didn't express well. The rails port and rendering server are separate databases, they also built on separate host, the rails port on the s1 host, and rendering server on the s2 host, can i use the render_expired command on the s1 host to updata tiles on the s2 host?

(31 Dec '16, 12:08) yuyy

Not easily - it communicates with the renderer via a socket. Easier to get the list of tiles from s1 to s2 and run render_expired on s2.

(03 Jan '17, 13:03) SomeoneElse ♦
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×76
×70
×6

question asked: 30 Dec '16, 13:36

question was seen: 944 times

last updated: 03 Jan '17, 13:03

powered by OSQA