Peerto Peer

The preceding distributed architectures have clear roles for each of the tiers. Client/server tiers can easily be labeled as either master/slave or producer/consumer. Tiers in an n-tier model tend to fall into roles such as presentation layer, business layer, or data layer. This needn't always be the case, however. Some designs benefit from a more collaborative model in which the lines between client and server are blurred. Workgroup scenarios are constructed this way because the main function of these distributed applications is to share information and processing.

A pure peer-to-peer design is comprised of many individual nodes with no centralized server, as shown in Figure 1-2. Without a well-known main server, there must be a mechanism that enables peers to find each other. This usually is achieved through broadcast techniques or some predefined configuration settings.

Peer

Figure 1-2: Peer-to-peer architecture

The Internet is usually considered a classic client/server architecture with a monolithic Web server servicing many thin clients. But the Internet has also given rise to some quasi-peer-to-peer applications, such as Napster and Gnutella. These systems allow collaborative sharing of data between peer machines. These peers use a centralized server for peer discovery and lookup, as shown in Figure 1-3. Although they're not a pure peer-to-peer architecture, these hybrid models usually scale much better than a completely decentralized peer model and deliver the same collaborative benefits.

Figure 1-2: Peer-to-peer architecture

The Internet is usually considered a classic client/server architecture with a monolithic Web server servicing many thin clients. But the Internet has also given rise to some quasi-peer-to-peer applications, such as Napster and Gnutella. These systems allow collaborative sharing of data between peer machines. These peers use a centralized server for peer discovery and lookup, as shown in Figure 1-3. Although they're not a pure peer-to-peer architecture, these hybrid models usually scale much better than a completely decentralized peer model and deliver the same collaborative benefits.

Lookup Server

Lookup Server

Peer

Peer

Figure 1-3: Peer-to-peer architecture with centralized lookup server

Even multitier designs can benefit from loosening the client-server role distinction. It's common for a client module to also be a server and for a server to be a client. We'll discuss this blurring of client-server roles when we look at client callbacks and events in Chapter 3, "Building Distributed Applications with .NET Remoting."

0 0

Post a comment