[Scheduler] Decouple maybe_send_health_check_signal from process_batch_result (#20227)

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Liangsheng Yin
2026-03-09 21:18:56 -07:00
committed by GitHub
co-authored by Claude Opus 4.6
parent 2e7682414b
commit 208f1428e9
5 changed files with 20 additions and 1 deletions
@@ -139,6 +139,8 @@ class SchedulerPPMixin:
self.pp_outputs = next_pp_outputs
self.maybe_send_health_check_signal()
# When the server is idle, self-check and re-init some states
if server_is_idle:
self.self_check_during_idle()
@@ -314,6 +316,8 @@ class SchedulerPPMixin:
self.running_batch.batch_is_full = False
self.maybe_send_health_check_signal()
# When the server is idle, self-check and re-init some states
if server_is_idle and len(self.disagg_prefill_inflight_queue) == 0:
self.self_check_during_idle()
@@ -504,6 +508,8 @@ class SchedulerPPMixin:
if self.server_args.disaggregation_decode_enable_offload_kvcache:
queue_size += len(self.decode_offload_manager.ongoing_offload)
self.maybe_send_health_check_signal()
if server_is_idle and queue_size == 0:
self.self_check_during_idle()