WO2022134471A1 - Blockchain node management method and apparatus, computer device, and storage medium - Google Patents

Blockchain node management method and apparatus, computer device, and storage medium Download PDF

Info

Publication number
WO2022134471A1
WO2022134471A1 PCT/CN2021/097242 CN2021097242W WO2022134471A1 WO 2022134471 A1 WO2022134471 A1 WO 2022134471A1 CN 2021097242 W CN2021097242 W CN 2021097242W WO 2022134471 A1 WO2022134471 A1 WO 2022134471A1
Authority
WO
WIPO (PCT)
Prior art keywords
node
blockchain network
current blockchain
nodes
target node
Prior art date
Application number
PCT/CN2021/097242
Other languages
French (fr)
Chinese (zh)
Inventor
代健武
Original Assignee
平安科技(深圳)有限公司
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 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2022134471A1 publication Critical patent/WO2022134471A1/en

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 
    • H04L67/1053Group management mechanisms  with pre-configuration of logical or physical connections with a determined number of other peers
    • H04L67/1057Group management mechanisms  with pre-configuration of logical or physical connections with a determined number of other peers involving pre-assessment of levels of reputation of peers
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/64Protecting data integrity, e.g. using checksums, certificates or signatures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/62Queue scheduling characterised by scheduling criteria
    • H04L47/625Queue scheduling characterised by scheduling criteria for service slots or service orders
    • H04L47/6275Queue scheduling characterised by scheduling criteria for service slots or service orders based on priority

Definitions

  • the present application relates to the field of blockchain technology, in particular to a management method, device, computer equipment and storage medium for blockchain nodes.
  • the newly added node can receive the same treatment as the node that joined earlier in the blockchain network, and for the unfair problem of the node that joins first, provide a A management method, apparatus, computer equipment and storage medium for a blockchain node.
  • a first aspect provides a method for managing blockchain nodes, including:
  • a node whose duration of joining the current blockchain network meets the preset conditions is selected as a target node, and the target node is given a first authority;
  • the first authority of the target node is updated to a second authority, wherein the authority level of the second authority is higher than that of the first authority permission level.
  • a second aspect provides a method and apparatus for managing a blockchain node, including:
  • the node access unit is used to traverse all the nodes in the current blockchain network to obtain the time information of the state change of each node;
  • the first authority granting unit is used to select a node whose duration of joining the current blockchain network satisfies a preset condition as a target node based on the duration of each node joining the current blockchain network, and assign the target node a first authority;
  • a node scoring unit used to obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records;
  • the second authority granting unit is configured to update the first authority of the target node to a second authority based on the contribution value of each target node in the current blockchain network, wherein the authority level of the second authority A permission level higher than the first permission.
  • a third aspect provides a computer device, including a memory and a processor, where computer-readable instructions are stored in the memory, and when the computer-readable instructions are executed by the processor, cause the processor to perform the following steps:
  • a node whose duration of joining the current blockchain network meets the preset conditions is selected as a target node, and the target node is given a first authority;
  • the first authority of the target node is updated to a second authority, wherein the authority level of the second authority is higher than that of the first authority permission level.
  • a fourth aspect provides a storage medium storing computer-readable instructions, which, when executed by one or more processors, cause the one or more processors to perform the following steps:
  • a node whose duration of joining the current blockchain network meets the preset conditions is selected as a target node, and the target node is given a first authority;
  • the first authority of the target node is updated to a second authority, wherein the authority level of the second authority is higher than that of the first authority permission level.
  • the time information of the state change of each node is obtained, and based on the time information of the state change of each node, it is obtained that each node joins the current blockchain network.
  • a node whose duration of joining the current blockchain network meets the preset conditions is selected as the target node, and the target node is given the first authority;
  • obtain the historical behavior records of each of the target nodes in the current blockchain network and score the target nodes based on the historical behavior records;
  • a permission is updated to a second permission with a higher permission level.
  • this application selects a plurality of newly added nodes as target nodes according to the time when the node joins the current blockchain network, and conducts key observations, and only allocates lower authority (limited authority) to these newly joined target nodes. , and then gradually increase the authority of the target node with high contribution value according to the contribution value of these target nodes in the blockchain network (that is, the authority of the target node is updated from the first authority to the second authority), that is, based on the current blockchain network
  • the contribution value of the middle node realizes the effective management and assistance of the blockchain network.
  • scoring the performance of the target node as the basis for the redistribution of authority, that is, assigning higher authority to the node with higher contribution value.
  • the fine-grained management strategy of nodes in the blockchain network is realized, thereby improving the transaction enthusiasm of nodes.
  • FIG. 1 is a block diagram of the internal structure of a computer device in one embodiment
  • FIG. 2 is a flowchart of a method for managing a blockchain node in one embodiment
  • 3 is another flowchart of a method for managing a blockchain node in one embodiment
  • FIG. 4 is a structural block diagram of an apparatus for managing a blockchain node in an embodiment.
  • first, second, etc. used in this application may be used herein to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish a first element from another element. For example, a first right may be referred to as a second right, and similarly, a second right may be referred to as a second right, without departing from the scope of this application.
  • a computer device and a blockchain node are included.
  • the computer device is a configuration device, for example, a computer device such as a computer, and a dynamic configuration tool with node permissions is installed on the computer device.
  • the management request of the blockchain node can be sent to the computer device, and the computer device receives the management request of the blockchain node and dynamically manages the nodes of the blockchain.
  • the computer device may be a smart phone, a tablet computer, a notebook computer, a desktop computer, etc., but is not limited thereto.
  • FIG. 1 is a schematic diagram of the internal structure of a computer device in one embodiment.
  • the computer device includes a processor, non-volatile storage medium, memory, and a network interface connected by a system bus.
  • the non-volatile storage medium of the computer device stores an operating system, a database and computer-readable instructions
  • the database may store a sequence of control information.
  • the processor can realize a A management method of blockchain nodes.
  • the processor of the computer device is used to provide computing and control capabilities and support the operation of the entire computer device.
  • Computer-readable instructions may be stored in the memory of the computer device, and when the computer-readable instructions are executed by the processor, the processor may execute a method for managing a blockchain node.
  • the network interface of the computer equipment is used for communication with the terminal connection.
  • FIG. 1 is only a block diagram of a partial structure related to the solution of the present application, and does not constitute a limitation on the computer equipment to which the solution of the present application is applied. Include more or fewer components than shown in the figures, or combine certain components, or have a different arrangement of components.
  • a method for managing blockchain nodes is proposed, which may include the following steps:
  • Step 201 traverse all nodes in the current blockchain network to obtain time information of state changes of each node.
  • the current blockchain network may include, but is not limited to, a consortium chain, a public chain, a private chain, and the like.
  • the state of a node may include, but is not limited to, joining state, transaction state, pending invalidation state, and so on. All nodes in the current blockchain network are traversed according to a predetermined time interval to obtain the time information of the state change of each node.
  • the predetermined time interval may be, for example, one day (24h), that is, each node is traversed once at a fixed time point every day.
  • the state change time information of the node such as the time when the node joined the blockchain network.
  • Step 202 Based on the time information of the state change of each node, obtain the time length of each node joining the current blockchain network.
  • the time information (or node generation time) when each node joins the current blockchain network is extracted from the time information of the state change of each node, and the time when each node joins the current blockchain network is the same as the time when each node joins the current blockchain network.
  • the current system time of the management node in the blockchain network is compared (for example, differential processing or time distance calculation processing can be performed) to determine the length of time for all nodes in the current dynamic blockchain network to join the current blockchain network (all nodes The duration of the generation), so that the blockchain network joining time attribute of all nodes can be obtained, which is used to indicate the relationship between the node and the current blockchain network.
  • Step 203 Based on the duration of each node joining the current blockchain network, select a node whose duration of joining the current blockchain network meets a preset condition as a target node, and assign a first authority to the target node.
  • selecting a node whose duration of joining the current blockchain network satisfies a preset condition as a target node refers to selecting multiple newly added nodes (that is, nodes with a shorter duration of joining the current blockchain network) as the target node.
  • the first permission here can be a limited permission.
  • the first permission is the observer permission.
  • the observer permission only has the permission to read the ledger, part of the block transportation and basic data storage permission, but no more advanced permission.
  • the scope of permission is compared. narrow.
  • Step 204 Obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records.
  • the historical behavior record of the target node in the current blockchain network may include, but is not limited to, how much load it has undertaken, how much data has been transmitted, how much storage capacity has been provided, and so on.
  • the method of determining the contribution value of the target node in the current blockchain network may include, but is not limited to, transmitting X blocks X/10 points for other nodes, and executing Y transaction queries (to share how much the blockchain network shares).
  • the query workload on the network Y/8 points, providing Z standard storage blocks for storing data such as shared ledgers on the blockchain network Z points, and then calculating the total score of all behavior records of the target node, the total score Corresponding to the contribution value of the target node in the current blockchain network, for example, the higher the total score of all behavior records of the target node, the greater the contribution value of the target node in the current blockchain network.
  • determining the contribution value of the target node in the current blockchain network based on the historical behavior record may include: assigning a positive or negative score to each historical behavior of each target node, accumulating all the history of each node The scoring result of the behavior obtains the scoring result of the target node, and the contribution value of the target node in the current blockchain network is determined according to the scoring result of the target node.
  • each target node has multiple historical behaviors, and each historical behavior is scored separately, and the final score of each node is the sum of the scores of all historical behavior records.
  • the negative score may include the target node's illegal transaction once -1, the target node's refusal to store the corresponding data once -2, the target node providing service timeout -1 and so on.
  • a step S7 is also included, and this step is used for eliminating the target node when the cumulative scoring result of the target node is lower than the minimum threshold.
  • the target node has fewer positive scores and more negative scores.
  • the final score is less than or equal to 0, the node is removed from the dynamic blockchain network.
  • this embodiment can also increase the minimum threshold, such as 5 points, etc., and the nodes below the minimum threshold will be eliminated. This method helps to urge each node member to actively participate in the operation of the blockchain network, and warns against misoperation Otherwise, the current blockchain network will be eliminated in the case of inaction, less action or wrong action, so that the managed blockchain network will have stronger vitality and vitality.
  • Step 205 Based on the contribution value of each target node in the current blockchain network, update the first authority of the target node to a second authority, wherein the authority level of the second authority is higher than the authority level of the first authority.
  • the scoring result of each target node is related to the historical behavior of the target node, and the historical behavior of the node can reflect the contribution value of the node to the current blockchain network, so based on the scoring results of each target node,
  • the first authority of the target node is updated to the second authority, that is, the corresponding authority of the target node is based on the contribution value of the target node to the current blockchain.
  • this application selects a plurality of newly added nodes as target nodes according to the time when the nodes join the current blockchain network, and is the object of key observation, and only allocates lower authority (limited authority) to these newly joined target nodes. Then, according to the contribution value of these target nodes in the blockchain network, the authority of the target node with high contribution value is gradually increased, that is, the effective management and assistance of the blockchain network is realized based on the contribution value of the nodes in the current blockchain network. , by scoring the performance of the target node as the basis for the redistribution of authority, the fine-grained management strategy of nodes in the blockchain network is realized.
  • step 201 in order to prevent the access to the node from affecting the normal operation of the node, in step 201, all nodes in the current blockchain network are traversed, which may specifically include:
  • Step 2011 Based on the running information of all nodes in the current blockchain network, set the priority of traversing nodes.
  • the operation information of the node may include, but is not limited to, whether the node is running, the load rate at runtime, and the like.
  • Step 2012 Access all nodes in the current blockchain network according to priority.
  • the priority setting rule can be: count the operation information of each node in each time period (including whether it is running, load rate at runtime, etc.) Set the priority, such as 1 point-2 points, A ⁇ C ⁇ E ⁇ G ⁇ B, 2 points-3 points C/G/B/E/A, ... and so on.
  • step 202 in order to discover nodes whose joining time information has been tampered with by the node itself, step 202 , based on the time information of the state changes of each node, obtain the time length of each node joining the current blockchain network, specifically Can include:
  • Step 2021 based on the time information of the state change of each node, extract the time information of the node joining the current blockchain network.
  • the time information of the state change of the node includes at least the time information of the state change of the node joining the blockchain network, so the time information of the node joining the current blockchain network can be extracted according to the time information of the state change of the node.
  • Step 2022 Perform randomness verification on the joining time information of the nodes, and mark the nodes whose joining time information has been tampered with dishonesty.
  • the randomness verification process may include, but is not limited to, collecting historical data on the chain of nodes adjacent to the node to be verified, and based on the node consensus technology, according to most or all of the nodes adjacent to the node to be verified.
  • the chain history data determines whether the node joining time information has been tampered with, which may specifically include: parsing the chain history data of the node adjacent to the node to be verified, and obtaining the join of the current node recorded by the adjacent node according to the analysis result of the chain history data.
  • Time consensus information if most of the joining time consensus information (for example, 95%) is the same as the node joining time, it proves that the node joining time is accurate; otherwise, it is determined that the node information has been tampered with. If it is found that the joining time information of a node has been tampered with by the node itself, the node will be marked.
  • Step 2023 Compare the joining time information of each node with the current system time of the management node in the current blockchain network, and determine the duration of the node joining the current blockchain network.
  • the scoring result of the node marked as dishonest in step 2022 is modified to zero to represent a punishment for dishonest nodes, in other implementations, it may also include: directly removing the dishonest node from the dynamic blockchain network, and restricting the node from being unable to join the current blockchain network for a period of time.
  • step 203 selecting a node whose duration of joining the current blockchain network satisfies a preset condition as a target node may include:
  • Step 2031 Sort all nodes in the current blockchain network based on the duration of each node joining the current blockchain network.
  • all nodes in the current blockchain network can be sorted based on the attribute of the time of joining the blockchain network.
  • the first sorting result of all nodes can be formed according to the joining time from long to short.
  • Step 2032 Select a preset number of nodes ranked at the beginning or end of the sorting result as the target node, or select a node in the sorting result whose duration of joining the current blockchain network is not greater than the preset time threshold as the target node. Wherein, the time for any target node to join the current blockchain network is less than the time for other nodes in the current blockchain network except the target node to join the current blockchain network.
  • selecting a preset number of nodes at the beginning or end of the sorting result as the target node may be to filter out a plurality of nodes with a shorter joining time from the first sorting result or the second sorting result For example, several nodes in the back can be screened out from the first sorting result or several nodes in the front can be screened out from the second sorting result. Focus on long nodes.
  • the node whose duration of joining the current blockchain network is not greater than the preset time threshold in the sorting result as the target node. It can be the node whose joining time is less than or equal to the threshold from the first sorting result or the second sorting result, that is, from the first sorting result or the second sorting result. After a node is found in the sorting result that is less than the threshold, the nodes behind the node in the first sorting result will be filtered out or the nodes in front of the node in the second sorting result will be filtered out. This method helps to improve The computing efficiency helps to realize the technical solution provided by this application more quickly when the blockchain network is complex and there is a lot of data.
  • step 2031 may further include sequentially numbering each node from small to large in the order of time from short to long, for example, starting from 1, 2, 3 .
  • Several nodes can be directly and quickly cut out according to the number, for example, 10 nodes (numbered 1-10) not greater than 10 can be directly screened out.
  • multiple nodes with a short joining time can be implemented in this way.
  • the fast and efficient determination of the algorithm has the outstanding advantages of simple algorithm implementation, small resource occupation, and very fast execution speed.
  • the management method of the blockchain nodes further includes:
  • Step 206 Receive a scoring request from other nodes other than the target node in the current blockchain network.
  • the nodes that are not screened in step 203 can send a scoring request.
  • the corresponding node that sent the scoring request can be included in the target node set, and the node that sent the scoring request can be included in the target node set.
  • a score is determined in step 204 together with other filtered target nodes, and then the requesting target node is assigned permissions according to the score.
  • Step 207 Use the node that issued the scoring request as the target node, and mark the node for scoring.
  • Step 208 Determine the candidate management node of the current blockchain network based on the number of times the target node is scored and marked and/or the authority change of the target node.
  • step 207 the node that sends out the scoring request is recorded and given an identifier A to it, and the authority changes of the nodes given the identifier A are monitored. If the set value is set, for example, it can be 8 times, then these nodes are used as elements in the candidate set of management nodes of the blockchain node. When it is necessary to determine the node for managing the whole or part of the blockchain network as the administrator, A suitable node may be selected as a management node from the candidate set of management nodes.
  • step 205 further includes a step of inspecting the behavior of each target node within a period of time after the current scoring, and then performing a second step on each target node according to the inspection result. Score to give each target node new permissions, and then return to step 1.
  • the investigated items may include but are not limited to how much load is borne, how much data is transmitted, how much storage capacity is provided, etc.
  • Each target node is directly scored based on the contribution made by the target node to the entire blockchain network within this time period, that is, the contribution degree, and in some embodiments, the contribution degree value can be directly used as the score value.
  • a management device for blockchain nodes which can effectively manage and assist the blockchain network based on the contribution value of the nodes in the blockchain network.
  • the device specifically Can include:
  • the node access unit 411 is used to traverse all the nodes in the current blockchain network to obtain the time information of the state change of each node;
  • the joining duration calculation unit 412 is used to obtain the duration of each node joining the current blockchain network based on the time information of the state change of each node;
  • the first authority granting unit 413 is configured to select a node whose duration of joining the current blockchain network satisfies a preset condition as a target node based on the duration of each node joining the current blockchain network, and assign a first authority to the target node;
  • the node scoring unit 414 is used to obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records;
  • the second authority granting unit 415 is configured to update the first authority of the target node to a second authority based on the contribution value of each target node in the current blockchain network, wherein the authority of the second authority The level is higher than the permission level of the first permission.
  • a computer device includes a memory, a processor, and a computer program stored in the memory and running on the processor.
  • the processor executes the computer program, the following steps are implemented: All nodes in the chain network are traversed to obtain the time information of the state change of each node; based on the time information of the state change of each node, the duration of each node joining the current blockchain network is obtained; based on each node joining the current blockchain network Select the node whose duration of joining the current blockchain network meets the preset conditions as the target node, and assign the first authority to the target node; obtain the historical behavior records of each target node in the current blockchain network, based on historical behavior Record the scoring of the target node; based on the scoring results of each target node, update the first authority of the target node to the second authority.
  • the step of traversing all nodes in the current blockchain network performed by the processor includes: setting the priority of traversing nodes based on the running information of all nodes in the current blockchain network; level access to all nodes in the current blockchain network.
  • the step of obtaining the duration of each node joining the current blockchain network based on the time information of the state change of each node executed by the processor includes: based on the time information of the state change of each node, extracting the node to join the current blockchain network.
  • Time information of the blockchain network includes: random verification of the joining time information of nodes to identify whether the joining time information has been tampered with; dishonest marking of nodes whose joining time information has been tampered with; The joining time information of each node except the node marked with dishonesty is compared with the current system time of the management node in the current blockchain network to determine the duration of each node joining the current blockchain network.
  • the processor when the processor executes the computer-readable instructions, the processor further performs the following steps: if it is detected that the scoring result of any node in the current blockchain network is less than the preset score value and/or is marked as dishonest, then Nodes are culled from the current blockchain network.
  • the step of selecting a node whose duration of joining the current blockchain network satisfies a preset condition as the target node performed by the processor includes: based on the duration of each node joining the current blockchain network, determining the current blockchain network All nodes in the network are sorted; select the preset number of nodes at the beginning or end of the sorting result as the target node, or select the one that has been added to the current blockchain network in the sorting result and is not greater than the preset time threshold.
  • the node is the target node; wherein, the time for any target node to join the current blockchain network is less than the time for other nodes in the current blockchain network except the target node to join the current blockchain network.
  • the step of scoring the target node based on the historical behavior record performed by the processor includes: scoring each historical behavior of each target node as positive or negative, and accumulating the scoring results of all historical behaviors of each node Get the scoring result of the target node.
  • the processor when the processor executes the computer-readable instructions, the processor further performs the following steps: receiving a scoring request from other nodes other than the target node in the current blockchain network; taking the node that issued the scoring request as the target node, and assigning a score to the node Carry out scoring and marking; determine the candidate management node of the current blockchain network based on the number of times of scoring and marking of the target node for scoring and marking and/or changes in the authority of the target node.
  • a storage medium storing computer-readable instructions
  • the computer-readable instructions when executed by one or more processors, cause the one or more processors to perform the following steps: All nodes in the chain network are traversed to obtain the time information of the state change of each node; based on the time information of the state change of each node, the duration of each node joining the current blockchain network is obtained; based on each node joining the current blockchain network Select the node whose duration of joining the current blockchain network meets the preset conditions as the target node, and assign the first authority to the target node; obtain the historical behavior records of each target node in the current blockchain network, based on historical behavior Record the scoring of the target node; based on the scoring results of each target node, update the first authority of the target node to the second authority.
  • the step of traversing all nodes in the current blockchain network performed by the processor includes: setting the priority of traversing nodes based on the running information of all nodes in the current blockchain network; level access to all nodes in the current blockchain network.
  • the step of obtaining the time length of each node joining the current blockchain network based on the time information of the state change of each node includes: based on the time information of the state change of each node, extracting the time information of the node joining the current blockchain network Time information; verify the randomness of the joining time information of the nodes, and mark the nodes whose joining time information has been tampered with dishonesty; compare the joining time information of each node with the current system time of the management node in the current blockchain network , to determine the length of time that the node joins the current blockchain network.
  • the processor when the processor executes the computer-readable instructions, the processor further performs the following steps: if it is detected that the node in the current blockchain network satisfies the preset condition, the node is removed from the current blockchain network; wherein, the preset The set conditions include: the scoring result of the node is less than the preset score value and or the node is marked with dishonesty.
  • the step of selecting a node whose duration of joining the current blockchain network satisfies a preset condition as a target node includes:
  • Sort all nodes in the current blockchain network based on the length of time each node has joined the current blockchain network; select a preset number of nodes at the beginning or end of the sorting result as the target node, or, select sorting In the result, the node whose duration of joining the current blockchain network is not greater than the preset time threshold is the target node; among them, the duration of any target node joining the current blockchain network is shorter than that of other nodes except the target node in the current blockchain network The length of time to join the current blockchain network.
  • the step of scoring the target node based on the historical behavior records includes: scoring each historical behavior of each target node as positive or negative, and accumulating the scoring results of all historical behaviors of each node to obtain the score of the target node result.
  • the processor when the processor executes the computer-readable instructions, the processor further performs the following steps: receiving a scoring request from other nodes other than the target node in the current blockchain network; taking the node that issued the scoring request as the target node, and assigning a score to the node Carry out scoring and marking; determine the candidate management node of the current blockchain network based on the number of times of scoring and marking of the target node for scoring and marking and/or changes in the authority of the target node.
  • the realization of all or part of the processes in the methods of the above embodiments can be accomplished by instructing relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium, and the program is During execution, it may include the processes of the embodiments of the above-mentioned methods.
  • the aforementioned storage medium may be a non-volatile storage medium such as a magnetic disk, an optical disc, a read-only memory (Read-Only Memory, ROM), or a volatile storage medium, namely a random access memory (Random Access Memory, RAM), etc.

