From 3651cfbf62ce4ba8d6f76312c9fdce5e13b6f859 Mon Sep 17 00:00:00 2001 From: wyx <3081879742@qq.com> Date: Thu, 6 Nov 2025 05:37:17 +0800 Subject: [PATCH] [router] fix: validate HTTP status codes in health check (#12631) --- sgl-router/src/core/workflow/steps/worker_registration.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/sgl-router/src/core/workflow/steps/worker_registration.rs b/sgl-router/src/core/workflow/steps/worker_registration.rs index aad49f395..8c44ff798 100644 --- a/sgl-router/src/core/workflow/steps/worker_registration.rs +++ b/sgl-router/src/core/workflow/steps/worker_registration.rs @@ -145,6 +145,7 @@ async fn try_http_health_check( .timeout(Duration::from_secs(timeout_secs)) .send() .await + .and_then(reqwest::Response::error_for_status) .map_err(|e| format!("Health check failed: {}", e))?; Ok(())