Commit 1b7f4888 authored by duanjinfei's avatar duanjinfei

broadcast tx arr goroutine

parent f6befab1
...@@ -36,10 +36,11 @@ func startTest() { ...@@ -36,10 +36,11 @@ func startTest() {
log.Errorf("Bath Send Tran error: %s", err) log.Errorf("Bath Send Tran error: %s", err)
return return
} }
go func() {
if err := transaction.InitBroadcastTxGoroutine(cfg); err != nil { if err := transaction.InitBroadcastTxGoroutine(cfg); err != nil {
log.Errorf("Init broadcast tx goroutine error: %s", err) log.Errorf("Init broadcast tx goroutine error: %s", err)
} }
for i := 0; i < 2; i++ {
go func() {
for { for {
select { select {
case arr := <-tranArrChan: case arr := <-tranArrChan:
...@@ -50,6 +51,7 @@ func startTest() { ...@@ -50,6 +51,7 @@ func startTest() {
} }
} }
}() }()
}
for { for {
log.Info("----------------------------------start") log.Info("----------------------------------start")
//arr := transaction.SignedTxArr(syncMap, SendTxAccountArr, cfg) //arr := transaction.SignedTxArr(syncMap, SendTxAccountArr, cfg)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment