diff options
author | Florian Klink <flokli@flokli.de> | 2024-12-04T17·12+0200 |
---|---|---|
committer | clbot <clbot@tvl.fyi> | 2024-12-04T21·52+0000 |
commit | 2879969f1b5cdc61012e08c7787a0b63a78cd248 (patch) | |
tree | 6da8f507c07488fec0a254b86c4eb98d59f26c61 | |
parent | e743e2439cd3c5b430e615c0021b47927b2dc98e (diff) |
chore(tvix): bump tower-otel-http-metrics, enable axum feature r/8982
Move back to a proper release containing the opentelemetry bump. Also enable the `axum` feature, which will give us a per-route accounting. Change-Id: Icdf4dc73588ef45b6596b320c14d9f44946327b3 Reviewed-on: https://cl.tvl.fyi/c/depot/+/12865 Reviewed-by: Ilan Joselevich <personal@ilanjoselevich.com> Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
-rw-r--r-- | tvix/Cargo.lock | 19 | ||||
-rw-r--r-- | tvix/Cargo.nix | 64 | ||||
-rw-r--r-- | tvix/Cargo.toml | 3 | ||||
-rw-r--r-- | tvix/crate-hashes.json | 1 | ||||
-rw-r--r-- | tvix/default.nix | 1 | ||||
-rw-r--r-- | tvix/nar-bridge/Cargo.toml | 2 |
6 files changed, 71 insertions, 19 deletions
diff --git a/tvix/Cargo.lock b/tvix/Cargo.lock index 73724b57a0e1..b38ff3b48d97 100644 --- a/tvix/Cargo.lock +++ b/tvix/Cargo.lock @@ -302,6 +302,7 @@ checksum = "504e3947307ac8326a5437504c517c4b56716c9d98fac0028c2acc7ca47d70ae" dependencies = [ "async-trait", "axum-core", + "axum-macros", "bytes", "futures-util", "http", @@ -373,6 +374,17 @@ dependencies = [ ] [[package]] +name = "axum-macros" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57d123550fa8d071b7255cb0cc04dc302baa6c8c4a79f55701552684d8399bce" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.79", +] + +[[package]] name = "axum-range" version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" @@ -4448,10 +4460,11 @@ checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e" [[package]] name = "tower-otel-http-metrics" -version = "0.8.0" -source = "git+https://github.com/francoposa/tower-otel-http-metrics?rev=2023a58e7287a691872f8e75f433179d29d1b439#2023a58e7287a691872f8e75f433179d29d1b439" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed0ba983713ec0f5d512dc28091fa3c1cb8fa5487de32a1b0bc0cb4159f9f89f" dependencies = [ - "futures-core", + "axum", "futures-util", "http", "opentelemetry", diff --git a/tvix/Cargo.nix b/tvix/Cargo.nix index 5045d5149ea8..32e2830d729b 100644 --- a/tvix/Cargo.nix +++ b/tvix/Cargo.nix @@ -1054,6 +1054,11 @@ rec { packageId = "axum-core"; } { + name = "axum-macros"; + packageId = "axum-macros"; + optional = true; + } + { name = "bytes"; packageId = "bytes"; } @@ -1168,6 +1173,11 @@ rec { ]; devDependencies = [ { + name = "axum-macros"; + packageId = "axum-macros"; + features = [ "__private" ]; + } + { name = "serde"; packageId = "serde"; features = [ "derive" ]; @@ -1208,7 +1218,7 @@ rec { "tracing" = [ "dep:tracing" "axum-core/tracing" ]; "ws" = [ "dep:hyper" "tokio" "dep:tokio-tungstenite" "dep:sha1" "dep:base64" ]; }; - resolvedDefaultFeatures = [ "default" "form" "http1" "http2" "json" "matched-path" "original-uri" "query" "tokio" "tower-log" "tracing" ]; + resolvedDefaultFeatures = [ "default" "form" "http1" "http2" "json" "macros" "matched-path" "original-uri" "query" "tokio" "tower-log" "tracing" ]; }; "axum-core" = rec { crateName = "axum-core"; @@ -1401,6 +1411,40 @@ rec { }; resolvedDefaultFeatures = [ "default" "tracing" "typed-header" ]; }; + "axum-macros" = rec { + crateName = "axum-macros"; + version = "0.4.2"; + edition = "2021"; + sha256 = "1klv77c889jm05bzayaaiinalarhvh2crc2w4nvp3l581xaj7lap"; + procMacro = true; + libName = "axum_macros"; + dependencies = [ + { + name = "proc-macro2"; + packageId = "proc-macro2"; + } + { + name = "quote"; + packageId = "quote"; + } + { + name = "syn"; + packageId = "syn 2.0.79"; + features = [ "full" "parsing" "extra-traits" ]; + } + ]; + devDependencies = [ + { + name = "syn"; + packageId = "syn 2.0.79"; + features = [ "full" "extra-traits" ]; + } + ]; + features = { + "__private" = [ "syn/visit-mut" ]; + }; + resolvedDefaultFeatures = [ "default" ]; + }; "axum-range" = rec { crateName = "axum-range"; version = "0.4.0"; @@ -7018,6 +7062,7 @@ rec { name = "tower-otel-http-metrics"; packageId = "tower-otel-http-metrics"; optional = true; + features = [ "axum" ]; } { name = "tracing"; @@ -14544,20 +14589,17 @@ rec { }; "tower-otel-http-metrics" = rec { crateName = "tower-otel-http-metrics"; - version = "0.8.0"; + version = "0.10.0"; edition = "2021"; - workspace_member = null; - src = pkgs.fetchgit { - url = "https://github.com/francoposa/tower-otel-http-metrics"; - rev = "2023a58e7287a691872f8e75f433179d29d1b439"; - sha256 = "1jiclkybx0fbgd6x2xfhzbq1xm3wba3vbixshqjy765c86jjffcg"; - }; + sha256 = "17zqz5cl3jy01cdjmqvx92jqzjy1lcghja6w2bazbh1yf61sj2zd"; libName = "tower_otel_http_metrics"; dependencies = [ { - name = "futures-core"; - packageId = "futures-core"; + name = "axum"; + packageId = "axum"; + optional = true; usesDefaultFeatures = false; + features = [ "matched-path" "macros" ]; } { name = "futures-util"; @@ -14600,7 +14642,7 @@ rec { features = { "axum" = [ "dep:axum" ]; }; - resolvedDefaultFeatures = [ "default" ]; + resolvedDefaultFeatures = [ "axum" "default" ]; }; "tower-service" = rec { crateName = "tower-service"; diff --git a/tvix/Cargo.toml b/tvix/Cargo.toml index 48c824bfffb8..eaf5bd334bfa 100644 --- a/tvix/Cargo.toml +++ b/tvix/Cargo.toml @@ -144,8 +144,7 @@ tonic-health = { version = "0.12.2", default-features = false } tonic-reflection = "0.12.2" tower = "0.4.13" tower-http = "0.5.2" -# https://github.com/francoposa/tower-otel-http-metrics/pull/13 -tower-otel-http-metrics = { git = "https://github.com/francoposa/tower-otel-http-metrics", rev = "2023a58e7287a691872f8e75f433179d29d1b439"} +tower-otel-http-metrics = "0.10.0" tracing = "0.1.40" tracing-indicatif = "0.3.6" tracing-opentelemetry = "0.28.0" diff --git a/tvix/crate-hashes.json b/tvix/crate-hashes.json index e4fd21a01d76..46a15356e97f 100644 --- a/tvix/crate-hashes.json +++ b/tvix/crate-hashes.json @@ -1,7 +1,6 @@ { "git+https://github.com/TrueLayer/reqwest-middleware?rev=8a494c165734e24c62823714843e1c9347027e8a#0.4.0": "10gaxsvqld8dfwnm0nk93sqbbd2mjl7zfdf6vglp6waka7h87mba", "git+https://github.com/TrueLayer/reqwest-middleware?rev=8a494c165734e24c62823714843e1c9347027e8a#reqwest-tracing@0.5.4": "10gaxsvqld8dfwnm0nk93sqbbd2mjl7zfdf6vglp6waka7h87mba", - "git+https://github.com/francoposa/tower-otel-http-metrics?rev=2023a58e7287a691872f8e75f433179d29d1b439#0.8.0": "1jiclkybx0fbgd6x2xfhzbq1xm3wba3vbixshqjy765c86jjffcg", "git+https://github.com/liufuyang/bigtable_rs?rev=1818355a5373a5bc2c84287e3a4e3807154ac8ef#0.2.10": "0mn6iw1z7gdxbarsqiwscbdr25nplwlvzs0rs51vgnnjfsnbgl6q", "git+https://github.com/tvlfyi/wu-manber.git#wu-manber@0.1.0": "1zhk83lbq99xzyjwphv2qrb8f8qgfqwa5bbbvyzm0z0bljsjv0pd" } \ No newline at end of file diff --git a/tvix/default.nix b/tvix/default.nix index 10ddb691ac78..dece9f06c0c5 100644 --- a/tvix/default.nix +++ b/tvix/default.nix @@ -21,7 +21,6 @@ let "bigtable_rs" "reqwest-middleware" "reqwest-tracing" - "tower-otel-http-metrics" "wu-manber" ]); }; diff --git a/tvix/nar-bridge/Cargo.toml b/tvix/nar-bridge/Cargo.toml index e9f8182960af..33fe2bd87c47 100644 --- a/tvix/nar-bridge/Cargo.toml +++ b/tvix/nar-bridge/Cargo.toml @@ -22,7 +22,7 @@ tokio = { workspace = true } tokio-listener = { workspace = true, features = ["axum07", "clap", "multi-listener", "sd_listen"] } tokio-util = { workspace = true, features = ["io", "io-util", "compat"] } tonic = { workspace = true, features = ["tls", "tls-roots"] } -tower-otel-http-metrics = { workspace = true, optional = true } +tower-otel-http-metrics = { workspace = true, features = ["axum"], optional = true } tvix-castore = { path = "../castore" } tvix-store = { path = "../store" } tvix-tracing = { path = "../tracing", features = ["tonic", "axum"] } |