What is the Client-Server Model?by Iwan Price-Evans on Networking • June 30, 2022
The Client-Server Model describes a type of centralized networking architecture where multiple users' devices are connected to a central server. This model is also known as the networking computing model because client requests and server services are delivered via the network.
Early networked systems used a central server, often referred to as a Mainframe, connected to many user devices called dumb terminals. The dumb terminals allowed the user to access the applications and processing power of the mainframe server but had none of their own processing functionality.
Modern Client-Server architecture typically has a central server that serves clients. Clients can be user applications, PCs, mobile devices, IoT devices, or any other network device or system that's connected to the server. Clients and servers can be located on an internal network or via the public internet.
Roles and Permissions
With Client-Server architecture, the client and server have different roles and permissions when performing work tasks.
Typically the server will host services that the client needs to perform functions or actions. The server will have most of the resources needed to serve all clients, which means that the clients have to perform less work. Modern applications use services hosted on a server that receives and responds to client requests. All clients are dependent on the server and if it fails, then none of the clients can fully function.
Peer-to-Peer vs Client-Server
You may also have heard of Peer-to-Peer (P2P) networking which is very different. With the Peer-to-Peer networking model, a group of devices (peers) perform the same functions and act as client and server. The clients are responsible for the whole application. An example of a modern Peer-to-Peer system is blockchain.
The Client-Server Model basics
The model performs a 3-step process:
- A client application on a networked device sends a request.
- The networked server receives and accepts the request, then performs processing.
- The server then sends a response to the client, delivering the requested service.
How does the Client-Server model work?
Web applications use the Client-Server model to implement functionality on the client's web browser, which may communicate with the server via APIs.
Client applications typically perform local data collection and validation, and the server performs data processing and updates.
- The client will send requests to the server, which is listening for these requests.
- The server receives, validates, and processes the requests, returning the required response to the client.
- The server will perform whatever action has been requested and sends the resulting data back to the client.
With this model, both client and server have their own functionality and are considered intelligent. This is unlike the early dumb terminal and mainframe model.
Connected clients and servers commonly communicate via the TCP/IP protocol. The protocol enables the connection between client and server, and creates, verifies, and maintains the connection. The protocol breaks client request data into chunks (packets), sends them to the appropriate destination server, and similarly manages the data packets in the response from the server.
Types of Client-Server Architecture
There are four common ways to implement the Client-Server Model.
- 1-Tier Architecture - This is an all-one approach. A single device runs all of the functions of a typically simple application. With 1-Tier architecture, the application presentation, business logic, and data management are all on the same device, and there is no need for network communication.
- 2-Tier Architecture - The client and server make up the two tiers and the network protocol links them. The presentation tier, or UI, sits on the client, and the application logic and data sit on the server.
- 3-Tier Architecture - This architecture introduces middleware to the 2-Tier approach. Middleware becomes the third tier or Application Tier. In this model, the client has the UI, the server has the database, and the middleware sits in between performing complex business logic functions. 3-Tier architecture enables features like improved security and load balancing.
- N-Tier Architecture - Adds additional tiers to the 3-Tier approach. N-Tier is a multi-tier architecture where it's possible to segment functionality and network traffic using middleware. N-Tier is used by enterprise organizations to provide the scalability and security they need. The N-Tier model allows individual application functions to be 'layered', even enabling a single function to be run from a separate computer. Security can be improved significantly by implementing segmented layers that can only communicate with the layer above and below. N-Tier brings more complexity which introduces the need for application delivery management tools.