Move metrics to Prometheus client 1.x, upgrade common-utils to 5.0, and cut 3.5.0 - #130
Merged
Merged
Conversation
…nd cut 3.5.0 common-utils 5 and prometheus-proxy 4.2 moved to the Prometheus Java client 1.x, and common-utils' MetricsService now serves PrometheusRegistry.defaultRegistry. A collector left in the old 0.x CollectorRegistry still compiles and runs but is never scraped -- which is what would have happened to the JVM collectors added in #129 had DefaultExports.initialize() been kept. They are now registered with JvmMetrics.builder().register(), the 30 recording sites move from labels(...) to labelValues(...), and server_start_time_seconds is set explicitly because 1.x dropped setToCurrentTime(). JvmMetricsTest now asserts against the registry that is actually served, using the 1.x metric names (jvm_memory_used_bytes, jvm_classes_currently_loaded). The public Metrics properties are now 1.x types, which is source-breaking for anything that records to them from outside the library. Since common-utils 4.x, FileSystemSource.file(path) resolves against pathPrefix itself, so Challenge's call -- which prepended pathPrefix as well -- doubled it on the upgrade. Invisible for a "./" root, fatal for "../", where the Python test content lives. Paths are now relative to the source root. The docs site did not build from the project's own uv environment: zensical.toml named the emoji extension by its Material for MkDocs path, and zensical remaps material.extensions only in YAML configs. CI masked it by also installing mkdocs-material; the config now names zensical.extensions.emoji and the workflow installs zensical alone. Also fixes an unresolvable KDoc link on Endpoints.STATIC_PATH; bumps Gradle 9.8.0, Kotlin 2.4.20, Flyway 13.8.0, kotlinter 5.7.0, buildconfig 6.1.2 and the website's Python deps; and documents the release (3.5.0, 2026-09-27) across CHANGELOG, RELEASE_NOTES, README, llms.txt, CLAUDE.md and the docs site. 381 tests, 0 failures, 6 skipped; lint and detekt clean. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
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.
Summary
Cuts 3.5.0 (release date 2026-09-27): a monitoring and maintenance release.
PrometheusRegistry, so anything still registered in the 0.xCollectorRegistrycompiles, runs, and is never scraped. The JVM collectors from Export JVM metrics and capture a heap dump on OOM #129 now useJvmMetrics.builder().register(). All 30 recording sites move fromlabels(...)tolabelValues(...).jvm_memory_used_bytesandjvm_classes_currently_loaded, not the 0.x names most published dashboards use.JvmMetricsTestasserts against the registry that is actually served.FileSystemSource.file()path fix. Since common-utils 4.x it resolves againstpathPrefixitself, soChallengeprepending it too doubled the prefix: invisible for"./", fatal for"../"(the Python test content).zensical.tomlused Material'smaterial.extensions.emojipath, which zensical only remaps in YAML configs, souv run zensical buildfailed locally. CI masked it by also installingmkdocs-material; the config now nameszensical.extensions.emojiand the workflow installs zensical alone.CHANGELOG.md,RELEASE_NOTES.md, and the website release notes;README.md,llms.txt,CLAUDE.md, and the server docs updated for JVM metrics, heap-dump reporting, local-run dumps, the Prometheus 1.x registry rule, and the zensical extension naming.Breaking change
The public
Metricsproperties are now Prometheus 1.x types, which is source-breaking for anything that records to them from outside the library (labels(...)→labelValues(...)). readingbat-site does not use these APIs.Test plan
./gradlew test lintKotlinMain lintKotlinTest detekt: 381 tests, 0 failures, 6 skipped; lint and detekt cleanuv run zensical build --clean(nomkdocs-material) and in an isolated zensical-only env matching CI; icon shortcodes render:8083/metricsexposesjvm_memory_used_bytes🤖 Generated with Claude Code