Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
noyoshi committed Nov 8, 2024
1 parent a2e14ce commit a4183eb
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
9 changes: 7 additions & 2 deletions router/src/health.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
use lorax_client::{
Batch, NextTokenChooserParameters, Request, ShardInfo, ShardedClient,
StoppingCriteriaParameters,
StoppingCriteriaParameters, Cl
};
use crate::{
ClassifyRequest, EmbedRequest
}
use std::sync::atomic::{AtomicBool, Ordering};
use std::sync::Arc;

Expand Down Expand Up @@ -123,6 +126,8 @@ impl Health {
self.generation_health.store(value, Ordering::SeqCst);
return value
}
// Return false - need to implement that shard type.
return false
}
}
}
}
3 changes: 1 addition & 2 deletions router/src/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -550,8 +550,7 @@ example = json ! ({"error": "unhealthy", "error_type": "healthcheck"})),
)]
/// Health check method
async fn health(
infer: Extension<Infer>,
health: Extension<Health>,
mut health: Extension<Health>,
) -> Result<(), (StatusCode, Json<ErrorResponse>)> {
match health.check().await {
true => Ok(()),
Expand Down

0 comments on commit a4183eb

Please sign in to comment.