chore: move our imports to tracing#2500
Merged
CommanderStorm merged 8 commits intomaplibre:mainfrom Jan 16, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR migrates the logging infrastructure from the log crate to the tracing crate across the entire Martin tile server codebase. This is a standard chore that modernizes the logging framework without changing functionality.
Changes:
- Replaced all
use log::*imports withuse tracing::*equivalents - Updated
log::macro!()calls totracing::macro!()across ~35 files - Refactored dynamic level logging in
OnInvalid::handle_tile_warningsto use explicit match statements (as tracing doesn't support dynamic level macros) - Updated
martin-core/Cargo.tomlto depend ontracinginstead oflog
Reviewed changes
Copilot reviewed 35 out of 37 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| martin/tests/utils.rs | Import migration: log::warn → tracing::warn |
| martin/src/srv/styles_rendering.rs | Import migration: log macros → tracing macros |
| martin/src/srv/styles.rs | Import migration: log::error → tracing::error |
| martin/src/srv/server.rs | Updated inline macro call: log::error! → tracing::error! |
| martin/src/source.rs | Import migration: log::debug → tracing::debug |
| martin/src/config/file/tiles/postgres/utils.rs | Import migration: log macros → tracing macros |
| martin/src/config/file/tiles/postgres/resolver/query_tables.rs | Import migration: log macros → tracing macros |
| martin/src/config/file/tiles/postgres/resolver/query_functions.rs | Import migration: log macros → tracing macros |
| martin/src/config/file/tiles/postgres/config_table.rs | Import migration: log macros → tracing macros |
| martin/src/config/file/tiles/postgres/config.rs | Import migration: log::warn → tracing::warn |
| martin/src/config/file/tiles/postgres/builder.rs | Import migration: log macros → tracing macros |
| martin/src/config/file/tiles/pmtiles.rs | Import migration: log macros → tracing macros |
| martin/src/config/file/resources/styles.rs | Import migration: log::warn → tracing::warn |
| martin/src/config/file/resources/sprites.rs | Import migration: log::warn → tracing::warn |
| martin/src/config/file/main.rs | Import migration and refactored OnInvalid logging logic to replace log! macro with explicit match statements |
| martin/src/config/file/file_config.rs | Import migration: log macros → tracing macros |
| martin/src/config/file/cors.rs | Import migration: log::info → tracing::info |
| martin/src/config/file/cache.rs | Updated inline macro calls: log:: → tracing:: |
| martin/src/config/args/postgres.rs | Import migration: log macros → tracing macros |
| martin/src/bin/martin.rs | Updated inline macro call: log::warn! → tracing::warn! |
| martin-core/src/tiles/postgres/tls.rs | Import migration: log macros → tracing macros |
| martin-core/src/tiles/postgres/source.rs | Import migration: log::debug → tracing::debug |
| martin-core/src/tiles/postgres/pool.rs | Import migration: log macros → tracing macros |
| martin-core/src/tiles/pmtiles/source.rs | Import migration: log macros → tracing macros |
| martin-core/src/tiles/pmtiles/cache.rs | Updated inline macro call: log::info! → tracing::info! |
| martin-core/src/tiles/mbtiles/source.rs | Import migration: log::trace → tracing::trace |
| martin-core/src/tiles/cog/source.rs | Import migration: log::warn → tracing::warn |
| martin-core/src/tiles/cache.rs | Updated inline macro calls: log:: → tracing:: |
| martin-core/src/resources/styles/mod.rs | Import migration: log macros → tracing macros |
| martin-core/src/resources/sprites/mod.rs | Import migration: log macros → tracing macros |
| martin-core/src/resources/sprites/cache.rs | Updated inline macro calls: log:: → tracing:: |
| martin-core/src/resources/fonts/mod.rs | Import migration: log macros → tracing macros |
| martin-core/src/resources/fonts/cache.rs | Updated inline macro calls: log:: → tracing:: |
| martin-core/src/config/id_resolver.rs | Import migration: log::warn → tracing::warn |
| martin-core/src/config/env.rs | Import migration: log::warn → tracing::warn |
| martin-core/Cargo.toml | Dependency change: log.workspace → tracing.workspace |
| Cargo.lock | Updated lock file reflecting dependency changes |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
nyurik
approved these changes
Jan 16, 2026
Member
nyurik
left a comment
There was a problem hiding this comment.
i did a few changes - do make sure you agree
Member
Author
|
thanks 👍🏻 |
Merged
CommanderStorm
added a commit
that referenced
this pull request
Jan 28, 2026
## 🤖 New release * `martin-tile-utils`: 0.6.8 -> 0.6.9 (✓ API compatible changes) * `mbtiles`: 0.15.0 -> 0.15.1 (✓ API compatible changes) * `martin-core`: 0.2.5 -> 0.2.6 (✓ API compatible changes) * `martin`: 1.2.0 -> 1.3.0 <details><summary><i><b>Changelog</b></i></summary><p> ## `mbtiles` <blockquote> ## [0.15.1](mbtiles-v0.15.0...mbtiles-v0.15.1) - 2026-01-27 ### Added - add MLT decoding support ([#2512](#2512)) - migrate our log library to tracing ([#2494](#2494)) ### Other - unignore `diff_and_patch_bsdiff` test with unique SQLite database names ([#2480](#2480)) - *(mbtiles)* remove the prefix-ism around how files are named for binary diff copy and simpify their naming ([#2478](#2478)) - *(mbtiles)* add assertion messages what we are checking to the copy tests ([#2477](#2477)) </blockquote> ## `martin-core` <blockquote> ## [0.2.6](martin-core-v0.2.5...martin-core-v0.2.6) - 2026-01-27 ### Added - migrate our log library to tracing ([#2494](#2494)) - *(martin-core)* Allow glyph ranges more than 0xFFFF ([#2438](#2438)) ### Fixed - *(perf)* Remove FontSources.masks as they were consuming large amounts of memory even when no font sources were set ([#2519](#2519)) - improve error message if no SVG sprite files are present ([#2516](#2516)) ### Other - move our imports to tracing ([#2500](#2500)) - *(deps)* shear our dependencys ([#2497](#2497)) </blockquote> ## `martin` <blockquote> ## [1.3.0](martin-v1.2.0...martin-v1.3.0) - 2026-01-27 ### Added - *(srv)* Add `route_prefix` configuration for native subpath support without the need of a reverse proxy override ([#2523](#2523)) - add MLT decoding support ([#2512](#2512)) - migrate our log library to tracing ([#2494](#2494)) - improve martin-cp progress output time estimate ([#2491](#2491)) - *(pg)* include ID column info for tables ([#2485](#2485)) - *(pg)* support PostgreSQL materialized views ([#2279](#2279)) - *(martin-core)* Allow glyph ranges more than 0xFFFF ([#2438](#2438)) ### Fixed - *(ui)* clipboard copy for http://0.0.0.0:3000 and unify implementations ([#2487](#2487)) - the `Copy` icon displaying nicely, next to the text and with enough padding ot all items ([#2483](#2483)) - update copy text to include icon for better visibility ([#2482](#2482)) - *(perf)* Remove FontSources.masks as they were consuming large amounts of memory even when no font sources were set ([#2519](#2519)) - improve error message if no SVG sprite files are present ([#2516](#2516)) ### Other - move our request logging to tracing ([#2508](#2508)) - move our imports to tracing ([#2500](#2500)) - *(deps)* shear our dependencys ([#2497](#2497)) - *(ui)* adjust margin for copy icon in URL component ([#2489](#2489)) - unignore `diff_and_patch_bsdiff` test with unique SQLite database names ([#2480](#2480)) - *(mbtiles)* remove the prefix-ism around how files are named for binary diff copy and simpify their naming ([#2478](#2478)) - *(mbtiles)* add assertion messages what we are checking to the copy tests ([#2477](#2477)) </blockquote> </p></details> --- This PR was generated with [release-plz](https://github.com/release-plz/release-plz/). --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
this PR moves our imports from logging to tracing.