Client-Server Architecture

At various points in this book, we discuss the design and implementation of client-server applications.

A client-server application is one that is broken into two component processes:

Sometimes, the client and server may engage in an extended dialogue of requests and responses.

Typically, the client application interacts with a user, while the server application provides access to some shared resource. Commonly, there are multiple instances of client processes communicating with one or a few instances of the server process.

The client and server may reside on the same host computer or on separate hosts connected via a network. To communicate with one another, the client and server use the IPC mechanisms discussed in Interprocess Communication and Synchronization.

Servers may implement a variety of services, such as:

Encapsulating a service within a single server is useful for a number of reasons, such as the following: