Don't keep generating transactions in non-sustained bench-tps mode (#7577)

This commit is contained in:
sakridge
2020-01-09 17:48:18 -08:00
committed by GitHub
parent 865c42465a
commit 2e89ec9105

View File

@ -197,7 +197,9 @@ where
sleep(Duration::from_millis(1));
}
} else {
while shared_tx_active_thread_count.load(Ordering::Relaxed) > 0 {
while !shared_txs.read().unwrap().is_empty()
|| shared_tx_active_thread_count.load(Ordering::Relaxed) > 0
{
sleep(Duration::from_millis(1));
}
}