core, eth, internal, miner: optimize txpool for quick ops

This commit is contained in:
Péter Szilágyi
2016-07-01 18:59:55 +03:00
parent 795b70423e
commit 0ef327bbee
14 changed files with 790 additions and 428 deletions

View File

@ -97,12 +97,12 @@ var errorToString = map[int]string{
}
type txPool interface {
// AddTransactions should add the given transactions to the pool.
AddTransactions([]*types.Transaction)
// AddBatch should add the given transactions to the pool.
AddBatch([]*types.Transaction)
// GetTransactions should return pending transactions.
// Pending should return pending transactions.
// The slice should be modifiable by the caller.
GetTransactions() types.Transactions
Pending() map[common.Address]types.Transactions
}
// statusData is the network packet for the status message.