[model-gateway] add --disable-health-check option to skip worker health probes (#17002)
This commit is contained in:
@@ -391,6 +391,7 @@ struct Router {
|
||||
health_check_timeout_secs: u64,
|
||||
health_check_interval_secs: u64,
|
||||
health_check_endpoint: String,
|
||||
disable_health_check: bool,
|
||||
enable_igw: bool,
|
||||
queue_size: usize,
|
||||
queue_timeout_secs: u64,
|
||||
@@ -591,6 +592,7 @@ impl Router {
|
||||
timeout_secs: self.health_check_timeout_secs,
|
||||
check_interval_secs: self.health_check_interval_secs,
|
||||
endpoint: self.health_check_endpoint.clone(),
|
||||
disable_health_check: self.disable_health_check,
|
||||
})
|
||||
.tokenizer_cache(config::TokenizerCacheConfig {
|
||||
enable_l0: self.tokenizer_cache_enable_l0,
|
||||
@@ -692,6 +694,7 @@ impl Router {
|
||||
health_check_timeout_secs = 5,
|
||||
health_check_interval_secs = 60,
|
||||
health_check_endpoint = String::from("/health"),
|
||||
disable_health_check = false,
|
||||
enable_igw = false,
|
||||
queue_size = 100,
|
||||
queue_timeout_secs = 60,
|
||||
@@ -777,6 +780,7 @@ impl Router {
|
||||
health_check_timeout_secs: u64,
|
||||
health_check_interval_secs: u64,
|
||||
health_check_endpoint: String,
|
||||
disable_health_check: bool,
|
||||
enable_igw: bool,
|
||||
queue_size: usize,
|
||||
queue_timeout_secs: u64,
|
||||
@@ -875,6 +879,7 @@ impl Router {
|
||||
health_check_timeout_secs,
|
||||
health_check_interval_secs,
|
||||
health_check_endpoint,
|
||||
disable_health_check,
|
||||
enable_igw,
|
||||
queue_size,
|
||||
queue_timeout_secs,
|
||||
|
||||
@@ -86,6 +86,7 @@ class RouterArgs:
|
||||
health_check_timeout_secs: int = 5
|
||||
health_check_interval_secs: int = 60
|
||||
health_check_endpoint: str = "/health"
|
||||
disable_health_check: bool = False
|
||||
# Circuit breaker configuration
|
||||
cb_failure_threshold: int = 10
|
||||
cb_success_threshold: int = 3
|
||||
@@ -599,6 +600,12 @@ class RouterArgs:
|
||||
default=RouterArgs.health_check_endpoint,
|
||||
help="Health check endpoint path",
|
||||
)
|
||||
health_group.add_argument(
|
||||
f"--{prefix}disable-health-check",
|
||||
action="store_true",
|
||||
default=RouterArgs.disable_health_check,
|
||||
help="Disable all worker health checks at startup",
|
||||
)
|
||||
# Tokenizer configuration
|
||||
tokenizer_group.add_argument(
|
||||
f"--{prefix}model-path",
|
||||
|
||||
Reference in New Issue
Block a user