[BugFix] --max-model-len=-1 causes over-limit requests to hang and starve the entire service (#39102)

Signed-off-by: triangle14 <y1019026570@gmail.com>
Signed-off-by: mgoin <mgoin64@gmail.com>
Co-authored-by: mgoin <mgoin64@gmail.com>
This commit is contained in:
triangleXIV
2026-04-08 14:03:17 -07:00
committed by GitHub
co-authored by mgoin
parent ad05edfbca
commit 7c94ae16c6
5 changed files with 82 additions and 4 deletions
+6 -1
View File
@@ -52,6 +52,7 @@ from vllm.v1.engine import (
EEPNotificationType,
EngineCoreOutput,
EngineCoreOutputs,
EngineCoreReadyResponse,
EngineCoreRequest,
EngineCoreRequestType,
FinishReason,
@@ -1385,11 +1386,15 @@ class EngineCoreProc(EngineCore):
# Register sockets with poller.
poller = zmq.Poller()
ready_response = EngineCoreReadyResponse(
max_model_len=self.vllm_config.model_config.max_model_len,
)
ready_payload = msgspec.msgpack.encode(ready_response)
for input_socket in input_sockets:
# Send initial message to each input socket - this is required
# before the front-end ROUTER socket can send input messages
# back to us.
input_socket.send(b"")
input_socket.send(ready_payload)
poller.register(input_socket, zmq.POLLIN)
if coord_socket is not None: