mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-09 21:43:47 +00:00
removing blocksize metric from worker
This commit is contained in:
parent
bbc42f5279
commit
c244b5fbb9
1 changed files with 0 additions and 6 deletions
|
|
@ -19,7 +19,6 @@ package miner
|
||||||
import (
|
import (
|
||||||
"errors"
|
"errors"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/ethereum/go-ethereum/metrics"
|
|
||||||
"math/big"
|
"math/big"
|
||||||
"sync"
|
"sync"
|
||||||
"sync/atomic"
|
"sync/atomic"
|
||||||
|
|
@ -78,8 +77,6 @@ var (
|
||||||
errBlockInterruptedByNewHead = errors.New("new head arrived while building block")
|
errBlockInterruptedByNewHead = errors.New("new head arrived while building block")
|
||||||
errBlockInterruptedByRecommit = errors.New("recommit interrupt while building block")
|
errBlockInterruptedByRecommit = errors.New("recommit interrupt while building block")
|
||||||
errBlockInterruptedByTimeout = errors.New("timeout while building block")
|
errBlockInterruptedByTimeout = errors.New("timeout while building block")
|
||||||
|
|
||||||
blockSizeGaugeName = "clique/block_size_in_bytes"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// environment is the worker's current environment and holds all
|
// environment is the worker's current environment and holds all
|
||||||
|
|
@ -1125,9 +1122,6 @@ func (w *worker) commit(env *environment, interval func(), update bool, start ti
|
||||||
env := env.copy()
|
env := env.copy()
|
||||||
// Withdrawals are set to nil here, because this is only called in PoW.
|
// Withdrawals are set to nil here, because this is only called in PoW.
|
||||||
block, err := w.engine.FinalizeAndAssemble(w.chain, env.header, env.state, env.txs, nil, env.receipts, nil)
|
block, err := w.engine.FinalizeAndAssemble(w.chain, env.header, env.state, env.txs, nil, env.receipts, nil)
|
||||||
if metrics.Enabled {
|
|
||||||
metrics.GetOrRegisterGauge(blockSizeGaugeName, nil).Update(int64(block.Size()))
|
|
||||||
}
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue