Repository navigation
fix(docker-image): include metrics-mcp module in the runtime image - #1840
Merged
Merged
Conversation
PR #1837 added the MCP metrics group as a docker-image maven dependency but omitted it from the zpm image manifest, so the packaged runtime image's jlink module set did not include io.aklivity.zilla.runtime.metrics.mcp. As a result mcp.* metric names failed engine schema validation ("must be one of [grpc/http/stream...]") and MCP metrics could not be enabled in a deployed Zilla. Add io.aklivity.zilla:metrics-mcp to zpm.json.template (the Dockerfile regenerates zpm.json from it) so the image links the metrics.mcp module. Verified: the rebuilt image's `java --list-modules` now includes io.aklivity.zilla.runtime.metrics.mcp and an mcp.* metrics config validates. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
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.
Problem
PR #1837 added MCP metrics (
mcp.*counters + histograms) and wiredmetrics-mcpas acloud/docker-imagemaven dependency, but did not add it to the zpm image manifest (zpm.json.template). The Dockerfile builds the runtime viazpmw installfrom that manifest, so the packaged image's jlink module set never includedio.aklivity.zilla.runtime.metrics.mcp.Effect: in a deployed Zilla, any
telemetry.metricsentry likemcp.tools.callfails schema validation —— because the mcp metrics group (and its schema patch) isn't on the engine classpath. So MCP metrics couldn't actually be used despite #1837.
Fix
Add
io.aklivity.zilla:metrics-mcptozpm.json.template(alongsidemetrics-stream/http/grpc). The Dockerfile regenerateszpm.jsonfrom the template, so this is the single source of truth.Verification
Rebuilt
develop-SNAPSHOT:java --list-modulesnow includesio.aklivity.zilla.runtime.metrics.mcptelemetry.metrics: [mcp.*]on an mcp server binding validates and emits, e.g.mcp_tools_call_total{method="tools.call",outcome="ok",tool="..."}via the prometheus exporter.Follow-up to #1837.
🤖 Generated with Claude Code