-
-
Notifications
You must be signed in to change notification settings - Fork 221
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
PMTiles cache, refactor file configs, modularize
* Implement PMTiles directory cache shared between all pmtiles, with configurable max cache size (in MB), or 0 to disable. * PMTiles now share web client instance, which optimizes connection reuse in case multiple pmtiles reside on the same host * Major refactoring to allow modular reuse, enabling the following build features: * **postgres** - enable PostgreSQL/PostGIS tile sources * **pmtiles** - enable PMTile tile sources * **mbtiles** - enable MBTile tile sources * **fonts** - enable font sources * **sprites** - enable sprite sources * Use justfile in the CI
- Loading branch information
Showing
31 changed files
with
585 additions
and
401 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -106,6 +106,14 @@ Martin data is available via the HTTP `GET` endpoints: | |
| `/font/{font1},…,{fontN}/{start}-{end}` | Composite Font source | | ||
| `/health` | Martin server health check: returns 200 `OK` | | ||
|
||
## Re-use Martin as a library | ||
Check failure on line 109 in README.md GitHub Actions / Build DocsHeadings should be surrounded by blank lines
|
||
Martin can be used as a standalone server, or as a library in your own Rust application. When used as a library, you can use the following features: | ||
* **postgres** - enable PostgreSQL/PostGIS tile sources | ||
Check failure on line 111 in README.md GitHub Actions / Build DocsLists should be surrounded by blank lines
|
||
* **pmtiles** - enable PMTile tile sources | ||
* **mbtiles** - enable MBTile tile sources | ||
* **fonts** - enable font sources | ||
* **sprites** - enable sprite sources | ||
|
||
## Documentation | ||
|
||
See [Martin book](https://maplibre.org/martin/) for complete documentation. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ lints.workspace = true | |
|
||
[package] | ||
name = "martin-tile-utils" | ||
version = "0.3.1" | ||
version = "0.4.0" | ||
authors = ["Yuri Astrakhan <[email protected]>", "MapLibre contributors"] | ||
description = "Utilites to help with map tile processing, such as type and compression detection. Used by the MapLibre's Martin tile server." | ||
keywords = ["maps", "tiles", "mvt", "tileserver"] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ lints.workspace = true | |
[package] | ||
name = "martin" | ||
# Once the release is published with the hash, update https://github.com/maplibre/homebrew-martin | ||
version = "0.11.6" | ||
version = "0.12.0" | ||
authors = ["Stepan Kuzmin <[email protected]>", "Yuri Astrakhan <[email protected]>", "MapLibre contributors"] | ||
description = "Blazing fast and lightweight tile server with PostGIS, MBTiles, and PMTiles support" | ||
keywords = ["maps", "tiles", "mbtiles", "pmtiles", "postgis"] | ||
|
@@ -59,10 +59,12 @@ name = "bench" | |
harness = false | ||
|
||
[features] | ||
default = [] | ||
#default = ["sprites", "fonts"] | ||
sprites = [] | ||
fonts = [] | ||
default = ["fonts", "mbtiles", "pmtiles", "postgres", "sprites"] | ||
fonts = ["dep:bit-set","dep:pbf_font_tools"] | ||
mbtiles = [] | ||
pmtiles = ["dep:moka"] | ||
postgres = ["dep:deadpool-postgres", "dep:json-patch", "dep:postgis", "dep:postgres", "dep:postgres-protocol", "dep:semver", "dep:tokio-postgres-rustls"] | ||
sprites = ["dep:spreet"] | ||
bless-tests = [] | ||
|
||
[dependencies] | ||
|
@@ -71,41 +73,41 @@ actix-http.workspace = true | |
actix-rt.workspace = true | ||
actix-web.workspace = true | ||
async-trait.workspace = true | ||
bit-set.workspace = true | ||
bit-set = { workspace = true, optional = true } | ||
brotli.workspace = true | ||
clap.workspace = true | ||
deadpool-postgres.workspace = true | ||
deadpool-postgres = { workspace = true, optional = true } | ||
env_logger.workspace = true | ||
flate2.workspace = true | ||
futures.workspace = true | ||
itertools.workspace = true | ||
json-patch.workspace = true | ||
json-patch = { workspace = true, optional = true } | ||
log.workspace = true | ||
martin-tile-utils.workspace = true | ||
mbtiles.workspace = true | ||
moka.workspace = true | ||
moka = { workspace = true, optional = true } | ||
num_cpus.workspace = true | ||
pbf_font_tools.workspace = true | ||
pbf_font_tools = { workspace = true, optional = true } | ||
pmtiles.workspace = true | ||
postgis.workspace = true | ||
postgres-protocol.workspace = true | ||
postgres.workspace = true | ||
postgis = { workspace = true, optional = true } | ||
postgres-protocol = { workspace = true, optional = true } | ||
postgres = { workspace = true, optional = true } | ||
regex.workspace = true | ||
reqwest.workspace = true | ||
rustls-native-certs.workspace = true | ||
rustls-pemfile.workspace = true | ||
rustls.workspace = true | ||
semver.workspace = true | ||
semver = { workspace = true, optional = true } | ||
serde.workspace = true | ||
serde_json.workspace = true | ||
serde_with.workspace = true | ||
serde_yaml.workspace = true | ||
spreet.workspace = true | ||
spreet = { workspace = true, optional = true } | ||
subst.workspace = true | ||
thiserror.workspace = true | ||
tilejson.workspace = true | ||
tokio = { workspace = true, features = ["io-std"] } | ||
tokio-postgres-rustls.workspace = true | ||
tokio-postgres-rustls = { workspace = true, optional = true } | ||
url.workspace = true | ||
|
||
[dev-dependencies] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.