WO2023020233A1 - 基于区块链的数据处理方法、装置、设备及存储介质 - Google Patents
基于区块链的数据处理方法、装置、设备及存储介质 Download PDFInfo
- Publication number
- WO2023020233A1 WO2023020233A1 PCT/CN2022/108482 CN2022108482W WO2023020233A1 WO 2023020233 A1 WO2023020233 A1 WO 2023020233A1 CN 2022108482 W CN2022108482 W CN 2022108482W WO 2023020233 A1 WO2023020233 A1 WO 2023020233A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- block
- business
- chain
- consensus
- blockchain
- Prior art date
Links
- 238000003672 processing method Methods 0.000 title claims abstract description 30
- 238000012795 verification Methods 0.000 claims description 94
- 238000012545 processing Methods 0.000 claims description 72
- 238000000034 method Methods 0.000 claims description 57
- 230000008569 process Effects 0.000 claims description 20
- 238000004590 computer program Methods 0.000 claims description 13
- 238000004364 calculation method Methods 0.000 claims description 7
- 230000000875 corresponding effect Effects 0.000 claims 4
- 230000002596 correlated effect Effects 0.000 claims 1
- 238000004422 calculation algorithm Methods 0.000 description 21
- 238000010586 diagram Methods 0.000 description 17
- 230000003993 interaction Effects 0.000 description 11
- 230000007246 mechanism Effects 0.000 description 9
- 239000000370 acceptor Substances 0.000 description 8
- 238000004891 communication Methods 0.000 description 6
- 230000006870 function Effects 0.000 description 6
- 238000013475 authorization Methods 0.000 description 5
- 238000005516 engineering process Methods 0.000 description 5
- 238000013500 data storage Methods 0.000 description 4
- 230000000694 effects Effects 0.000 description 4
- 238000007726 management method Methods 0.000 description 4
- 238000005065 mining Methods 0.000 description 4
- 230000008901 benefit Effects 0.000 description 3
- 230000005540 biological transmission Effects 0.000 description 3
- 238000012790 confirmation Methods 0.000 description 3
- 230000008520 organization Effects 0.000 description 3
- 238000004806 packaging method and process Methods 0.000 description 3
- 239000000284 extract Substances 0.000 description 2
- 230000002452 interceptive effect Effects 0.000 description 2
- 238000011835 investigation Methods 0.000 description 2
- 238000002360 preparation method Methods 0.000 description 2
- 238000012552 review Methods 0.000 description 2
- 238000012546 transfer Methods 0.000 description 2
- 238000013473 artificial intelligence Methods 0.000 description 1
- 230000006399 behavior Effects 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000002955 isolation Methods 0.000 description 1
- 238000000691 measurement method Methods 0.000 description 1
- 238000010295 mobile communication Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000000926 separation method Methods 0.000 description 1
- 238000012360 testing method Methods 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/104—Peer-to-peer [P2P] networks
- H04L67/1044—Group management mechanisms
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION 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
- G06Q30/00—Commerce
- G06Q30/06—Buying, selling or leasing transactions
- G06Q30/08—Auctions
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION 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/00—Finance; Insurance; Tax strategies; Processing of corporate or income taxes
- G06Q40/04—Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/12—Applying verification of the received information
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/104—Peer-to-peer [P2P] networks
- H04L67/1059—Inter-group management mechanisms, e.g. splitting, merging or interconnection of groups
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/32—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
- H04L9/3236—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using cryptographic hash functions
- H04L9/3239—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using cryptographic hash functions involving non-keyed hash functions, e.g. modification detection codes [MDCs], MD5, SHA or RIPEMD
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L2209/00—Additional information or applications relating to cryptographic mechanisms or cryptographic arrangements for secret or secure communication H04L9/00
- H04L2209/46—Secure multiparty computation, e.g. millionaire problem
- H04L2209/466—Electronic auction
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/50—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols using hash chains, e.g. blockchains or hash trees
Definitions
- the present application relates to the field of computer technology, in particular to a blockchain-based data processing method, a blockchain-based data processing device, a blockchain-based data processing device, a computer-readable storage medium, and A blockchain-based data computer program product.
- blockchain is widely used in asset transfer, business data storage and other aspects due to its traceability.
- the blockchain node After the blockchain node generates business data, it uploads the business data to the chain to ensure that the business data is traceable (that is, it cannot be tampered with after being on the chain).
- the business data requested to be chained within a period of time is usually packaged in a block for chaining.
- Practice has found that since a cross-chain business may be associated with multiple pieces of business data, the efficiency of processing cross-chain business is low.
- a blockchain-based data processing method device, device, storage medium, and computer program product are provided.
- the embodiment of the present application provides a blockchain-based data processing method
- the blockchain contains at least one block
- the blockchain is located in the blockchain network
- the blockchain network includes a witness sub-network and a consensus Sub-network
- the witness sub-network contains at least one business node
- the consensus sub-network contains at least two consensus clusters
- each consensus cluster includes multiple bookkeeping nodes
- each consensus cluster recommends a bookkeeping node in its respective consensus cluster as a representative Node
- the representative nodes of each consensus cluster form the consensus committee of the block chain
- the method is executed by the first representative node in the consensus committee, and the first representative node is any representative node in the consensus committee
- the data processing method is executed by computer equipment ,include:
- the target block waiting for consensus in the blockchain network; the target block is generated based on cross-chain business data;
- the on-chain instruction information indicates that the type of the next block to be on-chain in the blockchain is a joint exclusive type
- the target block will be added to the blockchain as the next block to be on-chain in the blockchain;
- Type blocks are used to store independent cross-chain business.
- the embodiment of the present application provides a block chain-based data processing device, the block chain contains at least one block; the block chain is located in the block chain network, and the block chain network includes a witness sub-network and a consensus Sub-network, the witness sub-network contains at least one business node; the consensus sub-network contains at least two consensus clusters; each consensus cluster includes multiple bookkeeping nodes, and each consensus cluster recommends a bookkeeping node in its respective consensus cluster as a representative node; the representative nodes of each consensus cluster form the consensus committee of the blockchain; the data processing device can be carried in the first representative node in the consensus committee, and the first representative node is any representative node in the consensus committee; the data processing device ,include:
- the obtaining unit is used to obtain the on-chain instruction information of the blockchain, and the on-chain instruction information is used to indicate the type of the next blockchain block to be uploaded; and is used to obtain the target block waiting for consensus in the blockchain network ;
- the target block is generated based on cross-chain business data;
- the processing unit is used to add the target block to the blockchain as the next block to be linked in the blockchain if the linking instruction information indicates that the type of the next block to be linked in the blockchain is a common exclusive type ; Among them, the block of common exclusive type is used to store independent cross-chain business.
- this application provides a data processing device based on block chain, which includes:
- processors for loading and executing computer readable instructions
- a computer-readable storage medium where computer-readable instructions are stored in the computer-readable storage medium, and when the computer-readable instructions are executed by a processor, the above-mentioned blockchain-based data processing method is implemented.
- the present application provides a non-volatile computer-readable storage medium storing computer-readable instructions, the computer-readable storage medium storing computer-readable instructions, the computer-readable instructions being adapted to be loaded by a processor and Execute the above-mentioned blockchain-based data processing method.
- the present application provides a computer program product
- the computer program product includes computer readable instructions
- the computer readable instructions are stored in a computer readable storage medium.
- the processor of the computer device reads the computer-readable instructions from the computer-readable storage medium, and the processor executes the computer-readable instructions, so that the computer device executes the above-mentioned blockchain-based data processing method.
- Figure 1a shows a schematic diagram of the architecture of a data sharing system provided by an exemplary embodiment of the present application
- Figure 1b shows a schematic structural diagram of a block chain provided by an exemplary embodiment of the present application
- Fig. 1c shows a schematic flow chart of generating a block provided by an exemplary embodiment of the present application
- Figure 1d shows a schematic diagram of a two-layer network architecture provided by an exemplary embodiment of the present application
- Figure 1e shows a schematic diagram of another two-layer network architecture provided by an exemplary embodiment of the present application
- Figure 1f shows a scene architecture diagram of an electronic invoice service based on a two-layer network provided by an exemplary embodiment of the present application
- Fig. 2 shows a schematic flow diagram of a blockchain-based data processing method provided by an exemplary embodiment of the present application
- FIG. 3 shows a schematic flow diagram of another blockchain-based data processing method provided by an exemplary embodiment of the present application
- Fig. 4 shows a schematic diagram of a blockchain-based data processing scenario provided by an exemplary embodiment of the present application
- Fig. 5 shows a schematic structural diagram of a blockchain-based data processing device provided by an exemplary embodiment of the present application
- Fig. 6 shows a schematic structural diagram of a blockchain-based data processing device provided by an exemplary embodiment of the present application.
- block chain is a computer technology such as distributed data storage, point-to-point transmission, consensus mechanism, encryption algorithm, etc. new application model. It is essentially a decentralized database, which is a series of data blocks associated with cryptographic methods. Each data block contains a batch of network transaction information, which is used to verify the validity of the information ( anti-counterfeiting) and generate the next block.
- the blockchain can include the underlying platform of the blockchain, the platform product service layer, and the application service layer.
- the blockchain network can be understood as a data sharing system 100.
- the data sharing system 100 can refer to a system for data sharing between nodes.
- An exemplary structure of the data sharing system 100 can be seen in FIG. 1a;
- the data sharing system 100 refers to a system for sharing data between nodes.
- the data sharing system may include multiple nodes 101, and the multiple nodes 101 may refer to various clients in the data sharing system.
- Each node 101 can receive input information during normal operation, and maintain shared data in the data sharing system based on the received input information.
- there may be an information connection between each node in the data sharing system there may be an information connection between each node in the data sharing system, and information transmission may be performed between nodes through the above information connection.
- nodes in the data sharing system when any node in the data sharing system receives input information, other nodes in the data sharing system will obtain the input information according to the consensus algorithm, and store the input information as data in the shared data, so that in the data sharing system The data stored on all nodes are consistent.
- each node in the data sharing system there is a node ID corresponding to it, and each node in the data sharing system can store the node IDs of other nodes in the data sharing system, so that according to the node IDs of other nodes, Broadcast the generated blocks to other nodes in the data sharing system.
- Each node can maintain a node ID list as shown in the following table, and store the node name and node ID in the node ID list.
- the node identification can be an IP (Internet Protocol, a protocol interconnected between networks) address and any other information that can be used to identify the node; for example, the node identification can also be a binary sequence code (such as 110001110), as shown In 1, only the IP address is used as an example for illustration:
- Every node in the data sharing system stores an identical blockchain.
- the blockchain is composed of multiple blocks. See Figure 1b.
- the blockchain is composed of multiple blocks.
- the founding block includes a block header and a block body.
- the block header stores input information characteristic values, version numbers, and timestamps.
- the input information is stored in the block body; the next block of the founding block takes the founding block as the parent block, and the next block also includes the block header and the block body, and the current block is stored in the block header
- the stored block data is associated, which ensures the security of the input information in the block.
- SHA256 is the eigenvalue algorithm used to calculate the eigenvalue
- version (version number) is the version information of the relevant block protocol in the blockchain
- prev_hash is the block header eigenvalue of the parent block of the current block
- merkle_root is the input information
- ntime is the update time of the update timestamp
- nbits is the current difficulty, which is a fixed value for a period of time, and will be determined again after a fixed period of time
- x is a random number
- TARGET is the threshold of the feature value, the feature The value threshold can be determined according to nbits.
- the node where the blockchain is located broadcasts the newly generated block to other nodes in the data sharing system where it is located according to the node identification of other nodes in the data sharing system, and other nodes perform consensus verification on the newly generated block , and add the newly generated block to its stored blockchain after completing the consensus verification.
- the nodes can perform consensus verification on the newly generated blocks through the consensus algorithm.
- the consensus algorithm can include but not limited to:
- Proof of work refers to the measurement method set by the system (such as the aforementioned data sharing system) to achieve a certain goal.
- a simple understanding is a proof to confirm the workload. In essence, whoever does more work has a better chance of getting extra rewards. Proof of work is commonly known as "mining”. Through AND or operation, a random number that meets the rules is calculated, that is, the right to bookkeeping is obtained this time, and the data that needs to be recorded in this round is issued. After verification by other nodes in the blockchain network store together. This makes the workload proof have the following advantages: complete decentralization, and nodes are free to enter and exit.
- the DPos share authorization certification mechanism is similar to board voting. People who hold electronic resources vote for a certain number of nodes, and perform verification and bookkeeping on their behalf. In order to motivate more people to participate in the election, the system will generate a small amount of electronic resources as rewards.
- the DPos share authorization proof mechanism is to allow everyone who holds BitShares to vote, resulting in 101 representatives, which we can understand as 101 supernodes or mining pools, and the rights of these 101 supernodes are completely independent from each other. equal. From a certain point of view, the DPos share authorization proof mechanism is a bit like a parliamentary system or a people's congress system.
- the pbft Byzantine fault-tolerant algorithm is a consensus algorithm based on message passing.
- the algorithm reaches consensus through three stages, and these stages may be repeated due to failure. Specifically, assuming that the total number of nodes is 3f+1, and f is a Byzantine error node, first, when the node finds that the leader (such as a representative node, accounting node or super node) is doing evil, it elects other replicas (nodes) through the algorithm as leader. Secondly, the leader broadcasts its selected value (value) to other replica nodes through the pre-prepare (pre-prepare) message. If other replica nodes accept it, they will send the prepare (prepare) message, and if they do not accept it, they will not send it.
- the leader such as a representative node, accounting node or super node
- the Paxos algorithm is a two-stage algorithm, which mainly has three types of roles, proposer (proposer), acceptor (receiver), and learner (learner).
- the proposer proposes a proposal, the acceptor agrees or rejects it, and the learner obtains the final value after reaching a consensus.
- the Paxos algorithm includes two phases, which are: 1 Preparation phase: the proposer selects a proposal number n and sends the prepare (preparation) request to a majority of the acceptors; after the acceptor receives the prepare request, if the proposal number is greater than it already For all prepare requests that are replied, the acceptor will reply to the proposer with the proposal it accepted last time, and promise not to reply to proposals smaller than n.
- 2Approval stage When a proposer receives most acceptors’ replies to the prepare request, it enters the approval stage; it will send an accept (accept) request to the acceptors that reply to the prepare request, including the number n and value (if there is no accepted value , then it can freely decide the value); on the premise of not violating its commitment to other proposers, the acceptor accepts the request after receiving the accept request.
- the Paxos algorithm is suitable for a simple fault-tolerant model, that is, there may only be failed or faulty nodes in the system, and there are no malicious nodes. If the number of failed nodes is x (x is a positive integer), then only the number of unfailed nodes is x+1. Maintain the normal operation of the system.
- the Raft algorithm contains three roles: follower, candidate and leader.
- a node can only be in one of these three states at a certain moment, and these three roles can be converted to each other as time and conditions change.
- the initial state of all nodes is follower.
- the follower who has not received the heartbeat packet after the timeout will turn into a candidate and broadcast a voting request.
- the node that has won the majority of votes will become a leader.
- Whoever sends out the first round of voting will benefit. Nodes will only give one vote.
- the leader node periodically sends heartbeat packets to other nodes, and the failure of the leader node will trigger a new round of voting.
- the embodiment of this application provides a double-layer chain, through P2P (Peer to Peer, point-to-point)
- P2P Peer to Peer, point-to-point
- the network forms a two-layer network architecture of "witness sub-network-consensus sub-network".
- the P2P network is a network of point-to-point connections, and each node connected by point-to-point connection is called a peer node.
- the P2P network is based on a specific network protocol, so that there is no need for a central node to maintain the network state between the peer nodes.
- Each node maintains the node state of the entire network and its communication with adjacent nodes The connection status of neighboring nodes.
- Figure 1d shows an architecture diagram of a two-layer network provided by an exemplary embodiment of the present application
- the blockchain network includes a witness subnetwork and a consensus subnetwork, and service nodes are deployed on In the witness sub-network, the consensus sub-network is deployed with accounting nodes running the blockchain consensus protocol; the witness sub-network and the consensus sub-network interact through the routing boundary indicated by the dotted line.
- the business nodes in the witness sub-network mainly perform business execution and do not participate in the bookkeeping consensus, and obtain block header data and partially authorized and visible block data from the consensus sub-network through identity authentication.
- the consensus sub-network is the core network in the blockchain network, which is used for bookkeeping consensus on the blockchain network.
- the witness sub-network and the consensus sub-network are in different network environments, the witness sub-network is in the public network, and the consensus sub-network is in the private network. Since the consensus sub-network is in a relatively secure private network, there is a consensus mechanism for mutual access to ensure security, and no additional identity management and network control are required.
- the business nodes are in the public network and may be accessed by other uncertain network terminals. Therefore, the behavior of business nodes and other possible nodes accessing the consensus sub-network needs to be strictly controlled.
- these bookkeeping nodes in the consensus sub-network can also be divided into multiple consensus clusters, that is, multiple consensus clusters can be deployed in the consensus sub-network, and each consensus cluster can include At least one accounting node.
- Consensus clusters can be divided according to different rules. The rules can include: division according to business types, such as accounting nodes that process business data of the same business type are divided into the same consensus cluster; The distance divides the consensus cluster, such as dividing two or more accounting nodes whose distance is less than the distance threshold into the same consensus cluster, and so on.
- the architecture of the two-layer blockchain network can be changed to Figure 1e.
- the blockchain network includes a witness subnetwork and a consensus subnetwork, and multiple consensus subnetworks are deployed in the consensus subnetwork.
- Cluster each consensus cluster contains at least one bookkeeping node; any business node in the witness subnetwork can carry out information connection with the bookkeeping node deployed by a certain consensus cluster in the consensus subnetwork.
- each consensus cluster can be used to provide consensus services for business data of one or more business types.
- Consensus cluster 1 in Figure 1e can be a cluster that provides consensus services for business data of the invoice business type, that is, each accounting node in the consensus cluster 1 only performs consensus processing for invoice data;
- consensus cluster 2 can be for A cluster that provides consensus services for business data of the credit investigation type, that is, each accounting node in the consensus cluster 2 only conducts consensus processing for business data related to credit investigation; and so on.
- each consensus cluster jointly maintains a blockchain in the blockchain network, which is called the main chain, which contains all the information of all business ecology in the blockchain network.
- each consensus cluster can organize its own business blockchain sub-chain, and the blockchain sub-chain in each consensus cluster only contains the information of each consensus cluster's own business.
- Each consensus cluster can recommend a bookkeeping node as a representative node in their respective consensus clusters; among them, the representative node not only participates in the consensus processing of the blockchain sub-chain in the consensus cluster to which it belongs, but also participates in the consensus on the main chain deal with.
- the non-representative nodes in the consensus cluster that is, the accounting nodes other than the representative nodes in the consensus cluster, only participate in the consensus processing of the blockchain sub-chains within the consensus cluster.
- the representative nodes elected by each consensus cluster jointly form the consensus committee of the main chain, and jointly carry out consensus processing on the main chain.
- the blockchain network includes: business layer, routing proxy layer, and core consensus network layer.
- the business layer, routing proxy layer, and core consensus network layer form the entire blockchain business system; among them, 1 business layer
- the business layer includes at least one business node.
- the business node can be an SPV node.
- the SPV node maintains a normal unstructured P2P network.
- the business node can handle (local tax bureau) taxation, bills (enterprise billing), payment (corporate capital flow) and other services.
- the core consensus network layer is in the consensus sub-network.
- the core consensus network layer includes various consensus clusters, such as consensus cluster 102, consensus cluster 103, ..., etc., and each consensus cluster maintains the block chain sub-chain in the cluster, for example , the consensus cluster 102 maintains the core chain 1 in the cluster, and the consensus cluster 103 maintains the core chain 2 in the cluster.
- the routing proxy layer includes at least one proxy node, which can provide routing services, authentication services, certificate cache services, peer-to-peer (P2P) services, etc.; wherein, the certificate cache service involves a certificate system (PKI, Public Key Infrastructure).
- PKI Public Key Infrastructure
- a certificate is the identity proof of a public key owner, which is issued by an authority (CA).
- asymmetric encryption and digital signature for information can be realized.
- the information interaction between the business layer and the core consensus network layer is through the routing proxy layer, that is, the business layer submits business operation interactions to the core consensus network layer through the routing proxy layer, so that the routing proxy layer isolates the business layer from the core consensus network layer effect.
- This solution can be executed by the first representative node in the consensus committee shown in Figure 1e, and the first representative node can be any representative node in the consensus committee.
- the representative node may specifically be a terminal device or a server.
- the terminal equipment may include but not limited to: smart phones (such as Android mobile phones, IOS mobile phones, etc.), tablet computers, portable personal computers, mobile Internet devices (Mobile Internet Devices, MID for short), etc. Do limited.
- the server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or it can provide cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, intermediate Cloud servers for basic cloud computing services such as email service, domain name service, security service, CDN (Content Delivery Network), and big data and artificial intelligence platforms, which are not limited in this embodiment of the application.
- cloud services cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, intermediate Cloud servers for basic cloud computing services such as email service, domain name service, security service, CDN (Content Delivery Network), and big data and artificial intelligence platforms, which are not limited in this embodiment of the application.
- the blockchain contains at least one block, such as M interlinked blocks, where M is a positive integer;
- the blockchain is located in the blockchain network, see Figure 1e, the blockchain network Including the witness sub-network and the consensus sub-network, the witness sub-network contains at least one business node;
- the consensus sub-network contains at least two consensus clusters, for example, it can contain N consensus clusters, N is an integer greater than 1;
- each consensus cluster consists of multiple Accounting nodes, each consensus cluster recommends an accounting node as a representative node in its own consensus cluster, then N consensus clusters can recommend N representative nodes;
- N representative nodes form the consensus committee of the blockchain; based on
- the data processing method of the blockchain is executed by the first representative node in the consensus committee, and the first representative node is any representative node in the consensus committee;
- the general principle of the data processing scheme based on the blockchain is as follows:
- the first representative node obtains the uplink indication information of the M+1th block of the blockchain, and the uplink indication information is used to indicate the next block to be uplinked in the blockchain, that is, the M+1th block
- the type of the block such as common exclusive type, exclusive type, common type, etc.
- the on-chain indication information of the M+1th block is generated based on the auction result information of the M+1th block
- the M+1th block The bidding result information of the block is processed by consensus on the bidding information of the M+1th block by each representative node in the blockchain network (for example, according to the bidding information, it is determined that the second party with the proposal authority of the M+1th block representative node); the auction result information of the M+1th block carries the type of the M+1th block; the bidding information is in the process of uploading the Mth block (consensus) If the representative node that needs to bid for the M+1th block broadcasts to other representative nodes in the blockchain network, the bidding information is used to bid for the proposal authority of
- the first representative node obtains the target block waiting for consensus in the blockchain network.
- the target block is the representative node that has obtained the proposal authority of the M+1 block in the blockchain network.
- the business data to be linked to the +1 block (that is, the business data indicated by the representative node in the bidding information that needs to be packaged in the M+1th block) is packaged and broadcast to the blockchain network of each representative node.
- the consensus verification of the target block is performed according to the consensus rules of the common exclusive type (that is, each representative node independently checks the block according to the consensus rules The target block is verified, and then the final verification result is determined according to its own verification result and the verification results of the target block broadcast by other representative nodes in the blockchain network); among them, the common exclusive type of block is used to store Independent cross-chain business, each cross-chain business is an independent cross-chain business, each cross-chain business is participated by at least two business parties, and each business party will provide at least one piece of business data to be deposited (that is, each Co-exclusive blocks are used to store business data associated with a cross-chain business); consensus rules are used to verify whether the target block meets the on-chain conditions (such as verifying whether the business data in the target block belongs to the same cross-chain business) Chain business, whether the business party of the target block matches the identifiers of multiple co-exclusive parties of the M+1th block indicated
- the target block passes the consensus verification, the target block is added to the blockchain as the M+1th block (that is, the target block is uploaded to the chain to obtain an updated blockchain).
- the on-chain instruction information of the M+1th block of the blockchain is obtained, and the target block waiting for consensus in the blockchain network, if the on-chain instruction information indicates the M+1th block
- the type of the common exclusive type is the common exclusive type
- the consensus verification of the target block will be performed according to the common exclusive type consensus rules.
- the common exclusive type of block is used to store independent cross-chain services. If the target block passes the consensus verification, the target block The block is added to the blockchain as the M+1th block. It can be seen that when it comes to cross-chain interaction, the relevant business data of independent cross-chain business is stored in one block through common exclusive blocks, which can improve the verification of multiple blocks when verifying cross-chain business. In this way, the verification efficiency of cross-chain business is improved, and the processing efficiency of cross-chain business is improved.
- the embodiment of this application proposes a more detailed block chain-based data processing method.
- the block chain-based data processing method proposed in the embodiment of this application will be described below in conjunction with the accompanying drawings for details.
- Fig. 2 shows a schematic flow diagram of a block chain-based data processing method provided by an exemplary embodiment of the present application; wherein, the block chain contains at least one interlinked block; the block chain is located in the block chain
- the blockchain network includes a witness subnetwork and a consensus subnetwork.
- the witness subnetwork includes at least one business node; the consensus subnetwork includes at least two consensus clusters; each consensus cluster includes multiple bookkeeping nodes , each consensus cluster recommends a bookkeeping node as a representative node in its respective consensus cluster; the representative nodes of each consensus cluster form the consensus committee of the blockchain; the data processing method based on the blockchain is determined by the first representative in the consensus committee Node execution, the first representative node is any representative node in the consensus committee; the data processing method based on blockchain may include but not limited to steps S201-S203:
- the on-chain indication information is used to indicate the information of the next block to be on-chain in the blockchain, specifically indicating the type of the next block to be on-chain, such as common exclusive type, exclusive type, common type, etc.
- the block chain contains M interlinked blocks, M is an integer greater than 1, the consensus sub-network contains N consensus clusters, and N is an integer greater than 1, then N consensus clusters recommend N Represents a node.
- the chaining instruction information can indicate the type of the M+1th block, such as the common exclusive type , exclusive type, common type, etc.; the on-chain instruction information of the M+1th block is generated based on the auction result information of the M+1th block; the auction result information of the M+1th block is generated by the district
- Each representative node in the block chain network performs consensus processing on the bidding information of the M+1th block (such as determining the second representative node with the proposal authority of the M+1th block according to the bidding information); the Mth The bidding result information of the +1 block carries the type of the M+1th block.
- the bidding information is broadcast by the representative node that needs to bid for the next block to other representative nodes in the blockchain network during the process of uploading the current block.
- the bidding information is broadcast by the representative node that needs to bid for the M+1th block to other representative nodes in the blockchain network during the chaining (consensus) process of the Mth block.
- the bidding information carries the relevant information of the business data that needs to be packaged in the M+1th block (such as the business data packaged in the M+1th block quantity, the identification of the business party associated with the M+1th block, the type of business data packaged in the M+1th block, etc.); the representative node that has obtained the proposal authority of the M+1th block can According to the bidding information of the representative node, the target block waiting for consensus is generated (that is, the business data reported in the bidding information is packaged to generate the target block waiting for consensus).
- the first representative node is specifically a computer device, and the computer device obtains the uplink indication information of the blockchain.
- the uplink indication information is used to indicate the type of the next block to be uplinked in the blockchain.
- the indication information can determine the type of the next block that needs to be uploaded in the blockchain.
- the target block waiting for consensus is obtained by packaging the block data to be linked to the next block to be linked by the representative node with the proposal authority of the block.
- the target block is generated based on the cross-chain business data, that is, the target block is obtained by packaging the business data of the cross-chain business.
- each cross-chain business is an independent cross-chain business, and each cross-chain business is participated by at least two business parties, and each business party will provide at least one piece of business data to be deposited, that is to say, each common exclusive type
- the block is used to store the business data associated with a cross-chain business.
- the target block waiting for consensus can be the block associated with the M+1th block to be on-chain
- the block data that is, the business data indicated by the representative node in the bidding information that needs to be packaged in the M+1th block
- the representative node with the proposal authority for the block is obtained from the blockchain network
- the representative node of the packaging authority to the M+1th block that is, the authority to generate the target block waiting for consensus).
- the representative node with the proposal authority can obtain the deposit information of one or more business data associated with the M+1th block from the resource pool of the blockchain network, specifically including cross-chain business data, and generate target blocks waiting for consensus based on the certificate information of these business data.
- the representative node with the proposal authority After the representative node with the proposal authority generates the target block, it will broadcast the target block to each representative node in the blockchain network.
- the first representative node can obtain the waiting consensus through the broadcast of the representative node with the proposal authority target block.
- the computer device obtains the target block waiting for consensus in the blockchain network.
- the target block can be generated by the representative node with the proposal authority according to the cross-chain business data, and the representative node with the proposal authority can generate the target block Broadcasting is performed so that the target block is obtained by the computer device.
- on-chain indication information indicates that the type of the next block to be on-chain in the blockchain is a common exclusive type, then add the target block to the blockchain as the next block to be on-chain in the blockchain; wherein, Co-exclusive blocks are used to store independent cross-chain services.
- the types of blocks can include co-exclusive types, and each co-exclusive type of block is used to store an independent cross-chain business.
- Each cross-chain business is an independent cross-chain business, each cross-chain business is participated by at least two business parties, and each business party will provide at least one piece of business data to be deposited
- the block is used to store the business data associated with a cross-chain business); for example, business party A and business party B participate in cross-chain business 1, business party B and business party C participate in cross-chain business 2, business party A, business Party B and business party C jointly participate in cross-chain business 3, then cross-chain business 1-cross-chain business 3 are three independent cross-chain businesses, that is to say, cross-chain business 1-cross-chain business 3 are stored in three different In the block of common exclusive type, the business data associated with cross-chain business 1 cannot be stored in the block used to store the business data associated with cross-chain business 2 or cross-chain business 3.
- the business data associated with cross-chain business 2 Data cannot be stored in the block used to store the business data associated with cross-chain business 1 or cross-chain business 3
- the business data associated with cross-chain business 3 cannot be stored in the block used to store cross-chain business 1 or cross-chain business 2 In the block of business data.
- the computer The device can add the target block to the blockchain as the next block to be uploaded to the blockchain, so as to process the target block on the chain.
- the computer equipment can perform consensus verification on the target block according to the consensus rules of the common exclusive type, and after the consensus verification is passed, the target block is added to the blockchain as the next block to be uploaded to the block chain. On the block chain, so as to ensure the accuracy of the block chain.
- the consensus rules are used to verify whether the target block meets the on-chain conditions, and the on-chain conditions can be determined according to the on-chain instruction information (such as verifying whether the business data in the target block belongs to the same cross-chain business, the target block’s Whether the business party matches the identifiers of multiple co-exclusive parties of the M+1th block indicated by the uplink indication information, etc.).
- the first representative node verifies the target block according to the consensus rules, and then according to its own verification results and the target block broadcast by other representative nodes in the blockchain network except the first representative node
- the verification result determines the final consensus verification result.
- Passing the consensus verification of the target block means that the first representative node determines that the target block satisfies On-chain conditions.
- the first representative node records the target block as the M+1th block of the blockchain.
- the target block generated according to the cross-chain business data is added to the blockchain, which can avoid separate processing of multiple blocks during cross-chain business processing. Carry out cross-chain business data processing, effectively realize the isolation processing of cross-chain business, reduce the interactive processing between multiple blocks, thereby improving the processing efficiency of cross-chain business.
- the on-chain instruction information of the blockchain is obtained, and the target block generated according to the cross-chain business data waiting for consensus in the blockchain network is obtained. If the on-chain instruction information indicates that the next blockchain to be on-chain If the block type is a common and exclusive type used to store independent cross-chain services, then the target block will be added to the blockchain as the next block to be uploaded to the blockchain. It can be seen that when it comes to cross-chain interaction, storing the relevant business data of independent cross-chain business in one block through the block of common exclusive type can improve the processing of cross-chain business. In this case, the relevant business data in the chain is interactively processed, thereby improving the processing efficiency of cross-chain business.
- the target block is added to the blockchain as the next block to be on-chain in the blockchain above, including: if the on-chain indication information indicates that the type of the next block to be on-chain in the blockchain is a common exclusive type, then the target block will be verified by consensus according to the consensus rules of the common exclusive type; if the target block passes the consensus If it is verified, the target block will be added to the blockchain as the next block to be uploaded to the blockchain.
- the consensus rules are used to verify whether the target block meets the on-chain conditions.
- the on-chain conditions can be determined according to the on-chain instruction information, such as including but not limited to checking whether the business data in the target block belong to the same cross-chain Whether the business, the business party of the target block matches the identifiers of multiple co-exclusive parties of the M+1th block indicated by the on-chain instruction information, etc.
- the target block passing the consensus verification means that the first representative node determines that the target block satisfies the above requirements based on its own verification results and the verification results of the target block broadcast by other representative nodes in the blockchain network except the first representative node. If the chain condition is met, the target block can be chained into the blockchain.
- the computer device can query the joint exclusive Type consensus rules.
- the computer equipment performs consensus verification on the target block according to the consensus rules of the common exclusive type. If the consensus verification passes, the computer equipment adds the target block to the blockchain as the next block to be uploaded to the blockchain. In this way, the on-chain processing of the target block is realized.
- the computer device performs consensus verification on the target block according to the consensus rules of the common exclusive type, and adds the target block to the block chain when the consensus verification passes, so as to ensure that the target block meets the on-chain conditions , which ensures the success rate of uploading the target block to the chain.
- Fig. 3 shows a schematic flow chart of another blockchain-based data processing method provided by an exemplary embodiment of the present application; wherein, the blockchain contains M interlinked blocks, and M is a positive integer;
- the block chain is located in the block chain network.
- the block chain network includes a witness sub-network and a consensus sub-network.
- the witness sub-network contains at least one business node; the consensus sub-network contains N consensus clusters, where N is greater than 1 Integer; each consensus cluster is composed of multiple bookkeeping nodes, and each consensus cluster recommends a bookkeeping node as a representative node in its own consensus cluster; N representative nodes form the consensus committee of the blockchain; the method is determined by the consensus committee Executed by the first representative node, the first representative node is any representative node in the consensus committee; the blockchain-based data processing method may include but not limited to steps S301-S305:
- the auction result information is used to indicate the second representative node that has obtained the proposal authority for the next block to be uploaded in the blockchain, and the second representative node Submitted bidding information for the next block to be uploaded on the blockchain.
- the auction result information of the next block to be uploaded in the blockchain is obtained by consensus processing of the bidding information of the next block to be uploaded in the blockchain by each representative node in the blockchain network.
- the information is determined to be submitted by the second representative node that has the proposal authority for the next block to be uploaded.
- the auction result information may indicate the second representative node that has obtained the proposal authority for the next block to be uploaded in the blockchain, and the bidding information submitted by the second representative node for the next block to be uploaded in the blockchain.
- the auction result information of the M+1th block is processed by consensus on the bidding information of the M+1th block by each representative node in the blockchain network (for example, according to The bidding information is obtained after determining the second representative node with the proposal authority of the M+1th block); the bidding result information of the M+1th block carries the type of the M+1th block.
- the bidding information is broadcasted by the representative node that needs to bid for the M+1th block to other representative nodes in the blockchain network during the chaining (consensus) process of the Mth block.
- the bidding information is used for Proposal authority to bid for the M+1th block (bid for a block of exclusive type or co-exclusive type); the bidding information carries relevant information about the business data that needs to be packaged in the M+1th block (such as packaged in The number of business data in the M+1th block, the identification of the business party associated with the M+1th block, the type of business data packaged in the M+1th block, etc.); get the M+th
- the representative node with the proposal authority of 1 block can generate the target block waiting for consensus according to the bidding information of the representative node (that is, pack the business data reported in the bidding information to generate the target block waiting for consensus); for example, When the representative node 1 needs to deposit the 1000 business data to be deposited associated with the representative node, it broadcasts the bidding information 1 to the consensus committee
- the bidding transaction specifies the identity of the representative node requesting the proposal authority of the M+1th block, and the amount of business data to be stored in the M+1th block.
- the consensus committee agrees on the bidding transaction, whether the number of business data to be stored in the resource pool meets the specified number of the bidding transaction; for example, suppose the bidding transaction specifies that the second representative node should be in the M+1th block Putting in 1000 exclusive type business data, the consensus committee’s consensus on the auction transaction includes: checking whether there are more than 1000 exclusive type business data or common type business data from the second representative node in the transaction pool.
- the business parties participating in the cross-chain business will randomly negotiate a representative node, carrying the signatures of each business party participating in the cross-chain business, to bid for a common exclusive type of area piece.
- the bidding information includes the identification of the business party that jointly occupies the M+1th block, the amount of business data that each business party needs to put in the M+1th block, etc.; for example, consensus cluster 1-consensus cluster 3 jointly participated in the completion of the cross-chain business 1, and the consensus cluster 1-consensus cluster 3 can determine the representative node 1 of the consensus cluster 1 through negotiation to represent the consensus cluster 1-consensus cluster 3 to apply for storing cross-chain business 1
- the representative node of the block of the common exclusive type of business data, the bidding information 1 generated by representative node 1 includes the identification of the representative node of consensus cluster 1-consensus cluster 3, and consensus cluster 1-consensus cluster 3 (that is, each business party ) the amount of business data that needs to be placed in the M+1th block, etc.
- the bidding information includes at least one of the quantity of business data to be packaged in the next block to be uploaded on the blockchain, the business party ID associated with the business data, or the type of business data.
- the target block also stores the business data to be deposited for each business party among multiple business parties.
- the target block is associated with the target business, and the service party ID associated with the business data refers to the target business ID.
- the type of business data refers to the type of cross-chain business data to be packaged in the next blockchain block to be uploaded.
- the bidding information includes at least one of the quantity of business data to be packaged in the next blockchain block to be uploaded, the business party identifier associated with the business data, or the type of business data. According to the bidding information, it can Generate corresponding on-chain instruction information to perform consensus verification on the target block through the on-chain instruction information to ensure the accuracy of cross-chain business data processing.
- the bidding information includes the waiting time and the amount of bidding resources, and the bidding result information.
- the consensus committee checks the bidding information based on the waiting time and the amount of bidding resources in the bidding information, and when the consensus of the bidding information Generated after the verification is successful.
- the consensus committee conducts a consensus check on the bidding information based on the waiting time and the amount of bidding resources in the bidding information sent by each representative node (such as checking whether there is a pending auction indicated by the bidding information in the resource pool in the blockchain network. certificate business data, whether the number of certificate business data to be stored in the resource pool in the blockchain network satisfies the quantity indicated by the bidding information, etc.).
- the bidding information can include the identification of the business parties participating in the cross-chain business, and the number of business data that each business party needs to package in the M+1th block.
- the consensus The committee can check whether the business party indicated by the bidding information participates in the cross-chain business, and can also check with each business party whether the amount of business data that needs to be packaged in the M+1th block is accurate, etc.
- the bidding information consensus verification is successful, the bidding result information is generated.
- the consensus committee based on the waiting time and the amount of bidding resources in the bidding information, the consensus committee generates the bidding result information after performing consensus verification on the bidding information, thereby ensuring the authority and validity of the bidding result information and ensuring Data processing is carried out in an orderly manner.
- the bidding information is at least obtained through a weighted operation based on the waiting time and the amount of bidding resources.
- the bidding information includes the waiting time and the amount of bidding resources.
- the bidding information can be calculated according to the waiting time, the amount of bidding resources and their corresponding weights, and then summed.
- the waiting time is inversely proportional to the amount of bidding resources (that is, the longer the waiting time , the less bidding resources are required, and the shorter the waiting time, the more bidding resources are required).
- the waiting time refers to the length of time from the time when the target representative node requests to obtain the proposal permission of the block to the current moment (the target representative node has not obtained the proposal permission of the block during the period), and the target representative node can be any representative node in the formula committee ;For example, if the representative node 1 requested to obtain the proposal permission of the block 10 minutes ago, and the representative node 1 did not obtain the proposal permission of the block within 10 minutes, the waiting time of the representative node 1 is 10 minutes; It means that node 2 requested to obtain the proposal authority of the block 30 minutes ago, and it means that node 2 obtained the proposal authority of the block 17 minutes ago, and obtained the proposal authority of the block again 8 minutes ago, which means that node 2 is waiting The duration is 8 minutes.
- Bidding resources can be set according to actual conditions. For example, bidding resources can be composed of one or more of the following: physical resources, virtual items, the number of business data to be deposited, and so on.
- the bidding information is obtained through the weighted calculation of the waiting time and the amount of bidding resources, so that the waiting time and the amount of bidding resources can be effectively balanced to ensure the distribution effect of the proposal authority and ensure the orderly processing of data based on the blockchain. .
- the bidding information is obtained by performing weighted calculations according to weights corresponding to the waiting time, bidding resource amount, and service priority.
- Different representative nodes can correspond to different priorities (taking the tax bureau as an example, the business (billing) priority of the national tax bureau is higher than the business (billing) priority of the municipal tax bureau, and the business (bill) priority of the municipal tax bureau higher than the business (invoicing) priority of the county-level tax bureau), the higher the business priority, the greater the corresponding weight, and the bidding information can be obtained through the calculation of the waiting time, the amount of bidding resources, and the weight corresponding to the business priority.
- the bidding information is obtained by weighting the waiting time and the amount of bidding resources according to the weight corresponding to the business priority, so that the business priority can be used to effectively balance the waiting time and the amount of bidding resources to ensure the authority of the proposal
- the distribution effect ensures the orderly progress of data processing based on blockchain.
- the bidding resource corresponding to the bidding resource amount includes at least one of physical resources, virtual items, or the quantity of business data to be deposited.
- the amount of bidding resources corresponding to the amount of bidding resources can be set according to actual needs, specifically including but not limited to the number of physical resources, virtual items, or business data to be deposited. By setting different bidding resources, it can be applied to different application scenarios, thereby expanding the applicable scenarios of the blockchain-based data method.
- the first representative node and the second representative node are different representative nodes.
- Obtaining the auction result information of the next block to be uploaded in the blockchain including: in the process of consensus on the block at the end of the blockchain, receiving the submission of the second representative node for the next pending block in the blockchain.
- the bidding information of the block on the chain, the bidding information is used to request the proposal permission of the next block to be chained in the blockchain; to perform consensus verification on the bidding information; and to receive the bidding result information broadcast by the consensus committee.
- the end position refers to the position of the last block in the blockchain.
- the block at the end of the blockchain is the Mth block. blocks.
- the first representative node receives the bidding information for the M+1th block submitted by the second representative node, and the bidding information is used for Request to obtain the proposal permission of the M+1th block; the first representative node performs consensus verification on the bidding information, and receives the bidding result information broadcast by the consensus committee (other representative nodes except the first representative node), and will repeat
- the bidding result information with the highest rate is determined as the final bidding result information; for example, suppose that among the bidding result information obtained by the first representative node, the repetition rate of bidding result information 1 generated according to bidding information 1 is 95%, and the repetition rate of bidding result information 1 generated according to bidding information 2 The repetition rate of the bidding result information 2 is 3%, and the repetition rate of the bidding result information 3
- the first representative node when the first representative node and the second representative node are different representative nodes, the first representative node receives the bidding information of the second representative node, and performs consensus verification based on the bidding information to receive the broadcasted bidding result Information, so as to ensure that the obtained auction result information is broadcast by the second representative node with proposal authority, and ensure the accuracy of the auction result information.
- the first representative node and the second representative node are the same representative node.
- the bidding information for the next block to be uploaded to the blockchain is submitted to the consensus committee, and the bidding information is used to request the next blockchain to be uploaded Proposal permissions for chain blocks; consensus verification of bidding information; and receiving bidding result information broadcast by the consensus committee.
- the end position refers to the position of the last block on the chain in the blockchain.
- the first representative node submits bidding information for the M+1th block to the consensus committee, and the bidding information is used to request to obtain the Proposal authority for M+1 blocks; the first representative node conducts consensus verification on the bidding information, and receives the bidding result information broadcast by the consensus committee (other representative nodes except the first representative node), and the one with the highest repetition rate
- the bidding result information is determined as the final bidding result information.
- the broadcasted bidding result information is received, so as to ensure that the obtained bidding result information is Broadcasted by the first representative node with proposal authority to ensure the accuracy of the auction result information.
- the first representative node determines the second representative node (that is, the representative node with the authority to propose the M+1th block) according to the bidding result information, and generates the second representative node according to the bidding information broadcast by the second representative node.
- the on-chain indication information of the M+1 block for example, the first representative node can directly use the bidding information broadcast by the second representative node as the on-chain indication information of the M+1th block; Extract part of the data from the broadcast bidding information (such as the identification of the business party associated with the M+1th block, the number of business data to be deposited by each business party, etc.), and generate the M+1th block based on the extracted data On-chain instruction information of the block.
- the on-chain instruction information is generated, specifically using the information submitted by the second representative node indicated by the bidding result information for the next block to be chained in the blockchain
- the auction information of the block generates on-chain indication information, which can accurately obtain the on-chain indication information of the next block to be on-chain in the blockchain, so as to accurately determine the type of the next block to be on-chain in the blockchain.
- generating the link indication information of the next block to be linked in the blockchain according to the bidding result information includes: extracting the bidding information from the bidding result information; On-chain indication information of a block to be on-chain.
- the auction result information carries the auction information
- the computer device extracts the auction information from the obtained auction result information, and generates the on-chain indication information of the next blockchain block to be uploaded based on the obtained auction information, so as to pass
- the on-chain indication information determines the type of the next block to be on-chain in the blockchain.
- by extracting the bidding information from the bidding result information to generate on-chain instruction information it is possible to determine the type of the next block to be on-chain in the blockchain according to the bidding information submitted by the second representative node with proposal authority , to ensure that the next block to be uploaded in the blockchain can be processed in an orderly manner.
- the first representative node and the second representative node are different representative nodes, and the first representative node obtains the target block waiting for consensus broadcast by the second representative node.
- the first representative node and the second representative node are the same representative node, and the first representative node obtains the cross-chain business data of each business party of the target business from the resource pool in the blockchain network, And generate the target block according to the cross-chain business data of each business party.
- the first representative node determines whether the auction transaction result information is packaged in the Mth block during the consensus process of the Mth block. If the auction transaction result information is packaged in the Mth block, then According to the auction transaction result information, the on-chain instruction information of the M+1th block is generated.
- the first representative node obtains the cross-chain business data of each business party of the target business from the resource pool in the blockchain network, and generates the target block, so that the efficient processing of the cross-chain business data can be realized.
- the M+1th block can only store the exclusive type of business data and common type of business data (preferentially put exclusive type of business data, and then put in common type of business data to fill the target block (that is, the number of business data in the M+1th block satisfies the above The number indicated by the chain indication message)).
- a bidding resource deduction service for the M+1th block is added, and the deduction service and business data are packaged into a target block.
- the M+1th block can only store the cross-chain business indicated by the bidding transaction result information Associated co-exclusive business data.
- the M+1th block is used to store normal type business data in the resource pool, and Transactions such as global on-chain configuration updates.
- the smart contract is changed, and the changed smart contract is used to determine the type of the target block as Ordinary type (that is, after T blocks of exclusive type or common exclusive type are continuously generated in the blockchain, a block of ordinary type must be generated), and T is a positive integer.
- Exclusive type of business data exclusive type of business data can only be placed in exclusive type blocks.
- Business data of the common exclusive type it can only be placed in the block of the common exclusive type, and the block of the common exclusive type is used to store the data of the common exclusive type associated with the cross-chain business jointly participated by 2 to N business parties business data.
- the co-exclusive type of business data associated with the cross-chain business can be a specially marked business data, which carries the blockchain sub-chain (private chain maintained by each consensus cluster) of the party participating in the cross-chain business Identification, the identification of each business party (such as the address of each business party, and the signature information of each business party, etc.).
- Ordinary type business data Ordinary type business data can be placed in both common type blocks and exclusive type blocks. When placed in exclusive type blocks, its priority Business data below the exclusive type.
- Consensus verification of the target block according to the consensus rules of the co-exclusive type includes the first representative node verifying the validity of the target block according to the on-chain instruction information, and the consensus committee determines the final consensus verification result based on voting.
- Consensus verification of the target block according to the consensus rules of the common exclusive type may include one or more of the following implementation methods:
- the target block is associated with the target business, and the target block is used to store the cross-chain business data of the target business; consensus verification is performed on the target block according to the consensus rules of the common exclusive type, including: verification Whether the target business is an independent cross-chain business; if the target business is an independent cross-chain business, it is determined that the target block passes the consensus verification.
- the computer equipment of the first representative node checks whether the target business is an independent cross-chain business; specifically, the computer equipment of the first representative node can check whether the business data of the target business is the business data of the common exclusive type, if the business of the target business If the data is not the business data of the co-exclusive type, it is determined that the target business is not an independent cross-chain business, and the target block has not passed the consensus verification; if the business data of the target business is the business data of the co-exclusive type, it is determined that the target block has passed the consensus verification After verification, the target block can be added to the blockchain.
- the computer device can also check whether the identification of the business party of the target business carried in the business data of the target business matches; if the business data of the target business carries If the identity of the business party of the target business matches, it is determined that the target business is an independent cross-chain business, and the target block passes the consensus verification; if the business data of the target business does not match the identity of the business party of the target business, it is determined that the target The business is an independent cross-chain business, and the target block passes the consensus verification; for example, if the target business is participated by business party A and business party B, if the business data of business party A carries the identity of business party B (and business party A) , and the business data of business party B carries the identification of business party A (and business party B), it is determined that the target business is an independent cross-chain business, and the target block passes the consensus verification; correspondingly, if the business data of business party A Carry the identification of business
- the computer device verifies the target business associated with the target block, so as to determine whether the target business is an independent cross-chain business, realizes the verification of the target block, and ensures that the target block meets the requirements of the next chain to be uploaded.
- the business condition of the block which ensures the accuracy of the next block added to the blockchain.
- the target block is associated with the target business, and the target block stores the identifications of multiple business parties participating in the target business; the on-chain indication information is also used to indicate the next blockchain area to be on-chain Identification of multiple co-exclusive parties to a block.
- the first representative node checks whether the identifiers of multiple business parties in the target block are consistent with the identifiers of multiple co-exclusive parties in the next block to be linked in the blockchain.
- There are M blocks in the blockchain Specifically, it can be determined whether the identifiers of multiple co-exclusive parties in the M+1th block are consistent with those of the multiple business parties in the target block; If the identifiers of multiple business parties in the target block are consistent with those of multiple co-exclusive parties in the M+1th block, the target block will not pass the consensus verification.
- Consensus verification for example, if the target block stores the identity of business party 1 and business party 2 participating in the target business, and the on-chain instruction information indicates that the identity of the co-exclusive party of the M+1th block is the business party 1 and business party 2, the first representative node determines that the target block has passed the consensus verification and can add the target block to the blockchain.
- the computer device checks the identification of the business party of the target business associated with the target block, so as to determine the identification of multiple business parties in the target block and the multiple business parties of the next block to be linked in the blockchain.
- the identification of the co-exclusive party is consistent, and the verification of the target block is realized to ensure that the target block meets the conditions of the business party of the next block to be chained, and to ensure the accuracy of the next block added to the blockchain.
- the target block also stores the business data to be deposited for each of the multiple business parties; the on-chain indication information is also used to indicate the occupancy quantity of each of the multiple joint exclusive parties .
- the target block also includes: obtaining the certificate to be stored for each business party in the target block The quantity of business data; check whether the quantity of business data to be deposited by each business party matches the corresponding quantity occupied by each co-exclusive party; if the quantity of business data to be deposited by each business party matches the corresponding If the occupancy quantity of the co-exclusive party matches, the step of judging and determining that the target block passes the consensus verification is continued.
- the first representative node obtains the number of business data to be deposited by each business party in the target block (such as counting the number of business data to be deposited by each business party in the target block), and checks that each business party Whether the number of business data to be deposited for certificates matches the corresponding number of occupancy of each common exclusive party (for example, checking the number of business data to be deposited by each business party in the target block and the corresponding occupancy of each common exclusive party) whether the number is the same), if the number of business data to be deposited by each business party matches the corresponding occupied quantity of each co-exclusive party; then the target block passes the consensus verification; if there is at least one The amount of business data does not match the amount occupied by the corresponding co-exclusive party; it is determined that the target block has not passed the consensus verification.
- the target block stores two pieces of business data to be deposited by business party 1 and one piece of data to be deposited by business party 2, and the on-chain instruction information indicates that the number of occupied by business party 1 is 2, and that of business party 2 is 1, the first representative node determines that the target block has passed the consensus verification.
- the computer device checks the number of business data to be deposited by each business party stored in the target block, thereby determining the number of business data to be deposited by each business party in the target block, and The number of occupancy of each co-exclusive party of the next block to be chained in the blockchain is matched to realize the verification of the target block and ensure that the target block conforms to the requirements of the business data to be deposited in the next block to be chained. A quantity condition that ensures the accuracy of the next block added to the blockchain.
- the target block is associated with the target business, and the target business is participated by multiple business parties.
- a business party refers to a consensus cluster in the consensus sub-network; the target block also stores multiple business party Each business party's business data to be stored; each business party maintains a block chain sub-chain (that is, each consensus cluster maintains a private chain for storing business data in the consensus cluster).
- Consensus verification is performed on the target block according to the consensus rules of the co-exclusive type, including: checking whether the business data to be deposited by each business party in the target block has been stored in each business party’s respective blockchain sub-chain; If the business data to be deposited of each business party in the target block has been stored in each business party's respective blockchain sub-chain, it is determined that the target block passes the consensus verification.
- the first representative node checks whether the business data to be deposited of each business party in the target block has been stored in each business party's respective block chain sub-chain (for example, the first representative node sends a confirmation to each business party information to confirm that the business data to be deposited by each business party has been stored in each business party’s respective blockchain sub-chain); if the business data to be deposited by each business party in the target block has been stored in each In the respective blockchain sub-chains of two business parties, it is determined that the target block has passed the consensus verification; if there is at least one business party in the target block whose business data to be deposited is not stored in the respective blockchain sub-chains of the business party , it is determined that the target block has not passed the consensus verification.
- the computer device checks whether the business data to be deposited in the target block has been stored in the respective blockchain sub-chains of each business party to ensure that the data stored in the respective blockchain sub-chains of each business party has been stored There is corresponding business data to be deposited to ensure that the target block meets the sub-chain storage conditions of the business data to be deposited in the next block to be uploaded to ensure the accuracy of the next block added to the blockchain.
- the M+1th block carries the type identifier of the block and the identifier of the business party associated with the M+1th block.
- the process of adding a new block to the blockchain is as follows:
- the second representative node of the M+1th block generates the target block to be consensus
- the second representative node of the M+1th block broadcasts the target block to be consensused to other representative nodes in the consensus committee except the second representative node;
- the representative nodes in the consensus committee verify the target block to be agreed upon, and broadcast their respective verification results to other representative nodes in the consensus committee (such as voting for the verification results approved by themselves);
- Each representative node in the consensus committee collects the votes of other representative nodes in the consensus committee, and broadcasts the collected voting results greater than the proportional threshold (such as 2/3);
- Each representative node in the consensus committee collects the voting results of other representative nodes in the consensus committee. If the proportion of votes obtained by the verification result indicating that the target block to be consensus is verified is greater than the ratio threshold (such as 2/3) , it means that the consensus of the target block to be agreed is passed;
- the target block is taken as the M+1th block in the blockchain, and the second representative node corresponding to the M+2th block is determined according to the consensus auction result information.
- FIG. 4 shows a schematic diagram of a blockchain-based data processing scenario provided by an exemplary embodiment of the present application.
- the consensus sub-network includes N consensus clusters, and N is an integer greater than 1.
- Each consensus cluster contained in the consensus sub-network can elect a bookkeeping node as a representative node, and N representative nodes form a consensus committee , the consensus committee maintains a block chain 401 of the consensus sub-network, and the block chain 401 is the main chain in the block chain network.
- N consensus clusters can bid for the proposal permission of the blockchain network.
- the consensus cluster with the proposal permission is responsible for generating the target block to be consensus
- the consensus cluster with the proposal permission is responsible for generating the target block to be consensus
- the consensus cluster with the proposal permission The representative node is responsible for broadcasting the target block to be consensused to each representative node in the consensus committee, and the consensus process is carried out by the consensus committee.
- block A1 in blockchain 401 is broadcast by the representative nodes in consensus cluster 3 to each representative node in the consensus committee
- block C1 in blockchain 401 is broadcast by representative nodes in consensus cluster 1 To each representative node in the consensus committee.
- the business data of the entire consensus sub-network can be recorded in the blockchain maintained by the consensus committee, which facilitates the management and review of business data provided by different consensus clusters in the entire consensus sub-network.
- each consensus cluster can also maintain its own blockchain sub-chain, which only contains its own business blocks, which is convenient for the consensus cluster to manage its own business data.
- the new block when a new block is generated in the consensus cluster, the new block can anchor the previous block generated in the consensus cluster to realize the organization of the blockchain sub-chain of the consensus cluster.
- Consensus cluster 1 shown in FIG. 4 consensus cluster 1 can organize its own block chain sub-chain 402, which includes block C1 and block C2 generated in consensus cluster 1; wherein, in the consensus When block C2 is generated in cluster 1, block C2 can anchor the previous block C1 of blockchain sub-chain 401 in consensus cluster 1, that is, block C2 records the previous block of blockchain sub-chain 402 in consensus cluster 1.
- the block C2 can also anchor the previous block in the block chain 401, and block 2 records the block chain
- the hash value (prehash) of block D1 in 401 that is, the hash value of block D1.
- each consensus cluster can organize its own blockchain sub-chain through the subprehash in the block to facilitate the management of business data in the cluster, and the consensus committee can maintain the blockchain of the entire consensus sub-network, which is convenient for Unified management and review of business data for the entire consensus sub-network.
- each consensus cluster in the consensus sub-network can also perform cross-chain interaction (that is, perform cross-chain business). specifically:
- Consensus Cluster 3 and Consensus Cluster 4 is an independent cross-chain business, and the business data of the co-exclusive type associated with this independent cross-chain business can only be placed in a separate co-exclusive type of area In the block, business data of common exclusive type associated with multiple independent cross-chain businesses cannot be mixed and packaged together;
- consensus cluster 3 Since the cross-chain business involves multi-party confirmation, as shown in Figure 4, in consensus cluster 3, A2 is added to the blockchain sub-chain maintained by the consensus cluster, and consensus cluster 4 is added to the consensus cluster to maintain B2 After the sub-chain of the blockchain, consensus cluster 3 and consensus cluster 4 need to wait for the A2+B2 block consensus on the main chain of the blockchain to pass before they can continue to add new blocks to the sub-chain of the blockchain they maintain.
- the consensus algorithm is bound to the blockchain electronic invoice processing logic, and each billing agency (local tax bureaus in different provinces and cities) obtains the opportunity to generate blocks by broadcasting bidding information to the consensus committee.
- each billing agency local tax bureaus in different provinces and cities
- the consensus committee In the process of consensus on the Nth block of the blockchain, it will be decided who will bid for the N+1 block.
- the representative nodes of different tax bureaus such as SPV nodes
- they will broadcast bidding information to the consensus committee to bid for an exclusive type of block.
- the representative node that obtains the proposal authority for the next block will pay a certain amount of bidding resources according to the waiting time after bidding for an exclusive type of block (waiting time).
- the weight and bidding resource scheme can be designed according to actual needs), the exclusive type of block will all pack the exclusive type of business data (billing data) and common type of business data (billing data) associated with the representative node .
- the business data of a single consensus cluster (corresponding organization) can be uploaded to the chain in batches, and exclusive blocks can allow a single representative node to store the associated business data in the In a single block, it is convenient for subsequent verification and auditing.
- Exclusive blocks can better isolate the business data of different representative nodes and better protect privacy.
- irrelevant blocks can be quickly skipped through the blockchain sub-chains maintained by each consensus cluster to improve efficiency and query efficiency.
- the bidding method can effectively meet the needs of representative nodes that need to upload a large amount of business data to the chain as soon as possible.
- the required bidding resources can be calculated as a whole through the waiting time to ensure the overall efficiency and fairness of the blockchain network.
- this application not only provides a feasible multi-business interaction scheme, but also guarantees the independence of each cross-chain business data through a common exclusive type of block.
- the blockchain sub-chain maintained by a consensus cluster can effectively synchronize cross-chain data related to itself.
- Practice has proved that the solution has good scalability and is suitable for scenarios where there are multiple consensus clusters in the blockchain network and different cross-chain services are continuously added.
- FIG. 5 shows a schematic structural diagram of a blockchain-based data processing device provided by an exemplary embodiment of the present application.
- the device can be mounted on the representative node shown in FIG. 1 e .
- the block chain-based data processing device shown in FIG. 5 can be used to perform some or all of the functions in the method embodiments described above in FIG. 2 and FIG. 3 .
- the blockchain contains at least one block; the blockchain is located in the blockchain network, and the blockchain network includes a witness sub-network and a consensus sub-network.
- the witness sub-network includes at least one business node; the consensus sub-network includes at least two Consensus clusters; each consensus cluster includes multiple bookkeeping nodes, and each consensus cluster recommends a bookkeeping node as a representative node in its own consensus cluster; representative nodes of each consensus cluster form the consensus committee of the blockchain; data processing
- the device can be mounted on the first representative node in the consensus committee, and the first representative node is any representative node in the consensus committee; please refer to Figure 5, and the detailed description of each unit is as follows:
- the obtaining unit 501 is used to obtain the on-chain instruction information of the blockchain, and the on-chain instruction information is used to indicate the type of the next blockchain block to be on-chain; and is used to obtain the target area waiting for consensus in the blockchain network block; the target block is generated based on cross-chain business data; and
- the processing unit 502 is configured to add the target block to the blockchain as the next block to be linked in the blockchain if the linking instruction information indicates that the type of the next block to be linked in the blockchain is a common exclusive type above; among them, the block of common exclusive type is used to store independent cross-chain business.
- the processing unit 502 is further configured to perform consensus on the target block according to the consensus rules of the common exclusive type if the on-chain indication information indicates that the type of the next block to be on-chain in the blockchain is the common exclusive type Verification; if the target block passes the consensus verification, the target block will be added to the blockchain as the next block to be uploaded to the blockchain.
- the target block is associated with the target business, and the target block is used to store the cross-chain business data of the target business; the processing unit 502 is also used to check whether the target business is an independent cross-chain business; if the target If the business is an independent cross-chain business, it is determined that the target block passes the consensus verification.
- the target block is associated with the target business, and the target block stores the identifications of multiple business parties participating in the target business; the on-chain indication information is also used to indicate the next block to be on-chain in the blockchain The identifiers of multiple common exclusive parties; the processing unit 502 is also used to check whether the identifiers of multiple business parties in the target block are consistent with the identifiers of multiple common exclusive parties of the next block to be uploaded in the blockchain; If the identifications of multiple business parties in the target block are consistent with the identifications of multiple co-exclusive parties in the next block to be linked in the blockchain, it is determined that the target block passes the consensus verification.
- the target block also stores the business data to be deposited for each of the multiple business parties; the on-chain indication information is also used to indicate the occupation of each of the multiple joint exclusive parties Quantity; the processing unit 502 is also used to obtain the quantity of business data to be deposited by each business party in the target block; check the quantity of business data to be deposited by each business party and the corresponding occupation quantity of each common exclusive party Whether it matches; if the number of business data to be deposited by each business party matches the corresponding number of occupancy by each co-exclusive party, then continue to execute the step of determining that the target block passes the consensus verification.
- the target block is associated with the target business, and the target business is participated by multiple business parties.
- a business party refers to a consensus cluster in the consensus sub-network; the target block also stores the The business data to be deposited of each business party; each business party maintains a block chain sub-chain; the processing unit 502 is also used to check whether the business data to be deposited of each business party in the target block has been stored in each in the respective blockchain sub-chains of each business party; if the business data to be deposited by each business party in the target block has been stored in each business party’s respective blockchain sub-chain, then it is determined that the target block is verified by consensus test.
- the acquiring unit 501 is also used to acquire the bidding result information of the next block to be linked in the blockchain, and the bidding result information is used to indicate the right to obtain the proposal authority of the next block to be linked in the blockchain.
- the acquiring unit 501 is also configured to receive the next block to be uploaded in the blockchain submitted by the second representative node during the process of consensus on the block at the end of the blockchain.
- Auction information the auction information is used to request the proposal permission of the next blockchain block to be uploaded; to perform consensus verification on the auction information; and to receive the auction result information broadcast by the consensus committee.
- the acquisition unit 501 is also used to submit For the bidding information of the next block to be chained in the blockchain, the bidding information is used to request the proposal authority for the next block to be chained in the blockchain; to perform consensus verification on the bidding information; and to receive the Auction result information.
- the obtaining unit 501 is further configured to extract the bidding information from the bidding result information; according to the extracted bidding information, generate uplink indication information of the next block to be uplinked in the blockchain.
- the bidding information includes at least one of the quantity of business data to be packaged in the next block to be uploaded on the blockchain, the business party ID associated with the business data, or the type of business data.
- the bidding information includes the waiting time and the amount of bidding resources; the bidding result information is that the consensus committee performs consensus verification on the bidding information based on the waiting time and the amount of bidding resources in the bidding information, and when the consensus of the bidding information Generated after the verification is successful.
- the bidding resource corresponding to the bidding resource amount includes at least one of physical resources, virtual items, or the quantity of business data to be deposited.
- the target block is associated with the target business, and the target business is participated by multiple business parties; if the first representative node and the second representative node are the same node, the processing unit 502 is also used to: The cross-chain business data of each business party of the target business is obtained from the resource pool in the chain network, and the target block is generated according to the cross-chain business data of each business party.
- step S201 and step S202 shown in FIG. 2 may be executed by the acquiring unit 501 shown in FIG. 5
- step S203 may be executed by the processing unit 502 shown in FIG. 5
- step S301 and step S303 shown in FIG. 3 may be executed by the acquisition unit 501 shown in FIG. 5
- step S302 , step S304 and step S305 may be executed by the processing unit 502 shown in FIG. 5 .
- Each unit in the block chain-based data processing device shown in Figure 5 can be separately or all combined into one or several other units to form, or one (some) units can be further divided into functional units Multiple smaller units can realize the same operation without affecting the realization of the technical effects of the embodiments of the present application.
- the above-mentioned units are divided based on logical functions.
- the functions of one unit may also be realized by multiple units, or the functions of multiple units may be realized by one unit.
- the blockchain-based data processing device may also include other units.
- these functions may also be implemented with the assistance of other units, and may be implemented cooperatively by multiple units.
- a general-purpose computing device such as a computer including processing elements such as a central processing unit (CPU), a random access storage medium (RAM), and a read-only storage medium (ROM) and storage elements.
- CPU central processing unit
- RAM random access storage medium
- ROM read-only storage medium
- Run computer programs capable of performing the steps involved in the corresponding methods as shown in Figure 2 and Figure 3, to construct a block chain-based data processing device as shown in Figure 5, and to realize The blockchain-based data processing method of the embodiment of this application.
- the computer program can be recorded on, for example, a computer-readable recording medium, loaded into the above-mentioned computing device via the computer-readable recording medium, and executed therein.
- the business data of a single consensus cluster (corresponding organization) can be uploaded to the chain in batches, and exclusive blocks can allow a single representative node to store the associated business data in the In a single block, it is convenient for subsequent verification and auditing.
- Exclusive blocks can better isolate the business data of different representative nodes and better protect privacy.
- irrelevant blocks can be quickly skipped through the blockchain sub-chains maintained by each consensus cluster to improve efficiency and query efficiency.
- the bidding method can effectively meet the needs of representative nodes that need to upload a large amount of business data to the chain as soon as possible.
- the required bidding resources can be calculated as a whole through the waiting time to ensure the overall efficiency and fairness of the blockchain network.
- this application not only provides a feasible multi-business interaction scheme, but also guarantees the independence of each cross-chain business data through a common exclusive type of block.
- the blockchain sub-chain maintained by a consensus cluster can effectively synchronize cross-chain data related to itself.
- Practice has proved that the solution has good scalability and is suitable for scenarios where there are multiple consensus clusters in the blockchain network and different cross-chain services are continuously added.
- FIG. 6 shows a schematic structural diagram of a blockchain-based data processing device provided by an exemplary embodiment of the present application.
- the blockchain-based data processing device includes at least processing device 601, communication interface 602 and memory 603.
- the processor 601, the communication interface 602 and the memory 603 may be connected through a bus or in other ways.
- the processor 601 or central processing unit (Central Processing Unit, CPU)) is the calculation core and control core of the terminal, which can analyze various instructions in the terminal and process various data of the terminal.
- CPU Central Processing Unit
- the CPU can use It is used to analyze the power-on/off instructions sent by the user to the terminal, and control the terminal to perform power-on/off operations; another example: the CPU can transmit various interactive data between the internal structures of the terminal, and so on.
- the communication interface 602 can optionally include standard wired interfaces and wireless interfaces (such as WI-FI, mobile communication interfaces, etc.), which can be used to send and receive data under the control of the processor 601; the communication interface 602 can also be used for internal data transfer of the terminal transmission and interaction.
- the memory 603 (Memory) is a storage device in the terminal, and is used to store programs and data.
- the memory 603 here may include not only a built-in memory of the terminal, but also an extended memory supported by the terminal.
- the memory 603 provides a storage space, which stores the operating system of the terminal, which may include but not limited to: Android system, iOS system, Windows Phone system, etc., which is not limited in this application.
- the embodiment of the present application also provides a computer-readable storage medium (Memory).
- the computer-readable storage medium is a memory device in a terminal, and is used to store computer-readable instructions and data. It can be understood that the computer-readable storage medium here may not only include a built-in storage medium in the terminal, but also include an extended storage medium supported by the terminal.
- the computer-readable storage medium provides storage space, and the storage space stores the processing system of the terminal.
- one or more computer-readable instructions adapted to be loaded and executed by the processor 601 are also stored in the storage space, and these computer-readable instructions may be one or more computer programs (including program codes).
- the computer-readable storage medium here can be a high-speed RAM memory, or a non-volatile memory (non-volatile memory), such as at least one disk memory; A computer-readable storage medium for the aforementioned processor.
- the computer-readable storage medium stores one or more computer-readable instructions; the processor 601 loads and executes the one or more computer-readable instructions stored in the computer-readable storage medium to implement Corresponding steps in the above embodiments of the blockchain-based data processing method.
- the embodiment of the present application also provides a non-volatile computer-readable storage medium storing computer-readable instructions, one or more computer-readable instructions are stored in the computer-readable storage medium, one or more computer-readable instructions
- the block chain-based data processing method suitable for being loaded by a processor and executing the above method embodiment.
- the embodiment of the present application also provides a computer program product containing instructions, which, when run on a computer, causes the computer to execute the blockchain-based data processing method of the above method embodiment.
- the embodiment of the present application also provides a computer program product or computer program, where the computer program product or computer program includes computer-readable instructions, and the computer-readable instructions are stored in a computer-readable storage medium.
- the processor of the computer device reads the computer-readable instructions from the computer-readable storage medium, and the processor executes the computer-readable instructions, so that the computer device executes the above-mentioned blockchain-based data processing method.
- the steps in the methods of the embodiments of the present application can be adjusted, combined and deleted according to actual needs.
- the modules in the device of the embodiment of the present application can be combined, divided and deleted according to actual needs.
- Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above-mentioned embodiments can be completed by instructing related hardware through a program, and the program can be stored in a computer-readable storage medium, and the readable storage medium can be Including: flash disk, read-only memory (Read-Only Memory, ROM), random access device (Random Access Memory, RAM), magnetic disk or optical disk, etc.
Landscapes
- Engineering & Computer Science (AREA)
- Business, Economics & Management (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer Security & Cryptography (AREA)
- Accounting & Taxation (AREA)
- Finance (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Marketing (AREA)
- Strategic Management (AREA)
- Computing Systems (AREA)
- General Business, Economics & Management (AREA)
- General Physics & Mathematics (AREA)
- Economics (AREA)
- Development Economics (AREA)
- Technology Law (AREA)
- Mathematical Physics (AREA)
- Entrepreneurship & Innovation (AREA)
- Computer Hardware Design (AREA)
- General Engineering & Computer Science (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)
Abstract
Description
节点名称 | 节点标识 |
节点1 | 117.114.151.174 |
节点2 | 117.116.189.145 |
… | … |
节点X(X为正整数) | xx.xxx.xxx.xxx |
Claims (20)
- 一种基于区块链的数据处理方法,其特征在于,所述区块链上包含至少一个区块;所述区块链位于区块链网络中,所述区块链网络包括见证子网络和共识子网络,所述见证子网络包含至少一个业务节点;所述共识子网络包含至少两个共识集群,每个所述共识集群包括多个记账节点,每个所述共识集群在各自的共识集群内推举一个记账节点作为代表节点;各个所述共识集群的代表节点组成所述区块链的共识委员会;所述方法由所述共识委员会中的第一代表节点执行,所述第一代表节点是所述共识委员会中的任一个代表节点;所述方法包括:获取所述区块链的上链指示信息,所述上链指示信息用于指示所述区块链下一个待上链区块的类型;获取所述区块链网络中等待共识的目标区块;所述目标区块是根据跨链业务数据生成的;及若所述上链指示信息指示所述区块链下一个待上链区块的类型为共同独占类型,则将所述目标区块作为所述区块链下一个待上链区块添加至所述区块链上;其中,共同独占类型的区块用于存储独立跨链业务。
- 如权利要求1所述的方法,其特征在于,所述若所述上链指示信息指示所述区块链下一个待上链区块的类型为共同独占类型,则将所述目标区块作为所述区块链下一个待上链区块添加至所述区块链上,包括:若所述上链指示信息指示所述区块链下一个待上链区块的类型为共同独占类型,则按照共同独占类型的共识规则对所述目标区块进行共识校验;及若所述目标区块通过所述共识校验,则将所述目标区块作为所述区块链下一个待上链区块添加至所述区块链上。
- 如权利要求2所述的方法,其特征在于,所述目标区块与目标业务相关联,所述目标区块用于存储所述目标业务的跨链业务数据;所述按照共同独占类型的共识规则对所述目标区块进行共识校验,包括:校验所述目标业务是否为独立跨链业务;及若所述目标业务是独立跨链业务,则确定所述目标区块通过所述共识校验。
- 如权利要求2所述的方法,其特征在于,所述目标区块与目标业务相关联,所述目标区块存储有参与所述目标业务的多个业务方的标识;所述上链指示信息还用于指示所述区块链下一个待上链区块的多个共同独占方的标识;所述按照共同独占类型的共识规则对所述目标区块进行共识校验,包括:检验所述目标区块中的多个业务方的标识与所述区块链下一个待上链区块的多个共同独占方的标识是否一致;及若所述目标区块中的多个业务方的标识与所述区块链下一个待上链区块的多个共同独占方的标识一致,则确定所述目标区块通过所述共识校验。
- 如权利要求4所述的方法,其特征在于,所述目标区块还存储有所述多个业务方中每个业务方的待存证业务数据;所述上链指示信息还用于指示所述多个共同独占方中每个共同 独占方的占用数量;在所述目标区块中的多个业务方的标识与所述区块链下一个待上链区块的多个共同独占方的标识一致之后,所述方法还包括:获取所述目标区块中每个业务方的待存证业务数据的数量;检验所述每个业务方的待存证业务数据的数量与相应的每个共同独占方的占用数量是否匹配;及若所述每个业务方的待存证业务数据的数量与相应的每个共同独占方的占用数量匹配,则继续执行判定确定所述目标区块通过所述共识校验的步骤。
- 如权利要求2所述的方法,其特征在于,所述目标区块与目标业务相关联,所述目标业务由多个业务方参与,一个所述业务方是指所述共识子网络中的一个共识集群;所述目标区块还存储有所述多个业务方中每个业务方的待存证业务数据;每个业务方维护有一条区块链子链;所述按照共同独占类型的共识规则对所述目标区块进行共识校验,包括:检验所述目标区块中的每个业务方的待存证业务数据是否已存储至所述每个业务方各自的区块链子链中;及若所述目标区块中的每个业务方的待存证业务数据已存储至所述每个业务方各自的区块链子链中,则确定所述目标区块通过所述共识校验。
- 如权利要求1所述的方法,其特征在于,所述获取所述区块链的上链指示信息,包括:获取所述区块链下一个待上链区块的竞拍结果信息,所述竞拍结果信息用于指示获得所述区块链下一个待上链区块的提案权限的第二代表节点,以及由所述第二代表节点提交的针对所述区块链下一个待上链区块的竞拍信息;及根据所述竞拍结果信息生成所述区块链下一个待上链区块的上链指示信息。
- 如权利要求7所述的方法,其特征在于,所述获取所述区块链下一个待上链区块的竞拍结果信息,包括:在对所述区块链上处于末尾位置的区块进行共识的过程中,接收所述第二代表节点提交的针对所述区块链下一个待上链区块的竞拍信息,所述竞拍信息用于请求获得所述区块链下一个待上链区块的提案权限;对所述竞拍信息进行共识校验;以及,接收所述共识委员会广播的所述竞拍结果信息。
- 如权利要求7所述的方法,其特征在于,若所述第一代表节点与所述第二代表节点为同一节点,则所述获取所述区块链下一个待上链区块的竞拍结果信息,包括:在对所述区块链上处于末尾位置的区块进行共识的过程中,向所述共识委员会提交针对所述区块链下一个待上链区块的竞拍信息,所述竞拍信息用于请求获得所述区块链下一个待上链区块的提案权限;对所述竞拍信息进行共识校验;以及,接收所述共识委员会广播的所述竞拍结果信息。
- 如权利要求7所述的方法,其特征在于,所述根据所述竞拍结果信息生成所述区块链下一个待上链区块的上链指示信息,包括:从所述竞拍结果信息中提取所述竞拍信息;及根据提取获得的所述竞拍信息,生成所述区块链下一个待上链区块的上链指示信息。
- 如权利要求7-10任一项所述的方法,其特征在于,所述竞拍信息包括待打包在所述区块链下一个待上链区块中的业务数据的数量、业务数据关联的业务方标识或业务数据的类型中的至少一项。
- 如权利要求7-10任一项所述的方法,其特征在于,所述竞拍信息包括等待时长和竞拍资源量;所述竞拍结果信息,是所述共识委员会基于所述竞拍信息中的所述等待时长和所述竞拍资源量,对所述竞拍信息进行共识校验,且当所述竞拍信息的共识校验成功后生成的。
- 如权利要求12所述的方法,其特征在于,所述等待时长和所述竞拍资源量呈负相关关系;所述竞拍信息至少根据所述等待时长和所述竞拍资源量进行加权运算得到。
- 如权利要求13所述的方法,其特征在于,所述竞拍信息根据所述等待时长、所述竞拍资源量以及业务优先级对应的权值进行加权运算得到。
- 如权利要求12所述的方法,其特征在于,所述竞拍资源量对应的竞拍资源包括实体资源、虚拟物品或待存证业务数据的数量中的至少一种。
- 如权利要求7所述的方法,其特征在于,所述目标区块与目标业务相关联,所述目标业务由多个业务方参与;若所述第一代表节点与所述第二代表节点为同一节点,则所述方法还包括:从所述区块链网络中的资源池中获取所述目标业务的各业务方的跨链业务数据,并根据所述各业务方的跨链业务数据生成所述目标区块。
- 一种基于区块链的数据处理装置,其特征在于,所述区块链上包含至少一个区块;所述区块链位于区块链网络中,所述区块链网络包括见证子网络和共识子网络,所述见证子网络包含至少一个业务节点;所述共识子网络包含至少两个共识集群;每个所述共识集群包括多个记账节点,每个所述共识集群在各自的共识集群内推举一个记账节点作为代表节点;各个所述共识集群的代表节点组成所述区块链的共识委员会;所述数据处理装置可以搭载在所述共识委员会中的第一代表节点中,所述第一代表节点是所述共识委员会中的任一个代表节点;所述数据处理装置,包括:获取单元,用于获取所述区块链的上链指示信息,所述上链指示信息用于指示所述区块链下一个待上链区块的类型;以及用于获取所述区块链网络中等待共识的目标区块;所述目标区块是根据跨链业务数据生成的;及处理单元,用于若所述上链指示信息指示所述区块链下一个待上链区块的类型为共同独占类型,则将所述目标区块作为所述区块链下一个待上链区块添加至所述区块链上;其中,共同独占类型的区块用于存储独立跨链业务。
- 一种基于区块链的数据处理设备,其特征在于,包括:一个或多个处理器,适于执行计算机可读指令;及计算机可读存储介质,所述计算机可读存储介质中存储有计算机可读指令,所述计算机可读指令被所述处理器执行时,实现如权利要求1-16任一项所述的基于区块链的数据处理方 法。
- 一种存储有计算机可读指令的非易失性计算机可读存储介质,其特征在于,所述计算机可读存储介质存储有计算机可读指令,所述计算机可读指令适于被处理器加载并执行如权利要求1-16任一项所述的基于区块链的数据处理方法。
- 一种计算机程序产品,所述计算机程序产品包括计算机可读指令,所述计算机可读指令存储在计算机可读存储介质中;计算机设备的处理器从所述计算机可读存储介质读取所述计算机指令,所述处理器执行所述计算机可读指令,使得所述计算机设备执行权利要求1-16任一项所述的方法。
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
EP22857546.0A EP4318362A1 (en) | 2021-08-18 | 2022-07-28 | Blockchain-based data processing method, apparatus and device, and storage medium |
US18/323,120 US20230299984A1 (en) | 2021-08-18 | 2023-05-24 | Blockchain-based data processing method, apparatus and device, and storage medium |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110948504.6 | 2021-08-18 | ||
CN202110948504.6A CN113395363B (zh) | 2021-08-18 | 2021-08-18 | 基于区块链的数据处理方法、装置、设备及存储介质 |
Related Child Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US18/323,120 Continuation US20230299984A1 (en) | 2021-08-18 | 2023-05-24 | Blockchain-based data processing method, apparatus and device, and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2023020233A1 true WO2023020233A1 (zh) | 2023-02-23 |
Family
ID=77622919
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2022/108482 WO2023020233A1 (zh) | 2021-08-18 | 2022-07-28 | 基于区块链的数据处理方法、装置、设备及存储介质 |
Country Status (4)
Country | Link |
---|---|
US (1) | US20230299984A1 (zh) |
EP (1) | EP4318362A1 (zh) |
CN (1) | CN113395363B (zh) |
WO (1) | WO2023020233A1 (zh) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116684425A (zh) * | 2023-07-28 | 2023-09-01 | 腾讯科技(深圳)有限公司 | 区块链的数据处理方法、系统、装置和计算机设备 |
CN117395305A (zh) * | 2023-12-11 | 2024-01-12 | 广东电网有限责任公司东莞供电局 | 基于区块链的安全计算方法、装置、设备及存储介质 |
Families Citing this family (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113395363B (zh) * | 2021-08-18 | 2021-10-29 | 腾讯科技(深圳)有限公司 | 基于区块链的数据处理方法、装置、设备及存储介质 |
CN113987566B (zh) * | 2021-10-13 | 2024-04-23 | 普洛斯科技(重庆)有限公司 | 基于Hyperledger Fabric的内部桥接跨链方法、装置、设备和介质 |
US20230409602A1 (en) * | 2022-06-21 | 2023-12-21 | International Business Machines Corporation | Data management |
CN115174685B (zh) * | 2022-07-05 | 2023-08-11 | 上海交通大学 | 基于流水线机制的区块链中的非中断式跨链委员会换届方法 |
CN115174598B (zh) * | 2022-09-01 | 2022-12-27 | 杭州趣链科技有限公司 | 区块同步方法、区块链系统、设备和存储介质 |
CN116562884B (zh) * | 2023-06-30 | 2023-09-26 | 睿格钛氪(北京)技术有限公司 | 数据要素流通方法、装置、电子设备及存储介质 |
CN116527684B (zh) * | 2023-07-03 | 2023-09-05 | 江西农业大学 | 基于1+1+n中继共识委员会的多链信息交互方法 |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20190340266A1 (en) * | 2018-05-01 | 2019-11-07 | International Business Machines Corporation | Blockchain implementing cross-chain transactions |
CN112948153A (zh) * | 2021-05-14 | 2021-06-11 | 支付宝(杭州)信息技术有限公司 | 一种消息跨链传输的方法和装置 |
CN113098694A (zh) * | 2021-04-09 | 2021-07-09 | 杭州链网科技有限公司 | 一种混合跨链共识方法 |
CN113256424A (zh) * | 2021-06-15 | 2021-08-13 | 腾讯科技(深圳)有限公司 | 一种交易数据处理方法、装置、设备及存储介质 |
CN113395363A (zh) * | 2021-08-18 | 2021-09-14 | 腾讯科技(深圳)有限公司 | 基于区块链的数据处理方法、装置、设备及存储介质 |
Family Cites Families (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107766540A (zh) * | 2017-10-31 | 2018-03-06 | 上海分布信息科技有限公司 | 一种分区的区块链网络及其实现分区存储的方法 |
GB201810707D0 (en) * | 2018-06-29 | 2018-08-15 | Bedrock Capital Ltd | Gospel L |
CN109905368B (zh) * | 2019-01-24 | 2021-12-10 | 真相网络科技(北京)有限公司 | 区块链跨链数据交互和验证方法、区块链系统及存储介质 |
CN110417883B (zh) * | 2019-07-23 | 2021-09-24 | 杭州云象网络技术有限公司 | 一种应用于区块链的点对点网络结构的设计方法 |
CN110598446B (zh) * | 2019-09-16 | 2024-06-28 | 腾讯科技(深圳)有限公司 | 基于区块链的测试方法、装置、存储介质和计算机设备 |
CN112804354B (zh) * | 2021-03-19 | 2021-07-06 | 腾讯科技(深圳)有限公司 | 跨链进行数据传输的方法、装置、计算机设备和存储介质 |
CN112861190B (zh) * | 2021-04-23 | 2021-07-16 | 腾讯科技(深圳)有限公司 | 数据跨链协同方法、系统及装置 |
-
2021
- 2021-08-18 CN CN202110948504.6A patent/CN113395363B/zh active Active
-
2022
- 2022-07-28 EP EP22857546.0A patent/EP4318362A1/en active Pending
- 2022-07-28 WO PCT/CN2022/108482 patent/WO2023020233A1/zh active Application Filing
-
2023
- 2023-05-24 US US18/323,120 patent/US20230299984A1/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20190340266A1 (en) * | 2018-05-01 | 2019-11-07 | International Business Machines Corporation | Blockchain implementing cross-chain transactions |
CN113098694A (zh) * | 2021-04-09 | 2021-07-09 | 杭州链网科技有限公司 | 一种混合跨链共识方法 |
CN112948153A (zh) * | 2021-05-14 | 2021-06-11 | 支付宝(杭州)信息技术有限公司 | 一种消息跨链传输的方法和装置 |
CN113256424A (zh) * | 2021-06-15 | 2021-08-13 | 腾讯科技(深圳)有限公司 | 一种交易数据处理方法、装置、设备及存储介质 |
CN113395363A (zh) * | 2021-08-18 | 2021-09-14 | 腾讯科技(深圳)有限公司 | 基于区块链的数据处理方法、装置、设备及存储介质 |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116684425A (zh) * | 2023-07-28 | 2023-09-01 | 腾讯科技(深圳)有限公司 | 区块链的数据处理方法、系统、装置和计算机设备 |
CN116684425B (zh) * | 2023-07-28 | 2023-10-27 | 腾讯科技(深圳)有限公司 | 区块链的数据处理方法、系统、装置和计算机设备 |
CN117395305A (zh) * | 2023-12-11 | 2024-01-12 | 广东电网有限责任公司东莞供电局 | 基于区块链的安全计算方法、装置、设备及存储介质 |
CN117395305B (zh) * | 2023-12-11 | 2024-03-19 | 广东电网有限责任公司东莞供电局 | 基于区块链的安全计算方法、装置、设备及存储介质 |
Also Published As
Publication number | Publication date |
---|---|
EP4318362A1 (en) | 2024-02-07 |
CN113395363A (zh) | 2021-09-14 |
US20230299984A1 (en) | 2023-09-21 |
CN113395363B (zh) | 2021-10-29 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
WO2023020233A1 (zh) | 基于区块链的数据处理方法、装置、设备及存储介质 | |
JP7278453B2 (ja) | ブロックチェーン・ネットワークにおいてトランザクションを管理するための方法、記憶媒体、電子デバイス、トランザクション検証ノード、スーパー・ノード及びブロックチェーン・ネットワーク | |
Yuan et al. | CSEdge: Enabling collaborative edge storage for multi-access edge computing based on blockchain | |
US20190354518A1 (en) | Chain mesh network for decentralized transaction systems | |
Kaur et al. | Scalability in blockchain: Challenges and solutions | |
CN112541758A (zh) | 基于区块链的多轮投票式容错排序共识机制与方法 | |
CN112163856A (zh) | 用于区块链与物联网融合场景的共识方法及系统 | |
CN113256297B (zh) | 基于区块链的数据处理方法、装置、设备及可读存储介质 | |
CN112822267B (zh) | 基于区块链的数据处理方法和装置 | |
WO2023116790A1 (zh) | 计算任务的执行方法、装置、存储介质及电子装置 | |
Lin et al. | A Blockchain-enabled decentralized settlement model for IoT data exchange services | |
Batool et al. | Fl-mab: client selection and monetization for blockchain-based federated learning | |
Wang et al. | An efficient, secured, and infinitely scalable consensus mechanism for peer-to-peer energy trading blockchain | |
CN116055052A (zh) | 基于区块链的数据处理方法、装置、设备及可读存储介质 | |
CN111222885B (zh) | 数据处理请求背书方法、装置、计算机设备及存储介质 | |
WO2023082883A1 (zh) | 跨区块链处理事务的方法、装置、计算机设备、计算机存储介质及计算机程序产品 | |
CN115455460A (zh) | 一种基于区块链的数据存储方法、装置、设备及介质 | |
CN116233139A (zh) | 区块链系统的数据处理方法、装置、介质及电子设备 | |
Bandara et al. | Lightweight, geo-scalable deterministic blockchain design for 5G networks sliced applications with hierarchical CFT/BFT consensus groups, IPFS and novel hardware design | |
Guo | Cypherium: a scalable and permissionless smart contract platform | |
CN113300853B (zh) | 金融征信信息管理方法、装置、电子设备及存储介质 | |
Putra et al. | Privacy-preserving Trust Management for Blockchain-based Resource Sharing in 6G-IoT | |
CN116112496A (zh) | 一种基于区块链网络的跨链交互方法及相关设备 | |
KR102494215B1 (ko) | 뉴럴 블록 신속 전파 프로토콜 기반의 블록체인을 구축하는 장치 및 그 동작 방법 | |
Lin et al. | Scalable Blockchain Oracle for AIGC Services |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 22857546 Country of ref document: EP Kind code of ref document: A1 |
|
WWE | Wipo information: entry into national phase |
Ref document number: 22857546.0 Country of ref document: EP Ref document number: 2022857546 Country of ref document: EP |
|
ENP | Entry into the national phase |
Ref document number: 2022857546 Country of ref document: EP Effective date: 20231026 |
|
WWE | Wipo information: entry into national phase |
Ref document number: 11202307921X Country of ref document: SG |
|
NENP | Non-entry into the national phase |
Ref country code: DE |