Restore VirtualMCPServer inline telemetry fallback for Prometheus metrics - #6469
Open
lorenzozanee wants to merge 1 commit into
Open
Restore VirtualMCPServer inline telemetry fallback for Prometheus metrics#6469lorenzozanee wants to merge 1 commit into
lorenzozanee wants to merge 1 commit into
Conversation
lorenzozanee
requested review from
ChrisJBurns,
JAORMX,
blkt,
jerm-dro,
jhrozek,
rdimitrov,
reyortiz3 and
tgrunnagle
as code owners
August 31, 2026 00:01
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6469 +/- ##
==========================================
- Coverage 78.02% 78.02% -0.01%
==========================================
Files 767 767
Lines 74273 74279 +6
==========================================
- Hits 57955 57953 -2
- Misses 16313 16321 +8
Partials 5 5 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
VirtualMCPServer with only spec.config.telemetry was silently ignored after stacklok#4819, leaving the vmcp ConfigMap without a telemetry block. Without /metrics registered the transport falls through to the MCP handler and returns 406. Restore the deprecated inline fallback when TelemetryConfigRef is unset (ref wins), log a migration warning, and keep Prometheus metrics reachable. Signed-off-by: lorenzozanee <wyz0707@proton.me>
lorenzozanee
force-pushed
the
fix/virtualmcp-inline-telemetry-metrics-6276
branch
from
August 31, 2026 00:34
73a00ca to
020f722
Compare
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
VirtualMCPServer inline
spec.config.telemetrywas accepted by the API but ignored by the operator after #4819, so the rendered vmcp ConfigMap had notelemetryblock. The vmcp process never registeredGET /metrics, and Prometheus scrapes hit the MCP catch-all handler returning406 Not Acceptable: Client must accept text/event-stream.normalizeTelemetrywhenTelemetryConfigRefis unset (ref still wins when both are set)V(1)deprecation warningconfig.telemetry is deprecated; migrate to spec.telemetryConfigRefTestConverter_InlineTelemetryasserts inline is applied,TestConverter_TelemetryConfigRefWinsasserts ref precedenceFixes #6276
Type of change
Test plan
task test)task test-e2e)task lint-fix)go test ./cmd/thv-operator/pkg/vmcpconfig/...- all pass including newTestConverter_InlineTelemetryandTestConverter_TelemetryConfigRefWins.API Compatibility
v1beta1API, OR theapi-break-allowedlabel is applied and the migration guidance is described above.No CRD change; restores previously documented inline path as deprecated fallback until removed.
Does this introduce a user-facing change?
Yes - Prometheus ServiceMonitors scraping VirtualMCPServer
/metricswithenablePrometheusMetricsPath: truenow succeed (HTTP 200) instead of MCP 406, without requiring migration toMCPTelemetryConfig. Users on the new path are unaffected.