Blazing fast and lightweight PostGIS, MBtiles and PMtiles tile server, tile generation, and mbtiles tooling.
Add a top level config parameter -- the size of cache memory (in MB) to use for caching tiles and PMT directories, defaulting to 512, and 0 to disable. This also removes the pmtiles.dir_cache_size_mb
parameter (it will be ignored, but will give a warning)
cache_size_mb: 512
The new cache will contain all tiles as provided by the source. So if PostgreSQL returns a non-compressed tile, the cache will contain the uncompressed variant, and will be compressed for each response. This will be fixed in the later releases.
Note that fonts and sprites are not cached at this time, and are still a TODO.
Full Changelog: https://github.com/maplibre/martin/compare/v0.12.0...v0.13.0
Martin now supports cached local and HTTP PMTiles sources. Additionally, multiple PMTiles sources share a single web client instance, optimizing connection reuse in case multiple pmtiles reside on the same host. Implemented by @nyurik with great help from @kyleslugg who did the integration testing CI work, see https://github.com/maplibre/martin/pull/991, https://github.com/maplibre/martin/pull/1095, https://github.com/maplibre/martin/pull/1094
pmtiles:
# Memory (in MB) to use for caching PMTiles directories [default: 32, 0 to disable]]
dir_cache_size_mb: 100
paths:
# scan this whole dir, matching all *.pmtiles files
- /dir-path
# specific pmtiles file will be published as a pmt source (filename without extension)
- /path/to/pmt.pmtiles
# A web server with a PMTiles file that supports range requests
- https://example.org/path/tiles.pmtiles
sources:
# named source matching source name to a single file
pm-src1: /path/to/pmt.pmtiles
# A named source to a web server with a PMTiles file that supports range requests
pm-web2: https://example.org/path/tiles.pmtiles
:memo: We badly need someone to document how to setup Martin on AWS lambda, and/or similar setup on the other cloud providers. See https://github.com/maplibre/martin/issues/1102
martin-cp
and mbtiles
improvementsmartin-cp
will now update min/max zoom levels after copying to an mbtiles file, but only if the existing metadata min/max zooms do not include the tiles actually contained in the file by @nyurik in https://github.com/maplibre/martin/pull/1096
Martin has been refactored to allow modular reuse to be more of a library in your own Rust application. When used as a library, you can use the following features to limit which backends are compiled by @nyurik in https://github.com/maplibre/martin/pull/1097 and https://github.com/maplibre/martin/pull/1094
Full Changelog: https://github.com/maplibre/martin/compare/v0.11.6...v0.12.0
martin-cp
will now set format=pbf
instead of mvt
. This is what QGIS and possibly others expect, and this is what tools like tilelive generates.martin-cp
sets minzoom
and maxzoom
metadata values based on the zoom parametersmbtiles meta-update
command to refresh zoom levels based on the present tiles.Full Changelog: https://github.com/maplibre/martin/compare/v0.11.5...v0.11.6
mbtiles
and martin-cp
now require --on-duplicate
when adding to existing mbtiles files by @nyurik
in https://github.com/maplibre/martin/pull/1064
mbtiles copy --bbox ...
filter to copy tiles within a bbox only by @nyurik
in https://github.com/maplibre/martin/pull/1060
mbtiles copy --copy (all|tiles|metadata)
flag to limit what gets copied by @nyurik
in https://github.com/maplibre/martin/pull/1073
mbtiles
commands by @nyurik in https://github.com/maplibre/martin/pull/1063
MbtilesCopier
into CopyArgs
by @nyurik in https://github.com/maplibre/martin/pull/1072
Full Changelog: https://github.com/maplibre/martin/compare/v0.11.4...v0.11.5
mbtiles validate
by @nyurik in https://github.com/maplibre/martin/pull/1057
tiles
table/view, e.g. bad tile index or incorrect data type.Full Changelog: https://github.com/maplibre/martin/compare/v0.11.3...v0.11.4
martin-cp
can also set metadata values after copying by @nyurik in https://github.com/maplibre/martin/pull/1038
Full Changelog: https://github.com/maplibre/martin/compare/v0.11.2...v0.11.3
martin-cp
by @nyurik in https://github.com/maplibre/martin/pull/1033
Full Changelog: https://github.com/maplibre/martin/compare/v0.11.1...v0.11.2
Full Changelog: https://github.com/maplibre/martin/compare/v0.11.0...v0.11.1
martin-cp
tool to bulk-copy tiles from any Martin-supported sources by @nyurik in https://github.com/maplibre/martin/pull/1011
mbtiles summary
tool to print MBTiles statistics by @sharkAndshark in https://github.com/maplibre/martin/pull/986
mbtiles copy --dst-type
arg name by @nyurik in https://github.com/maplibre/martin/pull/1003
Full Changelog: https://github.com/maplibre/martin/compare/v0.10.0...v0.11.0
Martin startup should now be much faster by default. See https://github.com/maplibre/martin/pull/958 by @nyurik, fixing #955
--disable-bounds
flag and disable_bounds
config parameters.--auto-bounds
/ -b
CLI parameter and auto_bounds
config value:
quick
: Compute table geometry bounds, but skips it if it takes longer than 5 seconds (default)calc
: Compute table geometry bounds. The startup time may be significant. Make sure all GEO columns have indexesskip
: Skip bounds calculation. The bounds will be set to the whole world-b
is now mapped to --auto-bounds
param, but it will fail if used by itself because it now requires a value./font/<name>/<start>-<end>
by @nyurik in https://github.com/maplibre/martin/pull/755
Fonts allow glyph fallback: list font names as comma-separated values, and whichever font first has the glyph, that's the glyph that will be included. This way you can specify fallback fonts - /font/Font1,Font2,Font3/0-255
--apply-patch
to copy, rename apply-diff by @nyurik in https://github.com/maplibre/martin/pull/945
Full Changelog: https://github.com/maplibre/martin/compare/v0.9.3...v0.10.0