Background
Currently, P2P file sharing is one of the most popular P2P applications. The P2P file sharing systems (e.g., BitTorrent, Napster, and Gnutella) have successfully attracted hundreds of millions of users. BitTorrent, one of the most successful P2P distributed file systems, supports over 1 billion online users. It has a large-scale deployment with thousands of nodes connected each day. Due to the fact that the number of nodes in the system is large, the behavior of taking a free car easily occurs under the condition that an incentive mechanism is not available. Nodes do not contribute when downloading resources greedily, resulting in an imbalance between uploading and downloading, causing other nodes to lose power for sharing as well. The greatest challenge of this system is therefore to provide incentives in an efficient, safe and practical manner.
There are many successful studies on P2P file sharing and its incentive mechanism today, such as the Tit-for-Tat policy, reputation management system or credit-based approach. From the above approaches, it can be seen that most reputation-based and credit-based incentive measures rely on a central trusted authority to improve efficiency and confidence. In the actual P2P system, it is difficult to find a third party trusted authority, which brings difficulties to the efficient and reliable implementation of the incentive scheme. The distributed technology of the block chain provides a potential solution for the distributed technology. Nakamoto published his famous paper in 2008, which introduced a practical blockchain consensus protocol, later referred to as bitcoin protocol. The protocol realizes a set of mechanism, so that nodes which are not trusted mutually can achieve consensus and jointly maintain an account book. The node uses the bitcoin to trade, the trade record confirmed by the account book can not be modified, and the consensus can be achieved without a third-party trusted institution. The first generation blockchain is primarily used as a decentralized digital distributed book for economic transactions until intelligent contracts emerge.
The intelligent contract is a script language embedded in a blockchain network and can provide rich functions. EtherFang is one of the most representative intelligent contract platforms. The etherhouse executes stack-based turing-complete language and manipulates blockchain state using the Etherhouse Virtual Machine (EVM). Rights and obligations of participating nodes, conditions triggering contract execution, and corresponding results of execution are specified in the intelligent contract. Current smart contracts still cannot afford heavy computational tasks and storage loads.
Through the above analysis, the problems and defects of the prior art are as follows: current smart contracts still cannot withstand the heavy computational tasks and storage loads.
The difficulty in solving the above problems and defects is:
1. most incentive methods for solving the problem of taking a free car in the distributed file sharing system need a trusted third party organization for guarantee. However, in a distributed system, it is difficult to find a third party trusted authority to efficiently and reliably execute the incentive scheme.
2. The existing reputation and reputation incentive methods cannot achieve the circulation of incentives in the system, and only increase or decrease the reputation value singly. Once the reputation of the user is too low, the account can be abandoned directly, and the problem of taking a free car cannot be well solved
The significance of solving the problems and the defects is as follows: and (3) a nested incentive method is used, downloading resources are paid, and nodes which actively respond to transaction requests and help file propagation are rewarded. The problem of carrying a free car in the distributed file sharing system is better solved, so that the system user activity is high, and the benign operation of the system is maintained.
Disclosure of Invention
Aiming at the problems in the prior art, the invention provides a nesting excitation method, a nesting excitation system and application of a distributed file sharing system.
The invention is realized in such a way that a nesting excitation method of a distributed file sharing system comprises the following steps:
nodes for helping file transmission are rewarded, the problem of taking a free bus in the distributed file sharing system is solved, and the user activity in the system is maintained;
helping the author recruit nodes to become primary suppliers, and scatter storage and transmission resources;
a secondary supplier is attracted to join in file transmission to obtain more incentives;
the primary and secondary providers are distinguished such that in the event that the secondary provider also receives a reward, the primary provider receives a greater reward, attracting the node to become the primary provider.
1. The system comprises an author, a primary supplier, a secondary supplier and a demander, and is established on a block chain system supporting an intelligent contract:
the author stores and distributes documents via primary and secondary suppliers, the demander receives documents via primary and secondary suppliers, and the trading and incentive distribution is performed via nested incentive intelligent contracts:
(1) to distribute storage and transmission pressure, authors have attracted primary suppliers to store file blocks using a propagation incentive contract.
(2) In order to prevent the situation that the transaction fails because part of the primary suppliers lose contact and cannot download the files. The author divides the file into blocks, and utilizes Erasure Code (Erasure Code) to carry out redundancy coding, thereby supporting the transaction under the condition that part of suppliers are disconnected.
(3) The creators set the revenue sharing proportion, the nested incentive intelligent contracts are deployed on the block chain, and the transactions and incentive distribution can be automatically executed after the transactions are generated.
(4) The demander purchases the file, carries out the transaction, and after receiving the file from the primary supplier, the intelligent contract executes the transaction and incentive distribution.
(5) After the demander finishes the transaction, the demander joins the file dissemination market to become a secondary supplier.
Further, in order to attract nodes to become primary suppliers and design propagation excitation according to the concept of revenue sharing, the distributed file sharing system nested excitation method adopts a propagation excitation method based on a block chain of a P2P file sharing system, and comprises the following steps:
the method comprises the following steps: the creator divides the file, divides the digital product into k parts, and needs n parts to recover the digital product, so that n file transmitters exist in each successful transaction;
step two: the creator sets the pricing of the digital product as Z, sets the income sharing proportion as tau, and takes tau.Z as the propagation incentive of each successful transaction;
step three: after the transaction is successful, the transmission incentive settlement is carried out, and each transmitter obtains the transmission incentive
Further, in order to distinguish a primary provider from a secondary provider so that the primary provider receives more bonus awards when the secondary provider also receives bonus awards, and further attract nodes to become the primary provider, the nested incentive method for the distributed file sharing system based on the block chain according to the P2P file sharing system is provided with the nested incentive method, which comprises the following steps:
the method comprises the following steps: setting a secondary profit sharing proportion alpha, and transmitting the incentive at the primary stage
Sharing is carried out on the basis of the above steps;
step two: judging the identities of n transmitters;
step three: when the transmitter is a primary supplier, the primary supplier obtains the complete transmission incentive
Step four: when the transmitter is a secondary supplier, the nested excitation is carried out for secondary sharing, and the secondary supplier obtains a part of the propagation excitation
The primary supplier who originally stored the file block gets another part of the propagation stimulus as
Further, the nested excitation method of the distributed file sharing system adopts a nested excitation automatic execution method of a P2P file sharing system based on a block chain, and comprises the following steps:
the method comprises the following steps: setting a digital product as Z, a primary income sharing proportion as tau and a secondary income sharing proportion as alpha;
step two: generating a nested excitation intelligent contract and deploying the contract on the block chain;
step three: and after the transaction is successful, triggering the intelligent contract and automatically executing incentive distribution.
Further, the nesting excitation method of the distributed file sharing system defines the role of nesting excitation of the P2P file sharing system based on block chains, and comprises the following steps:
(1) nodes for helping file transmission are rewarded, the problem of taking a free bus in the distributed file sharing system is solved, and the user activity in the system is maintained;
(2) helping the author recruit nodes to become primary suppliers, decentralize storage and dissemination resources;
(3) and secondary suppliers are attracted to join file propagation to obtain more incentives. (ii) a
(4) To distinguish the primary and secondary providers such that the primary provider receives more of the bonus award in the event the secondary provider also receives the bonus award, further attracting the node to become the primary provider.
It is a further object of the invention to provide a computer device comprising a memory and a processor, the memory storing a computer program which, when executed by the processor, causes the processor to perform the steps of:
nodes for helping file transmission are rewarded, the problem of taking a free bus in the distributed file sharing system is solved, and the user activity in the system is maintained;
helping the author recruit nodes to become primary suppliers, and scatter storage and transmission resources;
a secondary supplier is attracted to join in file transmission to obtain more incentives;
the primary and secondary providers are distinguished such that in the event that the secondary provider also receives a reward, the primary provider receives a greater reward, attracting the node to become the primary provider.
It is another object of the present invention to provide a computer-readable storage medium storing a computer program which, when executed by a processor, causes the processor to perform the steps of:
nodes for helping file transmission are rewarded, the problem of taking a free bus in the distributed file sharing system is solved, and the user activity in the system is maintained;
helping the author recruit nodes to become primary suppliers, and scatter storage and transmission resources;
a secondary supplier is attracted to join in file transmission to obtain more incentives;
the primary and secondary providers are distinguished such that in the event that the secondary provider also receives a reward, the primary provider receives a greater reward, attracting the node to become the primary provider.
Another object of the present invention is to provide a distributed file sharing system nesting excitation system for implementing the distributed file sharing system nesting excitation method, the distributed file sharing system nesting excitation system comprising:
the system comprises a user activity maintaining module, a data transmission module and a data transmission module, wherein the user activity maintaining module is used for rewarding nodes for helping file transmission, improving the problem of taking a free bus in the distributed file sharing system and maintaining the user activity in the system;
the scattered storage and transmission resource module is used for helping the author recruit nodes to become primary suppliers and scattered storage and transmission resources;
the excitation acquisition module is used for attracting a primary supplier and a secondary supplier to join in file transmission, acquiring excitation and expanding file transmission capacity;
the nested incentive module is used for distinguishing the primary supplier from the secondary supplier, so that under the condition that the secondary supplier obtains the reward, the reward obtained by the primary supplier is more, and the node is attracted to become the primary supplier.
The invention also aims to provide a terminal which carries the nesting incentive system of the distributed file sharing system.
The invention also aims to provide a blockchain network control system which carries the nested excitation system of the distributed file sharing system.
By combining all the technical schemes, the invention has the advantages and positive effects that: there is now much success in the research on P2P file sharing and its incentive mechanisms, such as reputation management systems and credit-based approaches. Reputation systems may help users identify uncooperative peers by monitoring the behavior of neighbors during data transmission and propagating uncooperative reputations in the network, such systems often lacking formal specification and analysis of incentive types and consideration of how to define the reputation of new users. Credit-based methods provide incentives by paying a certain amount of credit or virtual currency to collaborating users, which may be the most promising due to their clear and flexible incentive methods. Most reputation-based and credit-based incentive measures rely on a central trusted authority to improve efficiency and confidence. In the actual P2P system, it is difficult to find a third party trusted authority, which brings difficulties to efficiently and reliably implement the incentive scheme.
The invention solves the problem of no third-party trusted authority by using a block chain technology. The blockchain technique may reach consensus without a trusted third party. Cryptocurrency, as the original application of blockchains, may become the most efficient incentive for distributed file sharing systems. The downloading behavior of the file is replaced by purchasing behavior, and the downloading cost can eliminate the behavior of taking a free car. The creators get authoring incentives, the nodes that help document propagation get propagation incentives, the incentives can stimulate the nodes to create with high quality, are more willing to participate in the document propagation process, and can use the earned incentives on purchasing the required documents. This enables the incentive to be turned around in the system, forming a prototype of the incentive for currency based on block chains.
In the P2P file sharing system of the present invention, there are two kinds of file transferors, one is that the first nodes recruited by the author store files as primary providers, and the other is that the nodes that have subsequently purchased files participate in the propagation and transition to secondary providers. The invention aims to solve the problem that an effective incentive mechanism is lacked in a P2P file sharing system, and the nodes do not make any contribution to greedy underground resource-the behavior of carrying out a vehicle for convenience, so that other nodes are not willing to share, and a system user is inactive. The incentive mechanism is designed with the basic idea of rewarding nodes that respond positively to transaction requests to successfully transfer file blocks. And by utilizing a block chain and an intelligent contract technology, the automatic execution of incentive distribution is realized under the condition of no third-party trusted authority.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is further described in detail with reference to the following embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
Aiming at the problems in the prior art, the invention provides a nesting excitation method, a nesting excitation system and application of a distributed file sharing system, and the invention is described in detail with reference to the attached drawings.
As shown in fig. 1, the nested excitation method for a distributed file sharing system provided by the present invention includes the following steps:
s101: nodes for helping file transmission are rewarded, the problem of taking a free bus in the distributed file sharing system is solved, and the user activity in the system is maintained;
s102: helping the author recruit nodes to become primary suppliers, and scatter storage and transmission resources;
s103: a secondary supplier is attracted to join in file transmission to obtain more incentives;
s104: to distinguish the primary and secondary providers such that the primary provider receives more of the bonus award if the secondary provider also receives the bonus award, the attraction node becomes the primary provider.
Persons of ordinary skill in the art of the nested excitation method for a distributed file sharing system provided by the present invention may also use other steps to implement, and the nested excitation method for a distributed file sharing system provided by the present invention in fig. 1 is only a specific embodiment.
As shown in fig. 2, the nested excitation system of the distributed file sharing system provided by the present invention includes:
the system comprises a user activity maintaining module 1, a file sharing module and a file sharing module, wherein the user activity maintaining module is used for rewarding nodes for helping file transmission, improving the problem of taking a free bus in a distributed file sharing system and maintaining the user activity in the system;
the scattered storage and transmission resource module 2 is used for helping the creators recruit nodes to become primary suppliers and scatter storage and transmission resources;
the excitation acquisition module 3 is used for attracting a primary supplier and a secondary supplier to join in file transmission to obtain more excitation;
the nested incentive module 4 is used for distinguishing the primary supplier from the secondary supplier, so that under the condition that the secondary supplier obtains the reward, the reward obtained by the primary supplier is more, and the nodes are attracted to become the primary supplier.
The technical solution of the present invention is further described below with reference to the accompanying drawings.
The present invention designs a propagation incentive based on the concept of revenue sharing in order to attract nodes to become primary providers. According to the invention, the block chain-based propagation excitation method for the P2P file sharing system is provided, which comprises the following steps:
the method comprises the following steps: the creator divides the file, divides the digital product into k parts, and needs n parts to recover the digital product, so that n file transmitters exist in each successful transaction;
step two: the creator sets the pricing of the digital product as Z, sets the income sharing proportion as tau, and takes tau.Z as the propagation incentive of each successful transaction;
step three: after the transaction is successful, the transmission incentive settlement is carried out, and each transmitter obtains the transmission incentive
The invention sets nested incentives to distinguish between primary and secondary providers so that the primary provider receives more rewards when the secondary provider also receives rewards, further attracting nodes to become the primary provider. The invention provides a nested excitation method of a P2P file sharing system based on a block chain, which comprises the following steps:
the method comprises the following steps: setting a secondary profit sharing proportion alpha, and transmitting the incentive at the primary stage
Sharing is carried out on the basis of the above steps;
step two: judging the identities of n transmitters;
step three: when the transmitter is a primary supplier, the primary supplier obtains the complete transmission incentive
Step four: when the transmitter is a secondary supplier, the nested excitation is carried out for secondary sharing, and the secondary supplier obtains a part of the propagation excitation
The primary supplier who originally stored the file block gets another part of the propagation stimulus as
The invention provides a nested excitation automatic execution method of a P2P file sharing system based on a block chain, which comprises the following steps:
the method comprises the following steps: setting a digital product as Z, a primary income sharing proportion as tau and a secondary income sharing proportion as alpha;
step two: generating a nested excitation intelligent contract and deploying the contract on the block chain;
step three: and after the transaction is successful, triggering the intelligent contract and automatically executing incentive distribution.
The invention defines the role of a P2P file sharing system based on the nesting excitation of block chains, which comprises the following steps:
(1) nodes for assisting file transmission are rewarded to improve the problem of taking the free vehicles in the distributed file sharing system and maintain the activity of users in the system.
(2) The method helps the creators to recruit nodes to become primary suppliers, disperses storage and transmission resources, and reduces bandwidth pressure of the creators.
(3) And a secondary supplier is attracted to add file transmission, so that the transmission capability of resources is enhanced, the greater market demand is met, and further more incentives are obtained.
(4) To distinguish the primary and secondary providers such that the primary provider receives more of the bonus award in the event the secondary provider also receives the bonus award, further attracting the node to become the primary provider.
The technical solution of the present invention is further described with reference to the following specific examples.
According to the embodiment of the invention, the author earns the creation incentive by selling the original works, recruits nodes by giving the transmission incentive to the author, stores and transmits the files as primary suppliers, reduces the storage pressure of the author, and enhances the transmission capability of the files. In a distributed file sharing system, files need to be transmitted in blocks, and an author needs to perform block encoding on the files.
The method comprises the following steps: the author carries out block coding on the file Flie by using an error correcting code, divides the file Flie into 10 parts of R1-R10, and needs 5 parts of the file Flie to be recovered;
step two: recruiting 10 nodes as primary suppliers to respectively store file blocks, wherein the primary supplier F1 stores file blocks R1, F2 stores R2, F3 stores R3, F4 stores R4, F5 stores R5, F6 stores R6, F7 stores R7, F8 stores R8, F9 stores R9 and F10 stores R10;
step three: the author sets the pricing of the file Flie to be 100Coin, sets the primary revenue sharing proportion to be 20%, and sets the total propagation incentive in each successful transaction to be 20Coin, wherein the incentive obtained by each file transmitter is 20/5-4 Coin;
step four: the creator sets the secondary profit sharing proportion to be 30% and is used for distinguishing profits of the first-level provider Fi and the second-level provider Si;
step five: generating a nested excitation intelligent contract to be deployed on the block chain;
step six: the buyer pays 100Coin to purchase the file Flie, and receives 5 file blocks from [ F1-R1, F2-R2, S3-R3, S4-R4 and F5-R5 ];
step seven: triggering an intelligent contract, and judging the identities of 5 transmitters for excitation;
step eight: when the transmitter is a primary supplier, the primary suppliers F1, F2 and F5 obtain complete propagation excitation 4 Coin;
step nine: when the transmitter is a secondary supplier, nested excitation is carried out for secondary sharing, the secondary supplier S3 obtains one part of propagation excitation 1.2Coin, the primary supplier F3 which initially stores R3 obtains the other part of propagation excitation 2.8Coin, the secondary supplier S4 obtains the propagation excitation 1.2Coin, and the primary supplier F4 which initially stores R4 obtains the propagation excitation 2.8 Coin.
Example 2
At the initial stage of file dissemination, only the primary supplier provides file dissemination when no secondary supplier is added to the file dissemination market.
The method comprises the following steps: the author carries out block encoding on the file Flie by using an error correcting code, divides the file Flie into 7 parts [ R1-R7], and needs 4 parts to recover the file Flie;
step two: 7 nodes are recruited as primary suppliers to respectively store file blocks, the primary supplier F1 stores file blocks R1, F2 stores R2, F3 stores R3, F4 stores R4, F5 stores R5, F6 stores R6, and F7 stores R7;
step three: the author sets the pricing of the file Flie to be 100Coin, sets the primary revenue sharing proportion to be 20%, and sets the total propagation incentive in each successful transaction to be 20Coin, wherein the incentive obtained by each file transmitter is 20/4-5 Coin;
step four: the creator sets the secondary profit sharing proportion to be 30% and is used for distinguishing profits of the first-level provider Fi and the second-level provider Si;
step five: generating a nested excitation intelligent contract to be deployed on the block chain;
step six: the buyer pays 100Coin to purchase the file Flie, and receives 4 file blocks from F1-R1, F2-R2, F5-R5 and F6-R6;
step seven: triggering an intelligent contract, and judging the identities of 4 transmitters for excitation;
step eight: the transmitters are all primary suppliers, and the primary suppliers F1, F2, F5 and F6 obtain complete propagation excitation 5 Coin;
example 3
The number of creators recruiting primary providers must exceed the number of recoverable files, as close as possible to the number of encoded redundancies
The method comprises the following steps: the creator divides the file, redundantly encodes the digital product into k parts, and can recover the k parts by n parts;
step two: the author broadcasts k file blocks;
step three: checking the response quantity of the nodes in T time;
step four: if the number of the primary suppliers does not meet the condition, broadcasting the rest file blocks again;
step five: if the number of the primary suppliers is larger than n and is close to k, stopping broadcasting;
step six: and repeating the third step to the fifth step until the condition is met.
The invention realizes the transmission excitation by using the block chain and the intelligent contract technology in an effective, safe and practical mode, and stops the behavior of taking the convenient car. The nested incentive mechanism attracts nodes to participate in the file transmission process, increases the activity of system nodes, and reduces the storage and bandwidth pressure of creators. After obtaining the incentive, the node can be used for purchasing files to realize incentive circulation in the P2P file sharing system.
The technical solution of the present invention is further described with reference to the following specific examples.
According to the theoretical analysis of the nested incentive model, the demand of a market on the digital product is considered firstly, the demand is increased rapidly in a certain time period, the demand is gradually reduced after the heat is passed, the market demand is influenced by time factors, and the market demand shows a trend of increasing first and then decreasing along with the change of time. Assuming that the propagation period of the digital product is [0, T ], the demand function can be expressed as:
D(t)=A·t2·e-ηt (1)
a is the market demand rate which is not influenced by time; eta is the sensitivity coefficient of the demand to time; d (t) is the demand function.
Suppose a file transmitter T
iUnder the transaction requirement at the time t, the probability of successful transaction is P
tThen transmitter T
iPropagation excitation obtained at time t
Comprises the following steps:
when the first supplier F
iAs a transmitter T
iTime, primary supplier F
iPropagating excitation of
Is equal to transmitter T
iExcitation of
When the second supplier S
iAs a transmitter T
iA nested excitation mechanism will be implemented. Primary supplier F
iPropagating excitation of
And secondary supplier S
iExcitation of
Respectively as follows:
then primary supplier F
iTotal propagation excitation obtained at time t
Comprises the following steps:
propagation period [0, T ] in digital products]Inner, primary supplier FiObtained total propagation excitation INFiAnd secondary supplier SiObtained byTotal nested propagation excitation INSiRespectively is as follows:
it can be seen from the above formula that in the transmission process [0, T ], the transmission incentive of the primary supplier is divided into the incentive of the secondary supplier in addition to the part earned by the primary supplier. The nested incentive model can really ensure the benefit maximization of the primary suppliers and is more beneficial for the creators to recruit nodes as the primary suppliers. Nested incentives also encourage secondary providers to join document dissemination to obtain rewards, while also expanding the file dissemination capabilities.
In the description of the present invention, "a plurality" means two or more unless otherwise specified; the terms "upper", "lower", "left", "right", "inner", "outer", "front", "rear", "head", "tail", and the like, indicate orientations or positional relationships based on the orientations or positional relationships shown in the drawings, are only for convenience in describing and simplifying the description, and do not indicate or imply that the device or element referred to must have a particular orientation, be constructed in a particular orientation, and be operated, and thus, should not be construed as limiting the invention. Furthermore, the terms "first," "second," "third," and the like are used for descriptive purposes only and are not to be construed as indicating or implying relative importance.
It should be noted that the embodiments of the present invention can be realized by hardware, software, or a combination of software and hardware. The hardware portion may be implemented using dedicated logic; the software portions may be stored in a memory and executed by a suitable instruction execution system, such as a microprocessor or specially designed hardware. Those skilled in the art will appreciate that the apparatus and methods described above may be implemented using computer executable instructions and/or embodied in processor control code, such code being provided on a carrier medium such as a disk, CD-or DVD-ROM, programmable memory such as read only memory (firmware), or a data carrier such as an optical or electronic signal carrier, for example. The apparatus and its modules of the present invention may be implemented by hardware circuits such as very large scale integrated circuits or gate arrays, semiconductors such as logic chips, transistors, or programmable hardware devices such as field programmable gate arrays, programmable logic devices, etc., or by software executed by various types of processors, or by a combination of hardware circuits and software, e.g., firmware.
The above description is only for the purpose of illustrating the present invention and the appended claims are not to be construed as limiting the scope of the invention, which is intended to cover all modifications, equivalents and improvements that are within the spirit and scope of the invention as defined by the appended claims.