Documentation ¶
Overview ¶
Ethereum blockchain transaction pool crawler.
Execute: go run main.go -blockchain ethereum -interval 1
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitTxPool ¶
func InitTxPool()
func PollTxpoolContent ¶
func PollTxpoolContent(gethClient *rpc.Client, interval int, reporter *humbug.HumbugReporter, blockchain string)
Fetch list of transactions form Ethereum TxPool
Types ¶
type PendingTransaction ¶
type PendingTransaction struct { From string `json:"from"` Nonce uint64 `json:"nonce"` Transaction *Transaction `json:"transaction"` }
type PendingTransactions ¶
type PendingTransactions struct {
Transactions PendingTransaction `json:"transactions"`
}
type Transaction ¶
type Transaction struct { Type hexutil.Uint64 `json:"type"` // Common transaction fields: Nonce *hexutil.Uint64 `json:"nonce"` GasPrice *hexutil.Big `json:"gasPrice"` MaxPriorityFeePerGas *hexutil.Big `json:"maxPriorityFeePerGas"` MaxFeePerGas *hexutil.Big `json:"maxFeePerGas"` Gas *hexutil.Uint64 `json:"gas"` Value *hexutil.Big `json:"value"` Data *hexutil.Bytes `json:"input"` V *hexutil.Big `json:"v"` R *hexutil.Big `json:"r"` S *hexutil.Big `json:"s"` To *common.Address `json:"to"` // Access list transaction fields: ChainID *hexutil.Big `json:"chainId,omitempty"` // Only used for encoding: Hash common.Hash `json:"hash"` }
Click to show internal directories.
Click to hide internal directories.