[Elastic EP] Fix recovery lifecycle and add manual coverage (#31744)

Co-authored-by: Shangming Cai <csmthu@gmail.com>
This commit is contained in:
Xun Sun
2026-07-25 14:32:47 +08:00
committed by GitHub
co-authored by Shangming Cai
parent f9c14e6bd4
commit 9eb2dccbb7
7 changed files with 310 additions and 45 deletions
+6
View File
@@ -885,6 +885,12 @@ class Scheduler(
if model_runner.token_to_kv_pool.post_capture_active:
model_runner.post_capture_resize_kv_pool()
if (
self.server_args.elastic_ep_backend is not None
and self.server_args.ep_join_mode == "recover"
):
model_runner.post_capture_elastic_ep_recover()
# Dispatch the model worker
if self.spec_algorithm.is_none():
self.model_worker = self.tp_worker
+2 -2
View File
@@ -342,8 +342,8 @@ class TpModelWorker(BaseTpWorker):
self.world_group = get_world_group()
# Sync random seed across TP workers.
# Scale joiners cannot enter the launch-time WORLD broadcast.
if server_args.is_ep_scale_joiner:
# Elastic joiners cannot enter the launch-time WORLD broadcast.
if server_args.is_ep_joiner:
self.random_seed = server_args.random_seed
else:
self.random_seed = broadcast_pyobj(