From 0287512a474624452cab1fbbca831c46eb66f8a2 Mon Sep 17 00:00:00 2001 From: Pekka Enberg Date: Wed, 10 Sep 2025 11:50:22 +0300 Subject: [PATCH] stress: Disable database reopen and reconnect Nikita noticed that database reopen and reconnet cause most database operations to return "database locked", which means we're not getting the coverage we need. --- stress/main.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stress/main.rs b/stress/main.rs index f1a335fae..de9aaf5fa 100644 --- a/stress/main.rs +++ b/stress/main.rs @@ -519,7 +519,7 @@ async fn main() -> Result<(), Box> { let mut conn = db.lock().await.connect()?; println!("\rExecuting queries..."); for query_index in 0..nr_iterations { - if gen_bool(0.001) { + if gen_bool(0.001) && false { if opts.verbose { println!("Reopening database"); } @@ -531,7 +531,7 @@ async fn main() -> Result<(), Box> { } *db_guard = builder.build().await?; conn = db_guard.connect()?; - } else if gen_bool(0.01) { + } else if gen_bool(0.01) && false { // Reconnect to the database if opts.verbose { println!("Reconnecting to database");