CN104539728A - P2P transmission method and system based on AP - Google Patents

P2P transmission method and system based on AP Download PDF

Info

Publication number
CN104539728A
CN104539728A CN201510020819.9A CN201510020819A CN104539728A CN 104539728 A CN104539728 A CN 104539728A CN 201510020819 A CN201510020819 A CN 201510020819A CN 104539728 A CN104539728 A CN 104539728A
Authority
CN
China
Prior art keywords
seed file
message
matched
file
server
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201510020819.9A
Other languages
Chinese (zh)
Inventor
龙峻
白帆
袁洪
王彦青
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
BEIJING GUOCHUANG FUSHENG COMMUNICATION Co Ltd
Original Assignee
BEIJING GUOCHUANG FUSHENG COMMUNICATION Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by BEIJING GUOCHUANG FUSHENG COMMUNICATION Co Ltd filed Critical BEIJING GUOCHUANG FUSHENG COMMUNICATION Co Ltd
Priority to CN201510020819.9A priority Critical patent/CN104539728A/en
Publication of CN104539728A publication Critical patent/CN104539728A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/104Peer-to-peer [P2P] networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a P2P transmission method based on an AP. The method comprises the steps that a message is received through a server and a handshake protocol, and the accuracy of the message is judged according to the handshake protocol; when the judgment result shows that the message is accurate, the server judges the state of the server; when the state of the server is active, the server judges whether a message information seed file exists or not according to the message information; when the seed file does not exist, a seed file request message is sent; the seed file request message is received through the server, and the seed file message is stored in a middle pipeline; the information in the middle pipeline is read, and searched for the seed file according to the seed file request message; when the seed file is found, the seed file information is sent to the pipeline; the pipeline receives the seed file, and the seed file is sent to a user side. The P2P transmission method has the advantages that the pipeline transmission technology, the circular linked list neighbor technology and an event driving combining method are adopted, and the file transmission precision and efficiency are effectively improved.

Description