Abstract

The present application relates to a blockchain node management method and apparatus, a computer device, and a storage medium. The method comprises: traversing all nodes in a current blockchain network to obtain time information of a state change of each node; obtaining, on the basis of the time information of the state change of each node, the duration that each node joins a current blockchain network; selecting, on the basis of the duration that each node joins the current blockchain network, as target nodes the nodes that have joined the current blockchain network for a duration satisfying a preset condition, and giving the target nodes a first permission; obtaining past behavior records of each target node in the current blockchain network, and scoring the target nodes on the basis of the past behavior records; and updating the first permission of the target nodes to a second permission on the basis of the scoring result of each target node. In the present method, permission reallocation is based on scoring of each performance indicator of the nodes, such that a fine-grained management strategy of nodes in a blockchain network is achieved.

Description

区块链节点的管理方法、装置、计算机设备和存储介质Management method, device, computer equipment and storage medium of blockchain node
本申请要求于2020年12月23日提交国家知识产权局、申请号为202011537856.4,发明名称为“区块链节点的管理方法、装置、计算机设备和存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of the Chinese patent application filed on December 23, 2020 with the application number 202011537856.4 of the State Intellectual Property Office, and the invention title is “Management Method, Device, Computer Equipment and Storage Medium for Blockchain Nodes”, which The entire contents of this application are incorporated by reference.
技术领域technical field
本申请涉及区块链技术领域,特别是区块链节点的管理方法、装置、计算机设备和存储介质。The present application relates to the field of blockchain technology, in particular to a management method, device, computer equipment and storage medium for blockchain nodes.
背景技术Background technique
目前,当新的区块链节点加入一个已经搭建完成的区块链网络后,往往为该新加入的节点赋予所有权限,即该新加入的节点能够获得与区块链网络中在先加入的节点同等待遇,发明人意识到这不仅对于先加入的节点有失公平,而且不利于区块链网络的发展和扩大。可见这种只有加入或不加入区别的区块链网络管理方式过于粗糙,不利于调动节点成员的交易积极性。At present, when a new blockchain node joins a blockchain network that has already been built, all permissions are often given to the newly added node, that is, the newly added node can obtain the same Nodes are treated equally, and the inventor realizes that this is not only unfair to the nodes that join first, but also detrimental to the development and expansion of the blockchain network. It can be seen that this kind of blockchain network management method that only distinguishes between joining or not joining is too rough, which is not conducive to mobilizing the enthusiasm of node members for transactions.
因此,亟需一种对区块链网络更细粒度的管理。Therefore, there is an urgent need for a more fine-grained management of blockchain networks.
发明内容SUMMARY OF THE INVENTION
基于此,有必要针对现有节点加入区块链网络时,该新加入的节点能够获得与区块链网络中在先加入的节点同等待遇,对于先加入的节点有失公平的问题,提供一种区块链节点的管理方法、装置、计算机设备和存储介质。Based on this, it is necessary for the existing node to join the blockchain network, the newly added node can receive the same treatment as the node that joined earlier in the blockchain network, and for the unfair problem of the node that joins first, provide a A management method, apparatus, computer equipment and storage medium for a blockchain node.
第一方面提供了一种区块链节点的管理方法,包括:A first aspect provides a method for managing blockchain nodes, including:
对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息;Traverse all nodes in the current blockchain network to obtain the time information of the state change of each node;
基于各个节点的状态变化的时间信息,得到所述各个节点加入当前区块链网络的时长;Obtain the duration of each node joining the current blockchain network based on the time information of the state change of each node;
基于所述各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为所述目标节点赋予第一权限;Based on the duration of each node joining the current blockchain network, a node whose duration of joining the current blockchain network meets the preset conditions is selected as a target node, and the target node is given a first authority;
获取各所述目标节点在当前区块链网络中的历史行为记录,基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值;Obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records;
基于各所述目标节点在当前区块链网络中的贡献值,将所述目标节点的第一权限更新为第二权限,其中,所述第二权限的权限等级高于所述第一权限的权限等级。Based on the contribution value of each target node in the current blockchain network, the first authority of the target node is updated to a second authority, wherein the authority level of the second authority is higher than that of the first authority permission level.
第二方面提供了一种区块链节点的管理方法装置,包括:A second aspect provides a method and apparatus for managing a blockchain node, including:
节点访问单元,用于对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息;The node access unit is used to traverse all the nodes in the current blockchain network to obtain the time information of the state change of each node;
加入时长计算单元,用于基于各个节点的状态变化的时间信息,得到所述各 个节点加入当前区块链网络的时长;Joining the duration calculation unit, which is used to obtain the duration of each node joining the current blockchain network based on the time information of the state change of each node;
第一权限赋予单元,用于基于所述各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为所述目标节点赋予第一权限;The first authority granting unit is used to select a node whose duration of joining the current blockchain network satisfies a preset condition as a target node based on the duration of each node joining the current blockchain network, and assign the target node a first authority;
节点打分单元,用于获取各所述目标节点在当前区块链网络中的历史行为记录,基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值;A node scoring unit, used to obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records;
第二权限赋予单元,用于基于各所述目标节点在当前区块链网络中的贡献值,将所述目标节点的第一权限更新为第二权限,其中,所述第二权限的权限等级高于所述第一权限的权限等级。The second authority granting unit is configured to update the first authority of the target node to a second authority based on the contribution value of each target node in the current blockchain network, wherein the authority level of the second authority A permission level higher than the first permission.
第三方面提供了一种计算机设备,包括存储器和处理器,所述存储器中存储有计算机可读指令,所述计算机可读指令被所述处理器执行时,使得所述处理器执行以下步骤:A third aspect provides a computer device, including a memory and a processor, where computer-readable instructions are stored in the memory, and when the computer-readable instructions are executed by the processor, cause the processor to perform the following steps:
对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息;Traverse all nodes in the current blockchain network to obtain the time information of the state change of each node;
基于各个节点的状态变化的时间信息,得到所述各个节点加入当前区块链网络的时长;Obtain the duration of each node joining the current blockchain network based on the time information of the state change of each node;
基于所述各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为所述目标节点赋予第一权限;Based on the duration of each node joining the current blockchain network, a node whose duration of joining the current blockchain network meets the preset conditions is selected as a target node, and the target node is given a first authority;
获取各所述目标节点在当前区块链网络中的历史行为记录,基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值;Obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records;
基于各所述目标节点在当前区块链网络中的贡献值,将所述目标节点的第一权限更新为第二权限,其中,所述第二权限的权限等级高于所述第一权限的权限等级。Based on the contribution value of each target node in the current blockchain network, the first authority of the target node is updated to a second authority, wherein the authority level of the second authority is higher than that of the first authority permission level.
第四方面提供了一种存储有计算机可读指令的存储介质,所述计算机可读指令被一个或多个处理器执行时,使得一个或多个处理器执行以下步骤:A fourth aspect provides a storage medium storing computer-readable instructions, which, when executed by one or more processors, cause the one or more processors to perform the following steps:
对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息;Traverse all nodes in the current blockchain network to obtain the time information of the state change of each node;
基于各个节点的状态变化的时间信息,得到所述各个节点加入当前区块链网络的时长;Obtain the duration of each node joining the current blockchain network based on the time information of the state change of each node;
基于所述各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为所述目标节点赋予第一权限;Based on the duration of each node joining the current blockchain network, a node whose duration of joining the current blockchain network meets the preset conditions is selected as a target node, and the target node is given a first authority;
获取各所述目标节点在当前区块链网络中的历史行为记录,基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值;Obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records;
基于各所述目标节点在当前区块链网络中的贡献值,将所述目标节点的第一权限更新为第二权限,其中,所述第二权限的权限等级高于所述第一权限的权限等级。Based on the contribution value of each target node in the current blockchain network, the first authority of the target node is updated to a second authority, wherein the authority level of the second authority is higher than that of the first authority permission level.
上述区块链节点的管理方法、装置、计算机设备和存储介质,首先,得到各个节点的状态变化的时间信息,基于各个节点的状态变化的时间信息,得到所述各个节点加入当前区块链网络的时长;然后,基于所述各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为所述目标节点赋予第一权限;最后,获取各所述目标节点在当前区块链网络中的历史行为记录,基于所述历史行为记录对所述目标节点进行打分;基于各所述目标节点的打分结果,将所述目标节点的第一权限更新为权限等级更高的第二权限。因此,本申请根据节点的加入当前区块链网络的时间选出新加入的多个节点作为目标节点,进行重点观察的对象且只为这些新加入的目标节点分配较低的权限(有限权限),然后根据这些目标节点在区块链网络中的贡献值逐步地提升贡献值高的目标节点的权限(即目标节点的权限由第一权限更新为第二权限),即基于当前区块链网络中节点的贡献值实现对区块链网络的有效管理和辅助,通过对目标节点的各项表现进行打分的方式作为权限重新分配的依据,即为贡献值越高的节点分配更高的权限,实现了区块链网络中节点的细粒度管理策略,从而,提高了节点的交易积极性。For the management method, device, computer equipment and storage medium of the above-mentioned blockchain nodes, first, the time information of the state change of each node is obtained, and based on the time information of the state change of each node, it is obtained that each node joins the current blockchain network Then, based on the duration of each node joining the current blockchain network, a node whose duration of joining the current blockchain network meets the preset conditions is selected as the target node, and the target node is given the first authority; finally , obtain the historical behavior records of each of the target nodes in the current blockchain network, and score the target nodes based on the historical behavior records; A permission is updated to a second permission with a higher permission level. Therefore, this application selects a plurality of newly added nodes as target nodes according to the time when the node joins the current blockchain network, and conducts key observations, and only allocates lower authority (limited authority) to these newly joined target nodes. , and then gradually increase the authority of the target node with high contribution value according to the contribution value of these target nodes in the blockchain network (that is, the authority of the target node is updated from the first authority to the second authority), that is, based on the current blockchain network The contribution value of the middle node realizes the effective management and assistance of the blockchain network. By scoring the performance of the target node as the basis for the redistribution of authority, that is, assigning higher authority to the node with higher contribution value. The fine-grained management strategy of nodes in the blockchain network is realized, thereby improving the transaction enthusiasm of nodes.
附图说明Description of drawings
图1为一个实施例中计算机设备的内部结构框图;1 is a block diagram of the internal structure of a computer device in one embodiment;
图2为一个实施例中区块链节点的管理方法的流程图;2 is a flowchart of a method for managing a blockchain node in one embodiment;
图3为一个实施例中区块链节点的管理方法的另一流程图;3 is another flowchart of a method for managing a blockchain node in one embodiment;
图4为一个实施例中区块链节点的管理装置的结构框图。FIG. 4 is a structural block diagram of an apparatus for managing a blockchain node in an embodiment.
具体实施方式Detailed ways
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solutions and advantages of the present application more clearly understood, the present application will be described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application, but not to limit the present application.
可以理解,本申请所使用的术语“第一”、“第二”等可在本文中用于描述各种元件,但这些元件不受这些术语限制。这些术语仅用于将第一个元件与另一个元件区分。举例来说,在不脱离本申请的范围的情况下,可以将第一权限称为第二权限,且类似地,可将第二权限称为第二权限。It will be understood that the terms "first", "second", etc. used in this application may be used herein to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish a first element from another element. For example, a first right may be referred to as a second right, and similarly, a second right may be referred to as a second right, without departing from the scope of this application.
在一个实施例中提供的区块链节点的管理方法的实施环境中,包括计算机设备以及区块链的节点(如服务器)。计算机设备为配置设备,例如为电脑等计算机设备,计算机设备上安装有节点权限的动态配置工具。当需要配置时,可以向 计算机设备发出区块链节点的管理请求,计算机设备接收该区块链节点的管理请求,对区块链的节点进行动态管理。需要说明的是,计算机设备可为智能手机、平板电脑、笔记本电脑、台式计算机等,但并不局限于此。In an implementation environment of the method for managing a blockchain node provided in one embodiment, a computer device and a blockchain node (such as a server) are included. The computer device is a configuration device, for example, a computer device such as a computer, and a dynamic configuration tool with node permissions is installed on the computer device. When configuration is required, the management request of the blockchain node can be sent to the computer device, and the computer device receives the management request of the blockchain node and dynamically manages the nodes of the blockchain. It should be noted that the computer device may be a smart phone, a tablet computer, a notebook computer, a desktop computer, etc., but is not limited thereto.
图1为一个实施例中计算机设备的内部结构示意图。该计算机设备包括通过系统总线连接的处理器、非易失性存储介质、存储器和网络接口。其中,该计算机设备的非易失性存储介质存储有操作系统、数据库和计算机可读指令,数据库中可存储有控件信息序列,该计算机可读指令被处理器执行时,可使得处理器实现一种区块链节点的管理方法。该计算机设备的处理器用于提供计算和控制能力,支撑整个计算机设备的运行。该计算机设备的存储器中可存储有计算机可读指令,该计算机可读指令被处理器执行时,可使得处理器执行一种区块链节点的管理方法。该计算机设备的网络接口用于与终端连接通信。本领域技术人员可以理解,图1中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备的限定,具体的计算机设备可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。FIG. 1 is a schematic diagram of the internal structure of a computer device in one embodiment. The computer device includes a processor, non-volatile storage medium, memory, and a network interface connected by a system bus. Wherein, the non-volatile storage medium of the computer device stores an operating system, a database and computer-readable instructions, and the database may store a sequence of control information. When the computer-readable instructions are executed by the processor, the processor can realize a A management method of blockchain nodes. The processor of the computer device is used to provide computing and control capabilities and support the operation of the entire computer device. Computer-readable instructions may be stored in the memory of the computer device, and when the computer-readable instructions are executed by the processor, the processor may execute a method for managing a blockchain node. The network interface of the computer equipment is used for communication with the terminal connection. Those skilled in the art can understand that the structure shown in FIG. 1 is only a block diagram of a partial structure related to the solution of the present application, and does not constitute a limitation on the computer equipment to which the solution of the present application is applied. Include more or fewer components than shown in the figures, or combine certain components, or have a different arrangement of components.
如图2所示,在一个实施例中,提出了一种区块链节点的管理方法,该方法可以包括以下步骤:As shown in Figure 2, in one embodiment, a method for managing blockchain nodes is proposed, which may include the following steps:
步骤201、对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息。 Step 201 , traverse all nodes in the current blockchain network to obtain time information of state changes of each node.
在本实施例中,当前区块链网络可以包括但不限于联盟链、公有链、私有链等。节点的状态可以包括但不限于的加入状态、交易状态、待失效状态等等。按照预定的时间间隔对当前区块链网络中的所有节点进行遍历,以获得各节点的状态变化的时间信息。其中,预定的时间间隔例如可以是一天(24h),即每天固定的时间点遍历各节点一次。节点的状态变化时间信息例如节点加入区块链网络的时间。In this embodiment, the current blockchain network may include, but is not limited to, a consortium chain, a public chain, a private chain, and the like. The state of a node may include, but is not limited to, joining state, transaction state, pending invalidation state, and so on. All nodes in the current blockchain network are traversed according to a predetermined time interval to obtain the time information of the state change of each node. The predetermined time interval may be, for example, one day (24h), that is, each node is traversed once at a fixed time point every day. The state change time information of the node, such as the time when the node joined the blockchain network.
步骤202、基于各个节点的状态变化的时间信息,得到各个节点加入当前区块链网络的时长。Step 202: Based on the time information of the state change of each node, obtain the time length of each node joining the current blockchain network.
在本实施例中,从各节点的状态变化的时间信息中提取出各节点加入当前区块链网络的时间信息(或称为节点生成时间),将各节点加入当前区块链网络的时间与区块链网络中管理节点的当前系统时间进行比较(例如可进行做差处理或时间距离计算处理),以确定当前动态区块链网络中的所有节点加入当前区块链网络的时长(所有节点的生成的时长),从而可得到所有节点的区块链网络加入时间属性,用于表明节点与当前区块链网络的关系。In this embodiment, the time information (or node generation time) when each node joins the current blockchain network is extracted from the time information of the state change of each node, and the time when each node joins the current blockchain network is the same as the time when each node joins the current blockchain network. The current system time of the management node in the blockchain network is compared (for example, differential processing or time distance calculation processing can be performed) to determine the length of time for all nodes in the current dynamic blockchain network to join the current blockchain network (all nodes The duration of the generation), so that the blockchain network joining time attribute of all nodes can be obtained, which is used to indicate the relationship between the node and the current blockchain network.
步骤203、基于各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为目标节点赋予第一权限。Step 203: Based on the duration of each node joining the current blockchain network, select a node whose duration of joining the current blockchain network meets a preset condition as a target node, and assign a first authority to the target node.
在本实施例中,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,是指选择新加入的多个节点(即加入当前区块链网络的时间较短的节点)作为重点观察的对象(目标节点)。这里的第一权限可以是有限的权限,例如,第一权限是观察员权限,观察员权限一般只具有读账本的权限、部分区块运输和基础数据存储权限,而没有更高级的权限,权限范围比较窄。In this embodiment, selecting a node whose duration of joining the current blockchain network satisfies a preset condition as a target node refers to selecting multiple newly added nodes (that is, nodes with a shorter duration of joining the current blockchain network) as the target node. The object to focus on (target node). The first permission here can be a limited permission. For example, the first permission is the observer permission. Generally, the observer permission only has the permission to read the ledger, part of the block transportation and basic data storage permission, but no more advanced permission. The scope of permission is compared. narrow.
步骤204、获取各目标节点在当前区块链网络中的历史行为记录,基于历史行为记录确定所述目标节点在当前区块链网络中的贡献值。Step 204: Obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records.
在本实施例中,目标节点在当前区块链网络中的历史行为记录可以包括但不限于:承担了多少负载、传输了多少数据、提供了多少存储容量等等。确定所述目标节点在当前区块链网络中的贡献值的方式可包括但不限于为其他节点传输了X个区块X/10分,执行了Y次交易查询(以分担多少区块链网络上的查询工作负载)Y/8分,提供了Z个标准的存储块用于存储区块链网络上的共享账本等数据Z分,然后,计算目标节点所有行为记录的总得分,该总得分对应于目标节点在当前区块链网络的贡献值,例如,目标节点所有行为记录的总得分越高,则目标节点在当前区块链网络的贡献值越大。In this embodiment, the historical behavior record of the target node in the current blockchain network may include, but is not limited to, how much load it has undertaken, how much data has been transmitted, how much storage capacity has been provided, and so on. The method of determining the contribution value of the target node in the current blockchain network may include, but is not limited to, transmitting X blocks X/10 points for other nodes, and executing Y transaction queries (to share how much the blockchain network shares). The query workload on the network) Y/8 points, providing Z standard storage blocks for storing data such as shared ledgers on the blockchain network Z points, and then calculating the total score of all behavior records of the target node, the total score Corresponding to the contribution value of the target node in the current blockchain network, for example, the higher the total score of all behavior records of the target node, the greater the contribution value of the target node in the current blockchain network.
在一些实施例中,基于历史行为记录确定所述目标节点在当前区块链网络中的贡献值可以包括:对各目标节点的各历史行为打正分或打负分,累计各节点的所有历史行为的打分结果得到目标节点的打分结果,根据所述目标节点的打分结果确定所述目标节点在当前区块链网络中的贡献值。In some embodiments, determining the contribution value of the target node in the current blockchain network based on the historical behavior record may include: assigning a positive or negative score to each historical behavior of each target node, accumulating all the history of each node The scoring result of the behavior obtains the scoring result of the target node, and the contribution value of the target node in the current blockchain network is determined according to the scoring result of the target node.
可以理解的是,每个目标节点有多个历史行为,针对每个历史行为分别打分,最终每个节点打分结果是所有历史行为记录的得分总和。其中,打负分情况可以包括目标节点违规交易一次-1,目标节点拒绝存储相应数据一次-2,目标节点提供服务超时-1等等。It can be understood that each target node has multiple historical behaviors, and each historical behavior is scored separately, and the final score of each node is the sum of the scores of all historical behavior records. Among them, the negative score may include the target node's illegal transaction once -1, the target node's refusal to store the corresponding data once -2, the target node providing service timeout -1 and so on.
进一步地,在一些实施例中,还包括步骤S7,该步骤用于在目标节点的累计打分结果低于最低阈值时剔除该目标节点。例如该目标节点得正分的情况较少,得负分的情况较多,当最终得分小于或等于0分时将该节点从本动态区块链网络中剔除。当然,本实施例也可以将最低阈值提高,例如5分等,低于最低阈值的节点会被剔除,这种方式有助于督促各节点成员积极参与区块链网络运行,警示不要进行误操作,否则会在不作为或少作为或错作为情形下被剔除当前区块链网络,以使管理后的区块链网络具有更强的活力和生命力。Further, in some embodiments, a step S7 is also included, and this step is used for eliminating the target node when the cumulative scoring result of the target node is lower than the minimum threshold. For example, the target node has fewer positive scores and more negative scores. When the final score is less than or equal to 0, the node is removed from the dynamic blockchain network. Of course, this embodiment can also increase the minimum threshold, such as 5 points, etc., and the nodes below the minimum threshold will be eliminated. This method helps to urge each node member to actively participate in the operation of the blockchain network, and warns against misoperation Otherwise, the current blockchain network will be eliminated in the case of inaction, less action or wrong action, so that the managed blockchain network will have stronger vitality and vitality.
步骤205、基于各目标节点在当前区块链网络中的贡献值,将目标节点的第一权限更新为第二权限,其中,第二权限的权限等级高于第一权限的权限等级。Step 205: Based on the contribution value of each target node in the current blockchain network, update the first authority of the target node to a second authority, wherein the authority level of the second authority is higher than the authority level of the first authority.
可以理解的是,每个目标节点的打分结果与该目标节点的历史行为有关,而节点的历史行为又能体现该节点对当前区块链网络的贡献值,故基于各目标节点 的打分结果,将目标节点的第一权限更新为第二权限,也就是根据目标节点对当前区块链的贡献值为目标节点相应的权限。It can be understood that the scoring result of each target node is related to the historical behavior of the target node, and the historical behavior of the node can reflect the contribution value of the node to the current blockchain network, so based on the scoring results of each target node, The first authority of the target node is updated to the second authority, that is, the corresponding authority of the target node is based on the contribution value of the target node to the current blockchain.
可见,本申请根据节点的加入当前区块链网络的时间选出新加入的多个节点作为目标节点,进行重点观察的对象且只为这些新加入的目标节点分配较低的权限(有限权限),然后根据这些目标节点在区块链网络中的贡献值逐步地提升贡献值高的目标节点的权限,即基于当前区块链网络中节点的贡献值实现对区块链网络的有效管理和辅助,通过对目标节点的各项表现进行打分的方式作为权限重新分配的依据,实现了区块链网络中节点的细粒度管理策略。It can be seen that this application selects a plurality of newly added nodes as target nodes according to the time when the nodes join the current blockchain network, and is the object of key observation, and only allocates lower authority (limited authority) to these newly joined target nodes. Then, according to the contribution value of these target nodes in the blockchain network, the authority of the target node with high contribution value is gradually increased, that is, the effective management and assistance of the blockchain network is realized based on the contribution value of the nodes in the current blockchain network. , by scoring the performance of the target node as the basis for the redistribution of authority, the fine-grained management strategy of nodes in the blockchain network is realized.
在本申请实施例的一些变更实施方式中,为避免对节点的访问影响节点的正常运行,步骤201中对当前区块链网络中的所有节点进行遍历,具体可以包括:In some modified implementations of the embodiments of the present application, in order to prevent the access to the node from affecting the normal operation of the node, in step 201, all nodes in the current blockchain network are traversed, which may specifically include:
步骤2011、基于当前区块链网络中的所有节点的运行信息,设置遍历节点的优先级。Step 2011: Based on the running information of all nodes in the current blockchain network, set the priority of traversing nodes.
其中,节点的运行信息可以包括但不限于节点是否运行、运行时负荷率等。The operation information of the node may include, but is not limited to, whether the node is running, the load rate at runtime, and the like.
步骤2012、按照优先级访问当前区块链网络中的所有节点。Step 2012: Access all nodes in the current blockchain network according to priority.
可以理解的是,优先级的设置规则可以是:统计各节点在各时间段的运行信息(包括是否运行、运行时负荷率等),然后再根据统计的运行信息分别在各时间段为各节点设置优先级,例如1点-2点,A\C\E\G\B、2点-3点C/G/B/E/A,……等等。准备进行遍历时读取当前时间,确定当前时间所在时间段,然后以已经获得的当前时间段的优先级为依据,按照优先级中节点顺序进行遍历,以使本申请能够先访问相对空闲的节点,后访问忙碌的节点,有可能在后访问时原忙碌的节点相对空闲下来了,以最大化地在节点相对空闲时间对其进行访问和数据获取,故本实施例能够基于这种方式尽可能地避免区块链网络中节点访问过程对节点正常运行的影响。It can be understood that the priority setting rule can be: count the operation information of each node in each time period (including whether it is running, load rate at runtime, etc.) Set the priority, such as 1 point-2 points, A\C\E\G\B, 2 points-3 points C/G/B/E/A, ... and so on. When preparing to traverse, read the current time, determine the time period in which the current time is located, and then traverse in the order of nodes in the priority based on the priority of the current time period that has been obtained, so that the application can first access relatively idle nodes , the later access to the busy node, it is possible that the original busy node is relatively idle during the later access, so as to maximize the access and data acquisition of the node during the relative idle time of the node, so this embodiment can be based on this method as much as possible. It can avoid the influence of the node access process in the blockchain network on the normal operation of the node.
在本申请实施例的一些变更实施方式中,为了发现加入时间信息被节点自身篡改的节点,步骤202、基于各个节点的状态变化的时间信息,得到各个节点加入当前区块链网络的时长,具体可以包括:In some modified implementations of the embodiments of the present application, in order to discover nodes whose joining time information has been tampered with by the node itself, step 202 , based on the time information of the state changes of each node, obtain the time length of each node joining the current blockchain network, specifically Can include:
步骤2021、基于各个节点的状态变化的时间信息,提取节点加入当前区块链网络的时间信息。Step 2021 , based on the time information of the state change of each node, extract the time information of the node joining the current blockchain network.
其中,节点的状态变化的时间信息至少包括节点加入区块链网络的状态变化的时间信息,故根据节点的状态变化的时间信息可以提取节点加入当前区块链网络的时间信息。The time information of the state change of the node includes at least the time information of the state change of the node joining the blockchain network, so the time information of the node joining the current blockchain network can be extracted according to the time information of the state change of the node.
步骤2022、对节点的加入时间信息进行随机性验证,并对加入时间信息被篡改的节点进行不诚信标记。Step 2022: Perform randomness verification on the joining time information of the nodes, and mark the nodes whose joining time information has been tampered with dishonesty.
可以理解的是,随机性验证过程可包括但不限于分别采集与待验证节点相邻的节点的上链历史数据,并基于节点共识技术根据大部分或所有与待验证节点相邻的节点的上链历史数据判断节点加入时间信息是否被篡改,具体可以包括:解析与待验证节点相邻的节点的上链历史数据,根据上链历史数据的解析结果得到相邻的节点记录的当前节点的加入时间共识信息,如果加入时间共识信息中大部分(例如95%)均与节点加入时间相同,则证明节点加入时间准确;否则认定为节点信息已经被篡改。如果发现某节点的加入时间信息被节点自身篡改,则对该节点进行标记。It can be understood that the randomness verification process may include, but is not limited to, collecting historical data on the chain of nodes adjacent to the node to be verified, and based on the node consensus technology, according to most or all of the nodes adjacent to the node to be verified. The chain history data determines whether the node joining time information has been tampered with, which may specifically include: parsing the chain history data of the node adjacent to the node to be verified, and obtaining the join of the current node recorded by the adjacent node according to the analysis result of the chain history data. Time consensus information, if most of the joining time consensus information (for example, 95%) is the same as the node joining time, it proves that the node joining time is accurate; otherwise, it is determined that the node information has been tampered with. If it is found that the joining time information of a node has been tampered with by the node itself, the node will be marked.
步骤2023、将各节点的加入时间信息与当前区块链网络中管理节点的当前系统时间进行比较,确定节点加入当前区块链网络的时长。Step 2023: Compare the joining time information of each node with the current system time of the management node in the current blockchain network, and determine the duration of the node joining the current blockchain network.
进一步地,在一些实施例中,步骤204中,在为各个目标节点进行打分后,将被步骤2022中被标记为不诚信的节点的打分结果修改为零,以表示对不诚信节点的惩罚,在另一些实施中,还可以包括:直接将不诚信节点从动态区块链网络中剔除,并能限制该节点在一段时间内无法加入当前区块链网络的步骤。Further, in some embodiments, in step 204, after scoring each target node, the scoring result of the node marked as dishonest in step 2022 is modified to zero to represent a punishment for dishonest nodes, In other implementations, it may also include: directly removing the dishonest node from the dynamic blockchain network, and restricting the node from being unable to join the current blockchain network for a period of time.
在本申请实施例的一些变更实施方式中,步骤203、选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,可以包括:In some modified implementations of the embodiments of the present application, step 203, selecting a node whose duration of joining the current blockchain network satisfies a preset condition as a target node may include:
步骤2031、基于各节点加入当前区块链网络的时长,对当前区块链网络中的所有节点进行排序。Step 2031: Sort all nodes in the current blockchain network based on the duration of each node joining the current blockchain network.
在本实施例中,以区块链网络加入时间属性为依据,可对当前区块链网络中的所有节点进行排序处理,例如可以是按照加入时间由长到短形成所有节点的第一排序结果或者按照加入时间由短到长形成所有节点的第二排序结果,以便于对待处理节点进行筛选。In this embodiment, all nodes in the current blockchain network can be sorted based on the attribute of the time of joining the blockchain network. For example, the first sorting result of all nodes can be formed according to the joining time from long to short. Or form the second sorting result of all nodes according to the joining time from short to long, so as to facilitate the screening of the nodes to be processed.
步骤2032、选择排在排序结果的首端或末端的预设个数的节点为目标节点,或,选择排序结果中加入当前区块链网络的时长不大于预设时间阈值的节点为目标节点。其中,任一目标节点加入当前区块链网络的时长小于当前区块链网络中除目标节点以外的其他节点加入当前区块链网络的时长。Step 2032: Select a preset number of nodes ranked at the beginning or end of the sorting result as the target node, or select a node in the sorting result whose duration of joining the current blockchain network is not greater than the preset time threshold as the target node. Wherein, the time for any target node to join the current blockchain network is less than the time for other nodes in the current blockchain network except the target node to join the current blockchain network.
在本实施例中,选择排在排序结果的首端或末端的预设个数的节点为目标节点可以是,从第一排序结果或第二排序结果中筛选出加入时间较短的多个节点,例如可从第一排序结果中筛出排在后面的若干个节点或可从第二排序结果中筛出排在前面的若干个节点,则本申请能够针对性地对新加入或者加入时间不长的节点进行重点考察。In this embodiment, selecting a preset number of nodes at the beginning or end of the sorting result as the target node may be to filter out a plurality of nodes with a shorter joining time from the first sorting result or the second sorting result For example, several nodes in the back can be screened out from the first sorting result or several nodes in the front can be screened out from the second sorting result. Focus on long nodes.
选择排序结果中加入当前区块链网络的时长不大于预设时间阈值的节点为目标节点可以是,从第一排序结果或第二排序结果中筛选出加入时间小于或等于阈值的节点,即从排序结果中找到某个节点小于阈值后,则第一排序结果中该节 点后面的节点均会被筛选出或者第二排序结果中该节点前面的节点都会被筛选出,这种方式有助于提高运算的效率,在区块链网络较复杂、数据多情况下有助于更快地实现本申请提供的技术方案。Select the node whose duration of joining the current blockchain network is not greater than the preset time threshold in the sorting result as the target node. It can be the node whose joining time is less than or equal to the threshold from the first sorting result or the second sorting result, that is, from the first sorting result or the second sorting result. After a node is found in the sorting result that is less than the threshold, the nodes behind the node in the first sorting result will be filtered out or the nodes in front of the node in the second sorting result will be filtered out. This method helps to improve The computing efficiency helps to realize the technical solution provided by this application more quickly when the blockchain network is complex and there is a lot of data.
进一步地,在一些实施例中,步骤2031还可包括按照时间由短到长的顺序依次为各个节点从小到大地编号,例如从1开始,2,3……依次地进行编号,从而在步骤S4中可按照编号直接、快速地截取出若干个节点,例如将不大于10的10个节点(编号1-10)直接筛选出来,本实施例可通过该方式实现对加入时间较短的多个节点的快速、高效地确定,具有算法实现简单、占用资源小、执行速度非常快等突出优点。Further, in some embodiments, step 2031 may further include sequentially numbering each node from small to large in the order of time from short to long, for example, starting from 1, 2, 3 . Several nodes can be directly and quickly cut out according to the number, for example, 10 nodes (numbered 1-10) not greater than 10 can be directly screened out. In this embodiment, multiple nodes with a short joining time can be implemented in this way. The fast and efficient determination of the algorithm has the outstanding advantages of simple algorithm implementation, small resource occupation, and very fast execution speed.
进一步地,如图3所示,为了使区块链网络中的节点公平地提升自身权限,在本申请实施例的一些变更实施方式中,区块链节点的管理方法,还包括:Further, as shown in FIG. 3 , in order to enable the nodes in the blockchain network to upgrade their own authority fairly, in some modified implementations of the embodiments of this application, the management method of the blockchain nodes further includes:
步骤206、接收当前区块链网络中除目标节点以外的其他节点的打分请求。Step 206: Receive a scoring request from other nodes other than the target node in the current blockchain network.
在本实施例中,没有在步骤203中筛选出的节点可发出打分请求,在步骤204中收到打分请求后,可将发出打分请求的相应节点纳入目标节点集合中,将发出打分请求的节点作为目标节点,与其他筛选出的目标节点一起在步骤204中确定分数,然后根据分数为发出请求的目标节点分配权限。In this embodiment, the nodes that are not screened in step 203 can send a scoring request. After receiving the scoring request in step 204, the corresponding node that sent the scoring request can be included in the target node set, and the node that sent the scoring request can be included in the target node set. As a target node, a score is determined in step 204 together with other filtered target nodes, and then the requesting target node is assigned permissions according to the score.
步骤207、将发出打分请求的节点作为目标节点,并对节点进行打分标记。Step 207: Use the node that issued the scoring request as the target node, and mark the node for scoring.
步骤208、基于进行打分标记的目标节点的被打分标记的次数和/或目标节点的权限变化,确定当前区块链网络的备选管理节点。Step 208 : Determine the candidate management node of the current blockchain network based on the number of times the target node is scored and marked and/or the authority change of the target node.
在本实施例中,步骤207中记录发出打分请求的节点且为其赋予标识A,对赋予标识A的节点的权限变化进行监控,如果这些节点被赋予标识A的次数和权限提升的次数均达到了设定值,例如可以是8次,那么将这些节点作为区块链节点的管理节点备选集合中的元素,在需要确定用于管理整个或部分区块链网络的节点作为管理员时,可从管理节点备选集合中选择合适的节点作为管理节点。In this embodiment, in step 207, the node that sends out the scoring request is recorded and given an identifier A to it, and the authority changes of the nodes given the identifier A are monitored. If the set value is set, for example, it can be 8 times, then these nodes are used as elements in the candidate set of management nodes of the blockchain node. When it is necessary to determine the node for managing the whole or part of the blockchain network as the administrator, A suitable node may be selected as a management node from the candidate set of management nodes.
上述方式有助于提高区块链网络中节点活跃的积极性,能够促进各节点积极地参加交易、承担相应任务,以提高自身贡献度,并可在申请打分后根据贡献度评价结果得到相应的权限,所以本申请还能够提供一种区块链中节点公平地提升自身权限的方案。The above methods help to improve the enthusiasm of nodes in the blockchain network, and can promote each node to actively participate in transactions and undertake corresponding tasks, so as to improve their own contribution. , so this application can also provide a solution for nodes in the blockchain to fairly upgrade their own authority.
进一步地,在本申请实施例的一些变更实施方式中,步骤205中还包括在当前打分后的一段时间内对各目标节点行为进行考察的步骤,然后根据考察的结果对各目标节点进行二次打分,以赋予各目标节点的新权限,然后可再返回步骤1。其中,在一些实施例中在这一段时间内,例如可以是一个月或两个月等,考察的项目可包括但不限于承担了多少负载、传输了多少数据、提供了多少存储容量等 等,以目标节点在这一时间段内为整个区块链网络做出的贡献-即贡献度来直接为各目标节点打分,而且一些实施例中可直接将贡献度值作为分数值。Further, in some modified implementations of the embodiments of the present application, step 205 further includes a step of inspecting the behavior of each target node within a period of time after the current scoring, and then performing a second step on each target node according to the inspection result. Score to give each target node new permissions, and then return to step 1. Wherein, in some embodiments, during this period of time, for example, it may be one month or two months, etc., the investigated items may include but are not limited to how much load is borne, how much data is transmitted, how much storage capacity is provided, etc., Each target node is directly scored based on the contribution made by the target node to the entire blockchain network within this time period, that is, the contribution degree, and in some embodiments, the contribution degree value can be directly used as the score value.
如图4所示,在一个实施例中,提供了一种区块链节点的管理装置,能够基于区块链网络中节点的贡献值实现对区块链网络的有效管理和辅助,该装置具体可以包括:As shown in FIG. 4 , in one embodiment, a management device for blockchain nodes is provided, which can effectively manage and assist the blockchain network based on the contribution value of the nodes in the blockchain network. The device specifically Can include:
节点访问单元411,用于对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息;The node access unit 411 is used to traverse all the nodes in the current blockchain network to obtain the time information of the state change of each node;
加入时长计算单元412,用于基于各个节点的状态变化的时间信息,得到各个节点加入当前区块链网络的时长;The joining duration calculation unit 412 is used to obtain the duration of each node joining the current blockchain network based on the time information of the state change of each node;
第一权限赋予单元413,用于基于各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为目标节点赋予第一权限;The first authority granting unit 413 is configured to select a node whose duration of joining the current blockchain network satisfies a preset condition as a target node based on the duration of each node joining the current blockchain network, and assign a first authority to the target node;
节点打分单元414,用于获取各目标节点在当前区块链网络中的历史行为记录,基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值;The node scoring unit 414 is used to obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records;
第二权限赋予单元415,用于基于各所述目标节点在当前区块链网络中的贡献值,将所述目标节点的第一权限更新为第二权限,其中,所述第二权限的权限等级高于所述第一权限的权限等级。The second authority granting unit 415 is configured to update the first authority of the target node to a second authority based on the contribution value of each target node in the current blockchain network, wherein the authority of the second authority The level is higher than the permission level of the first permission.
在一个实施例中,提出了一种计算机设备,计算机设备包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,处理器执行计算机程序时实现以下步骤:对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息;基于各个节点的状态变化的时间信息,得到各个节点加入当前区块链网络的时长;基于各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为目标节点赋予第一权限;获取各目标节点在当前区块链网络中的历史行为记录,基于历史行为记录对目标节点进行打分;基于各目标节点的打分结果,将目标节点的第一权限更新为第二权限。In one embodiment, a computer device is proposed. The computer device includes a memory, a processor, and a computer program stored in the memory and running on the processor. When the processor executes the computer program, the following steps are implemented: All nodes in the chain network are traversed to obtain the time information of the state change of each node; based on the time information of the state change of each node, the duration of each node joining the current blockchain network is obtained; based on each node joining the current blockchain network Select the node whose duration of joining the current blockchain network meets the preset conditions as the target node, and assign the first authority to the target node; obtain the historical behavior records of each target node in the current blockchain network, based on historical behavior Record the scoring of the target node; based on the scoring results of each target node, update the first authority of the target node to the second authority.
在一个实施例中,处理器所执行的对当前区块链网络中的所有节点进行遍历的步骤包括:基于当前区块链网络中的所有节点的运行信息,设置遍历节点的优先级;按照优先级访问当前区块链网络中的所有节点。In one embodiment, the step of traversing all nodes in the current blockchain network performed by the processor includes: setting the priority of traversing nodes based on the running information of all nodes in the current blockchain network; level access to all nodes in the current blockchain network.
在一个实施例中,处理器所执行的基于各个节点的状态变化的时间信息,得到各个节点加入当前区块链网络的时长的步骤包括:基于各个节点的状态变化的时间信息,提取节点加入当前区块链网络的时间信息;对节点的加入时间信息进行随机性验证,以识别所述加入时间信息是否被篡改;对加入时间信息被篡改的节点进行不诚信标记;将当前区块链网络中除被不诚信标记的节点以外的各节点 的加入时间信息与当前区块链网络中管理节点的当前系统时间进行比较,确定各所述节点加入当前区块链网络的时长。In one embodiment, the step of obtaining the duration of each node joining the current blockchain network based on the time information of the state change of each node executed by the processor includes: based on the time information of the state change of each node, extracting the node to join the current blockchain network. Time information of the blockchain network; random verification of the joining time information of nodes to identify whether the joining time information has been tampered with; dishonest marking of nodes whose joining time information has been tampered with; The joining time information of each node except the node marked with dishonesty is compared with the current system time of the management node in the current blockchain network to determine the duration of each node joining the current blockchain network.
在一个实施例中,处理器执行计算机可读指令时还执行以下步骤:如果检测到当前区块链网络中的任一节点的打分结果小于预设分数值和/或被不诚信标记,则将节点从当前区块链网络中剔除。In one embodiment, when the processor executes the computer-readable instructions, the processor further performs the following steps: if it is detected that the scoring result of any node in the current blockchain network is less than the preset score value and/or is marked as dishonest, then Nodes are culled from the current blockchain network.
在一个实施例中,处理器所执行的选择加入当前区块链网络的时长满足预设条件的节点作为目标节点的步骤包括:基于各节点加入当前区块链网络的时长,对当前区块链网络中的所有节点进行排序;选择排在排序结果的首端或末端的预设个数的节点为目标节点,或,选择排序结果中加入当前区块链网络的时长不大于预设时间阈值的节点为目标节点;其中,任一目标节点加入当前区块链网络的时长小于当前区块链网络中除目标节点以外的其他节点加入当前区块链网络的时长。In one embodiment, the step of selecting a node whose duration of joining the current blockchain network satisfies a preset condition as the target node performed by the processor includes: based on the duration of each node joining the current blockchain network, determining the current blockchain network All nodes in the network are sorted; select the preset number of nodes at the beginning or end of the sorting result as the target node, or select the one that has been added to the current blockchain network in the sorting result and is not greater than the preset time threshold. The node is the target node; wherein, the time for any target node to join the current blockchain network is less than the time for other nodes in the current blockchain network except the target node to join the current blockchain network.
在一个实施例中,处理器所执行的基于历史行为记录对目标节点进行打分的步骤包括:对各目标节点的各历史行为打正分或打负分,累计各节点的所有历史行为的打分结果得到目标节点的打分结果。In one embodiment, the step of scoring the target node based on the historical behavior record performed by the processor includes: scoring each historical behavior of each target node as positive or negative, and accumulating the scoring results of all historical behaviors of each node Get the scoring result of the target node.
在一个实施例中,处理器执行计算机可读指令时还执行以下步骤:接收当前区块链网络中除目标节点以外的其他节点的打分请求;将发出打分请求的节点作为目标节点,并对节点进行打分标记;基于进行打分标记的目标节点的被打分标记的次数和/或目标节点的权限变化,确定当前区块链网络的备选管理节点。In one embodiment, when the processor executes the computer-readable instructions, the processor further performs the following steps: receiving a scoring request from other nodes other than the target node in the current blockchain network; taking the node that issued the scoring request as the target node, and assigning a score to the node Carry out scoring and marking; determine the candidate management node of the current blockchain network based on the number of times of scoring and marking of the target node for scoring and marking and/or changes in the authority of the target node.
在一个实施例中,提出了一种存储有计算机可读指令的存储介质,该计算机可读指令被一个或多个处理器执行时,使得一个或多个处理器执行以下步骤:对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息;基于各个节点的状态变化的时间信息,得到各个节点加入当前区块链网络的时长;基于各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为目标节点赋予第一权限;获取各目标节点在当前区块链网络中的历史行为记录,基于历史行为记录对目标节点进行打分;基于各目标节点的打分结果,将目标节点的第一权限更新为第二权限。In one embodiment, a storage medium storing computer-readable instructions is provided, the computer-readable instructions, when executed by one or more processors, cause the one or more processors to perform the following steps: All nodes in the chain network are traversed to obtain the time information of the state change of each node; based on the time information of the state change of each node, the duration of each node joining the current blockchain network is obtained; based on each node joining the current blockchain network Select the node whose duration of joining the current blockchain network meets the preset conditions as the target node, and assign the first authority to the target node; obtain the historical behavior records of each target node in the current blockchain network, based on historical behavior Record the scoring of the target node; based on the scoring results of each target node, update the first authority of the target node to the second authority.
在一个实施例中,处理器所执行的对当前区块链网络中的所有节点进行遍历的步骤包括:基于当前区块链网络中的所有节点的运行信息,设置遍历节点的优先级;按照优先级访问当前区块链网络中的所有节点。In one embodiment, the step of traversing all nodes in the current blockchain network performed by the processor includes: setting the priority of traversing nodes based on the running information of all nodes in the current blockchain network; level access to all nodes in the current blockchain network.
在一个实施例中,基于各个节点的状态变化的时间信息,得到各个节点加入当前区块链网络的时长的步骤包括:基于各个节点的状态变化的时间信息,提取节点加入当前区块链网络的时间信息;对节点的加入时间信息进行随机性验证,并对加入时间信息被篡改的节点进行不诚信标记;将各节点的加入时间信息与当 前区块链网络中管理节点的当前系统时间进行比较,确定节点加入当前区块链网络的时长。In one embodiment, the step of obtaining the time length of each node joining the current blockchain network based on the time information of the state change of each node includes: based on the time information of the state change of each node, extracting the time information of the node joining the current blockchain network Time information; verify the randomness of the joining time information of the nodes, and mark the nodes whose joining time information has been tampered with dishonesty; compare the joining time information of each node with the current system time of the management node in the current blockchain network , to determine the length of time that the node joins the current blockchain network.
在一个实施例中,处理器执行计算机可读指令时还执行以下步骤:如果检测到当前区块链网络中的节点满足预设条件,则将节点从当前区块链网络中剔除;其中,预设条件包括:节点的打分结果小于预设分数值和或节点被不诚信标记。In one embodiment, when the processor executes the computer-readable instructions, the processor further performs the following steps: if it is detected that the node in the current blockchain network satisfies the preset condition, the node is removed from the current blockchain network; wherein, the preset The set conditions include: the scoring result of the node is less than the preset score value and or the node is marked with dishonesty.
在一个实施例中,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点的步骤包括:In one embodiment, the step of selecting a node whose duration of joining the current blockchain network satisfies a preset condition as a target node includes:
基于各节点加入当前区块链网络的时长,对当前区块链网络中的所有节点进行排序;选择排在排序结果的首端或末端的预设个数的节点为目标节点,或,选择排序结果中加入当前区块链网络的时长不大于预设时间阈值的节点为目标节点;其中,任一目标节点加入当前区块链网络的时长小于当前区块链网络中除目标节点以外的其他节点加入当前区块链网络的时长。Sort all nodes in the current blockchain network based on the length of time each node has joined the current blockchain network; select a preset number of nodes at the beginning or end of the sorting result as the target node, or, select sorting In the result, the node whose duration of joining the current blockchain network is not greater than the preset time threshold is the target node; among them, the duration of any target node joining the current blockchain network is shorter than that of other nodes except the target node in the current blockchain network The length of time to join the current blockchain network.
在一个实施例中,基于历史行为记录对目标节点进行打分的步骤包括:对各目标节点的各历史行为打正分或打负分,累计各节点的所有历史行为的打分结果得到目标节点的打分结果。In one embodiment, the step of scoring the target node based on the historical behavior records includes: scoring each historical behavior of each target node as positive or negative, and accumulating the scoring results of all historical behaviors of each node to obtain the score of the target node result.
在一个实施例中,处理器执行计算机可读指令时还执行以下步骤:接收当前区块链网络中除目标节点以外的其他节点的打分请求;将发出打分请求的节点作为目标节点,并对节点进行打分标记;基于进行打分标记的目标节点的被打分标记的次数和/或目标节点的权限变化,确定当前区块链网络的备选管理节点。In one embodiment, when the processor executes the computer-readable instructions, the processor further performs the following steps: receiving a scoring request from other nodes other than the target node in the current blockchain network; taking the node that issued the scoring request as the target node, and assigning a score to the node Carry out scoring and marking; determine the candidate management node of the current blockchain network based on the number of times of scoring and marking of the target node for scoring and marking and/or changes in the authority of the target node.
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,该计算机程序可存储于一计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,前述的存储介质可为磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)等非易失性存储介质,或易失性存储介质即随机存储记忆体(Random Access Memory,RAM)等。Those of ordinary skill in the art can understand that the realization of all or part of the processes in the methods of the above embodiments can be accomplished by instructing relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium, and the program is During execution, it may include the processes of the embodiments of the above-mentioned methods. Wherein, the aforementioned storage medium may be a non-volatile storage medium such as a magnetic disk, an optical disc, a read-only memory (Read-Only Memory, ROM), or a volatile storage medium, namely a random access memory (Random Access Memory, RAM), etc.
以上所述实施例的各技术特征可以进行任意的组合,为使描述简洁,未对上述实施例中的各个技术特征所有可能的组合都进行描述,然而,只要这些技术特征的组合不存在矛盾,都应当认为是本说明书记载的范围。The technical features of the above-described embodiments can be combined arbitrarily. For the sake of brevity, all possible combinations of the technical features in the above-described embodiments are not described. However, as long as there is no contradiction between the combinations of these technical features, All should be regarded as the scope described in this specification.
以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对本申请专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。The above-mentioned embodiments only represent several embodiments of the present application, and the descriptions thereof are relatively specific and detailed, but should not be construed as a limitation on the scope of the patent of the present application. It should be pointed out that for those skilled in the art, without departing from the concept of the present application, several modifications and improvements can be made, which all belong to the protection scope of the present application. Therefore, the scope of protection of the patent of the present application shall be subject to the appended claims.

