Repository navigation
[Bugfix][KV Connector][Mooncake] Suppress completion for empty pulls - #59347
Conversation
525682e to
971efc5
Compare
|
LGTM, thanks for the fix |
|
✅ @wangyicong52, CI is now available for this PR.
|
|
/ci run |
|
❌ This PR is 71 commits behind upstream |
Signed-off-by: wangyicong <wangyicong@bytedance.com>
971efc5 to
90a0f96
Compare
|
/ci run |
|
✅ Triggered Buildkite CI #92742 for commit |
CI selector (shadow): 3 test steps (6 jobs) instead of 9 (14 jobs)Shadow mode: this changes nothing about what CI runs. It shows what the evidence-based selector would pick for this PR, next to today's rules. How it works. Feedback welcome: reply here if it would skip a step this change needs, or runs something unrelated.
Selector would run (3)
Would skip (today's rules run them) (6)
Would add (today's rules do not run them) (0)none AMD mirrors: would skip (16)
AMD mirrors: would add (0)none 2 changed files · base |
Purpose
Mooncake can issue a pull with no local destination blocks only to notify the Prefill side that its producer blocks may be released. The Decode request does not wait for remote KV in this case.
MooncakeConnectorWorker.process_pulling_resultcurrently reports every successful pull asfinished_recvingafter its worker tasks drain. For an empty pull, this sends a completion for a request that is not inWAITING_FOR_REMOTE_KVSand can trip the scheduler's request ownership/status assertion.Empty pulls are reachable both during early-abort cleanup and when a remote prefix hit is reduced to no transferable local blocks.
Change
Report a successful receive completion only when the pull contains at least one local destination block:
The producer notification and pull-task accounting are unchanged. This also matches the existing failed-receive path, which already skips scheduler notification when the pull has no local blocks.
Relationship to other work
#50565 addresses the early-abort cleanup variant by adding an explicit
notify_schedulerflag. Its current version intentionally still reports completion for an ordinary empty-block full-prefix pull. That does not cover the case where Decode does not enterWAITING_FOR_REMOTE_KVSafter the connector returns no transferable blocks.This PR applies the check at the worker completion sink, covering both cleanup-only and full-prefix empty pulls while preserving completion for every pull with real local destinations.
Test Plan
The regression test covers:
local_block_ids=[]: no scheduler completion;local_block_ids=[[]]: no scheduler completion;Test Result
git diff --check: passed.GPU Validation
Environment
vllm/vllm-openai:nightly-36768d1bfd39094681cdbc8cb37d4b31c0729c89(v0.30.1rc1.dev312+g36768d1bf).Prefill
Decode
Results
assert RequestStatus.is_finished(req.status), returned HTTP 500 through the P/D proxy, and shut down its API server withEngineDeadError.AI Assistance
AI assistance was used for investigation, test implementation, and PR drafting. The submitter reviewed the changes and ran the checks listed above.