6 #ifndef BITCOIN_NET_PROCESSING_H 7 #define BITCOIN_NET_PROCESSING_H 156 virtual void SetBestBlock(
int height, std::chrono::seconds time) = 0;
194 #endif // BITCOIN_NET_PROCESSING_H std::shared_ptr< const CTransaction > CTransactionRef
bool reconcile_txs
Whether transaction reconciliation protocol is enabled.
static constexpr bool DEFAULT_PRIVATE_BROADCAST
Default for -privatebroadcast.
bool ignores_incoming_txs
ServiceFlags
nServices flags
virtual void StartScheduledTasks(CScheduler &scheduler)=0
Begin running background tasks, should only be called once.
uint64_t m_addr_rate_limited
virtual void InitiateTxBroadcastPrivate(const CTransactionRef &tx)=0
Initiate a private transaction broadcast.
Interface for managing multiple Chainstate objects, where each chainstate is associated with chainsta...
virtual void UpdateLastBlockAnnounceTime(NodeId node, int64_t time_in_seconds)=0
This function is used for testing the stale tip eviction logic, see denialofservice_tests.cpp.
Manages warning messages within a node.
virtual util::Expected< void, std::string > FetchBlock(NodeId peer_id, const CBlockIndex &block_index)=0
Attempt to manually fetch block from a given peer.
static std::unique_ptr< PeerManager > make(CConnman &connman, AddrMan &addrman, BanMan *banman, ChainstateManager &chainman, CTxMemPool &pool, node::Warnings &warnings, Options opts)
virtual std::vector< PrivateBroadcast::TxBroadcastInfo > GetPrivateBroadcastInfo() const =0
Get info about transactions currently being privately broadcast.
bool private_broadcast
Whether private broadcast is used for sending transactions.
uint32_t max_headers_result
Number of headers sent in one getheaders message result (this is a test-only option).
Interface for message handling.
Implement this to subscribe to events generated in validation and mempool.
Stochastic address manager.
static const bool DEFAULT_PEERBLOCKFILTERS
int64_t CAmount
Amount in satoshis (Can be negative)
bool deterministic_rng
Whether or not the internal RNG behaves deterministically (this is a test-only option).
std::chrono::seconds median_outbound_time_offset
static const unsigned int MAX_HEADERS_RESULTS
Number of headers sent in one getheaders result.
virtual PeerManagerInfo GetInfo() const =0
Get peer manager info.
CAmount m_fee_filter_received
virtual std::vector< node::TxOrphanage::OrphanInfo > GetOrphanTransactions()=0
uint64_t m_addr_processed
static const unsigned int MAX_CMPCTBLOCKS_INFLIGHT_PER_BLOCK
Maximum number of outstanding CMPCTBLOCK requests for the same block.
Double ended buffer combining vector and stream-like interfaces.
virtual void SetBestBlock(int height, std::chrono::seconds time)=0
Set the height of the best block and its time (seconds since epoch).
virtual ServiceFlags GetDesirableServiceFlags(ServiceFlags services) const =0
Gets the set of service flags which are "desirable" for a given peer.
std::chrono::microseconds m_ping_wait
bool capture_messages
Whether all P2P messages are captured to disk.
ServiceFlags their_services
static const bool DEFAULT_PEERBLOOMFILTERS
The util::Expected class provides a standard way for low-level functions to return either error value...
std::chrono::seconds time_offset
virtual void CheckForStaleTipAndEvictPeers()=0
Evict extra outbound peers.
virtual bool GetNodeStateStats(NodeId nodeid, CNodeStateStats &stats) const =0
Get statistics from node state.
CTxMemPool stores valid-according-to-the-current-best-chain transactions that may be included in the ...
virtual void SendPings()=0
Send ping message to all peers.
The block chain is a tree shaped structure starting with the genesis block at the root...
static const uint32_t DEFAULT_BLOCK_RECONSTRUCTION_EXTRA_TXN
Default number of non-mempool transactions to keep around for block reconstruction.
static constexpr bool DEFAULT_TXRECONCILIATION_ENABLE
Whether transaction reconciliation protocol should be enabled by default.
virtual void UnitTestMisbehaving(NodeId peer_id)=0
virtual void InitiateTxBroadcastToAll(const Txid &txid, const Wtxid &wtxid)=0
Initiate a transaction broadcast to eligible peers.
static const bool DEFAULT_BLOCKSONLY
Default for blocks only.
std::vector< int > vHeightInFlight
Simple class for background tasks that should be run periodically or once "after a while"...
virtual std::vector< CTransactionRef > AbortPrivateBroadcast(const uint256 &id)=0
Abort private broadcast attempts for transactions currently being privately broadcast.
bool m_addr_relay_enabled
bool ignore_incoming_txs
Whether this node is running in -blocksonly mode.
virtual ~PeerManager()=default
uint32_t max_extra_txs
Number of non-mempool transactions to keep around for block reconstruction.