[model-gateway] add --disable-health-check option to skip worker health probes (#17002)
This commit is contained in:
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user