Claims (20)

  1. 一种区块链节点的管理方法,其中,包括:A method for managing blockchain nodes, comprising:
    对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息;Traverse all nodes in the current blockchain network to obtain the time information of the state change of each node;
    基于各个节点的状态变化的时间信息,得到所述各个节点加入当前区块链网络的时长;Obtain the duration of each node joining the current blockchain network based on the time information of the state change of each node;
    基于所述各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为所述目标节点赋予第一权限;Based on the duration of each node joining the current blockchain network, a node whose duration of joining the current blockchain network meets the preset conditions is selected as a target node, and the target node is given a first authority;
    获取各所述目标节点在当前区块链网络中的历史行为记录,基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值;Obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records;
    基于各所述目标节点在当前区块链网络中的贡献值,将所述目标节点的第一权限更新为第二权限,其中,所述第二权限的权限等级高于所述第一权限的权限等级。Based on the contribution value of each target node in the current blockchain network, the first authority of the target node is updated to a second authority, wherein the authority level of the second authority is higher than that of the first authority permission level.
  2. 根据权利要求1所述的区块链节点的管理方法,其中,所述对当前区块链网络中的所有节点进行遍历,包括:The method for managing blockchain nodes according to claim 1, wherein the traversing of all nodes in the current blockchain network includes:
    基于当前区块链网络中的所有节点的运行信息,设置遍历所述节点的优先级;Based on the running information of all nodes in the current blockchain network, set the priority of traversing the nodes;
    按照所述优先级访问当前区块链网络中的所有节点。All nodes in the current blockchain network are accessed according to the stated priority.
  3. 根据权利要求1所述的区块链节点的管理方法,其中,所述基于各个节点的状态变化的时间信息,得到所述各个节点加入当前区块链网络的时长,包括:The method for managing blockchain nodes according to claim 1, wherein the obtaining the time length of each node joining the current blockchain network based on the time information of the state change of each node, comprises:
    基于各个节点的状态变化的时间信息,提取所述节点加入当前区块链网络的时间信息;Based on the time information of the state change of each node, extract the time information of the node joining the current blockchain network;
    对所述节点的加入时间信息进行随机性验证以识别所述加入时间信息是否被篡改;Perform randomness verification on the joining time information of the node to identify whether the joining time information has been tampered with;
    对加入时间信息被篡改的节点进行不诚信标记;Dishonest marking of nodes whose joining time information has been tampered with;
    将当前区块链网络中除被不诚信标记的节点以外的各节点的加入时间信息与当前区块链网络中管理节点的当前系统时间进行比较,确定各所述节点加入当前区块链网络的时长。Compare the joining time information of each node in the current blockchain network except the node marked with dishonesty with the current system time of the management node in the current blockchain network, and determine the time when each said node joins the current blockchain network. duration.
  4. 根据权利要求1或3所述的区块链节点的管理方法,其中,所述方法还包括:The method for managing blockchain nodes according to claim 1 or 3, wherein the method further comprises:
    如果检测到当前区块链网络中的任一节点的打分结果小于预设分数值和/或被不诚信标记,则将所述节点从当前区块链网络中剔除。If it is detected that the scoring result of any node in the current blockchain network is less than the preset score value and/or is marked as dishonest, the node will be removed from the current blockchain network.
  5. 根据权利要求1所述的区块链节点的管理方法,其中,所述选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,包括:The method for managing blockchain nodes according to claim 1, wherein the selecting a node whose duration of joining the current blockchain network satisfies a preset condition as a target node comprises:
    基于各所述节点加入当前区块链网络的时长,对当前区块链网络中的所有节 点进行排序;Sort all nodes in the current blockchain network based on the duration of each node joining the current blockchain network;
    选择排在所述排序结果的首端或末端的预设个数的节点为所述目标节点,或,选择所述排序结果中加入当前区块链网络的时长不大于预设时间阈值的节点为目标节点;Selecting a preset number of nodes at the beginning or end of the sorting result as the target node, or selecting a node whose duration of joining the current blockchain network in the sorting result is not greater than the preset time threshold as the target node target node;
    其中,任一所述目标节点加入当前区块链网络的时长小于当前区块链网络中除所述目标节点以外的其他节点加入当前区块链网络的时长。Wherein, the duration of joining any of the target nodes in the current blockchain network is shorter than the duration of joining the current blockchain network by other nodes other than the target node in the current blockchain network.
  6. 根据权利要求1所述的区块链节点的管理方法,其中,所述基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值,包括:The method for managing blockchain nodes according to claim 1, wherein the determining the contribution value of the target node in the current blockchain network based on the historical behavior records comprises:
    对各所述目标节点的各历史行为打正分或打负分,累计各所述节点的所有历史行为的打分结果得到所述目标节点的打分结果,根据所述目标节点的打分结果确定所述目标节点在当前区块链网络中的贡献值。Each historical behavior of each described target node is scored as positive or negative, and the scoring results of all historical behaviors of each described node are accumulated to obtain the scoring result of the target node, and the described target node is determined according to the scoring result of the target node. The contribution value of the target node in the current blockchain network.
  7. 根据权利要求1所述的区块链节点的管理方法,其中,所述方法还包括:The method for managing blockchain nodes according to claim 1, wherein the method further comprises:
    接收当前区块链网络中除所述目标节点以外的其他节点的打分请求;Receive scoring requests from other nodes other than the target node in the current blockchain network;
    将发出打分请求的节点作为目标节点,并对所述节点进行打分标记;The node that issued the scoring request is used as the target node, and the node is scored and marked;
    基于进行打分标记的所述目标节点的被打分标记的次数和/或所述目标节点的权限变化,确定所述目标节点是否能作为当前区块链网络的备选管理节点。It is determined whether the target node can serve as a candidate management node of the current blockchain network based on the number of times the target node is scored and marked and/or the authority change of the target node.
  8. 一种区块链节点的管理方法装置,其中,包括:A method and device for managing a blockchain node, comprising:
    节点访问单元,用于对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息;The node access unit is used to traverse all the nodes in the current blockchain network to obtain the time information of the state change of each node;
    加入时长计算单元,用于基于各个节点的状态变化的时间信息,得到所述各个节点加入当前区块链网络的时长;Joining a duration calculation unit for obtaining the duration of each node joining the current blockchain network based on the time information of the state change of each node;
    第一权限赋予单元,用于基于所述各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为所述目标节点赋予第一权限;The first authority granting unit is used to select a node whose duration of joining the current blockchain network satisfies a preset condition as a target node based on the duration of each node joining the current blockchain network, and assign a first permission to the target node. authority;
    节点打分单元,用于获取各所述目标节点在当前区块链网络中的历史行为记录,基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值;A node scoring unit, used to obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records;
    第二权限赋予单元,用于基于各所述目标节点在当前区块链网络中的贡献值,将所述目标节点的第一权限更新为第二权限,其中,所述第二权限的权限等级高于所述第一权限的权限等级。The second authority granting unit is configured to update the first authority of the target node to a second authority based on the contribution value of each target node in the current blockchain network, wherein the authority level of the second authority A permission level higher than the first permission.
  9. 一种计算机设备,其中,包括存储器和处理器,所述存储器中存储有计算机可读指令,所述计算机可读指令被所述处理器执行时,使得所述处理器执行以下步骤:A computer device, comprising a memory and a processor, wherein computer-readable instructions are stored in the memory, and when the computer-readable instructions are executed by the processor, the processor is caused to perform the following steps:
    对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息;Traverse all nodes in the current blockchain network to obtain the time information of state changes of each node;
    基于各个节点的状态变化的时间信息,得到所述各个节点加入当前区块链网络的时长;Obtain the duration of each node joining the current blockchain network based on the time information of the state change of each node;
    基于所述各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为所述目标节点赋予第一权限;Based on the duration of each node joining the current blockchain network, a node whose duration of joining the current blockchain network meets the preset conditions is selected as a target node, and the target node is given a first authority;
    获取各所述目标节点在当前区块链网络中的历史行为记录,基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值;Obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records;
    基于各所述目标节点在当前区块链网络中的贡献值,将所述目标节点的第一权限更新为第二权限,其中,所述第二权限的权限等级高于所述第一权限的权限等级。Based on the contribution value of each target node in the current blockchain network, the first authority of the target node is updated to a second authority, wherein the authority level of the second authority is higher than that of the first authority permission level.
  10. 根据权利要求9所述的计算机设备,其中,所述处理器执行所述对当前区块链网络中的所有节点进行遍历时,具体包括:The computer device according to claim 9, wherein, when the processor executes the traversal of all nodes in the current blockchain network, it specifically includes:
    基于当前区块链网络中的所有节点的运行信息,设置遍历所述节点的优先级;Based on the running information of all nodes in the current blockchain network, set the priority of traversing the nodes;
    按照所述优先级访问当前区块链网络中的所有节点。All nodes in the current blockchain network are accessed according to the stated priority.
  11. 根据权利要求9所述的计算机设备,其中,所述处理器执行所述基于各个节点的状态变化的时间信息,得到所述各个节点加入当前区块链网络的时长,具体包括:The computer device according to claim 9, wherein the processor executes the time information based on the state change of each node to obtain the time length of each node joining the current blockchain network, which specifically includes:
    基于各个节点的状态变化的时间信息,提取所述节点加入当前区块链网络的时间信息;Based on the time information of the state change of each node, extract the time information of the node joining the current blockchain network;
    对所述节点的加入时间信息进行随机性验证以识别所述加入时间信息是否被篡改;Perform randomness verification on the joining time information of the node to identify whether the joining time information has been tampered with;
    对加入时间信息被篡改的节点进行不诚信标记;Dishonest marking of nodes whose joining time information has been tampered with;
    将当前区块链网络中除被不诚信标记的节点以外的各节点的加入时间信息与当前区块链网络中管理节点的当前系统时间进行比较,确定各所述节点加入当前区块链网络的时长。Compare the joining time information of each node in the current blockchain network except the node marked by dishonesty with the current system time of the management node in the current blockchain network, and determine the time when each node joins the current blockchain network. duration.
  12. 根据权利要求9所述的计算机设备,其中,所述处理器执行所述选择加入当前区块链网络的时长满足预设条件的节点作为目标节点时,具体包括:The computer device according to claim 9, wherein, when the processor executes the selection of a node whose duration of joining the current blockchain network satisfies a preset condition as a target node, the process specifically includes:
    基于各所述节点加入当前区块链网络的时长,对当前区块链网络中的所有节点进行排序;Sorting all nodes in the current blockchain network based on the length of time each of the nodes joined the current blockchain network;
    选择排在所述排序结果的首端或末端的预设个数的节点为所述目标节点,或,选择所述排序结果中加入当前区块链网络的时长不大于预设时间阈值的节点为目标节点;Selecting a preset number of nodes at the beginning or end of the sorting result as the target node, or selecting a node whose duration of joining the current blockchain network in the sorting result is not greater than the preset time threshold as the target node target node;
    其中,任一所述目标节点加入当前区块链网络的时长小于当前区块链网络中除所述目标节点以外的其他节点加入当前区块链网络的时长。Wherein, the duration of joining any of the target nodes in the current blockchain network is shorter than the duration of joining the current blockchain network by other nodes in the current blockchain network except the target node.
  13. 根据权利要求9所述的计算机设备,其中,所述处理器执行所述基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值时,具体包括:The computer device according to claim 9, wherein, when the processor performs the determining of the contribution value of the target node in the current blockchain network based on the historical behavior record, it specifically includes:
    对各所述目标节点的各历史行为打正分或打负分,累计各所述节点的所有历史行为的打分结果得到所述目标节点的打分结果,根据所述目标节点的打分结果确定所述目标节点在当前区块链网络中的贡献值。Each historical behavior of each described target node is scored as positive or negative, and the scoring results of all historical behaviors of each described node are accumulated to obtain the scoring result of the target node, and the described target node is determined according to the scoring result of the target node. The contribution value of the target node in the current blockchain network.
  14. 根据权利要求9所述的计算机设备,其中,所述计算机可读指令被所述处理器执行时,还使得所述处理器执行以下步骤:The computer device of claim 9, wherein the computer-readable instructions, when executed by the processor, further cause the processor to perform the following steps:
    接收当前区块链网络中除所述目标节点以外的其他节点的打分请求;Receive scoring requests from other nodes other than the target node in the current blockchain network;
    将发出打分请求的节点作为目标节点,并对所述节点进行打分标记;The node that issued the scoring request is used as the target node, and the node is scored and marked;
    基于进行打分标记的所述目标节点的被打分标记的次数和/或所述目标节点的权限变化,确定所述目标节点是否能作为当前区块链网络的备选管理节点。It is determined whether the target node can serve as a candidate management node of the current blockchain network based on the number of times the target node is scored and marked and/or the authority change of the target node.
  15. 一种存储有计算机可读指令的存储介质,其中,所述计算机可读指令被一个或多个处理器执行时,使得一个或多个处理器执行以下步骤:A storage medium storing computer-readable instructions, wherein the computer-readable instructions, when executed by one or more processors, cause the one or more processors to perform the following steps:
    对当前区块链网络中的所有节点进行遍历,得到各个节点的状态变化的时间信息;Traverse all nodes in the current blockchain network to obtain the time information of the state change of each node;
    基于各个节点的状态变化的时间信息,得到所述各个节点加入当前区块链网络的时长;Obtaining the duration of each node joining the current blockchain network based on the time information of the state change of each node;
    基于所述各节点加入当前区块链网络的时长,选择加入当前区块链网络的时长满足预设条件的节点作为目标节点,并为所述目标节点赋予第一权限;Based on the duration of each node joining the current blockchain network, a node whose duration of joining the current blockchain network meets the preset conditions is selected as a target node, and the target node is given a first authority;
    获取各所述目标节点在当前区块链网络中的历史行为记录,基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值;Obtain the historical behavior records of each target node in the current blockchain network, and determine the contribution value of the target node in the current blockchain network based on the historical behavior records;
    基于各所述目标节点在当前区块链网络中的贡献值,将所述目标节点的第一权限更新为第二权限,其中,所述第二权限的权限等级高于所述第一权限的权限等级。Based on the contribution value of each target node in the current blockchain network, the first authority of the target node is updated to a second authority, wherein the authority level of the second authority is higher than that of the first authority permission level.
  16. 根据权利要求15所述的计算机设备,其中,所述计算机可读指令被一个或多个处理器执行,使得一个或多个处理器执行所述对当前区块链网络中的所有节点进行遍历时,具体包括:16. The computer device of claim 15, wherein the computer-readable instructions are executed by one or more processors to cause the one or more processors to perform the traversal of all nodes in the current blockchain network when , including:
    基于当前区块链网络中的所有节点的运行信息,设置遍历所述节点的优先级;Based on the running information of all nodes in the current blockchain network, set the priority of traversing the nodes;
    按照所述优先级访问当前区块链网络中的所有节点。All nodes in the current blockchain network are accessed according to the stated priority.
  17. 根据权利要求15所述的计算机设备,其中,所述计算机可读指令被一个或多个处理器执行,使得一个或多个处理器执行所述基于各个节点的状态变化的时间信息,得到所述各个节点加入当前区块链网络的时长时,具体包括:16. The computer device of claim 15, wherein the computer-readable instructions are executed by one or more processors to cause the one or more processors to execute the time information based on state changes of the respective nodes to obtain the When each node joins the current blockchain network, it includes:
    基于各个节点的状态变化的时间信息,提取所述节点加入当前区块链网络的 时间信息;Based on the time information of the state change of each node, extract the time information of the node joining the current blockchain network;
    对所述节点的加入时间信息进行随机性验证以识别所述加入时间信息是否被篡改;Perform randomness verification on the joining time information of the node to identify whether the joining time information has been tampered with;
    对加入时间信息被篡改的节点进行不诚信标记;Dishonest marking of nodes whose joining time information has been tampered with;
    将当前区块链网络中除被不诚信标记的节点以外的各节点的加入时间信息与当前区块链网络中管理节点的当前系统时间进行比较,确定各所述节点加入当前区块链网络的时长。Compare the joining time information of each node in the current blockchain network except the node marked by dishonesty with the current system time of the management node in the current blockchain network, and determine the time when each node joins the current blockchain network. duration.
  18. 根据权利要求15所述的计算机设备,其中,所述计算机可读指令被一个或多个处理器执行,使得一个或多个处理器执行所述选择加入当前区块链网络的时长满足预设条件的节点作为目标节点时,具体包括:16. The computer device of claim 15, wherein the computer-readable instructions are executed by one or more processors such that the one or more processors execute the opt-in to the current blockchain network for a period of time that satisfies a preset condition When the node is used as the target node, it specifically includes:
    基于各所述节点加入当前区块链网络的时长,对当前区块链网络中的所有节点进行排序;Sorting all nodes in the current blockchain network based on the length of time each of the nodes joined the current blockchain network;
    选择排在所述排序结果的首端或末端的预设个数的节点为所述目标节点,或,选择所述排序结果中加入当前区块链网络的时长不大于预设时间阈值的节点为目标节点;Selecting a preset number of nodes at the beginning or end of the sorting result as the target node, or selecting a node whose duration of joining the current blockchain network in the sorting result is not greater than the preset time threshold as the target node target node;
    其中,任一所述目标节点加入当前区块链网络的时长小于当前区块链网络中除所述目标节点以外的其他节点加入当前区块链网络的时长。Wherein, the duration of joining any of the target nodes in the current blockchain network is shorter than the duration of joining the current blockchain network by other nodes other than the target node in the current blockchain network.
  19. 根据权利要求15所述的计算机设备,其中,所述计算机可读指令被一个或多个处理器执行,使得一个或多个处理器执行所述基于所述历史行为记录确定所述目标节点在当前区块链网络中的贡献值时,具体包括:16. The computer device of claim 15, wherein the computer-readable instructions are executed by one or more processors to cause the one or more processors to perform the determining, based on the historical behavior record, that the target node is currently The contribution value in the blockchain network specifically includes:
    对各所述目标节点的各历史行为打正分或打负分,累计各所述节点的所有历史行为的打分结果得到所述目标节点的打分结果,根据所述目标节点的打分结果确定所述目标节点在当前区块链网络中的贡献值。Each historical behavior of each described target node is scored as positive or negative, and the scoring results of all historical behaviors of each described node are accumulated to obtain the scoring result of the target node, and the described target node is determined according to the scoring result of the target node. The contribution value of the target node in the current blockchain network.
  20. 根据权利要求15所述的计算机设备,其中,所述计算机可读指令被一个或多个处理器执行时,还使得一个或多个处理器执行以下步骤:16. The computer device of claim 15, wherein the computer-readable instructions, when executed by one or more processors, further cause the one or more processors to perform the following steps:
    接收当前区块链网络中除所述目标节点以外的其他节点的打分请求;Receive scoring requests from other nodes other than the target node in the current blockchain network;
    将发出打分请求的节点作为目标节点,并对所述节点进行打分标记;The node that issued the scoring request is used as the target node, and the node is scored and marked;
    基于进行打分标记的所述目标节点的被打分标记的次数和/或所述目标节点的权限变化,确定所述目标节点是否能作为当前区块链网络的备选管理节点。It is determined whether the target node can serve as a candidate management node of the current blockchain network based on the number of times the target node is scored and marked and/or the authority change of the target node.
