1

Is there any documentation for using Kartotherian Server with a vanilla/non OSM PostGIS database? The Kartotherian core documentation doesn't cover database connections or definitions of different parameters. Tilelive isn't too helpful either.

1

You need to install Mapbox Studio Classic, and create a new data source (tm2source) - write SQL queries in the studio - to pull that data into vector form, similar to how we do it in WMF tm2source Afterwards, create a new style (tm2) based on that data source, make sure the studio shows what you need, and point Kartotherian to both of these dirs - source1 (bridge) to tm2source, and source2 (vector) to tm2. Your source config would be similar to the sample. Mapbox studio classic uses the same components as Kartotherian, so if it works in one, it will work in the other.

  • I'm managing the data in PostGIS and the data can have upwards of a million records so I want to avoid shpfile conversion. Ideally I'd like to generate the XML files directly without the use of studio...Correct me if I'm wrong but I should be able to use the Mapnik documentation to figure out how to define the XML right? – Maju Aug 5 '16 at 19:00
  • ah, sorry, I thought you meant you didn't want to use postgis at all :) Updated my answer. – Yurik Aug 5 '16 at 20:34
  • Thanks for the tip, but my files seem to be too big for MapBox Studio. For large files Studio gets rid of half the features and turns polygons into triangles. Any advice? Should I be using something like Tippecanoe for large files? – Maju Aug 8 '16 at 20:42
  • Files? I thought all your data is in SQL database? If you mean that the resultset is too large for each tile, you might need to use filtering and optimization, such as bbox filter, polygon simplification, etc. Mapbox studio should not simplify geoahapes for you -- your sql would usually do that. – Yurik Aug 9 '16 at 21:52
  • 1
    It seems you need to optimize your SQL query - use way && !bbox! where clause, as well as something like z(!scale_denominator!) >= 14 for zoom level filtering. For example, see github.com/kartotherian/osm-bright.tm2source/blob/master/… – Yurik Aug 14 '16 at 18:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.