Skip to content

Commit b79969b

Browse files
djcrami3l
authored andcommitted
Enable HTTP/2 support for reqwest download backend
1 parent a0946f0 commit b79969b

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

Cargo.lock

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ pulldown-cmark = { version = "0.13", default-features = false }
6767
rand = "0.9"
6868
regex = "1"
6969
remove_dir_all = { version = "1.0.0", features = ["parallel"] }
70-
reqwest = { version = "0.12", default-features = false, features = ["blocking", "gzip", "socks", "stream"], optional = true }
70+
reqwest = { version = "0.12", default-features = false, features = ["blocking", "gzip", "http2", "socks", "stream"], optional = true }
7171
retry = { version = "2", default-features = false, features = ["random"] }
7272
rs_tracing = { version = "1.1", features = ["rs_tracing"] }
7373
rustls = { version = "0.23", optional = true, default-features = false, features = ["logging", "aws_lc_rs", "tls12"] }

src/download/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -587,7 +587,7 @@ mod reqwest_be {
587587
.unwrap()
588588
.with_platform_verifier()
589589
.with_no_client_auth();
590-
tls_config.alpn_protocols = vec![b"http/1.1".to_vec()];
590+
tls_config.alpn_protocols = vec![b"h2".to_vec(), b"http/1.1".to_vec()];
591591

592592
let catcher = || {
593593
client_generic()

0 commit comments

Comments
 (0)