Skip to content

Commit

Permalink
fix: broken graceful shutdown (#252)
Browse files Browse the repository at this point in the history
  • Loading branch information
elcharitas authored Jan 29, 2025
1 parent 866e723 commit 7c65d66
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
5 changes: 2 additions & 3 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion crates/hyper/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ keywords = ["ngyn", "run-time", "platform", "hyper", "framework"]
[dependencies]
http-body-util = { workspace = true }
hyper = { version = "1", features = ["full"] }
hyper-util = { version = "0.1", features = ["full"] }
hyper-util = { version = "0.1.10", features = ["full"] }
ngyn_shared = { version = "0.5", path = "../shared" }
tokio = { version = "1", features = ["full"] }
3 changes: 2 additions & 1 deletion crates/hyper/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ use hyper::body::Incoming;
use hyper::server::conn::http1;
use hyper::{service::service_fn, Request};
use hyper_util::rt::TokioIo;
use hyper_util::server::graceful::GracefulShutdown;
use ngyn_shared::core::engine::{NgynHttpPlatform, PlatformData};
use ngyn_shared::server::NgynResponse;
use std::sync::Arc;
Expand Down Expand Up @@ -73,7 +74,7 @@ impl HyperApplication {
http1.max_headers(max_headers);
}

let graceful = hyper_util::server::graceful::GracefulShutdown::new();
let graceful = GracefulShutdown::new();
// when this signal completes, start shutdown
let mut signal = std::pin::pin!(shutdown_signal());

Expand Down

0 comments on commit 7c65d66

Please sign in to comment.