Skip to content

Commit

Permalink
Merge branch 'master' into upgrade/go-ethereum/v1.9.24-2021621140614
Browse files Browse the repository at this point in the history
  • Loading branch information
baptiste-b-pegasys authored Jun 29, 2021
2 parents f38ed0d + ce32f98 commit 35b0aa4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions miner/worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -843,6 +843,7 @@ func (w *worker) commitTransactions(txs *types.TransactionsByPriceAndNonce, coin

var coalescedLogs []*types.Log

loopStartTime := time.Now() // Quorum
for {
// In the following three cases, we will interrupt the execution of the transaction.
// (1) new head block event arrival, the interrupt signal is 1
Expand All @@ -851,6 +852,7 @@ func (w *worker) commitTransactions(txs *types.TransactionsByPriceAndNonce, coin
// For the first two cases, the semi-finished work will be discarded.
// For the third case, the semi-finished work will be submitted to the consensus engine.
if interrupt != nil && atomic.LoadInt32(interrupt) != commitInterruptNone {
log.Info("Aborting transaction processing due to 'commitInterruptNewHead',", "elapsed time", time.Since(loopStartTime)) // Quorum
// Notify resubmit loop to increase resubmitting interval due to too frequent commits.
if atomic.LoadInt32(interrupt) == commitInterruptResubmit {
ratio := float64(w.current.header.GasLimit-w.current.gasPool.Gas()) / float64(w.current.header.GasLimit)
Expand Down

0 comments on commit 35b0aa4

Please sign in to comment.