A kind of P2P transmission method based on AP and system
Technical field
The present invention relates to computer networking technology, specifically, relate to a kind of P2P transmission method based on AP and system.
Background technology
WAP (wireless access point) and wireless aps ( access Point) it is the access point of a wireless network, mainly contain route switching access equipment integrating and pure access point apparatus, equipment integrating performs access and route work, pure access device is only responsible for the access of wireless client, pure access device uses usually used as wireless network expansion, be connected with other AP or main AP, to expand wireless coverage, and equipment integrating is generally the core of wireless network.
P2P computing (Peer to Peer is called for short P2P) can simply be defined as by directly exchanging Sharing computer resource and service, and the network that P2P computing models applying layer is formed is commonly referred to peer-to-peer network.In P2P network environment, thousands of the computers be connected to each other all are in the status of equity, and in general whole network does not rely on special centralized servers.Each computer in network can serve as the requestor of network service, responds again to the request of other computer, provides resource and service.Usually these resources and service comprise: information share and exchange, computational resource (as sharing of CPU), Storage sharing (use as buffer memory and disk space) etc.
And in the prior art, the communication technology the popularizing also at made rapid progress along with wireless device of wireless, how to improve communication speed and the access quality of equipment room, become enterprise and improved the basic assignment that faces of self competitiveness, comprised broadcast, multicast, each side such as point-to-point, the method that can improve in theory all has can break-through point, wherein, based on the wire relay broadcasting technology of P2P, engineers, by changing the methods such as communication structure, improves transmission quality; Some method is applied in wireless network, also helpful, but wireless device is limited by hardware constraints, its system environments, and hardware processing capability all cannot compared with main equipment; Therefore, limited resource how is utilized to become one of difficult problem on wireless device.Instantly, domestic each leading enterprise of large IT releases the various wifi connecting TV one after another, both be an application to P2P technology, contrast the effect of various wifi, there is sacrifice speed to carry high-quality, have the Quality advance speed of sacrificing, have and sacrifice size and carry high performance, various wifi feature differs, but all must the transmission quality of limited wireless environment instability and the more small and weak hardware processing capability of relatively limited environment.
Transmission technology existing many-side on network of P2P is applied and reaches its maturity, foremost as Bittorrent; The network applications evolve of P2P so far, thoroughly weakens the concept of traditional server and client side, and server and client side's equity is turned to network node, can exchange resource mutually between node.
Because existing cable technology is based on cable network, track stability, be with roomy, hardware is secure, the unobstructed software radix based on this Environment Design is large, can not consider the problems such as packet loss, message size, memory size, hard-disk capacity, but these factors all can be exaggerated in wireless environments, so need when Software for Design to improve serious forgiveness, reduce message size, reduce memory consumption and disk consumption.
For the problem in correlation technique, at present effective solution is not yet proposed.
Summary of the invention
The object of this invention is to provide a kind of P2P transmission method based on AP and system, to overcome currently available technology above shortcomings.
The object of the invention is to be achieved through the following technical solutions:
According to an aspect of the present invention, provide a kind of P2P transmission method based on AP, should comprise the following steps based on the P2P transmission method of AP:
Adopt pre-configured Handshake Protocol to receive message by the server that pre-sets, judge the correctness of message according to described Handshake Protocol;
When judged result be message correct, described server judges oneself state;
When oneself state is active, described server judges whether to exist the seed file matched with described message information prestored according to described message information;
When there is not described seed file, send the seed file request message matched with seed file pre-set;
Described seed file request message is received by the server pre-set, and by described seed file packet storage in the intermediate conduit pre-set;
The information of reading pre-stored in intermediate conduit also according to described seed file request message, searches the seed file matched with seed file request message;
When finding seed file, described seed file information is sent to pipeline;
Seed file described in described conduit acceptor, and send described seed file to user side.
Further, judge that the correctness of message also comprises according to described Handshake Protocol:
When judged result is message error, described server performs the operational order of this message request of release prestored.
Further, described server judges that oneself state also comprises:
Under oneself state is sluggish situation, call the hash function lookup that prestores to prestore and the Resource Block matched with described message, judge whether to exist the seed file matched with described message information prestored according to described Resource Block and message information.
Further, described server judges whether to exist according to described message information the seed file matched with described message information prestored and also comprises:
When there is described seed file, send described seed file.
Further, search the seed file matched with seed file request message described in also to comprise:
When not finding seed file, described server automatically performs the operational order of this message request of release prestored.
According to a further aspect in the invention, provide a kind of P2P transmission system based on AP, should comprise based on the P2P transmission system of AP:
Receive message module, adopting pre-configured Handshake Protocol to receive message for the server by pre-setting, judging the correctness of message according to described Handshake Protocol;
State monitoring module, in judged result be message correct, described server judges oneself state;
Ff module, for being active at oneself state, described server judges whether to exist the seed file matched with described message information prestored according to described message information;
Request message sending module, for when there is not described seed file, sends the seed file request message matched with seed file pre-set;
Receiving memory module, receiving described seed file request message for the server by pre-setting, and by described seed file packet storage in the intermediate conduit pre-set;
File reads and searches module, according to described seed file request message, searches the seed file matched with seed file request message for the information of reading pre-stored in intermediate conduit;
File send module, for when finding seed file, is sent to pipeline by described seed file information;
Receive feedback module, for seed file described in described conduit acceptor, and send described seed file to user side.
Further, judge that the correctness of message also comprises according to described Handshake Protocol:
Program release module, for when judged result is message error, described server performs the operational order of this message request of release prestored.
Further, described server judges that oneself state also comprises:
Function call module, under being sluggish situation at oneself state, call the hash function lookup that prestores to prestore and the Resource Block matched with described message, judge whether to exist the seed file matched with described message information prestored according to described Resource Block and message information.
Further, described server judges whether to exist according to described message information the seed file matched with described message information prestored and also comprises:
File sends submodule, for when there is described seed file, sends described seed file.
Further, search the seed file matched with seed file request message described in also to comprise:
Release procedure submodule, for when not finding seed file, described server automatically performs the operational order of this message request of release prestored.
Beneficial effect of the present invention is: the present invention, by adopting pipeline transmission technology, circular linked list neighbor techniques and event driven Combination application method, has the following advantages:
1, the present invention can carry out multiple threads disk read-write task chain, single task is integrated into multitask, a large amount of disk read-write task can be focused on, be separated disk I/O operation and socket transmission operation, by disk read-write time and network latency parallelization, if the disk read-write time is m, network latency is n, then original m+n is become n (m>n);
2, the way to manage of neighbor node is doubly linked list structure, and be 2 times of single-track link table search efficiency, internal memory increases to O (1) order of magnitude.
Accompanying drawing explanation
In order to be illustrated more clearly in the embodiment of the present invention or technical scheme of the prior art, be briefly described to the accompanying drawing used required in embodiment below, apparently, accompanying drawing in the following describes is only some embodiments of the present invention, for those of ordinary skill in the art, under the prerequisite not paying creative work, other accompanying drawing can also be obtained according to these accompanying drawings.
Fig. 1 is that the P2P of a kind of P2P transmission method based on AP according to the embodiment of the present invention shakes hands and the schematic flow sheet of file transfer;
Fig. 2 is the schematic flow sheet of the seed file transmission of a kind of P2P transmission method based on AP according to the embodiment of the present invention;
Fig. 3 is the structural representation of a kind of P2P transmission system based on AP according to the embodiment of the present invention;
Fig. 4 is the flow chart of data processing schematic diagram of a kind of P2P transmission method based on AP according to the embodiment of the present invention.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, be clearly and completely described the technical scheme in the embodiment of the present invention, obviously, described embodiment is only the present invention's part embodiment, instead of whole embodiments.Based on the embodiment in the present invention, the every other embodiment that those of ordinary skill in the art obtain, all belongs to the scope of protection of the invention.
As Figure 1-4, according to the embodiment of the present invention according to an aspect of the present invention, provide a kind of P2P transmission method based on AP, should comprise the following steps based on the P2P transmission method of AP:
Adopt pre-configured Handshake Protocol to receive message by the server that pre-sets, judge the correctness of message according to described Handshake Protocol;
When judged result be message correct, described server judges oneself state;
When oneself state is active, described server judges whether to exist the seed file matched with described message information prestored according to described message information;
When there is not described seed file, send the seed file request message matched with seed file pre-set;
Described seed file request message is received by the server pre-set, and by described seed file packet storage in the intermediate conduit pre-set;
The information of reading pre-stored in intermediate conduit also according to described seed file request message, searches the seed file matched with seed file request message;
When finding seed file, described seed file information is sent to pipeline;
Seed file described in described conduit acceptor, and send described seed file to user side.
Judge that the correctness of message also comprises according to described Handshake Protocol:
When judged result is message error, described server performs the operational order of this message request of release prestored.
Described server judges that oneself state also comprises:
Under oneself state is sluggish situation, call the hash function lookup that prestores to prestore and the Resource Block matched with described message, judge whether to exist the seed file matched with described message information prestored according to described Resource Block and message information.
Described server judges whether to exist according to described message information the seed file matched with described message information prestored and also comprises:
When there is described seed file, send described seed file.
The described seed file matched with seed file request message of searching also comprises:
When not finding seed file, described server automatically performs the operational order of this message request of release prestored.
According to a further aspect in the invention, provide a kind of P2P transmission system based on AP, should comprise based on the P2P transmission system of AP:
Receive message module, adopting pre-configured Handshake Protocol to receive message for the server by pre-setting, judging the correctness of message according to described Handshake Protocol;
State monitoring module, in judged result be message correct, described server judges oneself state;
Ff module, for being active at oneself state, described server judges whether to exist the seed file matched with described message information prestored according to described message information;
Request message sending module, for when there is not described seed file, sends the seed file request message matched with seed file pre-set;
Receiving memory module, receiving described seed file request message for the server by pre-setting, and by described seed file packet storage in the intermediate conduit pre-set;
File reads and searches module, according to described seed file request message, searches the seed file matched with seed file request message for the information of reading pre-stored in intermediate conduit;
File send module, for when finding seed file, is sent to pipeline by described seed file information;
Receive feedback module, for seed file described in described conduit acceptor, and send described seed file to user side.
Judge that the correctness of message also comprises according to described Handshake Protocol:
Program release module, for when judged result is message error, described server performs the operational order of this message request of release prestored.
Described server judges that oneself state also comprises:
Function call module, under being sluggish situation at oneself state, call the hash function lookup that prestores to prestore and the Resource Block matched with described message, judge whether to exist the seed file matched with described message information prestored according to described Resource Block and message information.
Described server judges whether to exist according to described message information the seed file matched with described message information prestored and also comprises:
File sends submodule, for when there is described seed file, sends described seed file.
The described seed file matched with seed file request message of searching also comprises:
Release procedure submodule, for when not finding seed file, described server automatically performs the operational order of this message request of release prestored.
During embody rule, also comprise content file transfers flow process in the present invention, and described content file transfers flow process is consistent with seed file transfer process, all adopts line treatment pattern.
In addition, as shown in Figure 3-4, the structure in native system comprises SOURCE, and described SOURCE comprises seed file and can transfer files, cushioned by pipeline, and open up the transmission of individual threads process disk to pipeline, from pipeline, obtain request message subsequently or reply message, sending peer to.And concrete document transmission process is from disk copy to request or response structure, be copied to afterwards in pipeline, copy to socket queue from pipeline again and be sent to request or response peer, and when file transfer, the priority level of transformation task can be set according to the feature of file, make system can carry out corresponding process according to different priority levels, effectively can improve efficiency of transmission.
In addition, also comprise release procedure operation, use the delet method of more than three kinds during concrete operations in the present invention, in time deletion is transmitted node/be not transmitted node/No Assets node without connected node/time-out.
In addition, in the present invention, also increase anticipation function, judge whether certain transformation task can be performed, to reduce extra transformation task, effectively raise stability and the reliability of system cloud gray model.
Finally, the present invention uses doubly linked list managing neighbor node; Configuration intermediate conduit, as buffering, in conjunction with proprietary protocol, decreases the transmission time.
In sum, by means of technique scheme of the present invention, relative to prior art, the present invention has the following advantages:
1, multiple threads disk read-write task chain, single task is integrated into multitask, a large amount of disk read-write task can be focused on, be separated disk I/O operation and socket transmission operation, by disk read-write time and network latency parallelization, if the disk read-write time is m, network latency is n, then original m+n is become n (m>n);
2, time-out check mechanism eliminates idle task, and three kinds of deletion actions save EMS memory occupation space;
3, the way to manage of neighbor node is doubly linked list structure, and be 2 times of single-track link table search efficiency, internal memory increases to O (1) order of magnitude;
4, anticipation function and task grade classification have used for reference cpu task tupe, and effective message of Class1/4 is preferentially transmitted, and can account for more than 62% of message total.
The foregoing is only preferred embodiment of the present invention, not in order to limit the present invention, within the spirit and principles in the present invention all, any amendment done, equivalent replacement, improvement etc., all should be included within protection scope of the present invention.

