diff --git a/coordinator/Cargo.toml b/coordinator/Cargo.toml index 34b02ba47..f494e391a 100644 --- a/coordinator/Cargo.toml +++ b/coordinator/Cargo.toml @@ -77,7 +77,6 @@ path = "../crates/orderbook-commons" [dependencies.parking_lot] version = "0.12.1" -features = ["deadlock_detection"] [dependencies.rust_decimal] version = "1" diff --git a/crates/ln-dlc-node/Cargo.toml b/crates/ln-dlc-node/Cargo.toml index 5de882f91..e0c77d520 100644 --- a/crates/ln-dlc-node/Cargo.toml +++ b/crates/ln-dlc-node/Cargo.toml @@ -30,7 +30,7 @@ lightning-persister = { version = "0.0.114" } lightning-transaction-sync = { version = "0.0.114", features = ["esplora-blocking"] } log = "0.4.17" p2pd-oracle-client = { version = "0.1.0" } -parking_lot = { version = "0.12.1", features = ["deadlock_detection"] } +parking_lot = { version = "0.12.1" } rand = "0.8.5" reqwest = { version = "0.11", default-features = false, features = ["json"] } rust-bitcoin-coin-selection = { version = "0.1.0", features = ["rand"] } diff --git a/crates/ln-dlc-node/src/node/mod.rs b/crates/ln-dlc-node/src/node/mod.rs index bdd00bcc6..f1e226dc5 100644 --- a/crates/ln-dlc-node/src/node/mod.rs +++ b/crates/ln-dlc-node/src/node/mod.rs @@ -486,8 +486,6 @@ where self.keys_manager.clone(), )); - std::thread::spawn(monitor_for_deadlocks()); - tracing::info!("Lightning node started with node ID {}", self.info); Ok(RunningNode { _handles: handles }) @@ -573,25 +571,6 @@ fn spawn_background_processor( remote_handle } -/// Parking lot mutexes have the ability to mark deadlocks. -/// -/// Take advantage of this behaviour and log deadlocks when they occur. -fn monitor_for_deadlocks() -> impl Fn() { - move || loop { - let deadlocks = parking_lot::deadlock::check_deadlock(); - - for (i, threads) in deadlocks.iter().enumerate() { - tracing::error!(%i, "Deadlock detected"); - for t in threads { - tracing::error!(thread_id = %t.thread_id()); - tracing::error!("{:#?}", t.backtrace()); - } - } - - std::thread::sleep(Duration::from_secs(10)); - } -} - async fn lightning_wallet_sync( channel_manager: Arc, chain_monitor: Arc, diff --git a/mobile/native/Cargo.toml b/mobile/native/Cargo.toml index e6c7dfdd6..9bf3f788f 100644 --- a/mobile/native/Cargo.toml +++ b/mobile/native/Cargo.toml @@ -26,7 +26,7 @@ ln-dlc-node = { path = "../../crates/ln-dlc-node" } openssl = { version = "0.10.55", features = ["vendored"] } orderbook-client = { path = "../../crates/orderbook-client" } orderbook-commons = { path = "../../crates/orderbook-commons" } -parking_lot = { version = "0.12.1", features = ["deadlock_detection"] } +parking_lot = { version = "0.12.1" } reqwest = { version = "0.11", default-features = false, features = ["json"] } rust_decimal = { version = "1", features = ["serde-with-float"] } serde = { version = "1.0.152", features = ["serde_derive"] }