Ethereum Wire Protocol

tags: Ethereum Sub-protocols, Ethereum Simulator Node Started when a RLPx session had initiated. Three main tasks before switch to PoS: Chain synchronization Block propagation Transaction exchange: exchange pending transaction between nodes. Only transaction exchange remit after switch to PoS.

June 14, 2023 · 1 min · Gray King

Ethereum DevP2P

tags: Ethereum Networking, Ethereum Execution Layer Basic stack for p2p networking. Initiating RLPx Session. RLPX Session Communicate messages that encoded in RLP between peers.

June 14, 2023 · 1 min · Gray King

Ethereum Networking Layer

tags: Ethereum source: https://ethereum.org/en/developers/docs/networking-layer/

June 14, 2023 · 1 min · Gray King

Ethereum Discovery Nodes

tags: Ethereum Networking, Ethereum Simulator Node Boot nodes Using a small set that hardcoded bootnodes to bootstrap. Protocol Kademlia a modified form of Distributed Hash Table. Steps to join the network start client –> connect to bootnode –> bond to bootnode –> find neighbours –> bond to neighbours

June 14, 2023 · 1 min · Gray King

How is a Transaction Broadcasted

tags: Ethereum Simulator Node, Ethereum Execution Layer Node Side: Receive pending transactions If we want to broadcast our transactions to the network in Ethereum, two RPC calls are involved: https://ethereum.org/en/developers/docs/apis/json-rpc/#eth_sendtransaction https://ethereum.org/en/developers/docs/apis/json-rpc/#eth_sendrawtransaction So let’s follow those two calls to track how a transaction is broadcasted. Those two corresponding implementations are defined at internal/ethapi/api.go: SendTransaction SendRawTransaction And both of them are pointing to SubmitTransaction, which calls SendTx to put transaction into the txpool by calling: func (b *EthAPIBackend) SendTx(ctx context.Context, signedTx *types.Transaction) error { return b.eth.txPool.AddLocal(signedTx) } Miner Side: Execute pending transactions Miner start here at cmd/geth/main.go, which is calling: ...

June 12, 2023 · 2 min · Gray King