Day Two Cloud 091: BGP is a Data Exchange Protocol

This episode of Day Two Cloud is a conversation between me and Ethan about BGP, Border Gateway Protocol. As someone who does not have a lot of experience managing WANs and internet facing network gear, BGP is somewhat of a mystery to me. And to be honest, although Ethan answered a lot of my questions, I still don’t feel like I truly understand BGP. But at least I have a mental framework for learning more if the situation requires it.

What I did learn during the conversation is that BGP is a data exchange mechanism. That was my Aha! moment. BGP’s core function is to exchange information in a distributed and decentralized way. Unlike a database, which is the central store of truth on a topic, BGP daemons are constantly exchanging information and updating their local view of the world. On a small enough network of BGP nodes, the state of information can converge and be consistent across all the nodes. By which I mean, the database on each node would hold the same information. Ethan made the point that the internet is vast and ever changing, and BGP can no longer converge fast enough to get to a single source of truth. It’s pretty wild to think about how the entire system is in constant flux, forever chasing the truth and never reaching it. Like a hamster wheel of internet routing.

Back to my central point though, BGP nodes are simply exchanging information with other systems. That information could be about network routes, but it could also be about MAC addresses, link state, or jelly-bean counts. The flexibility of the data being exchanged lends the protocol to other uses beyond its original intent. It also means that BGP doesn’t really care whether you’re using IPv4, IPv6, or some future transit protocol. As long as there is information to exchange, BGP can do it.

One thing that struck me about BGP is that there are other data exchange mechanisms out there. The idea of a decentralized, distributed database is not new, and BGP is not the only player in town. It’s possible that there are more efficient or more secure data exchange protocols out there. Given the age of BGP, is there another protocol which could take its place? Granted that would be a heavy lift for the internet and require a lot of coordination between all the providers, big and small. But the protocol could have a shim that talks BGP while providers migrate over. Facebook announced Open/R back in 2016 and Google uses the Espresso protocol on their internal network. It’s not out of the question that one of the FAANG companies could push a new protocol hard enough to replace BGP in significant segments of the internet. Of course this isn’t my area of expertise and I defer to those who have the requisite background and knowledge to provide a meaningful analysis. I’m just enjoying my little thought experiment.

I think it is useful to consider software and infrastructure tools in the abstract before getting into the nitty-gritty. The abstraction tells us what the tool is actually meant to do, everything else is implementation details. BGP is meant to exchange information in a decentralized environment. If you want to design a competitor, that’s a good place to start.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.