PCT/CN2021/097242 2020-12-23 2021-05-31 Blockchain node management method and apparatus, computer device, and storage medium WO2022134471A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011537856.4 2020-12-23
CN202011537856.4A CN112738172B (en) 2020-12-23 2020-12-23 Block chain node management method and device, computer equipment and storage medium

Publications (1)

Publication Number Publication Date
WO2022134471A1 true WO2022134471A1 (en) 2022-06-30

Family

ID=75604762

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/097242 WO2022134471A1 (en) 2020-12-23 2021-05-31 Blockchain node management method and apparatus, computer device, and storage medium

Country Status (2)

Country Link
CN (1) CN112738172B (en)
WO (1) WO2022134471A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116502865A (en) * 2023-06-19 2023-07-28 江西财经大学 Intelligent management method and system for industrial enterprise production

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112738172B (en) * 2020-12-23 2022-03-08 平安科技(深圳)有限公司 Block chain node management method and device, computer equipment and storage medium
CN113259352A (en) * 2021-05-13 2021-08-13 深圳壹账通智能科技有限公司 Block chain node safety monitoring method and device, computer equipment and storage medium
CN117201488A (en) * 2022-05-31 2023-12-08 中国电信股份有限公司 Node management method, device, equipment and storage medium based on block chain

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102014135A (en) * 2010-12-03 2011-04-13 北京航空航天大学 Multilayer trust method for resisting selfish behavior in peer-to-peer (P2P) network
CN110490593A (en) * 2018-08-29 2019-11-22 华中科技大学 A kind of block chain common recognition method and system based on storage contribution margin
CN111818181A (en) * 2020-08-31 2020-10-23 腾讯科技(深圳)有限公司 Data processing method and device based on block chain and computer readable storage medium
CN112738172A (en) * 2020-12-23 2021-04-30 平安科技(深圳)有限公司 Block chain node management method and device, computer equipment and storage medium

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019124610A1 (en) * 2017-12-21 2019-06-27 문인식 Authentication method using separation, then distributed storage and combination of personal information using blockchain
GB2579635A (en) * 2018-12-07 2020-07-01 Dragon Infosec Ltd A node testing method and apparatus for a blockchain system
CN110533286B (en) * 2019-07-23 2023-04-18 平安科技(深圳)有限公司 Block chain-based coalition member management method and device and computer equipment
CN110493323B (en) * 2019-07-29 2020-12-01 华南理工大学 Block chain-based fairness file distribution method, system and storage medium
CN110427433B (en) * 2019-08-08 2023-04-07 上海中通吉网络技术有限公司 Block chain consensus method and storage medium
CN110502578A (en) * 2019-08-16 2019-11-26 江苏链路区块链技术有限公司 A kind of common recognition mechanism of rapid data cochain
CN110955721B (en) * 2019-10-23 2022-12-06 金蝶软件(中国)有限公司 Block link point state maintenance method and device, computer equipment and storage medium
CN111127206B (en) * 2019-12-25 2021-04-16 中国银联股份有限公司 Block chain data access control method and device based on intelligent contract
CN112737916B (en) * 2020-11-23 2022-01-07 腾讯科技(深圳)有限公司 Data processing method based on block chain network and related device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102014135A (en) * 2010-12-03 2011-04-13 北京航空航天大学 Multilayer trust method for resisting selfish behavior in peer-to-peer (P2P) network
CN110490593A (en) * 2018-08-29 2019-11-22 华中科技大学 A kind of block chain common recognition method and system based on storage contribution margin
CN111818181A (en) * 2020-08-31 2020-10-23 腾讯科技(深圳)有限公司 Data processing method and device based on block chain and computer readable storage medium
CN112738172A (en) * 2020-12-23 2021-04-30 平安科技(深圳)有限公司 Block chain node management method and device, computer equipment and storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116502865A (en) * 2023-06-19 2023-07-28 江西财经大学 Intelligent management method and system for industrial enterprise production

