TeachMeBitcoin

The "High-Bandwidth"Mode: Understanding `SENDCMPCT` options

From TeachMeBitcoin, the free encyclopedia Reading time: 3 min

The "High-Bandwidth" Mode: Understanding SENDCMPCT options

Compact Blocks come in two "Flavors": Low-Bandwidth and High-Bandwidth. This choice is managed by the SENDCMPCT message. It is a strategic decision that the Diplomat makes with every peer. It determines how "Aggressive" the node should be when announcing new blocks.

For the Sovereign Architect, High-Bandwidth mode is the "Reflex" of the node. It is the choice between "Waiting to be asked" and "Shouting immediately."

Analyzing the Reflex: SENDCMPCT

In the source code, we see how a node tells its peer which mode it prefers.

/**
 * PEDAGOGICAL ANALYSIS: THE SPEED SETTING
 * This logic tells our peer if we want them to "Push" blocks 
 * to us immediately or "Announce" them first.
 */
void PeerManagerImpl::SendCMPCT(CNode& pfrom)
{
 // 1. Send the preference for version 2 (SegWit compatible).
 // 2. Set "high_bandwidth" to true for our best friends.
 bool high_bandwidth = true; 
 MakeAndPushMessage(pfrom, NetMsgType::SENDCMPCT, high_bandwidth, 2);
}

Explaining the Reflex: The Trade-off of Speed

The Sovereignty of the Reflex

By choosing which peers to use for High-Bandwidth mode, you are tuning the "Nervous System" of your node. You are deciding which "Paths" in the global mesh should be the fastest. As a Sovereign Architect, you know that "Speed is Security" in a blockchain reorganization. By having at least a few high-bandwidth peers, you ensure your node is always among the first to hear the new truth. You are the "Master of the Reflex."


☕ Help support TeachMeBitcoin

TeachMeBitcoin is an ad-free, open-source educational repository curated by a passionate team of Bitcoin researchers and educators for public benefit. If you found our articles helpful, please consider supporting our hosting and ongoing content updates with a clean donation:

Ethereum: 0x578417C51783663D8A6A811B3544E1f779D39A85
Bitcoin: bc1q77k9e95rn669kpzyjr8ke9w95zhk7pa5s63qzz
Solana: 4ycT2ayqeMucixj3wS8Ay8Tq9NRDYRPKYbj3UGESyQ4J
Address copied to clipboard!