Skip to content

Commit 339dc4a

Browse files
feat: add /decode route
1 parent 094f191 commit 339dc4a

File tree

2 files changed

+3
-15
lines changed

2 files changed

+3
-15
lines changed

router/src/http/server.rs

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ use axum::routing::{get, post};
2020
use axum::{http, Json, Router};
2121
use axum_tracing_opentelemetry::middleware::OtelAxumLayer;
2222
use futures::future::join_all;
23-
use http::header::AUTHORIZATION;
2423
use futures::FutureExt;
24+
use http::header::AUTHORIZATION;
2525
use metrics_exporter_prometheus::{PrometheusBuilder, PrometheusHandle};
2626
use std::net::SocketAddr;
2727
use std::time::{Duration, Instant};
@@ -1385,20 +1385,6 @@ pub async fn run(
13851385
// Prometheus metrics route
13861386
.route("/metrics", get(metrics));
13871387

1388-
#[cfg(feature = "google")]
1389-
{
1390-
tracing::info!("Built with `google` feature");
1391-
tracing::info!(
1392-
"Environment variables `AIP_PREDICT_ROUTE` and `AIP_HEALTH_ROUTE` will be respected."
1393-
);
1394-
if let Ok(env_predict_route) = std::env::var("AIP_PREDICT_ROUTE") {
1395-
app = app.route(&env_predict_route, post(vertex_compatibility));
1396-
}
1397-
if let Ok(env_health_route) = std::env::var("AIP_HEALTH_ROUTE") {
1398-
app = app.route(&env_health_route, get(health));
1399-
}
1400-
let mut app = Router::new().merge(base_routes);
1401-
14021388
#[cfg(feature = "google")]
14031389
{
14041390
tracing::info!("Built with `google` feature");

router/tests/common.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,8 @@ pub async fn start_server(model_id: String, revision: Option<String>, dtype: DTy
6060
8090,
6161
None,
6262
None,
63+
2_000_000,
64+
None,
6365
None,
6466
None,
6567
)

0 commit comments

Comments
 (0)