Wednesday, May 2, 2007

Generic P2P Architecture, Tutorial and Example

Generic P2P Architecture, Tutorial and Example - The Code Project - VB / VBScript



Download source code - 16.8 Kb
This generic P2P architecture tutorial was brought to you by Planet API – Searching thousands of ASPX / ASP.NET Public Webmethods / Public Webservices, Search Engine APIs, Novelty APIs, B2B APIs, Game APIs, P2P APIs, Fun APIs, AI Chatbot APIs, etc.
Overview of P2P Culture
P2P (Peer To Peer) is when multiple computers think collectively towards a shared objective. Computer programs that use less central servers and rely on a collection of computers such as Gnutella, distributed media streaming, networks of DCC based IRC fservers etc. tend to be referred to as being more P2P. Computer programs where many end-users communicate with few central services tend to be referred to as being less P2P or not P2P. To fully understand and leverage P2P technology, one must separate his or her self from the dogma that our computer programs must be united by servers in our physical possession to synchronize activities. Rather, think of our computer programs from a more digital-life oriented perspective and break the computer software up over multiple machines and make no single part of the software critical to the collective objective.
P2P Philosophy
“Single servants are less powerful then a single server but the collective of many servants is more powerful then any single server” - Daniel Stephen Rule.
For example, a large software company gives each employee a very small amount of responsibility. Even if this means you get your month’s coding done in a few days, it is more beneficial to the company as a whole to not rely on any single employee too much and allows the company more overall stability and to ultimately write larger more complex software packages than any single person is capable of. Your software is more P2P if you leverage this same principle to achieve more bandwidth and computing speed.
Basic P2P Terminology
Peer or Servant
A computer program that acts as both a client and a server for the entire P2P network.
Connection Manager
A light server application that provides a starting point for applications which enter a P2P network. The less the connection manager is involved in the objective of your overall application, the more P2P your application is. The more P2P your application is, the less strain on your own hardware.