Repository navigation
Conversation
Collect the Prometheus metrics exposed by the vLLM Production Stack router: incoming requests, end-to-end latency, errors and token counts, per-backend load and prefix cache hit rate, backend health, and router resource usage. Signed-off-by: Lucas Barros <lucasbarros.kam@gmail.com>
joepeeples
approved these changes
Nov 5, 2026
This branch has not been deployed
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.
What does this PR do?
Adds a new Agent-based integration for the router of vLLM Production Stack, the reference Kubernetes deployment for vLLM.
The check scrapes the router's Prometheus endpoint (
/metricson port 8000) and maps its metrics tovllm_production_stack.*:status), errors byerror_type, and input and output tokens.The router labels per-backend series with
server(the engine URL); it is renamed tobackendso it does not clash with host-level tags.vllm:gpu_prefix_cache_hits_totalandvllm:gpu_prefix_cache_queries_totalare gauges despite the suffix, so they are submitted as gauges.Motivation
The
vllmintegration in integrations-core monitors each engine, but there is no integration for the Production Stack router, which is where request routing, per-backend load and backend failures show up. The router reuses thevllm:prefix for some names (for examplevllm:num_requests_running) with a different meaning and an extraserverlabel, so pointing thevllmcheck at it does not work well. This integration is meant to be used next tovllm.I'm happy to be listed as the maintainer of this integration.
Review checklist
Additional Notes
tests/fixtures/metrics.txtis a real scrape from the router at tagvllm-stack-0.1.13, running with static service discovery and round-robin routing in front of two OpenAI-compatible backends, after streaming and non-streaming requests, an unknown model, and one backend going down (which produced theClientConnectorErrorerrors and thestatus:errorlatency series).backend.prefix_cache.*) are zero in the fixture, andavg_itl/avg_decoding_lengthshow the router's-1"no data" value; the README mentions both.vllm:num_requests_waitingis declared by the router but never set, so it is not mapped.ddev test vllm_production_stack(unit),ddev test --lint, andddev validate(config, models, metadata, service-checks, readmes, openmetrics, typos, codeowners, package). I also ran the check against the live router and all 22 metrics plus the health service check came through.