Draft P2P distribution engine Protocol

Source: Internet
Author: User
Draft P2P distribution engine Protocol
I. Classification of P2P models

1. Static configuration model.
It is a relatively static and simple peer-to-peer positioning model. In this model
Point exactly knows where other peer points exist in the P2P network and what they provide
Share Resource content. It has a stable performance advantage when the entire network is under attack,
Unexpected random events and changes to the temporary status on the network cannot be handled. For example
The peer randomly enters and exits the network. Therefore, it cannot be applied in the actual environment.
2. dynamic configuration model (directory type)
In the dynamic configuration model, one or more servers are used to provide
Special Network Configuration Service. All peer information (such as name) is recorded in the configuration service.
Address resource metadata Status). Peer-to-Peer queries are used to determine the information they are interested in.
Bit. Napster is an example of using a dynamic configuration model. It improves the network
Manageability facilitates shared query and update of resources. But it also has a network
Security and cost problems.
3. dynamic configuration model (network type)
It consists of many Peer Points, which are functionally similar. No special
Directory Server. Peers must be located on the network where they are located to locate other peers. None
Peer nodes know the structure of the entire network and the identity of each peer in the network. If
They want to know the location of another peer in the network and must broadcast to its adjacent contacts.
Query request, and its neighbor contacts will try to satisfy this request. If these neighbors cannot finish
If all requests are met, the requests will be passed to their neighbors, and so on. Gnutella
It is implemented in this way.
4. dynamic configuration model (hash)
It does not need dedicated servers, and all the peer nodes in the network have a small workload.
Yes. First, assign a virtual address (VID) to each node in the network.
A key is used to indicate the shared content that can be provided. Take a hash function.
The function can convert a key into a hash value H (key ). Adjacent nodes in the network are defined as scattered
The column value is adjacent. The vid indicates the storage location of the document. When the resource is located, you can
Quickly obtain binary groups (Key, VID) based on H (key) to similar nodes to obtain
The storage location of the file.

Ii. P2P engine framework
1. P2P core layer (CORE)
Core functions required to provide services.
For example, peer network ),
Implement basic communication services between peers, such as establishing and revoking peer communication,
Discovery and listening of Peer Points.

Peer group ),
Groups peers based on specific services. A peer can be created, added, or exited.
You can update the relationship of a group member in a group.

Peer code ),
Codec the data exchanged between the peer and the endpoint.

Peer gateway ),
Provides routes, relay, and firewall for peer-to-peer communication data.

Peer security ),
Security Management of communication data, such as data encryption and decryption and peer verification.

Peer Monitor)


2. P2P service layer (services)
Provides common service functions such as information query, positioning, search, distribution, and management.

3. P2P application layer (applications)
Provides complete product application services and scalable intermediate components.
Such as file download, file sharing, personalized news services, instant messaging,
Video/audio communication/on-demand video service.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.