Claims (10)

1., based on a P2P transmission method of AP, it is characterized in that, comprise the following steps:
Adopt pre-configured Handshake Protocol to receive message by the server that pre-sets, judge the correctness of message according to described Handshake Protocol;
When judged result be message correct, described server judges oneself state;
When oneself state is active, described server judges whether to exist the seed file matched with described message information prestored according to described message information;
When there is not described seed file, send the seed file request message matched with seed file pre-set;
Described seed file request message is received by the server pre-set, and by described seed file packet storage in the intermediate conduit pre-set;
The information of reading pre-stored in intermediate conduit also according to described seed file request message, searches the seed file matched with seed file request message;
When finding seed file, described seed file information is sent to pipeline;
Seed file described in described conduit acceptor, and send described seed file to user side.
2. the P2P transmission method based on AP according to claim 1, is characterized in that, judges that the correctness of message also comprises according to described Handshake Protocol:
When judged result is message error, described server performs the operational order of this message request of release prestored.
3. the P2P transmission method based on AP according to claim 1, it is characterized in that, described server judges that oneself state also comprises:
Under oneself state is sluggish situation, call the hash function lookup that prestores to prestore and the Resource Block matched with described message, judge whether to exist the seed file matched with described message information prestored according to described Resource Block and message information.
4. the P2P transmission method based on AP according to claim 1, is characterized in that, described server judges whether to exist according to described message information the seed file matched with described message information prestored and also comprises:
When there is described seed file, send described seed file.
5. the P2P transmission method based on AP according to claim 1, is characterized in that, described in search the seed file matched with seed file request message and also comprise:
When not finding seed file, described server automatically performs the operational order of this message request of release prestored.
6., based on a P2P transmission system of AP, it is characterized in that, comprising:
Receive message module, adopting pre-configured Handshake Protocol to receive message for the server by pre-setting, judging the correctness of message according to described Handshake Protocol;
State monitoring module, in judged result be message correct, described server judges oneself state;
Ff module, for being active at oneself state, described server judges whether to exist the seed file matched with described message information prestored according to described message information;
Request message sending module, for when there is not described seed file, sends the seed file request message matched with seed file pre-set;
Receiving memory module, receiving described seed file request message for the server by pre-setting, and by described seed file packet storage in the intermediate conduit pre-set;
File reads and searches module, according to described seed file request message, searches the seed file matched with seed file request message for the information of reading pre-stored in intermediate conduit;
File send module, for when finding seed file, is sent to pipeline by described seed file information;
Receive feedback module, for seed file described in described conduit acceptor, and send described seed file to user side.
7. the P2P transmission system based on AP according to claim 6, is characterized in that, judges that the correctness of message also comprises according to described Handshake Protocol:
Program release module, for when judged result is message error, described server performs the operational order of this message request of release prestored.
8. the P2P transmission system based on AP according to claim 6, it is characterized in that, described server judges that oneself state also comprises:
Function call module, under being sluggish situation at oneself state, call the hash function lookup that prestores to prestore and the Resource Block matched with described message, judge whether to exist the seed file matched with described message information prestored according to described Resource Block and message information.
9. the P2P transmission system based on AP according to claim 6, is characterized in that, described server judges whether to exist according to described message information the seed file matched with described message information prestored and also comprises:
File sends submodule, for when there is described seed file, sends described seed file.
10. the P2P transmission system based on AP according to claim 6, is characterized in that, described in search the seed file matched with seed file request message and also comprise:
Release procedure submodule, for when not finding seed file, described server automatically performs the operational order of this message request of release prestored.
CN201510020819.9A 2015-01-15 2015-01-15 P2P transmission method and system based on AP Pending CN104539728A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510020819.9A CN104539728A (en) 2015-01-15 2015-01-15 P2P transmission method and system based on AP

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510020819.9A CN104539728A (en) 2015-01-15 2015-01-15 P2P transmission method and system based on AP

