# Functions
NewBlockSyncMgr return a BlockSyncMgr instance.
NewServer return a new p2pserver according to the pubkey.
NewSyncFlightInfo return a new SyncFlightInfo instance.
# Constants
s, Request block timeout time.
s, Request header timeout time.
Cache size of block wait to commit to ledger.
Number of blocks on flight.
Number of headers on flight.
keep CurrentHeaderHeight - CurrentBlockHeight <= SYNC_MAX_HEADER_FORWARD_SIZE.
# Structs
BlockSyncMgr is the manager class to deal with block sync.
P2PServer control all network activities.
ReconnectAddrs contain addr need to reconnect.
SyncFlightInfo record the info of fight object(header or block).