Peer Computing: an architectural pattern for distributed computing in which there are two classes of nodes:
the primary nodes (called “Peers”) interact with each other as peers over symmetrical protocols; while
each secondary node (called “Client”) act as client of (typically) one Peer that acts as server with respect to the Client, communicating via a client-server protocol.
This is illustrated in the following diagram:
In this architecture, if a Client A3 wishes to communicate with another Client C4 that is associated with a different Peer, it communicates with its own Peer A, which then communicates with the other Clients’ Peer C, which then communicates with the destination Client C4.
This communication path is shown in red in the following diagram:
The client-server computing architecture is centered around one single special node (the Server node). All other nodes are Client nodes that depend on that single Server node and communicate with that server node with asymmetrical protocols.
This is today’s prevalent computing architecture across the industry.
In P2P Computing, there is only one class of node. All nodes are equal peers to each other, communicating directly with each other through symmetric protocols.
There are two major flavors of Peer Computing:
Homogeneous Peer Computing: while peer nodes may run different applications, all of those applications fundamentally do the same thing. Examples: Bittorrent or E-mail.
Heterogeneous Peer Computing: peer nodes run many different applications, including many with substantially different functionality. Example: the Fediverse with apps such as Mastodon (microblogging), Pixelfed (image sharing) and Lemmy (threaded discussions around bookmarked articles).
- The E-mail network largely implements a homogenous Peer Computing model. It uses the SMTP protocol in a symmetrical fashion so that any Peer may communicate with any other Peer in either direction. Most users interact with those Peers via client-server protocols such as IMAP, POP or TEST.
- The decentralized social media network known as the Fediverse is a largely heterogeneous Peer Computing network, connected with the Fediverse network stack centered around the ActivityPub server-to-server specification. Users interact with the network by going through their Peers from Clients, such as mobile phone Clients or web Clients, using client-server protocols such as the ActivityPub client-to-server spec, the Mastodon API or REST APIs.
- The decentralized communication network formed around the Matrix protocol follows the Peer Computing architecture in a similar way the Fediverse does.
There are others, including XMPP/Jabber and the IndieWeb around the WebMention and related protocols.
Why do we need the term “Peer Computing”?
Today’s prevalent internet application architecture is a client-server architecture in which ever-larger servers, controlled by a small number of ever-larger and typically – to their users – unaccountable corporations, provide “walled-garden applications” to an ever-larger number of users. Examples include all large websites, from Facebook to Amazon.
This architecture, when deployed at scale, is known to have many undesirable properties, including:
Unilateral imposition of terms of service on users who often have no practical recourse.
Fostering of natural monopolies through network effects.
Unavoidable unwanted features, such as advertising, algorithmic manipulation or personal data collection.
Temptation of the server operator to extract as much economic value as possible from the users of the client nodes.
Inability for users and third-parties to freely innovate, as the gardens indeed are walled.
As a consequence, many developers and innovators are working, again, on alternate computing architectures that do not have these built-in downsides; or at the minimum, they have different tradeoffs.
The Peer Computing model outlined here is one such architecture that is used widely, such as in the dozens of apps constituting the Fediverse. It needs a name, so an architectural-level discussion of pros and cons can be had, irrespective of particular protocols such as ActivityPub, Matrix or SMTP. We propose Peer Computing.
- Many of the large internet platforms today are internally using the Peer Computing Architecture, for load distribution and availability reasons. However, they hide this fact from the outside world and appear as a single server, so from an architectural perspective, we must treat them as client-server architectures.
Who wrote this?
Feedback? Ping me on the Fediverse at @firstname.lastname@example.org.