Skip to content

Commit

Permalink
Fix tokio-uring & QUIC to use GSO & GRO properly.
Browse files Browse the repository at this point in the history
Requires 'quinn' to be closed at ../quinn & at the latest version
  • Loading branch information
Icelk committed Sep 14, 2023
1 parent 78d1fd1 commit 2babd07
Show file tree
Hide file tree
Showing 3 changed files with 200 additions and 82 deletions.
7 changes: 6 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,12 @@ futures-util = { version = "0.3", optional = true, default-features = false, fea
# HTTP/3
h3 = { version = "0.0.2", optional = true }
h3-quinn = { version = "0.0.3", optional = true }
quinn = { version = "0.10.1", default-features = false, features = ["tls-rustls", "log", "runtime-tokio"], optional = true }
quinn = { version = "0.10.2", default-features = false, features = ["tls-rustls", "log", "runtime-tokio"], optional = true }

[replace]
"quinn-udp:0.4.0" = { path = "../quinn/quinn-udp" }
"quinn:0.10.2" = { path = "../quinn/quinn" }
"quinn-proto:0.10.4" = { path = "../quinn/quinn-proto" }

[target.'cfg(unix)'.dependencies]
libc = { version = "0.2", default-features = false }
Expand Down
12 changes: 7 additions & 5 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -296,11 +296,13 @@ impl RunConfig {
Some(h3_quinn::quinn::ServerConfig::with_crypto(
descriptor.server_config.clone().unwrap(),
)),
uring_udp::UringUdpSocket::new(
tokio_uring::net::UdpSocket::from_std(socket.into()),
address.is_ipv4(),
)
.expect("failed to change socket settings"),
Arc::new(
uring_udp::UringUdpSocket::new(
tokio_uring::net::UdpSocket::from_std(socket.into()),
address.is_ipv4(),
)
.expect("failed to change socket settings"),
),
h3_quinn::quinn::default_runtime().unwrap(),
)
.unwrap();
Expand Down
Loading

0 comments on commit 2babd07

Please sign in to comment.