Last active
September 25, 2018 21:59
-
-
Save matthauck/e91aeaadebcde049742efc085ee9e934 to your computer and use it in GitHub Desktop.
Nested futures deadlock
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[[package]] | |
name = "arrayvec" | |
version = "0.4.7" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"nodrop 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "bitflags" | |
version = "1.0.4" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "byteorder" | |
version = "1.2.6" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "bytes" | |
version = "0.4.10" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"byteorder 1.2.6 (registry+https://github.com/rust-lang/crates.io-index)", | |
"iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "cfg-if" | |
version = "0.1.5" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "cloudabi" | |
version = "0.0.3" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "crossbeam-deque" | |
version = "0.6.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"crossbeam-epoch 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)", | |
"crossbeam-utils 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "crossbeam-epoch" | |
version = "0.5.2" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"arrayvec 0.4.7 (registry+https://github.com/rust-lang/crates.io-index)", | |
"cfg-if 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
"crossbeam-utils 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"lazy_static 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"memoffset 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
"scopeguard 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "crossbeam-utils" | |
version = "0.5.0" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "fuchsia-zircon" | |
version = "0.3.3" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)", | |
"fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "fuchsia-zircon-sys" | |
version = "0.3.3" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "futures" | |
version = "0.1.24" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "iovec" | |
version = "0.1.2" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)", | |
"winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "kernel32-sys" | |
version = "0.2.2" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
"winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "lazy_static" | |
version = "1.1.0" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "lazycell" | |
version = "1.2.0" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "libc" | |
version = "0.2.43" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "lock_api" | |
version = "0.1.3" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"owning_ref 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", | |
"scopeguard 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "log" | |
version = "0.4.5" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"cfg-if 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "memoffset" | |
version = "0.2.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "mio" | |
version = "0.6.16" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", | |
"fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", | |
"iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", | |
"kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", | |
"lazycell 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)", | |
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
"miow 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
"net2 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)", | |
"slab 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
"winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "mio-uds" | |
version = "0.6.7" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", | |
"libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)", | |
"mio 0.6.16 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "miow" | |
version = "0.2.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", | |
"net2 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)", | |
"winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
"ws2_32-sys 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "net2" | |
version = "0.2.33" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"cfg-if 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
"libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)", | |
"winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "nodrop" | |
version = "0.1.12" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "num_cpus" | |
version = "1.8.0" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "owning_ref" | |
version = "0.3.3" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"stable_deref_trait 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "parking_lot" | |
version = "0.6.4" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"lock_api 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", | |
"parking_lot_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "parking_lot_core" | |
version = "0.3.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)", | |
"rand 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
"rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)", | |
"smallvec 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
"winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "rand" | |
version = "0.5.5" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"cloudabi 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)", | |
"fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", | |
"libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)", | |
"rand_core 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
"winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "rand_core" | |
version = "0.2.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "rustc_version" | |
version = "0.2.3" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "scopeguard" | |
version = "0.3.3" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "semver" | |
version = "0.9.0" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"semver-parser 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "semver-parser" | |
version = "0.7.0" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "slab" | |
version = "0.4.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "smallvec" | |
version = "0.6.5" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"unreachable 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "stable_deref_trait" | |
version = "1.1.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "tokio" | |
version = "0.1.8" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"mio 0.6.16 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-codec 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-current-thread 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-executor 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-fs 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-io 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-reactor 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-tcp 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-threadpool 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-timer 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-udp 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-uds 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-codec" | |
version = "0.1.0" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"bytes 0.4.10 (registry+https://github.com/rust-lang/crates.io-index)", | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-io 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-current-thread" | |
version = "0.1.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-executor 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-deadlock" | |
version = "0.1.0" | |
dependencies = [ | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-executor" | |
version = "0.1.4" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-fs" | |
version = "0.1.3" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-io 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-threadpool 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-io" | |
version = "0.1.8" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"bytes 0.4.10 (registry+https://github.com/rust-lang/crates.io-index)", | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-reactor" | |
version = "0.1.5" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"crossbeam-utils 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"lazy_static 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
"mio 0.6.16 (registry+https://github.com/rust-lang/crates.io-index)", | |
"num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"parking_lot 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)", | |
"slab 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-executor 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-io 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-tcp" | |
version = "0.1.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"bytes 0.4.10 (registry+https://github.com/rust-lang/crates.io-index)", | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", | |
"mio 0.6.16 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-io 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-reactor 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-threadpool" | |
version = "0.1.6" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"crossbeam-deque 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
"crossbeam-utils 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
"num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"rand 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-executor 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-timer" | |
version = "0.2.6" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"crossbeam-utils 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"slab 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-executor 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-udp" | |
version = "0.1.2" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"bytes 0.4.10 (registry+https://github.com/rust-lang/crates.io-index)", | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
"mio 0.6.16 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-codec 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-io 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-reactor 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "tokio-uds" | |
version = "0.2.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"bytes 0.4.10 (registry+https://github.com/rust-lang/crates.io-index)", | |
"futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)", | |
"iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", | |
"libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)", | |
"log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
"mio 0.6.16 (registry+https://github.com/rust-lang/crates.io-index)", | |
"mio-uds 0.6.7 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-io 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
"tokio-reactor 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "unreachable" | |
version = "1.0.0" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"void 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "version_check" | |
version = "0.1.5" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "void" | |
version = "1.0.2" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "winapi" | |
version = "0.2.8" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "winapi" | |
version = "0.3.6" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"winapi-i686-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
"winapi-x86_64-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[[package]] | |
name = "winapi-build" | |
version = "0.1.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "winapi-i686-pc-windows-gnu" | |
version = "0.4.0" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "winapi-x86_64-pc-windows-gnu" | |
version = "0.4.0" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
[[package]] | |
name = "ws2_32-sys" | |
version = "0.2.1" | |
source = "registry+https://github.com/rust-lang/crates.io-index" | |
dependencies = [ | |
"winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", | |
"winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)", | |
] | |
[metadata] | |
"checksum arrayvec 0.4.7 (registry+https://github.com/rust-lang/crates.io-index)" = "a1e964f9e24d588183fcb43503abda40d288c8657dfc27311516ce2f05675aef" | |
"checksum bitflags 1.0.4 (registry+https://github.com/rust-lang/crates.io-index)" = "228047a76f468627ca71776ecdebd732a3423081fcf5125585bcd7c49886ce12" | |
"checksum byteorder 1.2.6 (registry+https://github.com/rust-lang/crates.io-index)" = "90492c5858dd7d2e78691cfb89f90d273a2800fc11d98f60786e5d87e2f83781" | |
"checksum bytes 0.4.10 (registry+https://github.com/rust-lang/crates.io-index)" = "0ce55bd354b095246fc34caf4e9e242f5297a7fd938b090cadfea6eee614aa62" | |
"checksum cfg-if 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "0c4e7bb64a8ebb0d856483e1e682ea3422f883c5f5615a90d51a2c82fe87fdd3" | |
"checksum cloudabi 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "ddfc5b9aa5d4507acaf872de71051dfd0e309860e88966e1051e462a077aac4f" | |
"checksum crossbeam-deque 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)" = "3486aefc4c0487b9cb52372c97df0a48b8c249514af1ee99703bf70d2f2ceda1" | |
"checksum crossbeam-epoch 0.5.2 (registry+https://github.com/rust-lang/crates.io-index)" = "30fecfcac6abfef8771151f8be4abc9e4edc112c2bcb233314cafde2680536e9" | |
"checksum crossbeam-utils 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "677d453a17e8bd2b913fa38e8b9cf04bcdbb5be790aa294f2389661d72036015" | |
"checksum fuchsia-zircon 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "2e9763c69ebaae630ba35f74888db465e49e259ba1bc0eda7d06f4a067615d82" | |
"checksum fuchsia-zircon-sys 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "3dcaa9ae7725d12cdb85b3ad99a434db70b468c09ded17e012d86b5c1010f7a7" | |
"checksum futures 0.1.24 (registry+https://github.com/rust-lang/crates.io-index)" = "0c84b40c7e2de99ffd70602db314a7a8c26b2b3d830e6f7f7a142a8860ab3ca4" | |
"checksum iovec 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "dbe6e417e7d0975db6512b90796e8ce223145ac4e33c377e4a42882a0e88bb08" | |
"checksum kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d" | |
"checksum lazy_static 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ca488b89a5657b0a2ecd45b95609b3e848cf1755da332a0da46e2b2b1cb371a7" | |
"checksum lazycell 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ddba4c30a78328befecec92fc94970e53b3ae385827d28620f0f5bb2493081e0" | |
"checksum libc 0.2.43 (registry+https://github.com/rust-lang/crates.io-index)" = "76e3a3ef172f1a0b9a9ff0dd1491ae5e6c948b94479a3021819ba7d860c8645d" | |
"checksum lock_api 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "949826a5ccf18c1b3a7c3d57692778d21768b79e46eb9dd07bfc4c2160036c54" | |
"checksum log 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)" = "d4fcce5fa49cc693c312001daf1d13411c4a5283796bac1084299ea3e567113f" | |
"checksum memoffset 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "0f9dc261e2b62d7a622bf416ea3c5245cdd5d9a7fcc428c0d06804dfce1775b3" | |
"checksum mio 0.6.16 (registry+https://github.com/rust-lang/crates.io-index)" = "71646331f2619b1026cc302f87a2b8b648d5c6dd6937846a16cc8ce0f347f432" | |
"checksum mio-uds 0.6.7 (registry+https://github.com/rust-lang/crates.io-index)" = "966257a94e196b11bb43aca423754d87429960a768de9414f3691d6957abf125" | |
"checksum miow 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "8c1f2f3b1cf331de6896aabf6e9d55dca90356cc9960cca7eaaf408a355ae919" | |
"checksum net2 0.2.33 (registry+https://github.com/rust-lang/crates.io-index)" = "42550d9fb7b6684a6d404d9fa7250c2eb2646df731d1c06afc06dcee9e1bcf88" | |
"checksum nodrop 0.1.12 (registry+https://github.com/rust-lang/crates.io-index)" = "9a2228dca57108069a5262f2ed8bd2e82496d2e074a06d1ccc7ce1687b6ae0a2" | |
"checksum num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c51a3322e4bca9d212ad9a158a02abc6934d005490c054a2778df73a70aa0a30" | |
"checksum owning_ref 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "cdf84f41639e037b484f93433aa3897863b561ed65c6e59c7073d7c561710f37" | |
"checksum parking_lot 0.6.4 (registry+https://github.com/rust-lang/crates.io-index)" = "f0802bff09003b291ba756dc7e79313e51cc31667e94afbe847def490424cde5" | |
"checksum parking_lot_core 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "ad7f7e6ebdc79edff6fdcb87a55b620174f7a989e3eb31b65231f4af57f00b8c" | |
"checksum rand 0.5.5 (registry+https://github.com/rust-lang/crates.io-index)" = "e464cd887e869cddcae8792a4ee31d23c7edd516700695608f5b98c67ee0131c" | |
"checksum rand_core 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "edecf0f94da5551fc9b492093e30b041a891657db7940ee221f9d2f66e82eef2" | |
"checksum rustc_version 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)" = "138e3e0acb6c9fb258b19b67cb8abd63c00679d2851805ea151465464fe9030a" | |
"checksum scopeguard 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)" = "94258f53601af11e6a49f722422f6e3425c52b06245a5cf9bc09908b174f5e27" | |
"checksum semver 0.9.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1d7eb9ef2c18661902cc47e535f9bc51b78acd254da71d375c2f6720d9a40403" | |
"checksum semver-parser 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3" | |
"checksum slab 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)" = "5f9776d6b986f77b35c6cf846c11ad986ff128fe0b2b63a3628e3755e8d3102d" | |
"checksum smallvec 0.6.5 (registry+https://github.com/rust-lang/crates.io-index)" = "153ffa32fd170e9944f7e0838edf824a754ec4c1fc64746fcc9fe1f8fa602e5d" | |
"checksum stable_deref_trait 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "dba1a27d3efae4351c8051072d619e3ade2820635c3958d826bfea39d59b54c8" | |
"checksum tokio 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "fbb6a6e9db2702097bfdfddcb09841211ad423b86c75b5ddaca1d62842ac492c" | |
"checksum tokio-codec 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "881e9645b81c2ce95fcb799ded2c29ffb9f25ef5bef909089a420e5961dd8ccb" | |
"checksum tokio-current-thread 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "8fdfb899688ac16f618076bd09215edbfda0fd5dfecb375b6942636cb31fa8a7" | |
"checksum tokio-executor 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "84823b932d566bc3c6aa644df4ca36cb38593c50b7db06011fd4e12e31e4047e" | |
"checksum tokio-fs 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "b5cbe4ca6e71cb0b62a66e4e6f53a8c06a6eefe46cc5f665ad6f274c9906f135" | |
"checksum tokio-io 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)" = "8d6cc2de7725863c86ac71b0b9068476fec50834f055a243558ef1655bbd34cb" | |
"checksum tokio-reactor 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "4bfbaf9f260635649ec26b6fb4aded03887295ffcd999f6e43fd2c4758f758ea" | |
"checksum tokio-tcp 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "5b4c329b47f071eb8a746040465fa751bd95e4716e98daef6a9b4e434c17d565" | |
"checksum tokio-threadpool 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "a5758cecb6e0633cea5d563ac07c975e04961690b946b04fd84e7d6445a8f6af" | |
"checksum tokio-timer 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)" = "d03fa701f9578a01b7014f106b47f0a363b4727a7f3f75d666e312ab7acbbf1c" | |
"checksum tokio-udp 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "da941144b816d0dcda4db3a1ba87596e4df5e860a72b70783fe435891f80601c" | |
"checksum tokio-uds 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "424c1ed15a0132251813ccea50640b224c809d6ceafb88154c1a8775873a0e89" | |
"checksum unreachable 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "382810877fe448991dfc7f0dd6e3ae5d58088fd0ea5e35189655f84e6814fa56" | |
"checksum version_check 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "914b1a6776c4c929a602fafd8bc742e06365d4bcbe48c30f9cca5824f70dc9dd" | |
"checksum void 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)" = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d" | |
"checksum winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)" = "167dc9d6949a9b857f3451275e911c3f44255842c1f7a76f33c55103a909087a" | |
"checksum winapi 0.3.6 (registry+https://github.com/rust-lang/crates.io-index)" = "92c1eb33641e276cfa214a0522acad57be5c56b10cb348b3c5117db75f3ac4b0" | |
"checksum winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2d315eee3b34aca4797b2da6b13ed88266e6d612562a0c46390af8299fc699bc" | |
"checksum winapi-i686-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" | |
"checksum winapi-x86_64-pc-windows-gnu 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" | |
"checksum ws2_32-sys 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d59cefebd0c892fa2dd6de581e937301d8552cb44489cdff035c6187cb63fa5e" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[package] | |
name = "tokio-deadlock" | |
version = "0.1.0" | |
authors = ["Matt Hauck <[email protected]>"] | |
[dependencies] | |
tokio = "0.1.8" | |
futures = "0.1.24" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extern crate futures; | |
extern crate tokio; | |
use futures::Future; | |
use futures::sync::oneshot; | |
const NUM_THREADS: usize = 2; | |
const NUM_JOBS: u32 = 2; | |
fn main() { | |
let mut threadpool = tokio::executor::thread_pool::Builder::new(); | |
threadpool.pool_size(NUM_THREADS); | |
let mut runtime = tokio::runtime::Builder::new() | |
.threadpool_builder(threadpool) | |
.build() | |
.unwrap(); | |
// launch the main future | |
runtime.spawn(futures::future::lazy(|| { | |
run(); | |
futures::future::ok(()) | |
})); | |
runtime.shutdown_on_idle().wait().unwrap(); | |
} | |
fn run() { | |
for i in 0..NUM_JOBS { | |
// launch some future work | |
tokio::spawn(futures::future::lazy(move || { | |
println!("starting {}", i); | |
let id = do_some_future_work(i).wait().unwrap(); | |
println!("finished {} -- {}", i, id); | |
futures::future::ok(()) | |
})); | |
} | |
} | |
fn do_some_future_work(id: u32) -> oneshot::Receiver<u32> { | |
let (tx, rx) = oneshot::channel::<u32>(); | |
// launch some nested future work | |
println!("spawning another future for {}", id); | |
tokio::spawn(futures::future::lazy(move || { | |
println!("sending response from the future for {}", id); | |
tx.send(id).unwrap(); | |
futures::future::ok(()) | |
})); | |
rx | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment