Module node

Source
Expand description

Main file for this blockchain. A node is the central task that runs and handles important events, such as new blocks, peer connection/disconnection, new addresses, etc. A node should not care about peer-specific messages, peers’ll handle things like pings.

Modules§

chain_selector_ctx
A module that connects with multiple peers and finds the best chain.
running_ctx
After a node catches-up with the network, we can start listening for new blocks, handing any request our user might make and keep our peers alive. This mode requires way less bandwidth and CPU to run, being bound by the number of blocks found in a given period.
sync_ctx
A node that downloads and validates the blockchain.

Structs§

AddedPeerInfo
A simple struct of added peers, used to track the ones we added manually by addnode <ip:port> add command.
LocalPeerView
Local information kept about each peer
NodeCommon
UtreexoNode
The main node that operates while florestad is up.

Enums§

ConnectionKind
The kind of connection we see this peer as.
NodeNotification
NodeRequest
Sent from node to peers, usually to request something
PeerStatus

Constants§

MAX_ADDRV2_ADDRESSES
As per BIP 155, limit the number of addresses to 1,000