Skip to content

Commit

Permalink
fix(chunk & batch proposer): metrics (scroll-tech#1195)
Browse files Browse the repository at this point in the history
Co-authored-by: colinlyguo <[email protected]>
  • Loading branch information
colinlyguo and colinlyguo authored Mar 14, 2024
1 parent 1606c27 commit 395a0b7
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion common/version/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"runtime/debug"
)

var tag = "v4.3.70"
var tag = "v4.3.71"

var commit = func() string {
if info, ok := debug.ReadBuildInfo(); ok {
Expand Down
8 changes: 4 additions & 4 deletions rollup/internal/controller/watcher/batch_proposer.go
Original file line number Diff line number Diff line change
Expand Up @@ -249,8 +249,8 @@ func (p *BatchProposer) proposeBatch() (*encoding.Batch, error) {
return nil, err
}

p.totalL1CommitGas.Set(float64(totalL1CommitCalldataSize))
p.totalL1CommitCalldataSize.Set(float64(totalL1CommitGas))
p.totalL1CommitCalldataSize.Set(float64(totalL1CommitCalldataSize))
p.totalL1CommitGas.Set(float64(totalL1CommitGas))
p.batchChunksNum.Set(float64(batch.NumChunks()))
return &batch, nil
}
Expand Down Expand Up @@ -282,8 +282,8 @@ func (p *BatchProposer) proposeBatch() (*encoding.Batch, error) {
}

p.batchFirstBlockTimeoutReached.Inc()
p.totalL1CommitGas.Set(float64(totalL1CommitCalldataSize))
p.totalL1CommitCalldataSize.Set(float64(totalL1CommitGas))
p.totalL1CommitCalldataSize.Set(float64(totalL1CommitCalldataSize))
p.totalL1CommitGas.Set(float64(totalL1CommitGas))
p.batchChunksNum.Set(float64(batch.NumChunks()))

batch.StartChunkIndex = dbChunks[0].Index
Expand Down
8 changes: 4 additions & 4 deletions rollup/internal/controller/watcher/chunk_proposer.go
Original file line number Diff line number Diff line change
Expand Up @@ -276,8 +276,8 @@ func (p *ChunkProposer) proposeChunk() (*encoding.Chunk, error) {
}

p.chunkTxNum.Set(float64(chunk.NumTransactions()))
p.chunkEstimateL1CommitGas.Set(float64(totalL1CommitCalldataSize))
p.totalL1CommitCalldataSize.Set(float64(totalL1CommitGas))
p.totalL1CommitCalldataSize.Set(float64(totalL1CommitCalldataSize))
p.chunkEstimateL1CommitGas.Set(float64(totalL1CommitGas))
p.maxTxConsumption.Set(float64(crcMax))
p.chunkBlocksNum.Set(float64(len(chunk.Blocks)))
return &chunk, nil
Expand Down Expand Up @@ -317,8 +317,8 @@ func (p *ChunkProposer) proposeChunk() (*encoding.Chunk, error) {

p.chunkFirstBlockTimeoutReached.Inc()
p.chunkTxNum.Set(float64(chunk.NumTransactions()))
p.chunkEstimateL1CommitGas.Set(float64(totalL1CommitCalldataSize))
p.totalL1CommitCalldataSize.Set(float64(totalL1CommitGas))
p.totalL1CommitCalldataSize.Set(float64(totalL1CommitCalldataSize))
p.chunkEstimateL1CommitGas.Set(float64(totalL1CommitGas))
p.maxTxConsumption.Set(float64(crcMax))
p.chunkBlocksNum.Set(float64(len(chunk.Blocks)))
return &chunk, nil
Expand Down

0 comments on commit 395a0b7

Please sign in to comment.