The client/server model

A common way of organizing software to run on distributed systems is to separate functions into two parts: clients and servers. A client is a program that uses services that other programs provide. The programs that provide the services are called servers. The client makes a request for a service, and a server performs that service. Server functions often require some resource management, in which a server synchronizes and manages access to the resource, and responds to client requests with either data or status information. Client programs typically handle user interactions and often request data or initiate some data modification on behalf of a user.

For example, a client can provide a form onto which a user (a person working at a data entry terminal, for example) can enter orders for a product. The client sends this order information to the server, which checks the product database and performs tasks that are needed for billing and shipping. Typically, multiple clients use a single server. For example, dozens or hundreds of clients can interact with a few servers that control database access.

The client is isolated from the need to know anything about the actual resource manager. If you change the database that you are using, the server possibly needs to be modified, but the client does not need to be modified. Because usually fewer copies exist of the server than of the client, and because the servers are often in locations that are easier to update (for example, on central machines instead of on PCs that are running on users' desks), the update procedure is also simplified. Also, this approach provides additional security. Only the servers, not the clients, need access to the data that the resource manager controls.

Clients can also access several different servers, and the servers themselves can act as clients to other servers. Exactly how the functions are distributed across servers is an application design decision. For example, a single server could provide all the services that a client needs, or the client could access multiple servers to perform different requests. The application designer must consider items such as scalability, location, and security. For example, are the clients and servers local or is the application distributed over a wide geographic area? Do the servers need to be on machines that are physically secure? Such design decisions are outside the scope of this introduction.

Some servers are part of an application and are referred to as application servers. Other servers are not part of a specific application. Instead, any application can use them. For example, the CICS® Structured File Server (SFS) provides record-oriented file access for applications.