A blockchain leader election method and a blockchain leader election device

A leader and blockchain technology, applied in the information field, can solve the problems of wasting system time, affecting system efficiency, difficulty in balancing efficiency and flexibility, etc., and achieve the effect of taking into account the effects, high efficiency, and preventing the absence of leaders

Inactive Publication Date: 2019-05-07
王春峰
View PDF4 Cites 7 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] The current leader election algorithm is difficult to take into account efficiency and flexibility; some use simple election algorithms, such as the method based on the node serial number in the Practical Byzantine Fault Tolerant Algorithm (PBFT); some are flexible, but rely on many computer hardware factors as Election factors, such as IP address, number of CPU cores, memory size, custom serial number, etc., need to go through the random calculation election mechanism of the competition window, which wastes system time and affects system efficiency

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • A blockchain leader election method and a blockchain leader election device
  • A blockchain leader election method and a blockchain leader election device
  • A blockchain leader election method and a blockchain leader election device

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0053] A blockchain leader election method provided in this embodiment includes

[0054] Step 1: Multiple nodes constituting a licensed chain include several core nodes, which are certified and authorized to participate in the leader election of the consensus algorithm and may become leaders in the licensed chain; all core nodes Constitutes a set of core nodes;

[0055] figure 1 It is a structural diagram of node deployment in the license chain in this embodiment. like figure 1 As shown, in the permission chain, there are 6 nodes, wherein nodes 101, 102, 103 and 104 are core nodes, and constitute a core node set 100={101, 102, 103, 104}, and nodes 105, 106 are non-core nodes .

[0056] Each core node (that is, all core nodes 101-104) periodically calculates its own node capabilities, and periodically broadcasts its status and capabilities to other core nodes, so that the current leader node and the entire network understand the status of this node, And maintain the latest...

Embodiment 2

[0091] This embodiment discloses a leader election device for leader election. The election device may be a hardware unit in a server or a software module. from figure 2 It can be seen from the figure that the leader election device 200 for leader election includes a node state maintenance module 201, a candidate node maintenance module 202, a node capability calculation module 203, an inter-node communication module 204, a system information module 205 and a configuration policy management module 206 composition.

[0092] The node state maintenance module 201 manages and maintains the state transition of the core node, obtains the capability information of the nodes in the license chain from the node capability calculation module 203 according to preset policies or rules, and obtains the capability information of the nodes in the license chain from the candidate node maintenance module 202 and the inter-node communication module 204 Obtain the state of the core node and mai...

Embodiment 3

[0099] This embodiment discloses a main flow of a leader election method. like image 3 As shown, based on this process, the leader election device can automatically maintain the state of the nodes, and can automatically run the consensus algorithm between each core node, thereby ensuring the consistency of information in the system. The algorithm includes:

[0100] Step S1: When any new node joins the core node set, its initial state is the candidate state. The candidate node first collects its own node capability information and sends it to all other core nodes through capability announcement.

[0101] Step S2: The candidate node listens to the current leader announcement (announcement or advertisement information sent by the current leader node) or backup node announcement (announcement or advertisement information sent by the candidate node) in the permission chain;

[0102] Step S2.1: Judging whether the current leader announcement or the backup node announcement is rec...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention provides a blockchain leader election method and a blockchain leader election device. According to the method, the backup node is determined in advance according to the node capability and the established strategy, so that leader node alternation is quickly realized after expiration or under emergency conditions, the core node can be quickly converted into the selected node, and a new leader node is quickly selected in a voting manner, so that the leader vacancy in a permission chain is prevented. Therefore, the leader is high in alternation speed and high in efficiency, and themethod and device can select a relatively complex node selection rule, and give consideration to the effect, the efficiency and the flexibility.

Description

technical field [0001] The present invention relates to the field of information technology, in particular to a blockchain leader election method and device thereof. Background technique [0002] Blockchain is a distributed system, and consistency is a key issue in distributed systems. The so-called consistency means: for multiple service nodes in the system, under the guarantee of the consensus mechanism, multiple service nodes reach a consensus on the processing results. Therefore, the blockchain solves the problem of mutual trust and consistency between nodes in a distributed scenario with the help of a consensus mechanism. [0003] The consensus mechanism methods used in the existing blockchain include: Proof of Work (POW), Proof of Stake (POS), Practical Byzantine Fault Tolerant Algorithm (PBFT), and Raft. Some consensus algorithms are suitable for public chains, and some are suitable for permissioned chains (consortium chains and private chains). In the permissioned...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): H04L12/24H04L29/08
Inventor 王春峰李军
Owner 王春峰
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products