fix(server): make native VMM registration ownership explicit - #416
Open
xiaguan wants to merge 1 commit into
Open
fix(server): make native VMM registration ownership explicit#416xiaguan wants to merge 1 commit into
xiaguan wants to merge 1 commit into
Conversation
xiaguan
force-pushed
the
codex/vmm-registration-resource
branch
3 times, most recently
from
July 24, 2026 10:57
69a1927 to
ad846ae
Compare
Signed-off-by: xiaguan <751080330@qq.com>
xiaguan
force-pushed
the
codex/vmm-registration-resource
branch
from
July 24, 2026 11:10
ad846ae to
ff77e32
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
This is stacked on #414 and defines the server-side ownership contract needed by the OpenInfer consumer in openinfer-project/openinfer#740.
instance_idas the fresh, non-reused process/registration-attempt identity on both the fd side channel and gRPC; no second registration ID or RPC schema changeArc<VmmRegistration>own the imported mapping and an operation gate; save/load tasks retain a guard until GPU work finishes, even if the RPC is cancelledinstance_id\0device_idSCM_RIGHTS message, but bound connections and pending fds, expire unmatched entries on activity, reject malformed/multi-fd messages without descriptor leaks, and recover only a verified stale socket inodeScope
Native VMM v1 supports the current Qwen layout only: one GPU, one fused allocation, and multiple layer views. Multiple GPUs or allocations per native instance, including the GLM layout, remain out of scope and fail early.
A native client must generate a fresh
instance_idfor every process/registration attempt and must not reuse it. Native loads requirewait_for_completion=true; an asynchronous native load cannot transfer the mapping lifetime into the existing detached worker contract safely.The UDS path remains explicit configuration rather than gRPC discovery. The wire protocol and
pegaflow_proto::VERSIONstay onnative-vmm-v1.Validation
cargo check --workspace --all-targets --no-default-features --features cuda-13,rdmacargo clippy --workspace --all-targets --no-default-features --features cuda-13,rdma -- -D warningscargo test -p pegaflow-server --lib --no-default-features --features cuda-13,rdma— 34 passedcargo test --release -p pegaflow-server --test mock_vllm_rpc_e2e --no-default-features --features cuda-13,rdma— 8 passedcargo test -p pegaflow-server --test native_vmm_rpc_e2e --no-default-features --features cuda-13,rdma -- --nocapture— 1 passed on a real GPUcd python && uv run pytest— 202 passed, 11 deselected--devices— CUDA driver auto-detected the GPU, initialized the torch-free path, served gRPC/HTTP, and shut down cleanlyprek run— all hooks passed, including release testsThe Python integration suite was not run because the local test environment does not include PyTorch; the native Rust GPU E2E covers the VMM registration/save/load/unregister path.