mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-27 07:06:42 +00:00
core/txpool/blobpool: rename buffer.add into storeCompleted
This commit is contained in:
parent
589f80ca56
commit
4d107e77dc
1 changed files with 5 additions and 4 deletions
|
|
@ -137,7 +137,7 @@ func (b *BlobBuffer) AddTx(txs []*types.Transaction, peer string) []error {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
if entry, ok := b.cells[hash]; ok {
|
if entry, ok := b.cells[hash]; ok {
|
||||||
b.add(hash, tx, entry)
|
b.storeCompleted(hash, tx, entry)
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
blobBufferTxFirstCounter.Inc(1)
|
blobBufferTxFirstCounter.Inc(1)
|
||||||
|
|
@ -162,13 +162,14 @@ func (b *BlobBuffer) AddCells(hash common.Hash, deliveries map[string]*PeerDeliv
|
||||||
added: time.Now(),
|
added: time.Now(),
|
||||||
}
|
}
|
||||||
if txe, ok := b.txs[hash]; ok {
|
if txe, ok := b.txs[hash]; ok {
|
||||||
b.add(hash, txe.tx, b.cells[hash])
|
b.storeCompleted(hash, txe.tx, b.cells[hash])
|
||||||
}
|
}
|
||||||
blobBufferCellsFirstCounter.Inc(1)
|
blobBufferCellsFirstCounter.Inc(1)
|
||||||
}
|
}
|
||||||
|
|
||||||
// add verifies cells per-peer, sorts them, and adds to the pool.
|
// storeCompleted verifies cells per-peer, sorts them, and schedules them for
|
||||||
func (b *BlobBuffer) add(hash common.Hash, tx *types.Transaction, cells *cellEntry) {
|
// addition into the pool. The actual addition happens in Flush().
|
||||||
|
func (b *BlobBuffer) storeCompleted(hash common.Hash, tx *types.Transaction, cells *cellEntry) {
|
||||||
sidecar := tx.BlobTxSidecar()
|
sidecar := tx.BlobTxSidecar()
|
||||||
|
|
||||||
// Per-peer cell verification
|
// Per-peer cell verification
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue