How bloXroute Achieves Its Performance

By Eleni Steinman, Strategy & Operations Manager

In our last blog post we talked about the importance of neutrality in building a system that solves the scalability bottleneck. In this post, we will discuss how the bloXroute Blockchain Distribution Network (BDN) scales blockchains to 1000s of transactions per second (TPS) — and we’re just getting started.

How are blocks currently propagated?

Blockchain nodes connect to peer nodes — who are often geographically dispersed around the world — to create a peer-to-peer (P2P) network. (Read our post by Soumya, Co-founder and CTO, on how peer nodes connect here). When a new block is mined, the winning node sends the block to its peers, who wait until they receive the entire block, validate that block and then sends the block on to their peers, until the block is propagated throughout the entire P2P network.

Slow block propagation has been an issue for many years. In late 2013 / early 2014, the Fast Relay Network (FRN) was introduced to mitigate this problem. The FRN was a volunteer service operated for many years for the benefit of the miner community, until its support was abruptly stopped, and later replaced by FIBRE. The Falcon Network is another relay service run by Cornell University and offers several enhancements over FRN such as faster block propagation.

While these relay networks have provided some performance benefits, they are not enough to remove the scalability bottleneck. This is because they were not built with the goal of scalability in mind (albeit FIBRE is specifically optimized for small blocks).

The scalability problem is a networking problem and requires a solution specifically designed to solve it. As a refresher (read our CEO and Co-founder, Uri Klarman’s post here for a more in depth explanation), sending larger blocks takes proportionally longer to send (e.g. 10x larger block takes 10x longer to send) and increases the probability of a fork by roughly the same proportion. At 100x larger blocks (only 300 TPS in bitcoin), the block propagation time becomes so long that it exceeds the 10 minutes interval between blocks and the blockchain breaks. This is why no blockchain can do full 300MB blocks every 10 seconds.

The bloXroute BDN

The bloXroute BDN is an enhancement to the Falcon Network. This new broadcast primitive that is able to capture the efficiencies of a single source node data transmission to send data faster while preserving the decentralized nature of blockchains (read more about how we do this here). We employ three elegant, yet powerful techniques to achieve this performance: transaction caching, cut-through routing, and an optimized dynamic scale topology.

Transaction caching: bloXroute reduces network redundancy through the use of transaction caching. Since transactions are already known when it’s time to send out the block (as an unconfirmed transaction stored in the mempool, rather than send a block with “raw” transactions, the BDN sends just a few bytes representing the transaction. It does this by indexing the transactions, and then utilizing the indexes when transmitting blocks.

The transaction propagation process is as follows:

When a miner builds and then sends its block to the Gateway, the Gateway replaces each transaction with a 4-byte internal ID. This technique allows bloXroute to effectively compress the block size by more than 100x (given that the average raw transaction is approximately 500 bytes, the index size is 4 bytes and the Gateway has a full mapping of the transactions that exist in the block) and in turn, propagate blocks over 100x faster (or 100x larger blocks at the same speed). If a transaction in a block has no internal ID, it is not replaced in the block.

Next, the block is encrypted and propagated throughout the BDN (relay servers). Once the block is received by the Gateways on the other end, the originating Gateway sends the encryption key, the block is decrypted by the receiving Gateways and reconstructed using their internal index tables.

Xthin blocks, Graphene and Compact blocks are similar techniques that compact blocks by replacing each transaction with its 6 bytes hash (not the usual 32 bytes SHA-256 hash). In our previous post, Uri, Co-Founder and CEO, explains the limitations of these solutions when the volume of transactions increases as keeping mempool in sync becomes harder, and collisions become frequent. Conversely, the bloXroute BDN does not suffer from the same desynchronization as the relay servers have a clear picture of all the data.

Cut-through Routing: Without a relay network, each hop in the block propagation checks the validity of the block it is receiving before sending that block on. A node will transmit blocks to its peer only when the block is fully received and validated. The bloXroute BDN does not wait until the entire block is received before it sends the block to a peer node but rather immediately streams each packet of data as it is received through a well-provisioned dedicated network infrastructure. This technique, known as cut through routing, allows bloXroute to broadcast data 10–100x quicker. Only once the blocks are received by the node through the Gateway are they validated.

Optimized topology: Another advantage of the BDN is its optimized topology. New Bitcoin nodes can find initial network peers by querying a set of hard-coded DNS servers. The DNS servers provide joining nodes with their initial peer list to connect to and from there, new bitcoin nodes can crawl through the network. The result, is a web of random connections where data is not propagated throughout the network in the most optimal route.

Conversely, bloXroute has strategically placed servers around the world to send data as efficiently as possible to the geographically dispersed set of nodes that comprises the various blockchain networks.

Furthermore, the BDN Control Plane will dynamically select the optimal relay peer based on network latencies and load. In most cases, the Control Plane will connect the Gateway to the closest relay server in terms of latency (ping distance).

This optimized topology allows the BDN to propagate data to the entire network more efficiently than a P2P network. Again, because bloXroute is provably neutral, it is able to take advantage of this efficiency without impacting the decentralized nature of blockchains.

Conclusion

bloXroute is able to achieve 1000s TPS using internal IDs, cut-through routing and an optimized topology. These techniques can provide scale that far surpasses the current needs of any single blockchain and are compatible with all blockchains as they run underneath the consensus layer.

— — —

We’re always looking for good people!

If you’re equally excited to solve the scalability bottleneck for all blockchains, consider joining our team! We are always looking for passionate partners to help us on this important journey. Check out our available positions to work with us in our Chicago offices.

Learn more