CN114338728A - Consensus method and system based on shared data - Google Patents

Consensus method and system based on shared data Download PDF

Info

Publication number
CN114338728A
CN114338728A CN202210251212.1A CN202210251212A CN114338728A CN 114338728 A CN114338728 A CN 114338728A CN 202210251212 A CN202210251212 A CN 202210251212A CN 114338728 A CN114338728 A CN 114338728A
Authority
CN
China
Prior art keywords
data
endorsement
information
block chain
industrial
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202210251212.1A
Other languages
Chinese (zh)
Other versions
CN114338728B (en
Inventor
胡殿凯
杨红飞
程东
薛闻斯
池邦成
张雪平
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huoshi Creation Technology Co ltd
Original Assignee
Hangzhou Firestone Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hangzhou Firestone Technology Co ltd filed Critical Hangzhou Firestone Technology Co ltd
Priority to CN202210251212.1A priority Critical patent/CN114338728B/en
Publication of CN114338728A publication Critical patent/CN114338728A/en
Application granted granted Critical
Publication of CN114338728B publication Critical patent/CN114338728B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a consensus method and a system based on shared data, so that data chaining is determined by three factors, namely endorsement success rate, data contribution rate and data utilization rate, and by coordinating the proportion of the three factors, under the condition that the number of surviving nodes in a block chain network is small, the consensus of the whole network can be achieved, and industrial data can be guaranteed to be chained at any time by an industrial big data contributor; meanwhile, the usability of the uplink data is improved through the data contribution rate and the data utilization rate, and the enthusiasm of industry organizations for contributing the industry data is improved through the industry data contribution rate.

Description

Consensus method and system based on shared data
Technical Field
The invention relates to the technical field of block chain data sharing, in particular to a consensus method and system based on shared data.
Background
With the rapid development of the digital industry, the security problem of industrial big data is more and more emphasized, the block chain can provide a trusted communication environment for the synchronous sharing of industrial big data due to the characteristics of decentralization, security, credibility, common maintenance and the like, and the industrial big data synchronization method based on the block chain also gradually becomes a main mode for carrying out data synchronous sharing among all large industrial organizations. Currently, when used for big data synchronization, the blockchain technique mainly adopts several common recognition mechanisms, such as: PoW, DPoS, Raft, PBFT, and consensus algorithms based on the above algorithms.
Each industrial mechanism has differences in contribution and use of data on a chain, and is mainly divided into two roles of an industrial data contributor and an industrial data user, wherein a few mechanisms can be the industrial data contributor and the industrial data user, but most mechanisms are the industrial data users, so that in the whole block chain network, the number of nodes of the industrial data users is large, when the industrial data users do not need to use the industrial data, most corresponding nodes are in a downtime state, and when too many downtime nodes are in the whole network, data uplink consensus is difficult to complete, and the problem of industrial data synchronization failure is easily caused; consensus mechanisms based on the number of nodes, for example: in the Raft and PBFT and the improved consensus algorithm thereof, the number of endorsement nodes is difficult to reach the number of consensus requirements, so that the whole network is difficult to reach consistency consensus, and the throughput of the consensus mechanisms based on computing power, such as PoW and DPoS, is small, the high throughput required by large data synchronization is difficult to realize, so that the method is not suitable for the application scene of large data synchronization sharing in the production industry.
Therefore, the existing consensus mechanism is difficult to ensure that industrial data can be linked up at any time by industrial big data contributors under the condition that the nodes are down too much; meanwhile, the conventional consensus mechanism can only ensure industrial data chaining and cannot block the chaining of useless industrial data, so that the useless industrial data on the chain are too much, the usability of the data on the chaining of industrial mechanisms cannot be judged, and the problem of storage resources of a block chain system caused by the waste of storage resources on the chain is easily caused; for mechanisms with different industrial data contribution rates, the conventional consensus mechanism cannot dynamically adjust the consensus difficulty according to the data contribution of the industrial mechanism, and is difficult to mobilize the enthusiasm of the industrial mechanism for contributing data.
Disclosure of Invention
The invention aims to provide a common identification method and a system based on shared data, so that data chaining is determined by three factors, namely endorsement success rate, data contribution rate and data utilization rate, through coordination of the proportion of the three factors, under the condition that the number of surviving nodes in a block chain network is small, the common identification of the consistency of the whole network can be achieved, industrial data can be guaranteed to be chained by an industrial big data contributor at any time, and meanwhile, the usability of the uplink data and the enthusiasm of industrial mechanism contribution industrial data are improved through the data contribution rate and the data utilization rate.
The purpose of the invention is realized by the following technical scheme:
according to a first aspect of the present description, a shared data-based consensus method comprises the steps of:
s1, submitting industrial data by an industrial data contributor mechanism in the block chain, generating industrial data information, and sending the industrial data information to an industrial data contribution node corresponding to the mechanism on the block chain; the industry data information contains data contribution rate and data utilization rate; the data contribution rate is the percentage of the total quantity of chained data of an industry data contributor organization to the total quantity of chained data; the data usage rate is a percentage of data used by other mechanisms in the blockchain in the industrial data information of the industrial data contributor mechanism uplink to a total percentage of the industrial data information of the industrial data contributor mechanism uplink;
s2, after receiving the industry data information, the industry data contribution node broadcasts the industry data information to the block chain nodes corresponding to other mechanisms in the block chain network;
s3, after receiving the broadcasted industrial data information, other organization nodes in the block chain verify the authenticity of the data contribution rate and the data utilization rate, if the authenticity passes, endorsement is carried out on the data contribution rate and the data utilization rate, corresponding endorsement information is generated and is broadcasted to all block chain nodes in the block chain network;
s4, judging the endorsement type after the block chain link point receives the endorsement information of the industrial data, if the endorsement type is the endorsement of the industrial data, calculating the endorsement success rate and calculating the consensus success rate, and if the consensus success rate reaches X%, storing the industrial data information into a local block chain; the success rate of the consensus is negotiated and set by each mechanism in the block chain; the endorsement success rate refers to the percentage of the number of the endorsement information received by the block chain nodes to the number of the block chain network nodes; the consensus success rate is obtained by summing the data contribution rate, the data utilization rate and the endorsement success rate after multiplying the data contribution rate, the data utilization rate and the endorsement success rate by weights respectively, and each weight is negotiated and set by all nodes in the block chain network.
Further, in step S1, the industry data information further includes an industry organization ID, a node ID, industry data, a data size, and a uplink data size; the data volume refers to the data capacity of the uplink data information of the current time of the mechanism providing the industrial data information; the uplink data amount refers to a data capacity of uplink data of an organization providing industrial data information.
Further, in step S1, the total amount of data on the chain refers to the total amount of data on the chain before the time node at which the transaction is submitted.
Further, in step S1, the total amount of uplink data and the total amount of uplink data are obtained by querying the blockchain transaction information.
Further, in step S1, the proportion of the data used by other mechanisms in the blockchain is obtained by multiplying the amount of data used by other mechanisms by the number of times of use of each piece of data, and summing all the data; the total proportion of the chain loading data is obtained by subtracting one from the number of times of use of each piece of data, multiplying the number of data used by other mechanisms on the chain, summing all the data and adding the number of the chain loaded data, the number of times of use is obtained by counting the number of endorsements corresponding to the industrial data information in the local block chain, and the type of the endorsements is data use number endorsements.
Further, in step S3, the authenticity verification means that the blockchain node calculates a data contribution rate and a data usage rate by checking related data in the local blockchain, and if both the calculated data contribution rate and the calculated data usage rate are greater than or equal to the data contribution rate and the data usage rate in the industrial data information, the verification is passed.
Further, in step S3, the endorsement information includes target information, an endorsement mechanism ID, an endorsement node ID, an endorsement identifier, and an endorsement category; the target information refers to industry data information of an uplink corresponding to the endorsement information; the endorsement type in the step is industrial data endorsement.
Further, after the industrial data using mechanism finishes using the industrial data, the data contribution rate needs to be updated, and the specific steps are as follows:
(1) the industry data contribution mechanism calculates the latest data contribution rate of the mechanism according to information on the chain, generates data contribution rate updating information and broadcasts the data contribution rate updating information to other mechanism nodes in other block chains in the block chain network through industry data contribution nodes; the data contribution rate updating information comprises the current contribution data volume, the total contribution data volume, the latest data contribution rate, the original data contribution rate and the data utilization rate information;
(2) after receiving the data contribution rate updating information, other mechanism nodes in the block chain carry out authenticity verification on the data contribution rate updating information, if the data contribution rate updating information passes the authenticity verification, carry out endorsement on the data contribution rate updating information, generate endorsement information and broadcast the endorsement information to all block chain nodes in the block chain network; target information in the endorsement information is data contribution rate updating information, and the endorsement type is data contribution rate endorsement;
(3) and after receiving the endorsement information, the block chain node judges the endorsement type, if the endorsement type is a data contribution rate endorsement, the endorsement success rate corresponding to the endorsement type is calculated, then the consensus success rate corresponding to the endorsement type is calculated, and if the consensus success rate reaches X%, the data contribution rate updating information is stored in a local block chain.
Further, after completing industrial data synchronization, the industrial data contribution mechanism needs to update the data usage rate based on the intelligent contract, and the specific steps are as follows:
(1) the industrial data user mechanism calls an intelligent contract to acquire corresponding industrial data information through industrial data use nodes in the corresponding block chain, and meanwhile generates the endorsement information and broadcasts the endorsement information to all block chain nodes in the block chain network; target information in the endorsement information is the industrial data information, and the endorsement type is data use frequency endorsement;
(2) and after receiving the endorsement information, the block chain node judges the endorsement type, and if the endorsement type is the data use frequency endorsement, the block chain node stores the endorsement information into a local block chain.
According to a second aspect of the present specification, there is provided a shared data-based consensus system, comprising a memory and one or more processors, the memory having stored therein executable code, the processors being configured to implement the shared data-based consensus method when executing the executable code.
The invention has the beneficial effects that: the invention does not depend on the number of the surviving nodes, so as to solve the problem that the industrial organization can not finish the uplink sharing of the industrial data under the condition that a few nodes survive; meanwhile, the availability of the uplink data is improved through the industrial data utilization rate, and the enthusiasm of the industrial institutions for contributing the industrial data is improved through the industrial data contribution rate. By setting the industrial data utilization rate, the consensus difficulty of chain data of industrial mechanisms is dynamically adjusted, and the problem of waste of on-chain storage resources caused by useless industrial data chain is reduced as much as possible; and through setting the contribution rate of the industrial data, the consensus difficulty of the industrial organization chaining data is dynamically adjusted, the probability of data chaining of the industrial organization is improved, and the industrial organization is promoted to actively and synchronously share the respective industrial data.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings without inventive exercise.
FIG. 1 is a flow chart of the consensus method of the present invention;
FIG. 2 is a flow chart of a method for updating data usage based on smart contracts;
FIG. 3 is a block diagram of a shared data based consensus system as provided by an exemplary embodiment.
Detailed Description
For better understanding of the technical solutions of the present application, the following detailed descriptions of the embodiments of the present application are provided with reference to the accompanying drawings.
It should be understood that the embodiments described are only a few embodiments of the present application, and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The terminology used in the embodiments of the present application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used in the examples of this application and the appended claims, the singular forms "a", "an", and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.
As shown in fig. 1, the consensus method based on shared data according to the present invention solves the problem that network consistency cannot be achieved due to excessive down of nodes in the synchronous industrial data sharing process of the blockchain network by improving the consensus mechanism, so that the industrial data contributors can still implement uplink synchronization of the industrial data under the condition that a few nodes are online; meanwhile, indexes such as data contribution rate and data utilization rate are added, the availability of industrial data on a chain is improved, and the enthusiasm of industrial institutions for contributing industrial data is mobilized. The method comprises the following steps:
s1, submitting industrial data by an industrial data contributor mechanism in the block chain, generating industrial data information, and sending the industrial data information to an industrial data contribution node corresponding to the mechanism on the block chain; the industry data contribution node refers to a block chain node corresponding to the industry data contributor mechanism, and each industry mechanism corresponds to one block chain node in the invention. The industrial data information comprises an industrial organization ID, a node ID, industrial data information, data volume, uplink data volume, data contribution rate and data utilization rate; the data contribution rate is the percentage of the total quantity of chained data of an industry data contributor organization to the total quantity of chained data; the total uplink data amount and the total uplink data amount are obtained by querying the blockchain transaction information, and the data contribution rate calculation formula is shown in formula 1:
data contribution rate = total amount of linked data/total amount of linked data of the organization equation 1
The data usage rate is a percentage of data used by other mechanisms in the blockchain in the industrial data information of the industrial data contributor mechanism uplink to a total percentage of the industrial data information of the industrial data contributor mechanism uplink; the data usage calculation formula is shown in formula 2:
data usage = data specific gravity/uplink data specific gravity used by other organization equation 2
Data specific gravity =usedby other mechanism
Figure 111309DEST_PATH_IMAGE001
(amount of data on chain used by other agencies. times of use) equation 2-1
Total proportion of uplink data = amount of uplink data +
Figure 933509DEST_PATH_IMAGE001
{ amount of data on chain used by other organization (number of uses-1) } equation 2-2
N represents the total record number of chain data of an industry data contributor mechanism, i represents a chain data number used by other mechanisms, the using times are obtained by counting the endorsement information quantity corresponding to the industry data information in a local block chain, and the endorsement type is data using time endorsement;
the data volume refers to the data capacity of the uplink data information of this time of the organization providing the industrial data information, and takes KB as a unit; the uplink data volume refers to the data capacity of uplink data of an organization providing industrial data information, and is based on KB as a unit; the total amount of data on the chain refers to the total amount of data on the chain before the time node at which the transaction was submitted.
S2, after receiving the industry data information, the industry data contribution node broadcasts the industry data information to the block chain nodes corresponding to other mechanisms in the block chain network; in the step, the broadcast is required to be broadcast to other block chain nodes (n-1) except the corresponding message broadcast node in the block chain network, and the block chain node (n-1) refers to any other block chain node except the corresponding message broadcast node in the block chain network.
S3, after receiving the broadcasted industrial data information, other nodes in the block chain verify the authenticity of the data contribution rate and the data utilization rate, if the verification is passed, the other nodes perform endorsement on the industrial data information to generate corresponding endorsement information, and the endorsement information is broadcasted to a block chain node (n) in the block chain network, wherein the block chain node (n) refers to any one block chain node in the block chain network; the authenticity verification means that the block chain node calculates the data contribution rate and the data utilization rate by checking related data in a local block chain, and if the calculated data contribution rate and the calculated data utilization rate are both greater than or equal to the data contribution rate and the data utilization rate in the industrial data information, the verification is passed; the endorsement information comprises target information, an endorsement mechanism ID, an endorsement node ID, an endorsement identifier and an endorsement type; the target information refers to industry data information of an uplink corresponding to the endorsement information; the endorsement type in the step is industrial data endorsement.
S4, judging the endorsement type after the block chain link point receives the endorsement information of the industrial data, if the endorsement type is the endorsement of the industrial data, calculating the endorsement success rate and calculating the consensus success rate, and if the consensus success rate reaches X%, storing the industrial data information into a local block chain; the endorsement success rate refers to the percentage of the number of the endorsement information received by the block chain nodes to the number of the block chain network nodes; as shown in equation 3;
endorsement success rate = endorsement information quantity/block chain network node quantity formula 3
The consensus success rate is the sum of the data contribution rate, the data utilization rate and the endorsement success rate multiplied by weights x, y and z, wherein x, y and z are different weights and can be set by all nodes in a block chain network. Specifically, as shown in formula 4;
consensus success rate = x data contribution rate + y data usage rate + z endorsement success rate formula 4
S5, the industrial data contribution mechanism needs to update the data contribution rate after completing the industrial data synchronization, and the specific steps are as follows:
s5-1, the industry data contribution mechanism calculates the latest data contribution rate of the mechanism according to the information on the chain, generates the data contribution rate updating information, and broadcasts the data contribution rate updating information to other block chain nodes (n-1) in the block chain network through industry data contribution nodes; the data contribution rate updating information comprises the present contribution data volume, the total contribution data volume, the latest data contribution rate, the original data contribution rate and the data utilization rate information.
S5-2, after receiving the data contribution rate updating information, other nodes in the block chain carry out the authenticity verification on the data contribution rate updating information, if the verification is passed, the other nodes carry out endorsement on the data contribution rate updating information to generate endorsement information, and the endorsement information is broadcasted to all block chain nodes (n) in the block chain network; the target information in the endorsement information is data contribution rate update information, and the endorsement type is data contribution rate endorsement.
And S5-3, judging the endorsement type after the endorsement information is received by the block chain link point, if the endorsement type is the data contribution rate endorsement, calculating the endorsement success rate corresponding to the endorsement type, then calculating the consensus success rate corresponding to the endorsement type, and if the consensus success rate reaches X%, storing the data contribution rate updating information to a local block chain.
S6, after completing the use of the industrial data, the industrial data using mechanism needs to update the data usage rate based on the intelligent contract, as shown in fig. 2, the specific steps are as follows:
s6-1, the industrial data user mechanism calls an intelligent contract to obtain corresponding industrial data information through industrial data use nodes in the corresponding block chain, and meanwhile, generates the endorsement information and broadcasts the endorsement information to all block chain nodes in the block chain network; target information in the endorsement information is the industrial data information, and the endorsement type is data use frequency endorsement;
and S6-2, after receiving the endorsement information, judging the endorsement type, and if the endorsement type is the data use frequency endorsement, storing the endorsement information into a local block chain.
The specific embodiment is as follows:
the embodiment of the application provides a consensus method based on shared data, and the consensus method is specifically introduced by taking an industrial big data sharing scene as an example according to different big data sharing scenes based on a block chain.
Before the consensus method of the present application is described in detail, an industrial big data sharing scenario is described. With the rapid development of the digital industry, the industrial productivity increasingly depends on data, and different industrial mechanisms need to share respective industrial data at proper time and cooperate with each other to realize the cooperative development among the mechanisms.
In this embodiment, an organization sharing its own industrial data is set as an industrial data contributor, an organization using industrial data of another organization is set as an industrial data consumer, and a small number of organizations contribute their own industrial data and apply industrial data of another organization, which is an industrial data contributor and an industrial data consumer. Before industrial data sharing is carried out, all organizations need to register block chain nodes and public and private key pairs in advance, and therefore participation in industrial data chaining consensus is facilitated.
Step 1: the industry data contributor A organization submits the industry data through a client side, generates a corresponding industry data information record Message-A and sends the Message-A to a corresponding industry data contribution node a.
Specifically, the industry data information record Message-a mainly includes related information such as organization ID, node ID, specific industry data, data volume, uplink data volume, data contribution rate, and data usage rate, and the specific information is { a organization ID: 00001; a node ID: j00001; industrial data: enterprise data from xxx, Hangzhou City; data volume: 3 KB; amount of uplink data: 5000 KB; data contribution rate: 10 percent; data usage rate: 70% }.
Wherein, the data volume and the uplink data volume are data capacity only, and take KB as a unit; the data contribution rate refers to the percentage of the total amount of the industry data shared by the chain of the organization a to the total amount of the industry data on the current block chain, and the specific calculation manner is shown in formula 1; the data utilization rate refers to the percentage of the industrial data linked by the a organization, in which the data used by other organizations accounts for the total percentage of all the industrial data linked by the a organization, and is calculated as shown in formula 2.
Step 2: after receiving the industry data information record Message-a, the industry data contribution node a broadcasts the industry data information record Message-a to all other nodes in the blockchain network.
Specifically, all other nodes refer to blockchain nodes corresponding to all other mechanisms in the blockchain network, for example: and nodes such as a node B and a node C corresponding to the industrial data contributor B organization and the industrial data consumer C organization.
And step 3: after all other nodes receive the industry data information record Message-A, verifying the data contribution rate and the data utilization rate of the A mechanism in the Message-A, and if the verification is passed, carrying out endorsement on the Message-A to generate endorsement information E-Message-A and broadcasting the endorsement information E-Message-A to all nodes of the block chain network.
Specifically, all other nodes calculate the data contribution rate and the data utilization rate corresponding to the mechanism a according to a formula 1 and a formula 2 by inquiring the relevant information of the local block chain, and if the calculated results are both greater than or equal to the data contribution rate and the data utilization rate in the Message-a, the verification is passed;
the endorsement information E-Message-A mainly comprises target information, an endorsement mechanism ID, an endorsement node ID, an endorsement identifier, an endorsement type and other information; for example: the endorsement information of the organization B on the Message-A is { target information: Message-A; b, organization ID: 00002; b, node ID: j00002; endorsement identification: the mechanism B signs the private key of the Message-A; the endorsement category: industry data endorsement }.
And 4, step 4: and after receiving the endorsement information E-Message-A, the block chain node judges the endorsement type, calculates the endorsement success rate if the endorsement type is the industrial data endorsement, then calculates the consensus success rate, and stores the industrial data information Message-A into the local block chain if the consensus success rate reaches 51 percent.
Specifically, the endorsement success rate refers to the percentage of the number of endorsement information E-Message-a received by the blockchain node from other nodes about the Message-a Message to the total number of the blockchain nodes, and the specific calculation manner is shown in formula 3.
And 5: after the industrial data contributor A mechanism completes the synchronization of the new block where the industrial data information recording Message-A is located, the latest data contribution rate of the mechanism needs to be updated.
Step 5-1: and the industry data contributor A mechanism calculates the latest industry data contribution rate of the mechanism by adopting a formula 1 according to the latest information on the chain, generates data contribution rate information C-Message-A, and broadcasts the data contribution rate information C-Message-A to other block chain nodes in the block chain network through the node a.
Specifically, the data contribution rate information C-Message-a includes the present contribution data amount, the total contribution data amount, the latest data contribution rate, the original data contribution rate, and the data usage rate information, for example: { this amount of contribution data: 3 KB; total amount of contribution data: 5003; latest data contribution rate: 10.1 percent; original data contribution rate: 10 percent; data usage rate: 70.1% }
Step 5-2: and after receiving the data contribution rate information C-Message-A, other block links perform authenticity verification on the data contribution rate information C-Message-A, if the data contribution rate information C-Message-A passes the authenticity verification, perform endorsement on the data contribution rate information C-Message-A, generate corresponding endorsement information E-C-Message-A and broadcast the endorsement information E-C-Message-A to all nodes in the block chain network.
Specifically, the endorsement information E-C-Message-A comprises information such as target information, an endorsement organization ID, an endorsement node ID, an endorsement identifier, and an endorsement type; for example: the endorsement information of the organization B to the C-Message-A is { target information: C-Message-A; b, organization ID: 00002; b, node ID: j00002; endorsement identification: the mechanism B signs the private key of the C-Message-A; the endorsement category: data contribution rate endorsement }.
Step 5-3: and after receiving the endorsement information E-C-Message-A, the block chain node judges the endorsement type, if the endorsement type is the data contribution rate endorsement, the corresponding endorsement success rate is calculated, then the corresponding consensus success rate is calculated, and if the consensus success rate reaches 51%, the data contribution rate information C-Message-A is stored in the local block chain.
Step 6: after the local synchronization of the new block where the industrial data information recording Message-a is located is completed, the industrial data user C mechanism needs to update the data usage rate based on an intelligent contract, and the specific steps are as follows:
s6-1, the industry data user C mechanism calls the intelligent contract to obtain the corresponding industry data information Message-A through the corresponding block chain using node C, and meanwhile, generates the endorsement information E-N-Message-A and broadcasts the endorsement information E-N-Message-A to all the block chain nodes in the block chain network.
Specifically, the endorsement information E-N-Message-A comprises information such as target information, an endorsement organization ID, an endorsement node ID, an endorsement identifier, and an endorsement type; for example: the endorsement information of the organization C to the Message-a is { target information: Message-A; c, organization ID: 00003; c, node ID: j00003; endorsement identification: the C organization signs the private key of the Message-A; the endorsement category: data usage endorsement }.
And S6-2, after the block chain link point receives the endorsement information E-N-Message-A, judging the endorsement type, and if the endorsement type is the data use frequency endorsement, storing the endorsement information E-N-Message-A into the local block chain.
Corresponding to the embodiment of the sharing method based on the shared data, the invention also provides an embodiment of a sharing system based on the shared data.
Referring to fig. 3, an embodiment of the present invention provides a shared data-based consensus system, which includes a memory and one or more processors, where the memory stores executable codes, and the processors execute the executable codes to implement the shared data-based consensus method in the foregoing embodiments.
The embodiment of the shared data based consensus system of the present invention can be applied to any data processing capable device, such as a computer or other like devices or apparatuses. The system embodiments may be implemented by software, or by hardware, or by a combination of hardware and software. Taking a software implementation as an example, as a system in a logical sense, the system is formed by reading corresponding computer program instructions in a nonvolatile memory into a memory for running through a processor of any device with data processing capability. From a hardware aspect, as shown in fig. 3, the hardware structure diagram of any device with data processing capability in which the shared data-based consensus system of the present invention is located is shown, except for the processor, the memory, the network interface, and the nonvolatile memory shown in fig. 3, in an embodiment, any device with data processing capability in which the system is located may also include other hardware according to the actual function of the any device with data processing capability, which is not described again.
The implementation process of the functions and actions of each unit in the system is specifically described in the implementation process of the corresponding step in the method, and is not described herein again.
For the system embodiment, since it basically corresponds to the method embodiment, reference may be made to the partial description of the method embodiment for relevant points. The above-described system embodiments are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the scheme of the invention. One of ordinary skill in the art can understand and implement it without inventive effort.
An embodiment of the present invention further provides a computer-readable storage medium, on which a program is stored, and when the program is executed by a processor, the shared data-based consensus method in the above embodiments is implemented.
The computer readable storage medium may be an internal storage unit, such as a hard disk or a memory, of any data processing capability device described in any of the foregoing embodiments. The computer readable storage medium may also be any external storage device of a device with data processing capabilities, such as a plug-in hard disk, a Smart Media Card (SMC), an SD Card, a Flash memory Card (Flash Card), etc. provided on the device. Further, the computer readable storage medium may include both an internal storage unit and an external storage device of any data processing capable device. The computer-readable storage medium is used for storing the computer program and other programs and data required by the arbitrary data processing-capable device, and may also be used for temporarily storing data that has been output or is to be output.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The foregoing description has been directed to specific embodiments of this disclosure. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
The terminology used in the description of the one or more embodiments is for the purpose of describing the particular embodiments only and is not intended to be limiting of the description of the one or more embodiments. As used in one or more embodiments of the present specification and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items.
The above description is only for the purpose of illustrating the preferred embodiments of the one or more embodiments of the present disclosure, and is not intended to limit the scope of the one or more embodiments of the present disclosure, and any modifications, equivalent substitutions, improvements, etc. made within the spirit and principle of the one or more embodiments of the present disclosure should be included in the scope of the one or more embodiments of the present disclosure.

Claims (10)

1. A consensus method based on shared data, the method comprising the steps of:
s1, submitting industrial data by an industrial data contributor mechanism in the block chain, generating industrial data information, and sending the industrial data information to an industrial data contribution node corresponding to the mechanism on the block chain; the industry data information contains data contribution rate and data utilization rate; the data contribution rate is the percentage of the total quantity of chained data of an industry data contributor organization to the total quantity of chained data; the data usage rate is a percentage of data used by other mechanisms in the blockchain in the industrial data information of the industrial data contributor mechanism uplink to a total percentage of the industrial data information of the industrial data contributor mechanism uplink;
s2, after receiving the industry data information, the industry data contribution node broadcasts the industry data information to the block chain nodes corresponding to other mechanisms in the block chain network;
s3, after receiving the broadcasted industrial data information, other organization nodes in the block chain verify the authenticity of the data contribution rate and the data utilization rate, if the authenticity passes, endorsement is carried out on the data contribution rate and the data utilization rate, corresponding endorsement information is generated and is broadcasted to all block chain nodes in the block chain network;
s4, judging the endorsement type after the block chain link point receives the endorsement information of the industrial data, if the endorsement type is the endorsement of the industrial data, calculating the endorsement success rate and calculating the consensus success rate, and if the consensus success rate reaches X%, storing the industrial data information into a local block chain; the success rate of the consensus is negotiated and set by each mechanism in the block chain; the endorsement success rate refers to the percentage of the number of the endorsement information received by the block chain nodes to the number of the block chain network nodes; the consensus success rate is obtained by summing the data contribution rate, the data utilization rate and the endorsement success rate after multiplying the data contribution rate, the data utilization rate and the endorsement success rate by weights respectively, and each weight is negotiated and set by all nodes in the block chain network.
2. The method according to claim 1, wherein in step S1, the industry data information further includes industry organization ID, node ID, industry data, data volume and uplink data volume; the data volume refers to the data capacity of the uplink data information of the current time of the mechanism providing the industrial data information; the uplink data amount refers to a data capacity of uplink data of an organization providing industrial data information.
3. The method according to claim 1, wherein in step S1, the total amount of data in the chain refers to a total amount of data in the chain before the time node of the transaction submission.
4. The method of claim 1, wherein in step S1, the total amount of uplink data and the total amount of uplink data are obtained by querying blockchain transaction information.
5. The consensus method as claimed in claim 1, wherein in step S1, the proportion of the data used by the other entities in the blockchain is determined by multiplying the amount of the data used by the other entities by the number of times of the data used by each piece of data, and summing all the data; the total proportion of the chain loading data is obtained by subtracting one from the number of times of use of each piece of data, multiplying the number of data used by other mechanisms on the chain, summing all the data and adding the number of the chain loaded data, the number of times of use is obtained by counting the number of endorsements corresponding to the industrial data information in the local block chain, and the type of the endorsements is data use number endorsements.
6. The method according to claim 1, wherein the authenticity verification in step S3 is that the blockchain node calculates a data contribution rate and a data usage rate by checking related data in a local blockchain, and if both the calculated data contribution rate and the calculated data usage rate are greater than or equal to the data contribution rate and the data usage rate in the industrial data information, the verification is passed.
7. The shared data-based consensus method of claim 1, wherein in step S3, said endorsement information comprises target information, endorsement authority ID, endorsement node ID, endorsement identification, and endorsement category; the target information refers to industry data information of an uplink corresponding to the endorsement information; the endorsement type in the step is industrial data endorsement.
8. The consensus method based on shared data as claimed in claim 1, wherein the industry data contribution mechanism needs to update the data contribution rate after completing the industry data synchronization, comprising the following steps:
(1) the industry data contribution mechanism calculates the latest data contribution rate of the mechanism according to information on the chain, generates data contribution rate updating information and broadcasts the data contribution rate updating information to other mechanism nodes in other block chains in the block chain network through industry data contribution nodes; the data contribution rate updating information comprises the current contribution data volume, the total contribution data volume, the latest data contribution rate, the original data contribution rate and the data utilization rate information;
(2) after receiving the data contribution rate updating information, other mechanism nodes in the block chain carry out authenticity verification on the data contribution rate updating information, if the data contribution rate updating information passes the authenticity verification, carry out endorsement on the data contribution rate updating information, generate endorsement information and broadcast the endorsement information to all block chain nodes in the block chain network; target information in the endorsement information is data contribution rate updating information, and the endorsement type is data contribution rate endorsement;
(3) and after receiving the endorsement information, the block chain node judges the endorsement type, if the endorsement type is a data contribution rate endorsement, the endorsement success rate corresponding to the endorsement type is calculated, then the consensus success rate corresponding to the endorsement type is calculated, and if the consensus success rate reaches X%, the data contribution rate updating information is stored in a local block chain.
9. The consensus method based on shared data as claimed in claim 1, wherein the industry data usage mechanism needs to update the data usage rate based on the intelligent contract after completing the industry data usage, the specific steps are as follows:
(1) the industrial data user mechanism calls an intelligent contract to acquire corresponding industrial data information through industrial data use nodes in the corresponding block chain, and meanwhile generates the endorsement information and broadcasts the endorsement information to all block chain nodes in the block chain network; target information in the endorsement information is the industrial data information, and the endorsement type is data use frequency endorsement;
(2) and after receiving the endorsement information, the block chain node judges the endorsement type, and if the endorsement type is the data use frequency endorsement, the block chain node stores the endorsement information into a local block chain.
10. A shared data based consensus system comprising a memory and one or more processors, said memory having stored therein executable code, wherein said processors, when executing said executable code, are configured to implement the shared data based consensus method according to any one of claims 1-9.
CN202210251212.1A 2022-03-15 2022-03-15 Consensus method and system based on shared data Active CN114338728B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210251212.1A CN114338728B (en) 2022-03-15 2022-03-15 Consensus method and system based on shared data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210251212.1A CN114338728B (en) 2022-03-15 2022-03-15 Consensus method and system based on shared data

Publications (2)

Publication Number Publication Date
CN114338728A true CN114338728A (en) 2022-04-12
CN114338728B CN114338728B (en) 2022-06-10

Family

ID=81033369

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210251212.1A Active CN114338728B (en) 2022-03-15 2022-03-15 Consensus method and system based on shared data

Country Status (1)

Country Link
CN (1) CN114338728B (en)

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101949712B1 (en) * 2018-06-29 2019-02-19 (주) 와이즈엠글로벌 Block chain generation method having consensus algorithm by stratified stochastic delegated proof of node and their commission allocation algorithm
CN109936457A (en) * 2019-02-20 2019-06-25 深圳前海微众银行股份有限公司 Block chain witnesses method, apparatus, equipment and computer readable storage medium in many ways
CN110012015A (en) * 2019-04-09 2019-07-12 中国科学院沈阳计算技术研究所有限公司 A kind of internet of things data sharing method and system based on block chain
CN110458540A (en) * 2019-07-25 2019-11-15 南京邮电大学 It is a kind of based on contribution degree with claim tag know together mechanism algorithm
CN110490593A (en) * 2018-08-29 2019-11-22 华中科技大学 A kind of block chain common recognition method and system based on storage contribution margin
CN110570196A (en) * 2019-09-05 2019-12-13 腾讯科技(深圳)有限公司 Transaction data processing method and device, terminal equipment and storage medium
CN110689433A (en) * 2019-09-26 2020-01-14 上海克而瑞信息技术有限公司 Resource management information service system, method and device based on alliance chain
US20200043115A1 (en) * 2018-08-02 2020-02-06 Zaius Networks Inc. doing business as (d.b.a.) BIGcontrols Permissioned blockchain ecosystem for economic development incentives
CN111078745A (en) * 2019-12-20 2020-04-28 京东数字科技控股有限公司 Data uplink method and device based on block chain technology
US20210012336A1 (en) * 2019-07-11 2021-01-14 Advanced New Technologies Co., Ltd. Shared blockchain data storage
WO2021184826A1 (en) * 2020-03-18 2021-09-23 腾讯科技(深圳)有限公司 Blockchain-based resource transfer method and apparatus, and node device and storage medium
CN113987080A (en) * 2021-12-28 2022-01-28 国网区块链科技(北京)有限公司 Block chain excitation method and device based on reputation consensus and related products

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101949712B1 (en) * 2018-06-29 2019-02-19 (주) 와이즈엠글로벌 Block chain generation method having consensus algorithm by stratified stochastic delegated proof of node and their commission allocation algorithm
US20200043115A1 (en) * 2018-08-02 2020-02-06 Zaius Networks Inc. doing business as (d.b.a.) BIGcontrols Permissioned blockchain ecosystem for economic development incentives
CN110490593A (en) * 2018-08-29 2019-11-22 华中科技大学 A kind of block chain common recognition method and system based on storage contribution margin
CN109936457A (en) * 2019-02-20 2019-06-25 深圳前海微众银行股份有限公司 Block chain witnesses method, apparatus, equipment and computer readable storage medium in many ways
CN110012015A (en) * 2019-04-09 2019-07-12 中国科学院沈阳计算技术研究所有限公司 A kind of internet of things data sharing method and system based on block chain
US20210012336A1 (en) * 2019-07-11 2021-01-14 Advanced New Technologies Co., Ltd. Shared blockchain data storage
CN110458540A (en) * 2019-07-25 2019-11-15 南京邮电大学 It is a kind of based on contribution degree with claim tag know together mechanism algorithm
CN110570196A (en) * 2019-09-05 2019-12-13 腾讯科技(深圳)有限公司 Transaction data processing method and device, terminal equipment and storage medium
CN110689433A (en) * 2019-09-26 2020-01-14 上海克而瑞信息技术有限公司 Resource management information service system, method and device based on alliance chain
CN111078745A (en) * 2019-12-20 2020-04-28 京东数字科技控股有限公司 Data uplink method and device based on block chain technology
WO2021184826A1 (en) * 2020-03-18 2021-09-23 腾讯科技(深圳)有限公司 Blockchain-based resource transfer method and apparatus, and node device and storage medium
CN113987080A (en) * 2021-12-28 2022-01-28 国网区块链科技(北京)有限公司 Block chain excitation method and device based on reputation consensus and related products

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
李亚珍等: "区块链技术在地学数据共享中的应用可行性分析", 《遥感技术与应用》 *
谭宇: ""基于区块链智能合约的在线知识共享机制研究"", 《重庆邮电大学硕士学位论文》 *

Also Published As

Publication number Publication date
CN114338728B (en) 2022-06-10

Similar Documents

Publication Publication Date Title
KR102215773B1 (en) Blockchain data protection based on account note model with zero-knowledge proof
US10839395B2 (en) Techniques for expediting processing of blockchain transactions
CN111095326B (en) Methods, systems, and apparatus for performing multiple transactions in a blockchain network
CN111095324B (en) Parallel execution of transactions in a distributed ledger system
US20220058732A1 (en) Cryptographic-asset collateral management
US20200311678A1 (en) Smart contract execution using distributed coordination
US20190052454A1 (en) System and method for controlling asset-related actions via a block chain
CN108390872B (en) Certificate management method, device, medium and electronic equipment
CN111309745B (en) Virtual resource processing method and device, electronic equipment and storage medium
WO2020157708A2 (en) Point-to-point distributed decentralized system
CN109274717A (en) Shared storage method, device, medium and electronic equipment based on block chain
Dorsala et al. Fair payments for verifiable cloud services using smart contracts
CN115668194A (en) Cross-partition calls in a partition's tamper-resistant data store
WO2019153660A1 (en) Transaction processing method and apparatus, and computer device and storage medium
US20220217004A1 (en) Systems and methods for non-parallelised mining on a proof-of-work blockchain network
CN113034137A (en) Data processing method and device based on block chain and related equipment
CN112995167A (en) Kafka mechanism-based power utilization information acquisition method, block chain network and user side
CN112788555B (en) Cross-operator telephone charge transfer settlement method, device and computing equipment
CN114338728B (en) Consensus method and system based on shared data
CN112269915B (en) Service processing method, device, equipment and storage medium
CN110098928B (en) Key generation method and device for collaborative signature
Wang et al. Rational adversary with flexible utility in secure two-party computation
CN113064899B (en) Method and device for storing asset securities type general evidence transaction certificates and electronic equipment
CN115632791B (en) Dynamic cross-chain data consistency decentration verification method
CN115174589B (en) Selection method and device of blockchain virtual machine, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CP01 Change in the name or title of a patent holder
CP01 Change in the name or title of a patent holder

Address after: 310051 7th floor, building B, 482 Qianmo Road, Xixing street, Binjiang District, Hangzhou City, Zhejiang Province

Patentee after: Huoshi Creation Technology Co.,Ltd.

Address before: 310051 7th floor, building B, 482 Qianmo Road, Xixing street, Binjiang District, Hangzhou City, Zhejiang Province

Patentee before: HANGZHOU FIRESTONE TECHNOLOGY Co.,Ltd.