Also Published As

Publication number Publication date
CN112738172A (en) 2021-04-30
CN112738172B (en) 2022-03-08

Similar Documents

Publication Publication Date Title
WO2022134471A1 (en) Blockchain node management method and apparatus, computer device, and storage medium
CN110868440B (en) Block chain male chain
JP6560308B2 (en) System and method for implementing a data storage service
CN109218408B (en) Method, medium, computer device and blockchain system for implementing consensus mechanism of blockchain system
US9697066B2 (en) Method for processing data quality exceptions in a data processing system
CN106537345A (en) Precisely tracking memory usage in multi-process computing environment
WO2016022720A2 (en) Method and apparatus of identifying a transaction risk
CN111491002B (en) Equipment inspection method, device, inspected equipment, inspection server and system
CN105426375A (en) Relationship network calculation method and apparatus
WO2017211157A1 (en) Monitoring method and apparatus for associated accounts
CN109460345B (en) Real-time data calculation method and system
CN109033365B (en) Data processing method and related equipment
CN107203623B (en) Load balancing and adjusting method of web crawler system
CN111026709B (en) Data processing method and device based on cluster access
Lopez-Sanchez et al. Automating decision making to help establish norm-based regulations
CN114372060A (en) Data storage method, device, equipment and storage medium
CN110737673B (en) Data processing method and system
CN107104829B (en) Physical equipment matching distribution method and device based on network topology data
CN115756955A (en) Data backup and data recovery method and device and computer equipment
CN112202581A (en) Group joining method and device and electronic equipment
CN111427871A (en) Data processing method, device and equipment
US8782364B2 (en) Determining availability of data elements in a storage system
US8407531B2 (en) Method of collecting and correlating locking data to determine ultimate holders in real time
CN111221847A (en) Monitoring data storage method and device and computer readable storage medium
US20180053000A1 (en) Implementing locale management on paas: locale replacement risk analysis

Legal Events

Date Code Title Description
NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21908482

Country of ref document: EP

Kind code of ref document: A1