go-spatial / tegola

Tegola is a Mapbox Vector Tile server written in Go
http://tegola.io/
MIT License
1.3k stars 197 forks source link

Offline tiles generation without postgis step #602

Open ingenieroariel opened 5 years ago

ingenieroariel commented 5 years ago

A friend recently stopped using tegola and switched to Tilemaker: https://github.com/systemed/tilemaker his use case was generating offline tiles to put on a mobile app (react + mapbox).

I had initially set up Tegola for him and he developed the prototype, but when it was time to put in production he could not figure out how to get the cache from tegola to his app and tried Tilemaker, turns out it produced exactly the create and forget tiles he was expecting, starting from an osm.pbf and outputting mbtiles or a folder with tiles.

To satisfy that use case we would need something like imposm + tegola directly to a folder we can serve with nginx (skipping postgis if possible).

pnorman commented 5 years ago

A vector tile set normally includes data from sources that imposm can't process (e.g. natural earth). Queries are also how the layers are defined, and those queries are evaluated by postgres.

ingenieroariel commented 5 years ago

Could naturalearth be processed with just the gdal/ogr driver? I believe imposm bundles ogr.

-a

On Tue, Apr 30, 2019 at 12:31 PM Paul Norman notifications@github.com wrote:

A vector tile set normally includes data from sources that imposm can't process (e.g. natural earth). Queries are also how the layers are defined, and those queries are evaluated by postgres.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/go-spatial/tegola/issues/602#issuecomment-488042966, or mute the thread https://github.com/notifications/unsubscribe-auth/AAANNV7AAC3TFVKTH4CGY43PTB66TANCNFSM4HJORWOQ .

ARolek commented 5 years ago

@ingenieroariel tegola can write to S3 or the file system so you could pre-generate the tileset and then serve it directly. The tiles are gzip encoded so I'm wondering if that's potentially where the issue lies. If nginx was not setting the Content-Encoded header correctly then the client might not know to decompress the tile prior to rendering it.