use latest hyper master branch to include socket buffer size fix

This commit is contained in:
Dietmar Maurer 2019-07-02 07:09:46 +02:00
parent f35197f449
commit 8fad30a4b1
2 changed files with 3 additions and 0 deletions

View File

@ -57,3 +57,5 @@ valgrind = ["valgrind_request"]
[replace] [replace]
"zstd-sys:1.4.10" = { path = "zstd-sys" } "zstd-sys:1.4.10" = { path = "zstd-sys" }
# include socket buffer size fix
"hyper:0.12.31" = { git = "https://github.com/hyperium/hyper.git" }

View File

@ -163,6 +163,7 @@ impl HttpClient {
let tlsconnector = builder.build().unwrap(); let tlsconnector = builder.build().unwrap();
let mut httpc = hyper::client::HttpConnector::new(1); let mut httpc = hyper::client::HttpConnector::new(1);
httpc.set_nodelay(true); // important for h2 download performance! httpc.set_nodelay(true); // important for h2 download performance!
httpc.set_recv_buf_size(Some(1024*1024)); //important for h2 download performance!
httpc.enforce_http(false); // we want https... httpc.enforce_http(false); // we want https...
let mut https = hyper_tls::HttpsConnector::from((httpc, tlsconnector)); let mut https = hyper_tls::HttpsConnector::from((httpc, tlsconnector));
https.https_only(true); // force it! https.https_only(true); // force it!