feat: measured oneshots (#3902)

* overseer: remove mut in connector

* monitored oneshots

* fmt

* remove debug log

* Update node/metered-channel/src/oneshot.rs

Co-authored-by: Andronik Ordian <write@reusable.software>

* Update node/metered-channel/src/oneshot.rs

Co-authored-by: Andronik Ordian <write@reusable.software>

* avoid two Arcs

* add expects

* alt impl

* rework the measured oneshots

* address review comments, use `Measurable` where possible

* chore/tracing: move `PrettyAuthorities` construction out of tracing macros

Co-authored-by: Andronik Ordian <write@reusable.software>
This commit is contained in:
Bernhard Schuster
2021-09-29 18:06:20 +02:00
committed by GitHub
parent c57a1e7934
commit 3c8e8637ff
6 changed files with 439 additions and 6 deletions
+10 -4
View File
@@ -4120,9 +4120,14 @@ dependencies = [
name = "metered-channel"
version = "0.9.9"
dependencies = [
"assert_matches",
"derive_more",
"env_logger 0.9.0",
"futures 0.3.17",
"futures-timer 3.0.2",
"log",
"thiserror",
"tracing",
]
[[package]]
@@ -10563,18 +10568,18 @@ dependencies = [
[[package]]
name = "thiserror"
version = "1.0.26"
version = "1.0.29"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "93119e4feac1cbe6c798c34d3a53ea0026b0b1de6a120deef895137c0529bfe2"
checksum = "602eca064b2d83369e2b2f34b09c70b605402801927c65c11071ac911d299b88"
dependencies = [
"thiserror-impl",
]
[[package]]
name = "thiserror-impl"
version = "1.0.26"
version = "1.0.29"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "060d69a0afe7796bf42e9e2ff91f5ee691fb15c53d38b4b62a9a53eb23164745"
checksum = "bad553cc2c78e8de258400763a647e80e6d1b31ee237275d756f6836d204494c"
dependencies = [
"proc-macro2",
"quote",
@@ -10791,6 +10796,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "84f96e095c0c82419687c20ddf5cb3eadb61f4e1405923c9dc8e53a1adacbda8"
dependencies = [
"cfg-if 1.0.0",
"log",
"pin-project-lite 0.2.4",
"tracing-attributes",
"tracing-core",