dont remember lol
cargo devel CI / cargo CI (push) Successful in 4m38s Details

This commit is contained in:
Christoph J. Scherr 2024-09-09 14:51:52 +02:00
parent 3e27923d14
commit 88dd0f7d9c
Signed by: cscherrNT
GPG Key ID: 8E2B45BC51A27EA7
2 changed files with 3 additions and 2 deletions

View File

@ -12,5 +12,7 @@ async fn main() {
debug!("spawning data_processing task: {store:#?}");
tokio::spawn(data_processing(store.clone()));
info!("starting webserver");
warp::serve(routes(store)).run(([127, 0, 0, 1], 3030)).await;
warp::serve(get_store(store))
.run(([127, 0, 0, 1], 3030))
.await;
}

View File

@ -18,7 +18,6 @@ pub fn get_store(store: Store) -> impl Filter<Extract = impl Reply, Error = Reje
warp::path!("api" / "v1" / "store")
.and(warp::get())
.and(with_store(store))
// .and(warp::body::content_length_limit(2 << 13))
.then(|store: Store| async move {
info!("GET /api/v1/store");
warp::reply::json(&store.get().await)