Skip to content

feat(vllm): adopt split gRPC services and Control discovery - #12734

Merged
connorcarpenter15 merged 7 commits into
mainfrom
feat/vllm-control-discovery
Aug 10, 2026
Merged

feat(vllm): adopt split gRPC services and Control discovery#12734
connorcarpenter15 merged 7 commits into
mainfrom
feat/vllm-control-discovery

Conversation

@connorcarpenter15

@connorcarpenter15 connorcarpenter15 commented Aug 6, 2026

Copy link
Copy Markdown
Member

Overview:

Part 1 of a 4-PR stack. This foundation moves the Dynamo vLLM sidecar and mocker to vLLM's split native gRPC services and discovers runtime metadata through Control.

Details:

  • Vendor the split vLLM Inference and Control protocols pinned to 2d2c3af18c52e8e4efa4b0b4903843b15c0dba0e.
  • Move the vLLM mocker to split inference, control, and health services; all mocker changes in the stack are confined to this PR.
  • Discover model identity, capacity, parallelism, KV-event sources, and readiness through Control.
  • Remove required model-path configuration and avoid advertising parser defaults the protocol cannot honor.
  • Use the shared sidecar transport while preserving existing launch, deployment, and documentation surfaces.

Deterministic DP/KV routing, cancellation handoff behavior, and multimodal conversion remain in later PRs.

Stack

  1. #12734 — split gRPC services and Control discovery
  2. #12736 — preserve decode handoff on cancellation
  3. #12735 — deterministic DP and KV routing
  4. #12214 — multimodal sidecar requests

Base: main

Validation

  • cargo fmt --all -- --check
  • cargo test -p dynamo-vllm-sidecar -p dynamo-vllm-mocker — 30 tests passed
  • cargo clippy -p dynamo-vllm-sidecar -p dynamo-vllm-mocker --all-targets -- -D warnings

Where should the reviewer start?

  • lib/sidecar/vllm/src/client.rs for health and startup retry behavior.
  • lib/sidecar/vllm/src/model.rs for Control metadata validation and identity checks.
  • lib/sidecar/vllm/src/engine.rs for bootstrap discovery and shared transport startup.
  • lib/mocker/servers/vllm/src/server.rs for the split-service mock contract.

Related Issues

This PR is NOT linked to an issue:

  • Confirmed — no related issue

@github-actions

github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

@datadog-official

datadog-official Bot commented Aug 6, 2026

Copy link
Copy Markdown

Pipelines

🎯 Code Coverage (details)
Patch Coverage: 50.00%
Overall Coverage: 47.07% (-5.28%)

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 1b1b290 | Docs | Datadog PR Page | Give us feedback!

@connorcarpenter15
connorcarpenter15 marked this pull request as ready for review August 6, 2026 15:31
@connorcarpenter15
connorcarpenter15 requested review from a team as code owners August 6, 2026 15:31

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 4 potential issues.

Open in Devin Review

Comment thread lib/sidecar/vllm/src/client.rs
Comment thread lib/sidecar/vllm/src/engine.rs
Comment thread lib/sidecar/vllm/src/engine.rs
Comment thread lib/sidecar/vllm/src/model.rs
@coderabbitai

coderabbitai Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Walkthrough

Changes

vLLM API migration and discovery

