implement per-thread, per-batch sleep in ms (throttling allows easier UI dev) (#2293)
* implement per-thread, per-batch sleep in ms (throttling allows easier UI development) * tidy up sleep() call with Duration::from_millis() instead of Duration::new() * fixup indentation style * removing multinode-demo/client-throttled.sh (same functionality available via arguments)
This commit is contained in:
@@ -233,9 +233,13 @@ pub fn do_tx_transfers(
|
||||
leader: &NodeInfo,
|
||||
shared_tx_thread_count: &Arc<AtomicIsize>,
|
||||
total_tx_sent_count: &Arc<AtomicUsize>,
|
||||
thread_batch_sleep_ms: usize,
|
||||
) {
|
||||
let client = mk_client(&leader);
|
||||
loop {
|
||||
if thread_batch_sleep_ms > 0 {
|
||||
sleep(Duration::from_millis(thread_batch_sleep_ms as u64));
|
||||
}
|
||||
let txs;
|
||||
{
|
||||
let mut shared_txs_wl = shared_txs.write().unwrap();
|
||||
|
Reference in New Issue
Block a user