File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -376,6 +376,8 @@ async fn main() -> Result<()> {
376376 too_many_requests : Arc :: new ( DashSet :: new ( ) ) ,
377377 too_many_requests_timeout_ms : u128:: from ( config. service . too_many_requests_timeout_ms ) ,
378378 running_num_requests : Arc :: new ( RequestCounter :: new ( ) ) ,
379+ lower_memory_threshold : config. service . lower_memory_threshold ,
380+ upper_memory_threshold : config. service . upper_memory_threshold ,
379381 } ;
380382
381383 let chat_completions_service_urls = app_state
Original file line number Diff line number Diff line change @@ -60,6 +60,11 @@ pub struct AtomaServiceConfig {
6060
6161 /// The timeout for the too many requests error in milliseconds.
6262 pub too_many_requests_timeout_ms : u64 ,
63+
64+ ///Lower threshold for memory usage, if the memory usage goes below this value, the service will not be considered overloaded
65+ pub lower_memory_threshold : f64 ,
66+ /// Upper threshold for memory usage, if the memory usage goes above this value, the service will be considered overloaded
67+ pub upper_memory_threshold : f64 ,
6368}
6469
6570impl AtomaServiceConfig {
You can’t perform that action at this time.
0 commit comments