Layer / File(s) Summary
Protocol contracts and code generation
.github/workflows/copyright-check.ps1, .pre-commit-config.yaml, lib/sidecar/vllm/proto/*, lib/sidecar/vllm/build.rs, lib/*/Cargo.toml
Replaced the legacy protobuf with separate Inference and Control services. Added multimodal request fields, metadata messages, health support, and updated build and tooling configuration.
Mock Inference, Control, and health services
lib/mocker/servers/vllm/src/*, lib/mocker/servers/vllm/tests/sidecar.rs, lib/mocker/servers/vllm/README.md
Updated the mock server and tests to register both services, report health, expose metadata, abort requests, and validate data-parallel ranks.
Health checks and metadata discovery
lib/sidecar/vllm/src/client.rs, lib/sidecar/vllm/src/model.rs
Added deadline-bounded service health checks and Control API discovery for model and server metadata.
Discovered model engine startup
lib/sidecar/vllm/src/engine.rs, lib/sidecar/vllm/src/convert.rs, lib/sidecar/vllm/src/tests.rs
The engine validates discovered metadata, checks identity consistency, propagates server limits, and sends the discovered served model name.
Launch, deployment, and executable updates
lib/sidecar/vllm/README.md, lib/sidecar/vllm/deploy/*, lib/sidecar/vllm/launch/*, lib/sidecar/vllm/tests/executable.rs
Removed --model-path from launch commands and updated documentation and help checks for Control-based discovery and health checks.

Estimated code review effort: 4 (Complex) | ~60 minutes

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 27.12% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly and concisely summarizes the main change: adopting split vLLM gRPC services and Control-based discovery.
Description check ✅ Passed The description includes all required sections, explains the changes, identifies review starting points, and confirms that no issue is linked.

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🧹 Nitpick comments (2)
lib/sidecar/vllm/src/model.rs (1)

63-71: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Name the field that changed in the identity error.

ModelIdentity also compares aliases, reasoning_parser, and tool_call_parser. If only one of those changes, the message prints identical source and served names, which makes the failure hard to diagnose. Include the two identity values in the message, for example with {:?} on self.identity and observed.identity.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@lib/sidecar/vllm/src/model.rs` around lines 63 - 71, Update
ModelIdentity::ensure_same_identity to include the complete expected and
observed identity values in the protocol error message, using debug formatting
for self.identity and observed.identity. Preserve the existing source and
served-name context while making changes to aliases, reasoning_parser, or
tool_call_parser visible.
lib/sidecar/vllm/src/tests.rs (1)

175-186: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Add an identity-mismatch startup test.

After bootstrap, set server.service.model_info_override to a different model and assert that engine.start(0) returns model identity changed between bootstrap and startup.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@lib/sidecar/vllm/src/tests.rs` around lines 175 - 186, Add a test covering
identity mismatch after bootstrap: update server.service.model_info_override
with a different model than the bootstrapped one, then assert engine.start(0)
fails with the error message “model identity changed between bootstrap and
startup.” Reuse the existing bootstrap, server, and model-construction helpers
in the surrounding tests.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@lib/mocker/servers/vllm/src/server.rs`:
- Around line 89-98: Update the ModelInfo construction to set
supports_text_input to false, matching PreparedRequest::new’s rejection of
Prompt::Text; leave token-ID input capability unchanged.

In `@lib/sidecar/vllm/src/engine.rs`:
- Around line 254-279: Document the synchronous execution constraint on
VllmSidecarEngine::from_args and its bootstrap_discover Runtime::block_on path.
State that it must be called before dynamo_backend_common::run in the production
entry point, while asynchronous callers must invoke it through spawn_blocking or
an equivalent dedicated thread.

In `@lib/sidecar/vllm/src/model.rs`:
- Around line 90-101: Update the required and nonempty helpers to return the
trimmed value after validation, while preserving their existing error and None
behavior for blank inputs. Ensure GenerateRequest.model receives the normalized
model name without surrounding whitespace.

---

Nitpick comments:
In `@lib/sidecar/vllm/src/model.rs`:
- Around line 63-71: Update ModelIdentity::ensure_same_identity to include the
complete expected and observed identity values in the protocol error message,
using debug formatting for self.identity and observed.identity. Preserve the
existing source and served-name context while making changes to aliases,
reasoning_parser, or tool_call_parser visible.

In `@lib/sidecar/vllm/src/tests.rs`:
- Around line 175-186: Add a test covering identity mismatch after bootstrap:
update server.service.model_info_override with a different model than the
bootstrapped one, then assert engine.start(0) fails with the error message
“model identity changed between bootstrap and startup.” Reuse the existing
bootstrap, server, and model-construction helpers in the surrounding tests.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: bd81be70-6b4b-4b97-8e51-4888cd03fadc

📥 Commits

Reviewing files that changed from the base of the PR and between b6d6480 and 663fa53.

⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (26)
  • .github/workflows/copyright-check.ps1
  • .pre-commit-config.yaml
  • lib/mocker/servers/vllm/Cargo.toml
  • lib/mocker/servers/vllm/README.md
  • lib/mocker/servers/vllm/src/main.rs
  • lib/mocker/servers/vllm/src/server.rs
  • lib/mocker/servers/vllm/src/server_request.rs
  • lib/mocker/servers/vllm/src/server_tests.rs
  • lib/mocker/servers/vllm/tests/sidecar.rs
  • lib/sidecar/vllm/Cargo.toml
  • lib/sidecar/vllm/README.md
  • lib/sidecar/vllm/build.rs
  • lib/sidecar/vllm/deploy/agg.yaml
  • lib/sidecar/vllm/deploy/disagg.yaml
  • lib/sidecar/vllm/launch/agg.sh
  • lib/sidecar/vllm/launch/disagg.sh
  • lib/sidecar/vllm/proto/README.md
  • lib/sidecar/vllm/proto/control.proto
  • lib/sidecar/vllm/proto/inference.proto
  • lib/sidecar/vllm/src/args.rs
  • lib/sidecar/vllm/src/client.rs
  • lib/sidecar/vllm/src/convert.rs
  • lib/sidecar/vllm/src/engine.rs
  • lib/sidecar/vllm/src/model.rs
  • lib/sidecar/vllm/src/tests.rs
  • lib/sidecar/vllm/tests/executable.rs
💤 Files with no reviewable changes (3)
  • lib/sidecar/vllm/tests/executable.rs
  • lib/sidecar/vllm/src/args.rs
  • lib/sidecar/vllm/launch/disagg.sh

Comment thread lib/mocker/servers/vllm/src/server.rs
Comment thread lib/sidecar/vllm/src/engine.rs
Comment thread lib/sidecar/vllm/src/model.rs
@connorcarpenter15
connorcarpenter15 requested a review from a team as a code owner August 6, 2026 18:13

@PeaBrane PeaBrane left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ General approval, conditional on resolving the inline comments before merge. Please also replace the stale vLLM gRPC v0.25.1 validation wording in lib/sidecar/vllm/src/convert.rs with feature-based wording.

Comment thread lib/sidecar/vllm/deploy/agg.yaml
Comment thread lib/sidecar/vllm/src/model.rs
Comment thread lib/sidecar/vllm/src/engine.rs
Comment thread lib/mocker/servers/vllm/src/main.rs Outdated
Signed-off-by: Connor Carpenter <connorc@nvidia.com>
Signed-off-by: Connor Carpenter <connorc@nvidia.com>
Signed-off-by: Connor Carpenter <connorc@nvidia.com>
Signed-off-by: Connor Carpenter <connorc@nvidia.com>
Signed-off-by: Connor Carpenter <connorc@nvidia.com>
@connorcarpenter15
connorcarpenter15 force-pushed the feat/vllm-control-discovery branch from 7a35d79 to 9a056be Compare August 7, 2026 20:43
Signed-off-by: Connor Carpenter <connorc@nvidia.com>

@tanmayv25 tanmayv25 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated multi-agent code-review pass over this PR's diff (framing + expert lenses, each finding adversarially verified). Findings below are all minor / non-blocking.

Comment thread lib/sidecar/vllm/src/tests.rs
Signed-off-by: Connor Carpenter <connorc@nvidia.com>
@connorcarpenter15
connorcarpenter15 merged commit 50bcfb6 into main Aug 10, 2026
124 of 125 checks passed
@connorcarpenter15
connorcarpenter15 deleted the feat/vllm-control-discovery branch August 10, 2026 17:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

actions documentation Improvements or additions to documentation feat size/XXL

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants