CN111277636A - Consensus algorithm for improving conventional PBFT (basic particle beam Fourier transform) - Google Patents

Consensus algorithm for improving conventional PBFT (basic particle beam Fourier transform) Download PDF

Info

Publication number
CN111277636A
CN111277636A CN202010040624.1A CN202010040624A CN111277636A CN 111277636 A CN111277636 A CN 111277636A CN 202010040624 A CN202010040624 A CN 202010040624A CN 111277636 A CN111277636 A CN 111277636A
Authority
CN
China
Prior art keywords
request
algorithm
pbft
node
client
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
CN202010040624.1A
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.)
Chengdu Univeristy of Technology
Original Assignee
Chengdu Univeristy of Technology
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 Chengdu Univeristy of Technology filed Critical Chengdu Univeristy of Technology
Priority to CN202010040624.1A priority Critical patent/CN111277636A/en
Publication of CN111277636A publication Critical patent/CN111277636A/en
Pending legal-status Critical Current

Links

Images

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/10Protocols in which an application is distributed across nodes in the network
    • H04L67/104Peer-to-peer [P2P] networks
    • H04L67/1044Group management mechanisms 
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Theoretical Computer Science (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a consensus algorithm for improving a traditional PBFT (basic capability Fourier transform), which mainly solves the problem that a master node of the traditional PBFT algorithm in the prior art is easy to crash or make errors when the communication complexity is increased. The method comprises (S1) revoking a master node comprised in the conventional PBFT algorithm, such that all node identities in the improved PBFT algorithm are peered; (S2) adding a ranking service to which the client sends a request; (S3) the ordering service sending the ordered request to the replica node; (S4) the replica node operates the request and returns the operation result to the client; (S5) the client receives the same reply from the f +1 different replica nodes, and then takes the reply as a result of the corresponding request. Through the scheme, the invention achieves the purpose of free subscription or quit, and has very high practical value and popularization value.

Description

Consensus algorithm for improving conventional PBFT (basic particle beam Fourier transform)
Technical Field
The invention belongs to the technical field of block chains, and particularly relates to a consensus algorithm for improving a traditional PBFT.
Background
At present, the blockchain is rapidly developed, and a consensus algorithm serving as a core component of the blockchain is researched by a plurality of technical teams. Consensus is the process of achieving a uniform agreement on the state of the network in a decentralized manner. Consensus is mainly classified into final consistency consensus algorithms such as a workload proof algorithm (POW), a stock-based proof algorithm (POS), and a delegated equity proof algorithm (DPOS), etc., strong consistency algorithms such as Paxos algorithm and a practical byzantine fault-tolerant algorithm (PBFT), etc.
The blockchain items are classified into public chains, alliance chains, and private chains. Where the federation chain only allows certified users to participate in billing, PBFT is typically used as a consensus mechanism. The PBFT algorithm requires at least n-3 f +1 nodes to tolerate f rogue nodes (n-3 f +1 nodes also achieve optimal performance, and many nodes will only affect performance). In the conventional PBFT algorithm (as shown in fig. 1), a master node is provided to sequence transactions, and the security and activity of operations are achieved through communication between nodes, but since all nodes issue information, when the number of nodes increases or the PBFT algorithm becomes complicated, the probability of master node downtime or error increases. Therefore, the traditional PBFT algorithm has the defects that when the communication complexity reaches O (n ^2), the performance is rapidly reduced when the number of nodes is increased, and the production and living requirements are difficult to meet.
Disclosure of Invention
The invention aims to provide a consensus algorithm for improving a traditional PBFT (basic capability function), and mainly solves the problem that a master node of the traditional PBFT algorithm is prone to being down or making errors when the communication complexity is increased in the prior art.
In order to achieve the purpose, the technical scheme adopted by the invention is as follows:
a consensus algorithm for improving conventional PBFT comprising the steps of:
(S1) canceling the master node included in the conventional PBFT algorithm, so that all the node identities in the improved PBFT algorithm are equal;
(S2) adding a ranking service to which the client sends a request;
(S3) the ordering service sending the ordered request to the replica node;
(S4) the replica node operates the request and returns the operation result to the client;
(S5) after receiving the same reply from f +1 different replica nodes, the client takes the reply as the result of the corresponding request, wherein f is the number of the rogue replicas, and the total number of the replicas is not less than 3f + 1.
Further, the conventional PBFT algorithm in the step (S1) includes a master node and a replica node, and all nodes in the improved PBFT algorithm are replica nodes.
Further, when the ranking service is added in the step (S2), the replica node can dynamically join or exit the consensus algorithm by subscribing or unsubscribing the ranking service.
Further, the sorting service in the step (S3) is one of a Solo sorting service, a Kafka sorting service, and a Raft sorting service, where the sorting service is connected to the client, receives and sorts the requests sent by the client, and sends the requests to the replica node subscribing to the sorting service after the sorting of the requests is completed.
Specifically, the operation result in the step (S4) includes two execution results, i.e., a request sending and a request receiving, the client sends the request to the ordering service for ordering, and the client receives the execution result returned by the replica node.
Compared with the prior art, the invention has the following beneficial effects:
(1) according to the invention, the main nodes are removed by the traditional PBFT consensus algorithm, and meanwhile, the sequencing service is added to replace the function of the traditional main nodes, so that the situations of main node downtime and errors in the traditional PBFT consensus algorithm are effectively avoided; in addition, due to the introduction of sequencing services, all nodes are copy nodes, and compared with copy nodes in the conventional PBFT consensus algorithm which cannot be freely subscribed and quitted, the improved PBFT consensus algorithm can freely subscribe or quit the whole consensus algorithm, so that the improved PBFT consensus algorithm becomes flexible.
Drawings
FIG. 1 is a block diagram of a conventional PBFT consensus algorithm.
FIG. 2 is a flow chart of the present invention.
Fig. 3 is an overall framework diagram of the present invention.
FIG. 4 is a schematic diagram of a node subscription service according to the present invention.
Detailed Description
The present invention is further illustrated by the following figures and examples, which include, but are not limited to, the following examples.
Examples
As shown in fig. 2 to 4, a consensus algorithm for improving the conventional PBFT comprises the following steps:
(S1) the conventional PBFT algorithm includes a master node and a replica node, and the master node included in the conventional PBFT algorithm is cancelled, so that all the node identities in the improved PBFT algorithm are peered.
(S2) adding sequencing service, sending request to sequencing service by client, identity of all replica nodes is equal, the replica nodes subscribe sequencing service, receiving request from client and executing request, the replica nodes send request result back to client node, then the sequencing service distributes sequenced request to replica nodes subscribing service to subscribe or unsubscribe sequencing service, at the same time, the replica nodes can dynamically join and quit consensus algorithm.
(S3) the node of the ordering service (the ordering service is one of Solo ordering service, Kafka ordering service and Raft ordering service) can be composed of a credible third party or credible node, and sends the ordered request to the replica node, wherein, the ordering service is connected with the client, mainly receives the request sent by the client and orders and numbers the request, and after the ordering of the request is completed, sends the request to the replica node subscribing the ordering service.
(S4) the replica node operates the request and returns the operation result (two execution results of sending request and receiving request) to the client, the client sends the request to the sequencing service for sequencing, and the client receives the execution result returned by the replica node. Wherein the replica node executes the request from the ranking service and returns the ranking result to the client. The replica node may subscribe to the ranking service and join in the consensus process, for example, in fig. 3, the replica node 0, the replica node 1, the replica node 2, and the replica node 3 subscribe to the ranking service, and the replica node 4 does not subscribe to the ranking service and does not join in the consensus.
Fig. 4 shows a specific ranking service — Raft, showing the process of node subscription or exit. As shown in fig. 4, the replica node 3 cancels the subscription service and exits the consensus process, and the replica node 4 subscribes to the ranking service and joins the consensus process.
(S5) the client receives the same reply from f +1 different copies as the result of the corresponding request (because there are only f malicious nodes in the consensus node, one of f +1 same results must come from the normal node).
The above embodiments are only preferred embodiments of the present invention, and are not intended to limit the scope of the present invention, but all changes that can be made by applying the principles of the present invention and performing non-inventive work on the basis of the principles shall fall within the scope of the present invention.

Claims (5)

1. A consensus algorithm for improving conventional PBFT, comprising the steps of:
(S1) canceling the master node included in the conventional PBFT algorithm, so that all the node identities in the improved PBFT algorithm are equal;
(S2) adding a ranking service to which the client sends a request;
(S3) the ordering service sending the ordered request to the replica node;
(S4) the replica node operates the request and returns the operation result to the client;
(S5) after receiving the same reply from f +1 different replica nodes, the client takes the reply as the result of the corresponding request, wherein f is the number of the rogue replicas, and the total number of the replicas is not less than 3f + 1.
2. The consensus algorithm for improving conventional PBFT as claimed in claim 1, wherein the conventional PBFT algorithm in step (S1) comprises a main node and a replica node, and the nodes in the improved PBFT algorithm are both replica nodes.
3. A consensus algorithm for improving the conventional PBFT according to claim 2, wherein a ranking service is added in said step (S2), and the replica node can dynamically join or exit the consensus algorithm by subscribing or unsubscribing the ranking service.
4. The consensus algorithm for improving conventional PBFT as claimed in claim 3, wherein the ranking service in step (S3) is one of Solo ranking service, Kafka ranking service and Raft ranking service, wherein the ranking service is connected to the client, receives the request from the client and ranks the request, and sends the request to the replica node subscribing to the ranking service after the request ranking is completed.
5. The consensus algorithm of claim 4, wherein the results of the operations in step (S4) comprise sending requests and receiving requests, wherein the client sends the requests to the ordering service for ordering, and wherein the client receives the results from the replica node.
CN202010040624.1A 2020-01-15 2020-01-15 Consensus algorithm for improving conventional PBFT (basic particle beam Fourier transform) Pending CN111277636A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010040624.1A CN111277636A (en) 2020-01-15 2020-01-15 Consensus algorithm for improving conventional PBFT (basic particle beam Fourier transform)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010040624.1A CN111277636A (en) 2020-01-15 2020-01-15 Consensus algorithm for improving conventional PBFT (basic particle beam Fourier transform)

Publications (1)

Publication Number Publication Date
CN111277636A true CN111277636A (en) 2020-06-12

Family

ID=71002164

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010040624.1A Pending CN111277636A (en) 2020-01-15 2020-01-15 Consensus algorithm for improving conventional PBFT (basic particle beam Fourier transform)

Country Status (1)

Country Link
CN (1) CN111277636A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114244859A (en) * 2022-02-23 2022-03-25 阿里云计算有限公司 Data processing method and device and electronic equipment
CN117527834A (en) * 2024-01-04 2024-02-06 成都理工大学 Improved PBFT consensus method based on reputation scoring mechanism

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109756558A (en) * 2018-12-04 2019-05-14 广州通链计算机智能技术有限责任公司 A kind of Byzantine failure tolerance common recognition algorithm based on asynchronous packet switching
US20190179939A1 (en) * 2017-12-11 2019-06-13 International Business Machines Corporation Distributed database having blockchain attributes
CN109981565A (en) * 2019-01-29 2019-07-05 广州中国科学院软件应用技术研究所 Block platform chain and implementation method based on Meta-BFT common recognition mechanism
CN110111102A (en) * 2019-03-29 2019-08-09 广东岭南通股份有限公司 A kind of virtual traffic card system and distribution method of commerce based on block chain technology

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20190179939A1 (en) * 2017-12-11 2019-06-13 International Business Machines Corporation Distributed database having blockchain attributes
CN109756558A (en) * 2018-12-04 2019-05-14 广州通链计算机智能技术有限责任公司 A kind of Byzantine failure tolerance common recognition algorithm based on asynchronous packet switching
CN109981565A (en) * 2019-01-29 2019-07-05 广州中国科学院软件应用技术研究所 Block platform chain and implementation method based on Meta-BFT common recognition mechanism
CN110111102A (en) * 2019-03-29 2019-08-09 广东岭南通股份有限公司 A kind of virtual traffic card system and distribution method of commerce based on block chain technology

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114244859A (en) * 2022-02-23 2022-03-25 阿里云计算有限公司 Data processing method and device and electronic equipment
CN117527834A (en) * 2024-01-04 2024-02-06 成都理工大学 Improved PBFT consensus method based on reputation scoring mechanism
CN117527834B (en) * 2024-01-04 2024-03-26 成都理工大学 Improved PBFT consensus method based on reputation scoring mechanism

Similar Documents

Publication Publication Date Title
Hong et al. Pyramid: A layered sharding blockchain system
CN111311414A (en) Block chain multi-party consensus method based on consistent hash algorithm
CN110677485A (en) Dynamic layered Byzantine fault-tolerant consensus method based on credit
Kleineberg et al. Evolution of the digital society reveals balance between viral and mass media influence
CN109189751A (en) Method of data synchronization and terminal device based on block chain
Hu et al. CRSM: An effective blockchain consensus resource slicing model for real-time distributed energy trading
CN111277636A (en) Consensus algorithm for improving conventional PBFT (basic particle beam Fourier transform)
CN114050904B (en) Consensus system and method based on two-level leader node fragmentation structure
CN112118321A (en) Practical Byzantine fault-tolerant consensus mechanism optimization system of industrial block chain
CN105988862A (en) Distributed transaction processing method and device
CN111179087B (en) Alliance chain consensus method based on grid arbitration
Ganesh et al. Broadcast extensions with optimal communication and round complexity
Malkhi et al. Efficient update diffusion in byzantine environments
CN114663104A (en) PBFT based on block chain product supply chain tracing
Zhong et al. Improve PBFT based on hash ring
Chen et al. Improvement of the DPoS consensus mechanism in blockchain based on PLTS
CN106357604A (en) Cumulative, cooperative assembly method for consistent data
Liu et al. Blockchain based storage and verification scheme of credible degree certificate
CN114499874B (en) Bayesian-busy-family fault-tolerant consensus optimization method applied to industrial Internet
CN114595051B (en) Method and system for enhancing cloud computing cooperative data processing and electronic equipment
CN115643008A (en) PBFT algorithm based on partition clustering
CN115174090A (en) Block chain consensus method and device
CN114499824A (en) Node system of block chain and cooperation method thereof
Su et al. Fully decentralized application model by peer to peer smart contract of blockchain
Huang et al. Design and analysis of a distributed consensus protocol for real-time blockchain systems

Legal Events

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

Application publication date: 20200612

RJ01 Rejection of invention patent application after publication