From 2f5ce0a97decec2b895157b2457e69d24687ea8e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Oliveira?= Date: Thu, 21 Mar 2024 10:27:34 +0000 Subject: [PATCH 1/5] deps: bump opentelemetry dependency (#5181) ## Description Updates `opentelemetry-otlp` from 0.13.0 to 0.14.0 Changes `opentelemetry` to `opentelemetry_sdk` dependency and updates to 0.21.0 Changes `opentelemetry_api` to `opentelemetry` and updates to 0.21.0 see https://github.com/open-telemetry/opentelemetry-rust/issues/1186 for more info superseeds https://github.com/libp2p/rust-libp2p/pull/4858 --- Cargo.lock | 92 ++++++++++++++++-------------------- examples/metrics/Cargo.toml | 8 ++-- examples/metrics/src/main.rs | 14 ++---- 3 files changed, 50 insertions(+), 64 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 52913f9796e7..c872cdb48ca7 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -3672,7 +3672,7 @@ dependencies = [ "libp2p", "opentelemetry", "opentelemetry-otlp", - "opentelemetry_api", + "opentelemetry_sdk", "prometheus-client", "tokio", "tracing", @@ -4050,26 +4050,32 @@ dependencies = [ [[package]] name = "opentelemetry" -version = "0.20.0" +version = "0.21.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9591d937bc0e6d2feb6f71a559540ab300ea49955229c347a517a28d27784c54" +checksum = "1e32339a5dc40459130b3bd269e9892439f55b33e772d2a9d402a789baaf4e8a" dependencies = [ - "opentelemetry_api", - "opentelemetry_sdk", + "futures-core", + "futures-sink", + "indexmap 2.2.1", + "js-sys", + "once_cell", + "pin-project-lite", + "thiserror", + "urlencoding", ] [[package]] name = "opentelemetry-otlp" -version = "0.13.0" +version = "0.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e5e5a5c4135864099f3faafbe939eb4d7f9b80ebf68a8448da961b32a7c1275" +checksum = "f24cda83b20ed2433c68241f918d0f6fdec8b1d43b7a9590ab4420c5095ca930" dependencies = [ "async-trait", "futures-core", "http 0.2.9", + "opentelemetry", "opentelemetry-proto", "opentelemetry-semantic-conventions", - "opentelemetry_api", "opentelemetry_sdk", "prost", "thiserror", @@ -4079,11 +4085,11 @@ dependencies = [ [[package]] name = "opentelemetry-proto" -version = "0.3.0" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1e3f814aa9f8c905d0ee4bde026afd3b2577a97c10e1699912e3e44f0c4cbeb" +checksum = "a2e155ce5cc812ea3d1dffbd1539aed653de4bf4882d60e6e04dcf0901d674e1" dependencies = [ - "opentelemetry_api", + "opentelemetry", "opentelemetry_sdk", "prost", "tonic", @@ -4091,47 +4097,30 @@ dependencies = [ [[package]] name = "opentelemetry-semantic-conventions" -version = "0.12.0" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73c9f9340ad135068800e7f1b24e9e09ed9e7143f5bf8518ded3d3ec69789269" +checksum = "f5774f1ef1f982ef2a447f6ee04ec383981a3ab99c8e77a1a7b30182e65bbc84" dependencies = [ "opentelemetry", ] -[[package]] -name = "opentelemetry_api" -version = "0.20.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a81f725323db1b1206ca3da8bb19874bbd3f57c3bcd59471bfb04525b265b9b" -dependencies = [ - "futures-channel", - "futures-util", - "indexmap 1.9.3", - "js-sys", - "once_cell", - "pin-project-lite", - "thiserror", - "urlencoding", -] - [[package]] name = "opentelemetry_sdk" -version = "0.20.0" +version = "0.21.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa8e705a0612d48139799fcbaba0d4a90f06277153e43dd2bdc16c6f0edd8026" +checksum = "2f16aec8a98a457a52664d69e0091bac3a0abd18ead9b641cb00202ba4e0efe4" dependencies = [ "async-trait", "crossbeam-channel", "futures-channel", "futures-executor", "futures-util", + "glob", "once_cell", - "opentelemetry_api", + "opentelemetry", "ordered-float", "percent-encoding", "rand 0.8.5", - "regex", - "serde_json", "thiserror", "tokio", "tokio-stream", @@ -4139,9 +4128,9 @@ dependencies = [ [[package]] name = "ordered-float" -version = "3.9.2" +version = "4.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1e1c390732d15f1d48471625cd92d154e66db2c56645e29a9cd26f4699f72dc" +checksum = "a76df7075c7d4d01fdcb46c912dd17fba5b60c78ea480b475f2b6ab6f666584e" dependencies = [ "num-traits", ] @@ -6041,17 +6030,6 @@ dependencies = [ "valuable", ] -[[package]] -name = "tracing-log" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" -dependencies = [ - "lazy_static", - "log", - "tracing-core", -] - [[package]] name = "tracing-log" version = "0.2.0" @@ -6065,18 +6043,20 @@ dependencies = [ [[package]] name = "tracing-opentelemetry" -version = "0.21.0" +version = "0.22.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75327c6b667828ddc28f5e3f169036cb793c3f588d83bf0f262a7f062ffed3c8" +checksum = "c67ac25c5407e7b961fafc6f7e9aa5958fd297aada2d20fa2ae1737357e55596" dependencies = [ + "js-sys", "once_cell", "opentelemetry", "opentelemetry_sdk", "smallvec", "tracing", "tracing-core", - "tracing-log 0.1.3", + "tracing-log", "tracing-subscriber", + "web-time", ] [[package]] @@ -6094,7 +6074,7 @@ dependencies = [ "thread_local", "tracing", "tracing-core", - "tracing-log 0.2.0", + "tracing-log", ] [[package]] @@ -6470,6 +6450,16 @@ dependencies = [ "wasm-bindgen", ] +[[package]] +name = "web-time" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa30049b1c872b72c89866d458eae9f20380ab280ffd1b1e18df2d3e2d98cfe0" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + [[package]] name = "webpki-roots" version = "0.25.2" diff --git a/examples/metrics/Cargo.toml b/examples/metrics/Cargo.toml index 39412d29aeaf..499e1fb7f4bb 100644 --- a/examples/metrics/Cargo.toml +++ b/examples/metrics/Cargo.toml @@ -12,13 +12,13 @@ release = false futures = "0.3.30" hyper = { version = "0.14", features = ["server", "tcp", "http1"] } libp2p = { path = "../../libp2p", features = ["tokio", "metrics", "ping", "noise", "identify", "tcp", "yamux", "macros"] } -opentelemetry = { version = "0.20.0", features = ["rt-tokio", "metrics"] } -opentelemetry-otlp = { version = "0.13.0", features = ["metrics"]} -opentelemetry_api = "0.20.0" +opentelemetry = { version = "0.21.0", features = ["metrics"] } +opentelemetry-otlp = { version = "0.14.0", features = ["metrics"] } +opentelemetry_sdk = { version = "0.21.2", features = ["rt-tokio", "metrics"] } prometheus-client = { workspace = true } tokio = { version = "1", features = ["full"] } tracing = "0.1.37" -tracing-opentelemetry = "0.21.0" +tracing-opentelemetry = "0.22.0" tracing-subscriber = { version = "0.3", features = ["env-filter"] } [lints] diff --git a/examples/metrics/src/main.rs b/examples/metrics/src/main.rs index 3ab6815cb32d..6b7ad9cedfb2 100644 --- a/examples/metrics/src/main.rs +++ b/examples/metrics/src/main.rs @@ -25,8 +25,7 @@ use libp2p::core::Multiaddr; use libp2p::metrics::{Metrics, Recorder}; use libp2p::swarm::{NetworkBehaviour, SwarmEvent}; use libp2p::{identify, identity, noise, ping, tcp, yamux}; -use opentelemetry::sdk; -use opentelemetry_api::KeyValue; +use opentelemetry::KeyValue; use prometheus_client::registry::Registry; use std::error::Error; use std::time::Duration; @@ -87,13 +86,10 @@ fn setup_tracing() -> Result<(), Box> { let tracer = opentelemetry_otlp::new_pipeline() .tracing() .with_exporter(opentelemetry_otlp::new_exporter().tonic()) - .with_trace_config( - sdk::trace::Config::default().with_resource(sdk::Resource::new(vec![KeyValue::new( - "service.name", - "libp2p", - )])), - ) - .install_batch(opentelemetry::runtime::Tokio)?; + .with_trace_config(opentelemetry_sdk::trace::Config::default().with_resource( + opentelemetry_sdk::Resource::new(vec![KeyValue::new("service.name", "libp2p")]), + )) + .install_batch(opentelemetry_sdk::runtime::Tokio)?; tracing_subscriber::registry() .with(tracing_subscriber::fmt::layer().with_filter(EnvFilter::from_default_env())) From 46a043e8cba256c6c3f0e77cec4aa751f546df81 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 21 Mar 2024 10:40:53 +0000 Subject: [PATCH 2/5] deps: bump obi1kenobi/cargo-semver-checks-action from 2.3 to 2.4 Pull-Request: #5249. --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 24a211966a80..a489fec1f1ff 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -319,7 +319,7 @@ jobs: - uses: actions/checkout@v4 - run: wget -q -O- https://github.com/obi1kenobi/cargo-semver-checks/releases/download/v0.27.0/cargo-semver-checks-x86_64-unknown-linux-gnu.tar.gz | tar -xz -C ~/.cargo/bin shell: bash - - uses: obi1kenobi/cargo-semver-checks-action@48f4ef7da6d907d69d18249e0ba79aa98c61b9db # v2 + - uses: obi1kenobi/cargo-semver-checks-action@c7306483f698c511eaf7416d1bf2e1958c90140f # v2 rustfmt: runs-on: ubuntu-latest From 4a6d59c51b9a36540b2ddb29303088622def01a1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 21 Mar 2024 11:13:38 +0000 Subject: [PATCH 3/5] deps: bump wasm-bindgen-test from 0.3.41 to 0.3.42 Pull-Request: #5241. --- Cargo.lock | 8 ++++---- wasm-tests/webtransport-tests/Cargo.toml | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index c872cdb48ca7..a6ba0896894f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -6406,9 +6406,9 @@ checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" [[package]] name = "wasm-bindgen-test" -version = "0.3.41" +version = "0.3.42" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "143ddeb4f833e2ed0d252e618986e18bfc7b0e52f2d28d77d05b2f045dd8eb61" +checksum = "d9bf62a58e0780af3e852044583deee40983e5886da43a271dd772379987667b" dependencies = [ "console_error_panic_hook", "js-sys", @@ -6420,9 +6420,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-test-macro" -version = "0.3.41" +version = "0.3.42" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5211b7550606857312bba1d978a8ec75692eae187becc5e680444fffc5e6f89" +checksum = "b7f89739351a2e03cb94beb799d47fb2cac01759b40ec441f7de39b00cbf7ef0" dependencies = [ "proc-macro2", "quote", diff --git a/wasm-tests/webtransport-tests/Cargo.toml b/wasm-tests/webtransport-tests/Cargo.toml index b98e56440b16..918df42bef7d 100644 --- a/wasm-tests/webtransport-tests/Cargo.toml +++ b/wasm-tests/webtransport-tests/Cargo.toml @@ -19,7 +19,7 @@ multiaddr = { workspace = true } multihash = { workspace = true } wasm-bindgen = "0.2.90" wasm-bindgen-futures = "0.4.42" -wasm-bindgen-test = "0.3.41" +wasm-bindgen-test = "0.3.42" web-sys = { version = "0.3.68", features = ["Response", "Window"] } [lints] From cdafe0e63a9e4fd9cd58d35f28f716c9f8edef3c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 21 Mar 2024 11:25:25 +0000 Subject: [PATCH 4/5] deps: bump heck from 0.4.1 to 0.5.0 Pull-Request: #5240. --- Cargo.lock | 14 ++++++++++---- swarm-derive/Cargo.toml | 2 +- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index a6ba0896894f..d02ad913326a 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -933,7 +933,7 @@ version = "4.4.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cf9804afaaf59a91e75b022a30fb7229a7901f60c755489cc61c9b423b836442" dependencies = [ - "heck", + "heck 0.4.1", "proc-macro2", "quote", "syn 2.0.52", @@ -1421,7 +1421,7 @@ version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5ffccbb6966c05b32ef8fbac435df276c4ae4d3dc55a8cd0eb9745e6c12f546a" dependencies = [ - "heck", + "heck 0.4.1", "proc-macro2", "quote", "syn 2.0.52", @@ -1895,6 +1895,12 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + [[package]] name = "hermit-abi" version = "0.3.2" @@ -3260,7 +3266,7 @@ dependencies = [ name = "libp2p-swarm-derive" version = "0.34.3" dependencies = [ - "heck", + "heck 0.5.0", "proc-macro2", "quote", "syn 2.0.52", @@ -5547,7 +5553,7 @@ version = "0.25.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "23dc1fa9ac9c169a78ba62f0b841814b7abae11bdd047b9c58f893439e309ea0" dependencies = [ - "heck", + "heck 0.4.1", "proc-macro2", "quote", "rustversion", diff --git a/swarm-derive/Cargo.toml b/swarm-derive/Cargo.toml index b2906e9de96d..d2d8796acb36 100644 --- a/swarm-derive/Cargo.toml +++ b/swarm-derive/Cargo.toml @@ -14,7 +14,7 @@ categories = ["network-programming", "asynchronous"] proc-macro = true [dependencies] -heck = "0.4" +heck = "0.5" quote = "1.0" syn = { version = "2.0.52", default-features = false, features = ["clone-impls", "derive", "parsing", "printing", "proc-macro"] } proc-macro2 = "1.0" From a579e691c46a8efd2e38ebafca1c59a9b58fc56c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 21 Mar 2024 15:14:00 +0000 Subject: [PATCH 5/5] deps: bump reqwest from 0.11.25 to 0.11.26 Pull-Request: #5239. --- Cargo.lock | 31 +++++-------------------------- 1 file changed, 5 insertions(+), 26 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index d02ad913326a..4554147f4e45 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2274,7 +2274,7 @@ dependencies = [ "log", "rtnetlink", "smol", - "system-configuration 0.5.1", + "system-configuration", "tokio", "windows", ] @@ -4804,9 +4804,9 @@ dependencies = [ [[package]] name = "reqwest" -version = "0.11.25" +version = "0.11.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0eea5a9eb898d3783f17c6407670e3592fd174cb81a10e51d4c37f49450b9946" +checksum = "78bf93c4af7a8bb7d879d51cebe797356ff10ae8516ace542b5182d9dcac10b2" dependencies = [ "base64 0.21.7", "bytes", @@ -4833,7 +4833,7 @@ dependencies = [ "serde_json", "serde_urlencoded", "sync_wrapper", - "system-configuration 0.6.0", + "system-configuration", "tokio", "tokio-native-tls", "tokio-rustls", @@ -5657,18 +5657,7 @@ checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" dependencies = [ "bitflags 1.3.2", "core-foundation", - "system-configuration-sys 0.5.0", -] - -[[package]] -name = "system-configuration" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "658bc6ee10a9b4fcf576e9b0819d95ec16f4d2c02d39fd83ac1c8789785c4a42" -dependencies = [ - "bitflags 2.4.1", - "core-foundation", - "system-configuration-sys 0.6.0", + "system-configuration-sys", ] [[package]] @@ -5681,16 +5670,6 @@ dependencies = [ "libc", ] -[[package]] -name = "system-configuration-sys" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e1d1b10ced5ca923a1fcb8d03e96b8d3268065d724548c0211415ff6ac6bac4" -dependencies = [ - "core-foundation-sys", - "libc", -] - [[package]] name = "tempfile" version = "3.10.1"