Skip to content

Commit

Permalink
perf: do not compile traces in release mode (paradigmxyz#2652)
Browse files Browse the repository at this point in the history
  • Loading branch information
gakonst committed May 16, 2023
1 parent 5dfbc9c commit ae2b095
Show file tree
Hide file tree
Showing 28 changed files with 33 additions and 27 deletions.
3 changes: 3 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -60,3 +60,6 @@ incremental = false
[patch.crates-io]
# patched for quantity U256 responses <https://github.com/recmo/uint/issues/224>
ruint = { git = "https://github.com/paradigmxyz/uint" }

[workspace.dependencies]
tracing = { version = "^0.1.0", default-features = false }
5 changes: 4 additions & 1 deletion bin/reth/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ secp256k1 = { version = "0.27.0", features = [
] }

# tracing
tracing = "0.1"
tracing = { workspace = true }

# io
fdlimit = "0.2.1"
Expand Down Expand Up @@ -94,3 +94,6 @@ backon = "0.4"
hex = "0.4"
thiserror = "1.0"
pretty_assertions = "1.3.0"

[features]
only-info-logs = ["tracing/release_max_level_info"]
2 changes: 1 addition & 1 deletion crates/blockchain-tree/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ reth-provider = { path = "../storage/provider" }
# common
parking_lot = { version = "0.12"}
lru = "0.10"
tracing = "0.1"
tracing = { workspace = true }

# mics
aquamarine = "0.3.0"
Expand Down
2 changes: 1 addition & 1 deletion crates/consensus/auto-seal/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ reth-transaction-pool = { path = "../../transaction-pool" }
futures-util = "0.3"
tokio = { version = "1", features = ["sync", "time"] }
tokio-stream = "0.1"
tracing = "0.1"
tracing = { workspace = true }

[dev-dependencies]
reth-interfaces = { path = "../../interfaces", features = ["test-utils"] }
2 changes: 1 addition & 1 deletion crates/consensus/beacon/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ tokio-stream = "0.1.10"
futures = "0.3"

# misc
tracing = "0.1"
tracing = { workspace = true }
thiserror = "1.0"
metrics = "0.20.1"
schnellru = "0.2"
Expand Down
2 changes: 1 addition & 1 deletion crates/interfaces/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ tokio-stream = "0.1.11"
# misc
auto_impl = "1.0"
thiserror = "1.0.37"
tracing = "0.1"
tracing = { workspace = true }
rand = "0.8.5"
arbitrary = { version = "1.1.7", features = ["derive"], optional = true }
secp256k1 = { version = "0.27.0", default-features = false, features = [
Expand Down
2 changes: 1 addition & 1 deletion crates/net/discv4/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ tokio = { version = "1", features = ["io-util", "net", "time"] }
tokio-stream = "0.1"

# misc
tracing = "0.1"
tracing = { workspace = true }
thiserror = "1.0"
hex = "0.4"
rand = { version = "0.8", optional = true }
Expand Down
2 changes: 1 addition & 1 deletion crates/net/dns/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ async-trait = "0.1"
linked_hash_set = "0.1"
schnellru = "0.2"
thiserror = "1.0"
tracing = "0.1"
tracing = { workspace = true }
parking_lot = "0.12"
serde = { version = "1.0", optional = true }
serde_with = { version = "2.1.0", optional = true }
Expand Down
2 changes: 1 addition & 1 deletion crates/net/downloaders/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ tokio = { version = "1.0", features = ["sync"] }
tokio-stream = "0.1"

# misc
tracing = "0.1.37"
tracing = { workspace = true }
metrics = "0.20.1"
rayon = "1.6.0"

Expand Down
2 changes: 1 addition & 1 deletion crates/net/ecies/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ tokio-util = { version = "0.7.4", features = ["codec"] }
pin-project = "1.0"

educe = "0.4.19"
tracing = "0.1.37"
tracing = { workspace = true }

# HeaderBytes
generic-array = "0.14.6"
Expand Down
2 changes: 1 addition & 1 deletion crates/net/eth-wire/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ tokio-util = { version = "0.7.4", features = ["io", "codec"] }
futures = "0.3.24"
tokio-stream = "0.1.11"
pin-project = "1.0"
tracing = "0.1.37"
tracing = { workspace = true }
snap = "1.0.5"
smol_str = "0.1"
metrics = "0.20.1"
Expand Down
2 changes: 1 addition & 1 deletion crates/net/nat/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ igd = { git = "https://github.com/stevefan1999-personal/rust-igd", features = [
] }

# misc
tracing = "0.1"
tracing = { workspace = true }
pin-project-lite = "0.2.9"
tokio = { version = "1", features = ["time"] }
thiserror = "1.0"
Expand Down
2 changes: 1 addition & 1 deletion crates/net/network/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ reth-metrics-derive = { path = "../../metrics/metrics-derive" }
# misc
auto_impl = "1"
aquamarine = "0.3.0"
tracing = "0.1"
tracing = { workspace = true }
fnv = "1.0"
thiserror = "1.0"
parking_lot = "0.12"
Expand Down
2 changes: 1 addition & 1 deletion crates/payload/basic/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ futures-core = "0.3"
futures-util = "0.3"

## misc
tracing = "0.1"
tracing = { workspace = true }
2 changes: 1 addition & 1 deletion crates/payload/builder/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ futures-util = "0.3"
## misc
thiserror = "1.0"
sha2 = { version = "0.10", default-features = false }
tracing = "0.1.37"
tracing = { workspace = true }


[features]
Expand Down
2 changes: 1 addition & 1 deletion crates/primitives/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ secp256k1 = { version = "0.27.0", default-features = false, features = [
crc = "3"

# tracing
tracing = "0.1"
tracing = { workspace = true }

# tokio
tokio = { version = "1", default-features = false, features = ["sync"] }
Expand Down
2 changes: 1 addition & 1 deletion crates/revm/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ reth-consensus-common = { path = "../consensus/common" }
revm = { version = "3" }

# common
tracing = "0.1.37"
tracing = { workspace = true }

[dev-dependencies]
reth-rlp = { path = "../rlp" }
Expand Down
2 changes: 1 addition & 1 deletion crates/rpc/ipc/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ tower = "0.4"
# misc
jsonrpsee = { version = "0.18", features = ["server", "client"] }
serde_json = "1.0"
tracing = "0.1.37"
tracing = { workspace = true }
bytes = "1.4"
thiserror = "1.0.37"

Expand Down
2 changes: 1 addition & 1 deletion crates/rpc/rpc-builder/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ hyper = "0.14"
strum = { version = "0.24", features = ["derive"] }
serde = { version = "1.0", features = ["derive"] }
thiserror = "1.0"
tracing = "0.1"
tracing = { workspace = true }

[dev-dependencies]
reth-tracing = { path = "../../tracing" }
Expand Down
2 changes: 1 addition & 1 deletion crates/rpc/rpc-engine-api/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ async-trait = "0.1"
thiserror = "1.0.37"
jsonrpsee-types = "0.18"
jsonrpsee-core = "0.18"
tracing = "0.1"
tracing = { workspace = true }

[dev-dependencies]
reth-interfaces = { path = "../../interfaces", features = ["test-utils"] }
Expand Down
2 changes: 1 addition & 1 deletion crates/rpc/rpc/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ serde_json = "1.0"
thiserror = "1.0"
hex = "0.4"
rand = "0.8.5"
tracing = "0.1"
tracing = { workspace = true }
tracing-futures = "0.2"
schnellru = "0.2"
futures = "0.3.26"
Expand Down
2 changes: 1 addition & 1 deletion crates/staged-sync/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ serde_json = "1.0.91"
walkdir = "2.3.2"
eyre = "0.6.8"
shellexpand = "3.0.0"
tracing = "0.1.37"
tracing = { workspace = true }

# crypto
rand = { version = "0.8", optional = true }
Expand Down
2 changes: 1 addition & 1 deletion crates/stages/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ futures-util = "0.3.25"
pin-project = "1.0.12"

# observability
tracing = "0.1.36"
tracing = { workspace = true }
metrics = "0.20.1"

# misc
Expand Down
2 changes: 1 addition & 1 deletion crates/storage/provider/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ tokio = { version = "1.21", features = ["sync", "macros", "rt-multi-thread"] }
tokio-stream = { version = "0.1", features = ["sync"] }

# tracing
tracing = "0.1"
tracing = { workspace = true }

# misc
thiserror = "1.0.37"
Expand Down
2 changes: 1 addition & 1 deletion crates/tasks/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ tracing-futures = "0.2"
futures-util = "0.3"

## misc
tracing = { version = "0.1", default-features = false }
tracing = { workspace = true, default-features = false }
thiserror = "1.0"
dyn-clone = "1.0"

Expand Down
2 changes: 1 addition & 1 deletion crates/tracing/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ readme = "README.md"
description = "tracing helpers"

[dependencies]
tracing = { version = "0.1", default-features = false }
tracing = { workspace = true, default-features = false }
tracing-subscriber = { version = "0.3", default-features = false, features = ["env-filter", "fmt"] }
tracing-appender = "0.2"
tracing-journald = "0.3"
2 changes: 1 addition & 1 deletion crates/transaction-pool/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ reth-metrics-derive = { path = "../metrics/metrics-derive" }
# misc
aquamarine = "0.3.0"
thiserror = "1.0"
tracing = "0.1"
tracing = { workspace = true }
serde = { version = "1.0", features = ["derive", "rc"], optional = true }
fnv = "1.0.7"
bitflags = "1.3"
Expand Down
2 changes: 1 addition & 1 deletion crates/trie/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ reth-db = { path = "../storage/db" }
tokio = { version = "1.21.2", default-features = false, features = ["sync"] }

# tracing
tracing = "0.1"
tracing = { workspace = true }

# misc
hex = "0.4"
Expand Down

0 comments on commit ae2b095

Please sign in to comment.