Java Reference
In-Depth Information
Figure 16.2 Expanded conceptual model showing several clients interacting with a
single server machine.
Before building a UML collaboration diagram for this conceptual model, we
first introduce a useful design pattern . Design patterns came into vogue in 1995
with the publication of the famous Design Patterns book [14]. While important,
that book is not particularly easy to understand for the non-computer scientist.
Ye t design patterns are immensely useful, so it is important to understand some
simple patterns. Design patterns need not be mysterious. A design pattern can
be defined simply as a proven good solution for a commonly occurring software
design issue - in other words, a “template” or “best practice” for how to solve a
common problem.
The common software design issue in the case of a client/server system is
how to support multiple clients with one server. One does not wish to lock out
all other clients when one client is using the server. A web server is a common
example. Popular web servers such as search engines, auction sites, or online
shopping sites might have to support thousands of simultaneous clients. Thus the
conceptual model could be expanded to that shown in Figure 16.2.
We can imagine that the multiple clients are created as needed by multiple
users, but how does one server handle multiple clients? In an object-oriented
solution, the “server” is actually made up of several server objects. Because
we're still at the conceptual model phase, remember that the boxes labeled client
and server in the figure do not represent objects . They are simply concepts at this
point. Later we draw diagrams with actual objects in them. Where do all of the
server objects come from, how many are needed, and what happens if the server
machine runs out of server objects?
Search WWH ::




Custom Search