[P/D] NixlConnector DP fixes (#18903)

Signed-off-by: Will Eaton <weaton@redhat.com>
This commit is contained in:
Will Eaton
2025-05-29 14:08:40 -04:00
committed by GitHub
parent d1d61f3351
commit 64eaf5fe05
3 changed files with 18 additions and 6 deletions

View File

@@ -707,6 +707,15 @@ class DPEngineCoreProc(EngineCoreProc):
assert dp_size > 1
assert 0 <= local_dp_rank <= dp_rank < dp_size
if vllm_config.kv_transfer_config is not None:
# modify the engine_id and append the local_dp_rank to it to ensure
# that the kv_transfer_config is unique for each DP rank.
vllm_config.kv_transfer_config.engine_id = (
f"{vllm_config.kv_transfer_config.engine_id}_dp{local_dp_rank}"
)
logger.debug("Setting kv_transfer_config.engine_id to %s",
vllm_config.kv_transfer_config.engine_id)
from vllm.platforms import current_platform
device_control_env_var = current_platform.device_control_env_var
world_size = vllm_config.parallel_config.world_size