Search⌘ K

Essential Network Protocols for Distributed Systems

Learn how core network protocols like TCP, UDP, and HTTP are foundational to designing robust and scalable distributed systems.

A distributed system’s greatest strength and weakness are that its components are separate. Without a robust communication backbone, it’s just a collection of isolated computers. The choice of how these components talk to each other is a critical decision in System Design, influencing a system’s performance, reliability, and scalability.

This lesson will break down the essential network protocols that enable this communication. Let’s start with a simple model.

Basic communication flow between a client and a server
Basic communication flow between a client and a server

The diagram above shows a simple end-to-end flow. A client request travels to a server, and different protocols govern this communication. We will now explore these protocols, starting with the application layer, where most engineers interact with them day-to-day.

HTTP as an architectural backbone

The Hypertext Transfer Protocol (HTTP) is the foundation of communication on the web. As an application-layer protocol, it defines how clients and servers exchange messages. For System Design, knowing how HTTP works is essential for building APIs and web services.

The stateless nature of HTTP

The most important characteristic of HTTP is that it is statelessA communication protocol where the server does not store any information about previous client requests. Each request is treated as a new, independent transaction.. Each request from a client to a server must contain all the information needed to understand and complete the request. The server does not retain any memory of past requests. This design simplifies server logic and enhances scalability, but it means stateful information (like user sessions) must be managed externally.

Note: While the HTTP protocol is stateless, applications built on it are often stateful. State is maintained by the application using techniques like session cookies or authentication tokens sent in headers.

Core components of an HTTP request

An HTTP request sent by a client is made up of the following parts:

  • Methods: Verbs that define the desired action, for example, GET is used to retrieve data, POST to submit data, PUT ...