Repository navigation
[Bugfix] Register statistics for dynamically added replicas - #7298
Conversation
Signed-off-by: leegangtoe <leegangtoe@gmail.com>
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
|
This PR appears to belong to: docs/design/module/observability.md. Module owners: @lishunyang12 @vraiti @tzhouam Routing: @lishunyang12 via module of the changed files, semantic router, CODEOWNERS; @vraiti via module of the changed files, semantic router; @tzhouam via CODEOWNERS @leegangtoe, please review your own changes and leave a short self-review comment describing what you checked. PRs without author self-review may not be assigned a reviewer. Please take a look when you have a chance. If you would like an automated review, mention @vllm-omni-review-bot in a comment. |
Omni ReviewBot triage noteAutomated triage of commit
These are automated triage suggestions only — the final decision belongs to the maintainers. |
|
Self-review completed on head
|
…ject#7298) Signed-off-by: leegangtoe <leegangtoe@gmail.com> Signed-off-by: Matthieu Laneuville <matthieu.laneuville@surf.nl>
…ject#7298) Signed-off-by: leegangtoe <leegangtoe@gmail.com>
Purpose
Fixes #7296.
Adding a headless replica to a running distributed stage can terminate the orchestrator
with
KeyError: (0, 1)when log statistics are enabled. Both the orchestrator's engine-indexmap and the Prometheus per-engine metric tables contain only the initial replicas.
Register a new replica before recording its first statistics. Bind new metric children to
the existing families, preserving the counters of replicas already serving requests.
Registration covers nested label tables and helper collectors, including speculative
position counters. Heads with no initial replica initialize collectors on their first join.
Repeated registration preserves the same index and counters; new replicas start awake.
This branch is based directly on main and is independent of the multimodal cache fix #7297.
Detached replicas retain their metric series; this change does not remove historical series.
Test Plan
vLLM Version: 0.28.0; PyTorch 2.13.0+cu130, CUDA runtime 13.0, Transformers 5.14.1.
vLLM-Omni Commit:
efb39d72ff82dcd88ca31a02a1413e003e93878c; base main5e4baea64d0f4cd1b6ce147e4f7a28f0f41d995f.CPU regression tests use the real upstream logger and Prometheus registry. Model configuration
loading is mocked. Coverage includes zero initial replicas, multiple stages, sparse replica IDs,
repeat registration, existing counter preservation, new gauges/histograms, speculative position
counters, sleep-state preservation, and the shared orchestrator output-processing path.
From the repository root, with compatible vLLM/PyTorch, pytest and pytest-asyncio installed
(no model weights or GPU execution needed):
The existing Buildkite L1 CPU sweeps collect these modules; no pipeline change is needed.
For serving validation, use the head/headless commands in #7296 with default log statistics.
Start one replica, send text requests, attach a second replica, then send concurrent text
requests and inspect
/metrics. Text requests isolate this fix from the separate audio-cachebug. Tested on two H200 GPUs with Qwen3-Omni-30B-A3B-Instruct thinker-only, TP=1 per replica,
memory utilization 0.60, prefix caching enabled, eager execution disabled, round-robin routing.
Test Result
with
KeyError: (0, 3)(initial replica counts 0 and 1).joining passed (concurrency 8), with no
KeyErroror output-processing failures.The existing counter was preserved and the new replica's
awakegauge was 1.orchestrator.py. Running the same hook on the same files in the base reports 20errors; comparison after normalizing line numbers shows no new diagnostics.
These are correctness checks, not throughput benchmarks. Optional KV-transfer connector
configurations and distributed multi-node serving were not exercised by the GPU run.