[model-gateway] add --disable-health-check option to skip worker health probes (#17002)

This commit is contained in:
Ziwen Zhao
2026-01-13 17:28:32 -08:00
committed by GitHub
parent 5938c3b06a
commit cf25852a1d
17 changed files with 159 additions and 14 deletions
+11 -7
View File
@@ -880,13 +880,17 @@ pub async fn startup(config: ServerConfig) -> Result<(), Box<dyn std::error::Err
let router_manager = RouterManager::from_config(&config, &app_context).await?;
let router: Arc<dyn RouterTrait> = router_manager.clone();
let _health_checker = app_context
.worker_registry
.start_health_checker(config.router_config.health_check.check_interval_secs);
debug!(
"Started health checker for workers with {}s interval",
config.router_config.health_check.check_interval_secs
);
if !config.router_config.health_check.disable_health_check {
let _health_checker = app_context
.worker_registry
.start_health_checker(config.router_config.health_check.check_interval_secs);
debug!(
"Started health checker for workers with {}s interval",
config.router_config.health_check.check_interval_secs
);
} else {
info!("Global health checks disabled via CLI/config; skipping health checker");
}
if let Some(ref load_monitor) = app_context.load_monitor {
load_monitor.start().await;