From fd79dfa9559552637687700dde1bea6c1c7f0057 Mon Sep 17 00:00:00 2001 From: georgehao Date: Mon, 24 Mar 2025 15:41:00 +0800 Subject: [PATCH] add log to debug tx latency --- core/tx_pool.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/tx_pool.go b/core/tx_pool.go index 0109d5677676..776ebc7dfc66 100644 --- a/core/tx_pool.go +++ b/core/tx_pool.go @@ -1120,12 +1120,13 @@ func (pool *TxPool) addTxs(txs []*types.Transaction, local, sync bool) []error { // Exclude transactions with invalid signatures as soon as // possible and cache senders in transactions before // obtaining lock - _, err := types.Sender(pool.signer, tx) + from, err := types.Sender(pool.signer, tx) if err != nil { errs[i] = ErrInvalidSender invalidTxMeter.Mark(1) continue } + log.Info("Adding transaction to pool", "hash", tx.Hash().Hex(), "to", tx.To(), "from", from) // Accumulate all unknown transactions for deeper processing news = append(news, tx) }