Publications (1)

Publication Number Publication Date
CN104539728A true CN104539728A (en) 2015-04-22

Family

ID=52855195

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510020819.9A Pending CN104539728A (en) 2015-01-15 2015-01-15 P2P transmission method and system based on AP

Country Status (1)

Country Link
CN (1) CN104539728A (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101662508A (en) * 2009-09-11 2010-03-03 华为技术有限公司 Method for data transmission based on point-to-point protocol, device and system thereof
EP2216958A1 (en) * 2009-02-10 2010-08-11 Alcatel Lucent Method and device for reconstructing torrent content metadata
CN101841558A (en) * 2010-03-23 2010-09-22 中国科学院计算技术研究所 Method and system for downloading resource in P2SP network
CN102130964A (en) * 2011-04-11 2011-07-20 成都市华为赛门铁克科技有限公司 Method for acquiring bit torrent (BT) seed file and relevant devices
CN103248666A (en) * 2012-02-14 2013-08-14 深圳市腾讯计算机系统有限公司 System, method and device for offline resource download

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2216958A1 (en) * 2009-02-10 2010-08-11 Alcatel Lucent Method and device for reconstructing torrent content metadata
CN101662508A (en) * 2009-09-11 2010-03-03 华为技术有限公司 Method for data transmission based on point-to-point protocol, device and system thereof
CN101841558A (en) * 2010-03-23 2010-09-22 中国科学院计算技术研究所 Method and system for downloading resource in P2SP network
CN102130964A (en) * 2011-04-11 2011-07-20 成都市华为赛门铁克科技有限公司 Method for acquiring bit torrent (BT) seed file and relevant devices
CN103248666A (en) * 2012-02-14 2013-08-14 深圳市腾讯计算机系统有限公司 System, method and device for offline resource download

Similar Documents

Publication Publication Date Title
CN108268208B (en) RDMA (remote direct memory Access) -based distributed memory file system
CN111277616B (en) RDMA-based data transmission method and distributed shared memory system
US10681127B2 (en) File upload method and system
US9143452B2 (en) Data processing
JP4696089B2 (en) Distributed storage system
CN103780679B (en) Long delay remote invocation method based on http protocol
CN103581245A (en) Content delivery method and system of content delivery network
US9392081B2 (en) Method and device for sending requests
WO2015062228A1 (en) Method and device for accessing shared memory
CN109088829A (en) Data scheduling method, device, storage medium and equipment
US20140143339A1 (en) Method, apparatus, and system for resource sharing
US9967360B2 (en) Method and system for information exchange utilizing an asynchronous persistent store protocol
CN103475682A (en) File transfer method and file transfer equipment
US11922059B2 (en) Method and device for distributed data storage
US20150088995A1 (en) Method and apparatus for sharing contents using information of group change in content oriented network environment
CN113259415B (en) Network message processing method and device and network server
WO2022242361A1 (en) Data download method and apparatus, computer device and storage medium
CN110213338A (en) A kind of clustering acceleration calculating method and system based on cryptographic calculation
CN101064715A (en) Realization of embedded system based P2P technique
CN106330994A (en) User message publishing method and system
US20090132582A1 (en) Processor-server hybrid system for processing data
EP3939236B1 (en) Node and cluster management on distributed self-governed ecosystem
CN102427474B (en) Data transmission system in cloud storage
CN104539727A (en) Cache method and system based on AP platform
TWI571077B (en) Integration network device and service integration method thereof

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20150422

RJ01 Rejection of invention patent application after publication