print gomaxprocs in txgen

pull/69/head
Rongjian Lan 6 years ago
parent f44762fa54
commit 30b82cc6dc
  1. 5
      client/txgen/main.go

@ -8,6 +8,7 @@ import (
"math/rand" "math/rand"
"os" "os"
"path" "path"
"runtime"
"sync" "sync"
"time" "time"
@ -332,7 +333,7 @@ func main() {
wg.Add(len(shardIdLeaderMap)) wg.Add(len(shardIdLeaderMap))
utxoPoolMutex.Lock() utxoPoolMutex.Lock()
log.Warn("STARTING TX GEN") log.Warn("STARTING TX GEN", "gomaxprocs", runtime.GOMAXPROCS(0))
for shardId, _ := range shardIdLeaderMap { // Generate simulated transactions for shardId, _ := range shardIdLeaderMap { // Generate simulated transactions
go func() { go func() {
txs, crossTxs := generateSimulatedTransactions(subsetCounter, *numSubset, int(shardId), nodes) txs, crossTxs := generateSimulatedTransactions(subsetCounter, *numSubset, int(shardId), nodes)
@ -370,7 +371,7 @@ func main() {
lock.Unlock() lock.Unlock()
subsetCounter++ subsetCounter++
time.Sleep(5000 * time.Millisecond) //time.Sleep(5000 * time.Millisecond)
} }
// Send a stop message to stop the nodes at the end // Send a stop message to stop the nodes at the end

Loading…
Cancel
Save