chore: update actix-rt, remove tokio 0.2 from workspace

This commit is contained in:
Ryan Leckey 2021-01-10 11:34:39 -08:00
parent 7144ebc8a0
commit 6adf743225
No known key found for this signature in database
GPG Key ID: F8AA68C235AB08C9
3 changed files with 51 additions and 253 deletions

296
Cargo.lock generated
View File

@ -2,9 +2,9 @@
# It is not intended for manual editing.
[[package]]
name = "actix-macros"
version = "0.1.3"
version = "0.2.0-beta.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b4ca8ce00b267af8ccebbd647de0d61e0674b6e61185cc7a592ff88772bed655"
checksum = "32d550809c1471a3ed937cb2afefd7cba179a6ac4a0cb46361b3541bfcad7084"
dependencies = [
"quote",
"syn",
@ -12,32 +12,12 @@ dependencies = [
[[package]]
name = "actix-rt"
version = "1.1.1"
version = "2.0.0-beta.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "143fcc2912e0d1de2bcf4e2f720d2a60c28652ab4179685a1ee159e0fb3db227"
checksum = "ac24f3f660d4c394cc6d24272e526083c257d6045d3be76a9d0a76be5cb56515"
dependencies = [
"actix-macros",
"actix-threadpool",
"copyless",
"futures-channel",
"futures-util",
"smallvec",
"tokio 0.2.24",
]
[[package]]
name = "actix-threadpool"
version = "0.3.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d209f04d002854b9afd3743032a27b066158817965bf5d036824d19ac2cc0e30"
dependencies = [
"derive_more",
"futures-channel",
"lazy_static",
"log",
"num_cpus",
"parking_lot",
"threadpool",
"tokio",
]
[[package]]
@ -55,6 +35,16 @@ version = "1.0.37"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ee67c11feeac938fae061b232e38e0b6d94f97a9df10e6271319325ac4c56a86"
[[package]]
name = "async-attributes"
version = "1.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "efd3d156917d94862e779f356c5acae312b08fd3121e792c857d7928c8088423"
dependencies = [
"quote",
"syn",
]
[[package]]
name = "async-channel"
version = "1.5.1"
@ -66,19 +56,6 @@ dependencies = [
"futures-core",
]
[[package]]
name = "async-compat"
version = "0.1.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3f0bb3019d8e5ffe88594b122ba9ba37280a3bc8d94a742b56c8417457215ae4"
dependencies = [
"futures-core",
"futures-io",
"once_cell",
"pin-project-lite 0.1.11",
"tokio 0.2.24",
]
[[package]]
name = "async-compat"
version = "0.1.5"
@ -87,8 +64,8 @@ dependencies = [
"futures-core",
"futures-io",
"once_cell",
"pin-project-lite 0.2.1",
"tokio 1.0.1",
"pin-project-lite",
"tokio",
]
[[package]]
@ -135,7 +112,7 @@ dependencies = [
"polling",
"vec-arena",
"waker-fn",
"winapi 0.3.9",
"winapi",
]
[[package]]
@ -153,6 +130,7 @@ version = "1.8.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8f9f84f1280a2b436a2c77c2582602732b6c2f4321d5494d6e799e6c367859a8"
dependencies = [
"async-attributes",
"async-channel",
"async-global-executor",
"async-io",
@ -169,7 +147,7 @@ dependencies = [
"memchr",
"num_cpus",
"once_cell",
"pin-project-lite 0.2.1",
"pin-project-lite",
"pin-utils",
"slab",
"wasm-bindgen-futures",
@ -195,7 +173,7 @@ checksum = "d9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8"
dependencies = [
"hermit-abi",
"libc",
"winapi 0.3.9",
"winapi",
]
[[package]]
@ -257,12 +235,6 @@ version = "1.4.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ae44d1a3d5a19df61dd0c8beb138458ac2a53a7ac09eba97d55592540004306b"
[[package]]
name = "bytes"
version = "0.5.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0e4cec68f03f32e44924783795810fa50a7035d8c8ebe78580ad7e6c703fba38"
[[package]]
name = "bytes"
version = "1.0.0"
@ -275,7 +247,7 @@ version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "90706ba19e97b90786e19dc0d5e2abd80008d99d4c0c5d1ad0b5e72cec7c494d"
dependencies = [
"bytes 1.0.0",
"bytes",
]
[[package]]
@ -312,7 +284,7 @@ dependencies = [
"num-integer",
"num-traits",
"time",
"winapi 0.3.9",
"winapi",
]
[[package]]
@ -345,12 +317,6 @@ version = "0.4.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "28b9d6de7f49e22cf97ad17fc4036ece69300032f45f78f30b4a4482cdc3f4a6"
[[package]]
name = "copyless"
version = "0.1.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a2df960f5d869b2dd8532793fde43eb5427cceb126c929747a26823ab0eeb536"
[[package]]
name = "cpuid-bool"
version = "0.1.2"
@ -427,17 +393,6 @@ dependencies = [
"lazy_static",
]
[[package]]
name = "derive_more"
version = "0.99.11"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "41cb0e6161ad61ed084a36ba71fbba9e3ac5aee3606fb607fe08da6acbcf3d8c"
dependencies = [
"proc-macro2",
"quote",
"syn",
]
[[package]]
name = "digest"
version = "0.9.0"
@ -491,22 +446,6 @@ dependencies = [
"percent-encoding",
]
[[package]]
name = "fuchsia-zircon"
version = "0.3.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2e9763c69ebaae630ba35f74888db465e49e259ba1bc0eda7d06f4a067615d82"
dependencies = [
"bitflags",
"fuchsia-zircon-sys",
]
[[package]]
name = "fuchsia-zircon-sys"
version = "0.3.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3dcaa9ae7725d12cdb85b3ad99a434db70b468c09ded17e012d86b5c1010f7a7"
[[package]]
name = "futures-channel"
version = "0.3.9"
@ -550,7 +489,7 @@ dependencies = [
"futures-io",
"memchr",
"parking",
"pin-project-lite 0.2.1",
"pin-project-lite",
"waker-fn",
]
@ -586,7 +525,7 @@ dependencies = [
"futures-macro",
"futures-task",
"memchr",
"pin-project-lite 0.2.1",
"pin-project-lite",
"pin-utils",
"proc-macro-hack",
"proc-macro-nested",
@ -662,15 +601,6 @@ dependencies = [
"cfg-if 1.0.0",
]
[[package]]
name = "iovec"
version = "0.1.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b2b3ea6ff95e175473f8ffe6a7eb7c00d054240321b84c57051175fe3c1e075e"
dependencies = [
"libc",
]
[[package]]
name = "js-sys"
version = "0.3.46"
@ -680,16 +610,6 @@ dependencies = [
"wasm-bindgen",
]
[[package]]
name = "kernel32-sys"
version = "0.2.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d"
dependencies = [
"winapi 0.2.8",
"winapi-build",
]
[[package]]
name = "kv-log-macro"
version = "1.0.7"
@ -759,25 +679,6 @@ dependencies = [
"autocfg 1.0.1",
]
[[package]]
name = "mio"
version = "0.6.23"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4afd66f5b91bf2a3bc13fad0e21caedac168ca4c707504e75585648ae80e4cc4"
dependencies = [
"cfg-if 0.1.10",
"fuchsia-zircon",
"fuchsia-zircon-sys",
"iovec",
"kernel32-sys",
"libc",
"log",
"miow 0.2.2",
"net2",
"slab",
"winapi 0.2.8",
]
[[package]]
name = "mio"
version = "0.7.7"
@ -786,32 +687,9 @@ checksum = "e50ae3f04d169fcc9bde0b547d1c205219b7157e07ded9c5aff03e0637cb3ed7"
dependencies = [
"libc",
"log",
"miow 0.3.6",
"miow",
"ntapi",
"winapi 0.3.9",
]
[[package]]
name = "mio-uds"
version = "0.6.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "afcb699eb26d4332647cc848492bbc15eafb26f08d0304550d5aa1f612e066f0"
dependencies = [
"iovec",
"libc",
"mio 0.6.23",
]
[[package]]
name = "miow"
version = "0.2.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ebd808424166322d4a38da87083bfddd3ac4c131334ed55856112eb06d46944d"
dependencies = [
"kernel32-sys",
"net2",
"winapi 0.2.8",
"ws2_32-sys",
"winapi",
]
[[package]]
@ -821,7 +699,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5a33c1b55807fbed163481b5ba66db4b2fa6cde694a5027be10fb724206c5897"
dependencies = [
"socket2",
"winapi 0.3.9",
"winapi",
]
[[package]]
@ -831,18 +709,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8123a81538e457d44b933a02faf885d3fe8408806b23fa700e8f01c6c3a98998"
dependencies = [
"libc",
"winapi 0.3.9",
]
[[package]]
name = "net2"
version = "0.2.37"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "391630d12b68002ae1e25e8f974306474966550ad82dac6886fb8910c19568ae"
dependencies = [
"cfg-if 0.1.10",
"libc",
"winapi 0.3.9",
"winapi",
]
[[package]]
@ -851,7 +718,7 @@ version = "0.3.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3f6bb902e437b6d86e03cce10a7e2af662292c5dfef23b65899ea3ac9354ad44"
dependencies = [
"winapi 0.3.9",
"winapi",
]
[[package]]
@ -964,7 +831,7 @@ dependencies = [
"libc",
"redox_syscall",
"smallvec",
"winapi 0.3.9",
"winapi",
]
[[package]]
@ -986,15 +853,9 @@ checksum = "d4fd5641d01c8f18a23da7b6fe29298ff4b55afcccdf78973b24cf3175fee32e"
[[package]]
name = "pin-project-lite"
version = "0.1.11"
version = "0.2.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "c917123afa01924fc84bb20c4c03f004d9c38e5127e3c039bbf7f4b9c76a2f6b"
[[package]]
name = "pin-project-lite"
version = "0.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e36743d754ccdf9954c2e352ce2d4b106e024c814f6499c2dadff80da9a442d8"
checksum = "ba36e0a6cc5a4c645073f4984f1ed55d09f5857d4de7c14550baa81a39ef5a17"
[[package]]
name = "pin-utils"
@ -1012,7 +873,7 @@ dependencies = [
"libc",
"log",
"wepoll-sys",
"winapi 0.3.9",
"winapi",
]
[[package]]
@ -1216,7 +1077,7 @@ checksum = "122e570113d28d773067fab24266b66753f6ea915758651696b6e35e49f88d6e"
dependencies = [
"cfg-if 1.0.0",
"libc",
"winapi 0.3.9",
"winapi",
]
[[package]]
@ -1238,10 +1099,9 @@ name = "sqlx-core"
version = "0.6.0-pre"
dependencies = [
"actix-rt",
"async-compat 0.1.4",
"async-compat 0.1.5",
"async-compat",
"async-std",
"bytes 1.0.0",
"bytes",
"bytestring",
"conquer-once",
"crossbeam",
@ -1251,8 +1111,7 @@ dependencies = [
"log",
"memchr",
"parking_lot",
"tokio 0.2.24",
"tokio 1.0.1",
"tokio",
]
[[package]]
@ -1260,10 +1119,10 @@ name = "sqlx-example-quickstart"
version = "0.0.0"
dependencies = [
"anyhow",
"async-std",
"env_logger",
"log",
"sqlx",
"tokio 1.0.1",
]
[[package]]
@ -1273,7 +1132,7 @@ dependencies = [
"anyhow",
"base64",
"bitflags",
"bytes 1.0.0",
"bytes",
"bytestring",
"either",
"futures-executor",
@ -1357,15 +1216,6 @@ dependencies = [
"lazy_static",
]
[[package]]
name = "threadpool"
version = "1.8.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d050e60b33d41c19108b32cea32164033a9013fe3b46cbd4457559bfbf77afaa"
dependencies = [
"num_cpus",
]
[[package]]
name = "time"
version = "0.1.44"
@ -1374,7 +1224,7 @@ checksum = "6db9e6914ab8b1ae1c260a4ae7a49b6c5611b40328a735b21862567685e73255"
dependencies = [
"libc",
"wasi 0.10.0+wasi-snapshot-preview1",
"winapi 0.3.9",
"winapi",
]
[[package]]
@ -1392,25 +1242,6 @@ version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "cda74da7e1a664f795bb1f8a87ec406fb89a02522cf6e50620d016add6dbbf5c"
[[package]]
name = "tokio"
version = "0.2.24"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "099837d3464c16a808060bb3f02263b412f6fafcb5d01c533d309985fbeebe48"
dependencies = [
"bytes 0.5.6",
"futures-core",
"iovec",
"lazy_static",
"libc",
"mio 0.6.23",
"mio-uds",
"pin-project-lite 0.1.11",
"signal-hook-registry",
"slab",
"winapi 0.3.9",
]
[[package]]
name = "tokio"
version = "1.0.1"
@ -1419,21 +1250,12 @@ checksum = "d258221f566b6c803c7b4714abadc080172b272090cdc5e244a6d4dd13c3a6bd"
dependencies = [
"autocfg 1.0.1",
"libc",
"mio 0.7.7",
"num_cpus",
"pin-project-lite 0.2.1",
"tokio-macros",
]
[[package]]
name = "tokio-macros"
version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "42517d2975ca3114b22a16192634e8241dc5cc1f130be194645970cc1c371494"
dependencies = [
"proc-macro2",
"quote",
"syn",
"mio",
"once_cell",
"parking_lot",
"pin-project-lite",
"signal-hook-registry",
"winapi",
]
[[package]]
@ -1593,12 +1415,6 @@ dependencies = [
"cc",
]
[[package]]
name = "winapi"
version = "0.2.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "167dc9d6949a9b857f3451275e911c3f44255842c1f7a76f33c55103a909087a"
[[package]]
name = "winapi"
version = "0.3.9"
@ -1609,12 +1425,6 @@ dependencies = [
"winapi-x86_64-pc-windows-gnu",
]
[[package]]
name = "winapi-build"
version = "0.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2d315eee3b34aca4797b2da6b13ed88266e6d612562a0c46390af8299fc699bc"
[[package]]
name = "winapi-i686-pc-windows-gnu"
version = "0.4.0"
@ -1627,7 +1437,7 @@ version = "0.1.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178"
dependencies = [
"winapi 0.3.9",
"winapi",
]
[[package]]
@ -1636,16 +1446,6 @@ version = "0.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
[[package]]
name = "ws2_32-sys"
version = "0.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d59cefebd0c892fa2dd6de581e937301d8552cb44489cdff035c6187cb63fa5e"
dependencies = [
"winapi 0.2.8",
"winapi-build",
]
[[package]]
name = "zeroize"
version = "1.2.0"

View File

@ -30,7 +30,7 @@ async = ["futures-util", "futures-io", "futures-core"]
# async runtimes
async-std = ["async", "_async-std"]
actix = ["async", "actix-rt", "tokio_02", "async-compat_02"]
actix = ["async", "actix-rt", "_tokio", "async-compat"]
tokio = ["async", "_tokio", "async-compat"]
# mock runtime; intended for testing drivers
@ -38,13 +38,11 @@ _mock = ["conquer-once", "parking_lot", "crossbeam"]
[dependencies]
log = "0.4.11"
actix-rt = { version = "1.1", optional = true }
actix-rt = { version = "2.0.0-beta.2", optional = true }
_async-std = { version = "1.8", optional = true, package = "async-std" }
futures-util = { version = "0.3", optional = true, features = ["io"] }
_tokio = { version = "1.0", optional = true, package = "tokio", features = ["net"] }
tokio_02 = { version = "0.2", optional = true, package = "tokio", features = ["net"] }
async-compat = { version = "*", git = "https://github.com/taiki-e/async-compat", branch = "tokio1", optional = true }
async-compat_02 = { version = "0.1", optional = true, package = "async-compat" }
futures-io = { version = "0.3", optional = true }
futures-core = { version = "0.3", optional = true }
bytes = "1.0"

View File

@ -1,7 +1,7 @@
use std::io;
use actix_rt::net::TcpStream;
use async_compat_02::Compat;
use async_compat::Compat;
use futures_util::io::{Read, Write};
use futures_util::{future::BoxFuture, AsyncReadExt, AsyncWriteExt, FutureExt, TryFutureExt};