CN112287031B - Data synchronization method and device of block chain system, readable medium and electronic equipment - Google Patents

Data synchronization method and device of block chain system, readable medium and electronic equipment Download PDF

Info

Publication number
CN112287031B
CN112287031B CN202011473334.2A CN202011473334A CN112287031B CN 112287031 B CN112287031 B CN 112287031B CN 202011473334 A CN202011473334 A CN 202011473334A CN 112287031 B CN112287031 B CN 112287031B
Authority
CN
China
Prior art keywords
nodes
block
synchronized
node
height
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011473334.2A
Other languages
Chinese (zh)
Other versions
CN112287031A (en
Inventor
朱耿良
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN202011473334.2A priority Critical patent/CN112287031B/en
Publication of CN112287031A publication Critical patent/CN112287031A/en
Application granted granted Critical
Publication of CN112287031B publication Critical patent/CN112287031B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/23Updating
    • G06F16/2308Concurrency control
    • G06F16/2315Optimistic concurrency control
    • G06F16/2322Optimistic concurrency control using timestamps
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/23Updating
    • G06F16/2365Ensuring data consistency and integrity
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/602Providing cryptographic facilities or services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange

Abstract

The embodiment of the application provides a data synchronization method, a data synchronization device, a readable medium and electronic equipment of a block chain system, wherein the method comprises the following steps: obtaining buffer mapping tables corresponding to a plurality of associated nodes respectively, wherein the buffer mapping tables corresponding to the nodes are used for recording whether block body data of each block height is stored or not; counting the number of nodes storing the block body data of each height of the block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively to obtain the number of nodes corresponding to the height of each block to be synchronized; determining the synchronization sequence of the heights of the blocks to be synchronized according to the number of nodes corresponding to the heights of the blocks to be synchronized; and synchronizing the block volume data corresponding to the heights of the blocks to be synchronized respectively according to the synchronization sequence of the heights of the blocks to be synchronized. The technical scheme of the embodiment of the application effectively solves the cold start problem of data synchronization, so that the data synchronization process of the block chain system is more flexible and stable.

Description

Data synchronization method and device of block chain system, readable medium and electronic equipment
Technical Field
The present application relates to the field of blockchain technologies, and in particular, to a data synchronization method and apparatus for a blockchain system, a readable medium, and an electronic device.
Background
With the continuous development of the block chain technology, on a block chain platform, nodes are connected with each other, and block data can be pulled from each node to each other, however, the block data pulled from each node is pulled from each node in sequence according to the block height, and such a method has certain defects.
Disclosure of Invention
Embodiments of the present application provide a data synchronization method and apparatus for a blockchain system, a readable medium, and an electronic device, so as to effectively solve a cold start problem of data synchronization to a certain extent, and make a data synchronization process of the blockchain system more flexible and stable.
Other features and advantages of the present application will be apparent from the following detailed description, or may be learned by practice of the application.
According to an aspect of the embodiments of the present application, there is provided a data synchronization method for a blockchain system, including: obtaining buffer mapping tables corresponding to a plurality of associated nodes respectively, wherein the buffer mapping tables corresponding to the nodes are used for recording whether block body data of each block height is stored or not; counting the number of nodes storing the block body data of each height of the block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively to obtain the number of nodes corresponding to the height of each block to be synchronized; determining the synchronization sequence of the heights of the blocks to be synchronized according to the number of nodes corresponding to the heights of the blocks to be synchronized; and synchronizing the block volume data corresponding to the heights of the blocks to be synchronized respectively according to the synchronization sequence of the heights of the blocks to be synchronized.
According to an aspect of the embodiments of the present application, there is provided a data synchronization apparatus for a blockchain system, including: the first obtaining unit is configured to obtain buffer mapping tables corresponding to a plurality of associated nodes respectively, and the buffer mapping tables corresponding to the nodes are used for recording whether block body data of each block height is stored or not; the counting unit is configured to count the number of nodes storing the block body data of each height of the block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively, so as to obtain the number of nodes corresponding to each height of the block to be synchronized; the first determining unit is configured to determine a synchronization sequence of the heights of the multiple blocks to be synchronized according to the number of nodes corresponding to the heights of the blocks to be synchronized; and the first synchronization unit is configured to synchronize the block volume data corresponding to the heights of the multiple blocks to be synchronized according to the synchronization sequence of the heights of the multiple blocks to be synchronized.
In some embodiments of the present application, based on the foregoing scheme, the first determining unit is configured to: and determining the synchronization sequence of the heights of the blocks to be synchronized based on the inverse correlation relationship between the synchronization priority of the blocks to be synchronized and the number of nodes corresponding to the blocks to be synchronized.
In some embodiments of the present application, based on the foregoing solution, the apparatus further includes: a second obtaining unit, configured to obtain a buffer mapping table corresponding to a target node other than the plurality of nodes if the number of nodes corresponding to the determined height of the target block to be synchronized is zero; and the first re-determining unit is configured to re-determine the number of nodes corresponding to the height of each block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the target node.
In some embodiments of the present application, based on the foregoing solution, the second obtaining unit is further configured to: obtaining a buffer mapping table corresponding to a first node except the plurality of nodes; determining whether the first node stores block volume data of the target block height to be synchronized according to a buffer mapping table corresponding to the first node; if the first node is determined not to store the block data of the target block height to be synchronized, the buffer mapping tables corresponding to other nodes are obtained again until the target node is determined, wherein the block data of the target block height to be synchronized is stored in the target node.
In some embodiments of the present application, based on the foregoing scheme, the first re-determining unit is further configured to: after the number of nodes corresponding to the height of each block to be synchronized is re-determined, if the number of nodes corresponding to the height of the target block to be synchronized is still zero, re-obtaining a buffer mapping table corresponding to a second node except the plurality of nodes and the target node; and re-determining the number of nodes corresponding to the height of each block to be synchronized again according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the second node.
In some embodiments of the present application, based on the foregoing solution, the apparatus further includes: a third obtaining unit, configured to obtain, if the number of nodes corresponding to the determined height of the target block to be synchronized is zero, a buffer mapping table corresponding to a designated node other than the plurality of nodes, where the buffer mapping table corresponding to the designated node records and stores block volume data of the height of the target block to be synchronized; and the second re-determining unit is configured to re-determine the number of nodes corresponding to the height of each block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the designated node.
In some embodiments of the present application, based on the foregoing solution, the apparatus further includes: a second determining unit, configured to determine, if the number of nodes corresponding to the determined height of the target block to be synchronized is zero, a synchronization sequence of the heights of the other blocks to be synchronized according to the number of nodes corresponding to the heights of the other blocks to be synchronized except the height of the target block to be synchronized; and the second synchronization unit is configured to synchronize the block volume data corresponding to the heights of the other blocks to be synchronized according to the synchronization sequence of the heights of the other blocks to be synchronized.
In some embodiments of the present application, based on the foregoing solution, the blockchain system includes a service node sub-network and a billing node sub-network, the apparatus is disposed in a target service node in the service node sub-network, and the associated nodes are a plurality of service nodes associated with the target service node in the service node sub-network, the apparatus further includes: and the fourth acquisition unit is configured to acquire the block volume data corresponding to the height of the target block to be synchronized from the accounting node sub-network.
In some embodiments of the present application, based on the foregoing solution, the apparatus further includes: a fifth obtaining unit, configured to obtain a buffer mapping table corresponding to a specified node except the plurality of nodes, where the buffer mapping table corresponding to the specified node records and stores block volume data of the target block height to be synchronized; a sixth obtaining unit, configured to obtain, from the designated node, block volume data corresponding to the height of the target block to be synchronized.
In some embodiments of the present application, based on the foregoing solution, the apparatus further includes: a seventh obtaining unit configured to obtain sizes of buffer mapping tables respectively corresponding to the nodes that can be connected to; and a selecting unit configured to select the associated plurality of nodes from the connectable nodes according to sizes of buffer mapping tables respectively corresponding to the connectable nodes.
In some embodiments of the present application, based on the foregoing solution, the selecting unit is configured to: and selecting the nodes with the size of the buffer mapping table exceeding a first preset threshold from the connectable nodes as the associated nodes according to the sizes of the buffer mapping tables respectively corresponding to the connectable nodes.
In some embodiments of the present application, based on the foregoing solution, the blockchain system includes a service node sub-network and a billing node sub-network, and the apparatus is disposed in a target service node in the service node sub-network, and the apparatus further includes: an eighth obtaining unit, configured to obtain, from the sub-network of accounting nodes, routing information of a service node whose size of the buffer mapping table exceeds a second preset threshold; and the establishing unit is configured to establish connection with the service node according to the routing information of the service node.
According to an aspect of the embodiments of the present application, there is provided a computer readable medium, on which a computer program is stored, which when executed by a processor, implements the data synchronization method of the blockchain system as described in the above embodiments.
According to an aspect of an embodiment of the present application, there is provided an electronic device including: one or more processors; a storage device for storing one or more programs which, when executed by the one or more processors, cause the one or more processors to implement the data synchronization method of the blockchain system as described in the above embodiments.
According to an aspect of embodiments herein, there is provided a computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the data synchronization method of the blockchain system provided in the above-mentioned various optional embodiments.
In the technical solutions provided in some embodiments of the present application, the number of nodes corresponding to each height of the block to be synchronized is obtained by counting the number of nodes storing the block volume data of each height of the block to be synchronized, then the synchronization sequence of the heights of the blocks to be synchronized is determined according to the number of nodes corresponding to each height of the block to be synchronized, and then the block volume data corresponding to the heights of the blocks to be synchronized are synchronized according to the synchronization sequence of the heights of the blocks to be synchronized. According to the technical scheme, the node number of the block body data with the height of each block to be synchronized is stored in the statistical mode, the synchronization sequence is determined according to the node number, and compared with a mode of directly pulling in sequence according to the sequence of the block height, the cold start problem of data synchronization is effectively solved, and the data synchronization process of a block chain system is more flexible and stable.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the application.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and together with the description, serve to explain the principles of the application. It is obvious that the drawings in the following description are only some embodiments of the application, and that for a person skilled in the art, other drawings can be derived from them without inventive effort. In the drawings:
fig. 1 shows a schematic structural diagram of a blockchain network.
Fig. 2 is a schematic diagram illustrating a connection relationship between blocks in a block chain.
Fig. 3 shows a schematic diagram of a process of generating a tile.
Fig. 4A to 4C are architecture diagrams of a blockchain system applied in the embodiment of the present application.
FIG. 5 shows a schematic diagram of an electronic invoice system, according to one embodiment of the present application.
Fig. 6 shows a flow chart of a data synchronization method of a blockchain system according to an embodiment of the present application.
Fig. 7 illustrates a schematic diagram of buffer mapping tables respectively corresponding to a plurality of associated nodes according to an embodiment of the present application.
Fig. 8 shows a flow chart of a data synchronization method of a blockchain system according to an embodiment of the present application.
Fig. 9 shows a flow chart of a data synchronization method of a blockchain system according to an embodiment of the present application.
Fig. 10 shows a flow chart of a data synchronization method of a blockchain system according to an embodiment of the present application.
Fig. 11 shows a flow diagram of a data synchronization method of a blockchain system according to an embodiment of the present application.
Fig. 12 shows a flow chart of a data synchronization method of a blockchain system according to an embodiment of the present application.
Fig. 13 shows a flow chart of a data synchronization method of a blockchain system according to an embodiment of the present application.
Fig. 14 shows a block diagram of a data synchronization apparatus of a blockchain system according to an embodiment of the present application.
FIG. 15 illustrates a schematic structural diagram of a computer system suitable for use in implementing the electronic device of an embodiment of the present application.
Detailed Description
Example embodiments will now be described more fully with reference to the accompanying drawings. Example embodiments may, however, be embodied in many different forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the concept of example embodiments to those skilled in the art.
Furthermore, the described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to give a thorough understanding of embodiments of the application. One skilled in the relevant art will recognize, however, that the subject matter of the present application can be practiced without one or more of the specific details, or with other methods, components, devices, steps, and so forth. In other instances, well-known methods, devices, implementations, or operations have not been shown or described in detail to avoid obscuring aspects of the application.
It is to be noted that the terms used in the specification and claims of the present application and the above-described drawings are only for describing the embodiments and are not intended to limit the scope of the present application. It will be understood that the terms "comprises," "comprising," "includes," "including," "has," "having," and the like, when used herein, specify the presence of stated features, integers, steps, operations, elements, components, and/or groups thereof, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It will be further understood that, although the terms first, second, third, etc. may be used herein to describe various elements, these elements should not be limited by these terms. These terms are only used to distinguish one element from another. For example, a first element could be termed a second element without departing from the scope of the present invention. Similarly, a second element may be termed a first element. As used herein, the term "and/or" includes any and all combinations of one or more of the associated listed items.
The block diagrams shown in the figures are functional entities only and do not necessarily correspond to physically separate entities. I.e. these functional entities may be implemented in the form of software, or in one or more hardware modules or integrated circuits, or in different networks and/or processor means and/or microcontroller means.
The flow charts shown in the drawings are merely illustrative and do not necessarily include all of the contents and operations/steps, nor do they necessarily have to be performed in the order described. For example, some operations/steps may be decomposed, and some operations/steps may be combined or partially combined, so that the actual execution sequence may be changed according to the actual situation.
It should be noted that: reference herein to "a plurality" means two or more. "and/or" describe the association relationship of the associated objects, meaning that there may be three relationships, e.g., A and/or B may mean: a exists alone, A and B exist simultaneously, and B exists alone. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship.
The Blockchain (Blockchain) is a novel application mode of computer technologies such as distributed data storage, point-to-point transmission, a consensus mechanism, an encryption algorithm and the like. The blockchain is essentially a decentralized database, which is a series of data blocks (i.e., blocks) associated by using cryptography, each data block containing information of a batch of network transactions for verifying the validity (anti-counterfeiting) of the information and generating the next block. The blockchain may include a blockchain underlying platform, a platform product services layer, and an application services layer.
The block chain underlying platform can comprise processing modules such as user management, basic service, intelligent contract and operation monitoring. The user management module is responsible for identity information management of all blockchain participants, and comprises public and private key generation maintenance (account management), key management, user real identity and blockchain address corresponding relation maintenance (authority management) and the like, and under the authorization condition, the user management module supervises and audits the transaction condition of certain real identities and provides rule configuration (wind control audit) of risk control; the basic service module is deployed on all block chain node equipment and used for verifying the validity of the service request, recording the service request to storage after consensus on the valid request is completed, for a new service request, the basic service firstly performs interface adaptation analysis and authentication processing (interface adaptation), then encrypts service information (consensus management) through a consensus algorithm, transmits the service information to a shared account (network communication) completely and consistently after encryption, and performs recording and storage; the intelligent contract module is responsible for registering and issuing contracts, triggering the contracts and executing the contracts, developers can define contract logics through a certain programming language, issue the contract logics to a block chain (contract registration), call keys or other event triggering and executing according to the logics of contract clauses, complete the contract logics and simultaneously provide the function of upgrading and canceling the contracts; the operation monitoring module is mainly responsible for deployment, configuration modification, contract setting, cloud adaptation in the product release process and visual output of real-time states in product operation, such as: alarm, monitoring network conditions, monitoring node equipment health status, and the like.
The platform product service layer provides basic capability and an implementation framework of typical application, and developers can complete block chain implementation of business logic based on the basic capability and the characteristics of the superposed business. The application service layer provides the application service based on the block chain scheme for the business participants to use.
Referring to the blockchain network shown in fig. 1, a plurality of nodes 101 may be included in the blockchain network, and the plurality of nodes 101 may be respective clients forming the blockchain network. Each node 101 may receive input information and maintain shared data within the blockchain network based on the received input information while operating normally. In order to ensure information intercommunication in the blockchain network, information connection can exist between each node in the blockchain network, and information transmission can be carried out between the nodes through the information connection. For example, when any node in the blockchain network receives input information, other nodes in the blockchain network acquire the input information according to a consensus algorithm, and store the input information as shared data, so that the data stored on all the nodes in the blockchain network are consistent.
Each node in the blockchain network has a corresponding node identifier, and each node in the blockchain network can store the node identifiers of other nodes, so that the generated blocks can be broadcasted to other nodes in the blockchain network according to the node identifiers of other nodes. Each node can maintain a node identification list, and the node name and the node identification are correspondingly stored in the node identification list. The node identifier may be an IP (Internet Protocol) address and any other information that can be used to identify the node.
Each node in the blockchain network stores one identical blockchain. The block chain is composed of a plurality of blocks, as shown in fig. 2, the block chain is composed of a plurality of blocks, the starting block includes a block header and a block main body, the block header stores input information characteristic values, version numbers, timestamps, difficulty values and the like, and the block main body stores input information; the next block of the starting block takes the starting block as a parent block, the next block also comprises a block head and a block main body, the block head stores the input information characteristic value of the current block, the block head characteristic value of the parent block, the version number, the timestamp, the difficulty value and the like, so that the block data stored in each block in the block chain is associated with the block data stored in the parent block, and the safety of the input information in the block is ensured.
When each block in the block chain is generated, referring to fig. 3, when a node where the block chain is located receives input information, the input information is verified, after the verification is completed, the input information is stored in a memory pool, and a hash tree for recording the input information is updated; and then, updating the updating time stamp to the time when the input information is received, trying different random numbers, and calculating the characteristic value for multiple times, so that the calculated characteristic value can meet the following formula:
Figure 987347DEST_PATH_IMAGE001
wherein, SHA256 is a characteristic value algorithm used for calculating a characteristic value; version is version information of the relevant block protocol in the block chain; prev _ hash is a block head characteristic value of a parent block of the current block; merkle _ root is a characteristic value of the input information; ntime is the update time of the update timestamp; nbits is the current difficulty, is a fixed value within a period of time, and is determined again after exceeding a fixed time period; x is a random number; TARGET is a feature threshold, which can be determined from nbits.
Therefore, when the random number meeting the formula is obtained through calculation, the information can be correspondingly stored, and the block head and the block main body are generated to obtain the current block. And then, the node where the block chain is located respectively sends the newly generated blocks to other nodes in the data sharing system where the newly generated blocks are located according to the node identifications of the other nodes in the data sharing system, the newly generated blocks are verified by the other nodes, and the newly generated blocks are added to the block chain stored in the newly generated blocks after the verification is completed.
Each node in the blockchain network may be a server or a terminal device. The server may be an independent physical server, a server cluster or a distributed system formed by a plurality of physical servers, or a Cloud server providing basic Cloud Computing services such as a Cloud service, a Cloud database, Cloud Computing (Cloud Computing), a Cloud function, Cloud storage, a Network service, Cloud communication, a middleware service, a domain name service, a security service, a Content Delivery Network (CDN), a big data and artificial intelligence platform, and the like. The terminal device may be, but is not limited to, a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart speaker, a smart watch, and the like. The nodes may be directly or indirectly connected through wired or wireless communication, and the application is not limited herein.
The cloud computing refers to a delivery and use mode of an IT infrastructure, and specifically refers to acquiring required resources in an on-demand and easily-extensible manner through a network; the generalized cloud computing refers to a delivery and use mode of a service, and refers to obtaining a required service in an on-demand and easily-extensible manner through a network. Such services may be IT and software, internet related, or other services. Cloud Computing is a product of development and fusion of traditional computers and Network Technologies, such as Grid Computing (Grid Computing), Distributed Computing (Distributed Computing), Parallel Computing (Parallel Computing), Utility Computing (Utility Computing), Network Storage (Network Storage Technologies), Virtualization (Virtualization), Load balancing (Load Balance), and the like. With the development of diversification of internet, real-time data stream and connecting equipment and the promotion of demands of search service, social network, mobile commerce, open collaboration and the like, cloud computing is rapidly developed. Different from the prior parallel distributed computing, the generation of cloud computing can promote the revolutionary change of the whole internet mode and the enterprise management mode in concept.
Based on the blockchain technology, embodiments of the present application provide an architecture of a blockchain system. As shown in fig. 4A, the blockchain system includes a billing node sub-network 2 and a service node sub-network 1. Accounting node sub-network 2 comprises accounting nodes for consensus and recording of block data onto the blockchain, and service node sub-network 1 comprises service nodes for verification of data blocks recorded by the accounting nodes onto the blockchain or for synchronization of corresponding transaction data requested from the accounting nodes.
In one embodiment of the application, billing node sub-network 2 and service node sub-network 1 may be connected via a proxy node 10, and proxy node 10 may be a service node of service node sub-network 1, which is responsible for passing information to be passed by billing node 21 to service node 11. The service node 11 is a terminal of a transaction party generating various transaction data to be linked, and may also be a terminal inquiring transaction data from the accounting node network 2. The transaction data generated by the service node 11 is transmitted to the accounting node 21 through the proxy node 10, and then is recorded on the blockchain after being identified, which is beneficial to the uniform processing and supervision of the transaction data, and the service node 11 can also perform the uplink supervision and witness of the transaction data through the information sent by the accounting node 21 through the proxy node 10, which is very important in some scenes that need uniform supervision but also afraid of collective cheating of the supervised nodes and therefore need supervision.
In the structure shown in fig. 4A, the service node network 1 adopts a P2P (Peer-to-Peer) network mode. The P2P network is a distributed application architecture that distributes tasks and workloads among peers, and is a form of networking or networking that the peer-to-peer computing model forms at the application layer, i.e., "peer-to-peer" or "peer-to-peer" networks. It can be defined as: participants of the network share a portion of the hardware resources (processing power, storage power, network connectivity, printers, etc.) they own, which provide services and content over the network and which can be accessed directly by other peer nodes without going through intermediate entities. Participants in this network are both providers and acquirers of resources, services and content. Therefore, in the service node sub-network 1, when the proxy node 10 receives the message transmitted from the accounting node 21, the message is transmitted to the surrounding service nodes 11, and the surrounding service nodes 11 receive the message and transmit the message to the surrounding service nodes 11, so that the message is transmitted between each service node 11 of the service node sub-network 1.
Fig. 4B shows an architecture of another blockchain system applied in the embodiments of the present application. This architecture differs from that shown in fig. 4A in that: the P2P network mode is not adopted in the service node subnetwork 1, but the mode of the broadcast network is adopted. In particular, proxy node 10, upon receiving the message passed from accounting node 21, broadcasts the message to other service nodes 11 in service node subnetwork 1. In this way, the propagation of the message between each service node 11 of the service node network 1 is also achieved.
Fig. 4C shows an architecture of another blockchain system applied by the embodiment of the present invention. This architecture differs from that shown in fig. 4A in that: its billing node sub-network 2 is divided into a plurality of branched billing node networks. Each network of branch accounting nodes may be responsible for the recording of some type of transaction information. For example, a business may have a supply chain financial transaction and may need to record contract information, credit, etc. generated during supply and marketing to the blockchain, and the business may need to issue invoices and also record invoicing information, invoice reimbursement information, etc. to the blockchain. In this case, in order to facilitate the requirement that the accounting node is supervised by the same department, the accounting node for recording the supply chain financial service transaction and the accounting node for recording the transaction in the invoice circulation process may belong to different departments. For example, the accounting node for recording the supply chain financial service transaction is an accounting terminal set by a bank, and the accounting node for recording the transaction in the invoice circulation process is an accounting terminal set by a national tax bureau. And supply chain financial transaction and recording of transactions during invoicing may also end up on a network of accounting nodes in different branches.
It should be noted that while in the architecture of the blockchain system shown in fig. 4A to 4C, the proxy node 10 is located in the service node sub-network 1, in other embodiments of the present application, the proxy node 10 may also be located in the accounting node sub-network 2, or may be independent of the service node sub-network 1 and the accounting node sub-network 2.
The architecture of the blockchain system shown in fig. 4A to 4C can be applied to the application scenario of electronic invoices, and is described in detail as follows:
in one embodiment of the application, the accounting nodes in the sub-network of accounting nodes may be respective terminals of the tax administration, for example, the sub-network of accounting nodes is formed by using the terminals of the tax administration deployed in a plurality of regions as one accounting node respectively. Each service node in a service node sub-network may be a local tax office terminal, an invoicing agent facilitator terminal, an invoicing enterprise terminal, a personal user terminal, etc.
Specifically, in the electronic invoice system shown in fig. 5, a service layer, a routing agent layer, and a consensus network (billing network) layer may be included. The service layer is a service node sub-network, which includes each service node, such as a local tax bureau in a tax private network; billing facilitators, reimbursement facilitators, enterprises, etc. in the public cloud; payment facilitators, circulation facilitators, businesses, etc. in the private cloud.
The routing agent layer includes an agent node, the agent node provides functions of routing service, certificate caching and authentication service, P2P service, and the like, and the routing agent layer performs an isolation function on the service layer and the consensus network layer, which refers to the technical solutions of the foregoing embodiments. Alternatively, the proxy node in the routing proxy layer may be in a tax private network. The consensus network (billing network) layer is a billing node network, and includes a plurality of block chains, but in other embodiments of the present application, a block chain may be included in the consensus network (billing network) layer.
In an embodiment of the present application, in order to implement synchronization between services, a data synchronization scheme is proposed in the embodiment of the present application, and details of implementation of the technical scheme of the embodiment of the present application are set forth in the following:
fig. 6 is a flowchart illustrating a data synchronization method of a blockchain system according to an embodiment of the present application, and referring to fig. 6, the data synchronization method of the blockchain system includes:
step S610, obtaining buffer mapping tables corresponding to a plurality of associated nodes respectively, wherein the buffer mapping tables corresponding to the nodes are used for recording whether block body data of each block height is stored or not;
step S620, counting the number of nodes of the block body data storing the height of each block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively to obtain the number of nodes corresponding to the height of each block to be synchronized;
step S630, determining a synchronization sequence of the heights of the blocks to be synchronized according to the number of nodes corresponding to the heights of the blocks to be synchronized;
step S640 is to synchronize the block volume data corresponding to the heights of the multiple blocks to be synchronized according to the synchronization sequence of the heights of the multiple blocks to be synchronized.
These steps are described in detail below.
In step S610, buffer mapping tables corresponding to a plurality of associated nodes are obtained, and the buffer mapping table corresponding to each node is used to record whether block body data of each block height is stored.
Specifically, in this embodiment, an arbitrary node in the blockchain network is taken as an example to be described as an execution subject, and the node may be an arbitrary lightweight node (i.e., SPV node) in the blockchain network, an arbitrary consensus node in the blockchain network, or an arbitrary node other than the consensus node in the blockchain network.
The node as the execution subject may be a computer device, the computer device may be a server or a terminal device, and the number of servers or the number of terminal devices corresponding to the node as the execution subject is determined according to an actual application scenario, which is not limited thereto.
Besides the node as the execution subject, the blockchain network may further include a plurality of nodes connected to the node as the execution subject, and the node as the execution subject and the plurality of nodes may pull the blockchain data from each other. The block data may include a block header data in the block, and may further include a block volume data, where the block volume data is a hash value of all the service data in the block and all the service data in the block.
The node as the execution subject may pull all the block header data, but it does not mean that there is no missing block body data in the node as the execution subject, for example, if the node as the execution subject pulls the block header data with the block height of 1-100, it indicates that there should be block body data with the block height of 1-100 in the node as the execution subject in principle, however, in an actual scenario of this case, there may be missing block body data during pulling, for example, if the node as the execution subject does not pull the block body data with the block height of 50, the missing block body data is the block body data with the block height of 50.
In view of the above problem that there is missing block data in the node as the execution subject, in this embodiment, a data synchronization method of a blockchain system is proposed, in this embodiment, the node as the execution subject may first obtain buffer mapping tables corresponding to a plurality of associated nodes, for example, as shown in fig. 7, corresponding to a plurality of nodes associated with the target node, where the plurality of nodes are node 1, node 2, node 3, node 4, and node 5, and the node 1, node 2, node 3, node 4, and node 5 maintain respective buffer mapping tables, and the buffer mapping tables are used to record whether block data of each block height is stored, where a number "1" indicates that block data is stored, and a number "0" indicates that there is no block data in the storage area. From the corresponding buffer mapping table of node 1, it can be seen that node 1 stores block volume data at block height 1, block height 2, block height 3, block height 5, block height 8 and block height 9.
In step S620, the number of nodes storing the block data of each height of the block to be synchronized is counted according to the buffer mapping tables corresponding to the plurality of nodes, so as to obtain the number of nodes corresponding to each height of the block to be synchronized.
Further, after the node serving as the execution main body obtains the buffer mapping tables corresponding to the plurality of nodes, the node number of the block data in which the heights of the blocks to be synchronized are stored may be counted according to each buffer mapping table, so as to obtain the node number corresponding to the height of each block to be synchronized. The height of each block to be synchronized is the height of the node missing block data as the execution subject.
For example, assuming that a node as an execution subject has a block height (i.e., a height of a block to be synchronized) with a missing block volume data, which is a height 3 of the block to be synchronized, a height 5 of the block to be synchronized, a height 6 of the block to be synchronized, and a height 9 of the block to be synchronized, respectively, and a plurality of nodes associated with the node as the execution subject are a node 1, a node 2, a node 3, a node 4, and a node 5 shown in fig. 7, the number of nodes corresponding to the height 3 of the block to be synchronized, the number of nodes corresponding to the height 5 of the block to be synchronized, the number of nodes corresponding to the height 6 of the block to be synchronized, and the number of nodes corresponding to the height 9 of the block to be synchronized are counted as 1, 4, and 3, respectively.
In step S630, a synchronization sequence of the heights of the multiple blocks to be synchronized is determined according to the number of nodes corresponding to the heights of the blocks to be synchronized.
Furthermore, after the number of nodes corresponding to each height of the block to be synchronized is obtained through statistics, the synchronization sequence of the heights of the plurality of blocks to be synchronized can be determined.
In an embodiment of the present application, the node as the execution subject may determine a synchronization order of heights of a plurality of blocks to be synchronized based on an inverse correlation relationship between a synchronization priority of the blocks to be synchronized and a number of nodes corresponding to the blocks to be synchronized. That is, the larger the number of nodes corresponding to the block to be synchronized is, the smaller the synchronization priority of the block to be synchronized is, and the later the synchronization sequence is.
Continuing with the example in step S620, since the numbers of nodes corresponding to the height 3 of the block to be synchronized, the height 5 of the block to be synchronized, the height 6 of the block to be synchronized, and the height 9 of the block to be synchronized are 1, 2, 4, and 3, respectively, it can be determined that the synchronization sequence is the height 3 of the block to be synchronized, the height 5 of the block to be synchronized, the height 9 of the block to be synchronized, and the height 6 of the block to be synchronized according to the inverse correlation relationship between the numbers of nodes and the synchronization priority.
In step S640, the block volume data corresponding to the heights of the blocks to be synchronized are synchronized according to the synchronization sequence of the heights of the blocks to be synchronized.
After the synchronization sequence of the heights of the multiple blocks to be synchronized is determined, the node serving as the execution main body can pull the block data from the corresponding node according to the synchronization sequence of the heights of the multiple blocks to be synchronized, so that the block data corresponding to the heights of the multiple blocks to be synchronized are synchronized.
For example, in the example of the above step, for the block height to be synchronized 5, since each of the node 2, the node 3, the node 4, and the node 5 stores the block volume data corresponding to the block height 5, the node as the execution subject may pull the block volume data from any one of the node 2, the node 3, the node 4, and the node 5.
Based on the technical scheme of the embodiment, the node number of the block body data with the height of each block to be synchronized is stored in a statistical mode, then the synchronization sequence is determined according to the node number, and compared with a mode of directly pulling in sequence according to the sequence of the block heights, the technical scheme of the embodiment of the application effectively solves the cold start problem of data synchronization, so that the data synchronization process of a block chain system is more flexible and stable.
In an embodiment of the present application, if the number of nodes corresponding to the determined target to-be-synchronized block height is zero, the node serving as the execution subject may re-determine the number of nodes corresponding to each to-be-synchronized block height, as shown in fig. 8, specifically including steps S810 to S820, which are described in detail as follows:
step 810, if the number of the nodes corresponding to the determined height of the target block to be synchronized is zero, obtaining a buffer mapping table corresponding to a target node except the plurality of nodes.
Specifically, if the node serving as the execution subject determines that the number of nodes corresponding to the target block height to be synchronized is zero according to the buffer mapping tables corresponding to the plurality of nodes, it indicates that none of the plurality of nodes stores the block data of the target block height to be synchronized.
It can be understood that the blockchain network includes, in addition to the node as the execution subject and the plurality of nodes associated with the node as the execution subject, other nodes, so that when it is determined that the number of nodes corresponding to the target block height to be synchronized is zero according to buffer mapping tables corresponding to the plurality of nodes, buffer mapping tables corresponding to target nodes other than the plurality of nodes can be obtained, where the buffer mapping tables corresponding to the target nodes are used for recording whether the target nodes store block volume data of each block height.
Step S820, re-determining the number of nodes corresponding to the height of each block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes and the buffer mapping table corresponding to the target node.
After the node serving as the execution main body acquires the buffer mapping table corresponding to the target node, because the buffer mapping table corresponding to the target node records whether the target node stores the block body data of each block height, the node serving as the execution main body can count the number of nodes storing the block body data of each height to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes and the buffer mapping table corresponding to the target node, and obtain the number of nodes corresponding to each height to be synchronized again.
In an embodiment of the present application, if there is still a situation that the number of nodes corresponding to the target block height to be synchronized is zero in the number of nodes corresponding to each retrieved block height to be synchronized, that is, it means that block body data corresponding to the target block height to be synchronized is not stored in the target node, so that the node serving as the execution subject cannot complete data synchronization of the target block height to be synchronized, and therefore, the node serving as the execution subject may perform the operations of obtaining the buffer mapping table + re-determining the number of nodes again, as shown in fig. 9, in this embodiment, steps S910 to S920 may be specifically included, and the following detailed description is given below:
step S910, if the number of nodes corresponding to the height of the target block to be synchronized is still zero, re-obtaining the buffer mapping table corresponding to the second node except the plurality of nodes and the target node.
In this embodiment, if the number of nodes corresponding to the re-determined target block height to be synchronized is still zero, the node serving as the execution subject may re-acquire the plurality of nodes and the buffer mapping table corresponding to the second node other than the target node, where the buffer mapping table corresponding to the second node records whether the second node stores the block body data of each block height.
Step S920, re-determining the number of nodes corresponding to the height of each block to be synchronized again according to the buffer mapping tables corresponding to the plurality of nodes and the buffer mapping table corresponding to the second node.
Further, after the node serving as the execution subject acquires the buffer mapping table corresponding to the second node, the number of nodes corresponding to the height of each block to be synchronized may be re-determined.
In this embodiment, if the number of nodes corresponding to the target to-be-synchronized block height that is re-determined again is still zero, the node that is the execution subject may further repeatedly perform the operations of obtaining the buffer mapping table and re-determining the number of nodes until the number of nodes corresponding to the target to-be-synchronized block height that is finally determined is not zero.
In the foregoing embodiment, each time the node serving as the execution subject repeatedly executes the two operations of obtaining the buffer mapping table + redetermining the number of nodes, in an embodiment of the present application, in order to further improve the synchronization efficiency, the node serving as the execution subject may not repeatedly execute the two operations of obtaining the buffer mapping table + redetermining the number of nodes, but only needs to repeatedly execute one operation of obtaining the buffer mapping table, as shown in fig. 10, in this embodiment, the step S1010 to the step S1030 may be specifically included, and the following detailed description is given:
and step S1010, obtaining a buffer mapping table corresponding to a first node except the plurality of nodes.
Specifically, if the node serving as the execution subject determines that the number of nodes corresponding to the target block height to be synchronized is zero according to the buffer mapping tables corresponding to the plurality of nodes, the node serving as the execution subject may first obtain the buffer mapping table corresponding to the first node other than the plurality of nodes.
The first node is a node in the blockchain network except for the node as an execution subject and a plurality of nodes associated with the node as the execution subject, and the buffer mapping table corresponding to the first node is used for recording whether the first node stores block volume data of each block height.
Step S1020, determining whether the first node stores the block data of the target block height to be synchronized according to the buffer mapping table corresponding to the first node.
Further, since the number of nodes corresponding to the target block height to be synchronized is zero, it indicates that none of the plurality of nodes stores the block body data of the target block height to be synchronized, in this case, in order to achieve synchronization of the block body data corresponding to the target block height to be synchronized, the node serving as the execution main body acquires the buffer mapping table corresponding to the first node other than the plurality of nodes through step S1010, and then determines whether the first node stores the block body data of the target block height to be synchronized according to the buffer mapping table corresponding to the first node.
If the first node is determined to store the block data with the target block height to be synchronized, it is indicated that the block data corresponding to the target block height to be synchronized can be synchronized, and if the first node is determined not to store the block data with the target block height to be synchronized, it is indicated that the block data corresponding to the target block height to be synchronized cannot be synchronized.
Step S1030, if it is determined that the first node does not store the block data of the target block height to be synchronized, the buffer mapping tables corresponding to other nodes are obtained again until the target node is determined, where the block data of the target block height to be synchronized is stored in the target node.
In this embodiment, the node serving as the execution subject only needs to repeatedly execute one operation of obtaining the buffer mapping table, but does not need to repeatedly execute two operations of obtaining the buffer mapping table and re-determining the number of nodes, which means that the node serving as the execution subject can finally determine the target node storing the block body data of the target to-be-synchronized block height by repeatedly obtaining the buffer mapping table, and then, according to the buffer mapping tables corresponding to the plurality of nodes and the buffer mapping table corresponding to the target node, perform one operation of re-determining the number of nodes.
Therefore, if the node as the executing subject determines that the first node does not store the block volume data with the target block height to be synchronized, the node as the executing subject may re-acquire the buffer mapping tables corresponding to other nodes until the target node is determined, and the target node is the node storing the block volume data with the target block height to be synchronized.
In an embodiment of the present application, a designated node exists in a blockchain network, and a buffer mapping table corresponding to the designated node records and stores block volume data of a target block height to be synchronized, so that if the number of nodes corresponding to the determined target block height to be synchronized is zero, a node serving as an execution subject may directly obtain the buffer mapping table corresponding to the designated node, as shown in fig. 11, which may specifically include step S1110 to step S1120, and the detailed description is as follows:
step S1110, if the number of nodes corresponding to the determined height of the target block to be synchronized is zero, obtaining a buffer mapping table corresponding to a designated node other than the plurality of nodes, where the buffer mapping table corresponding to the designated node records and stores block volume data of the height of the target block to be synchronized.
In this embodiment, a designated node exists in the blockchain network, and the designated node stores the block data of the target block height to be synchronized, and in some embodiments, the designated node may be a node that stores the block data of each block height, so that the designated node also stores the block data of the target block height to be synchronized, or the designated node may be a node that does not store the block data of each block height, but stores the block data of the target block height to be synchronized.
Since the designated node stores the block body data of the target block height to be synchronized, the node serving as the execution main body determines that the number of nodes corresponding to the target block height to be synchronized is zero, and the buffer mapping table corresponding to the designated node can be directly obtained.
Step S1120, re-determining the number of nodes corresponding to the height of each block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes and the buffer mapping table corresponding to the designated node.
Further, after the node serving as the execution subject acquires the buffer mapping table corresponding to the designated node, the number of nodes storing the block volume data of each to-be-synchronized height may be counted according to the buffer mapping tables corresponding to the plurality of nodes and the buffer mapping table corresponding to the designated node, and the number of nodes corresponding to each to-be-synchronized block height may be obtained again.
In an embodiment of the present application, if the node serving as the execution subject determines that the number of nodes corresponding to the target block height to be synchronized is zero, the block volume data corresponding to the target block height to be synchronized and the block volume data corresponding to other block heights to be synchronized may be synchronized, as shown in fig. 12, in this embodiment, the method may specifically include steps S1210 to S1220:
step 1210, if the number of nodes corresponding to the determined height of the target block to be synchronized is zero, determining a synchronization sequence of the heights of the other blocks to be synchronized according to the number of nodes corresponding to the heights of the other blocks to be synchronized except the height of the target block to be synchronized.
In this embodiment, if the number of nodes corresponding to the determined height of the target block to be synchronized is zero, the number of nodes corresponding to the height of the target block to be synchronized is not considered, but the synchronization sequence of the heights of the other blocks to be synchronized is determined directly according to the number of nodes corresponding to the heights of the other blocks to be synchronized except the height of the target block to be synchronized.
The method for determining the synchronization sequence of the heights of the other blocks to be synchronized according to the number of nodes corresponding to the heights of the other blocks to be synchronized may be to determine the synchronization sequence of the heights of the other blocks to be synchronized based on an inverse correlation relationship between the synchronization priority of the other blocks to be synchronized and the number of nodes corresponding to the other blocks to be synchronized.
Step S1220, synchronizing the block volume data corresponding to the heights of the other blocks to be synchronized according to the synchronization sequence of the heights of the other blocks to be synchronized.
Since the number of nodes corresponding to the heights of other blocks to be synchronized is not zero, which means that block volume data corresponding to the heights of other blocks to be synchronized is stored in the plurality of nodes, after the synchronization sequence of the heights of other blocks to be synchronized is determined, the node serving as the execution main body can pull the block volume data from the corresponding node according to the synchronization sequence of the heights of other blocks to be synchronized, so as to synchronize the block volume data corresponding to the heights of other blocks to be synchronized.
In an embodiment of the present application, the blockchain system may be the blockchain system shown in fig. 4A to 4C, where the blockchain system includes a service node sub-network and an accounting node sub-network, a node as an executing subject may be a target service node in the service node sub-network, and the associated nodes are service nodes in the service node sub-network that are associated with the target service node.
It is understood that the sub-network of the accounting node includes an accounting node, and the accounting node is configured to perform consensus on the block data and record the block data onto the block chain, in other words, the sub-network of the accounting node stores the block data of each block height, so that the node serving as the executing subject can obtain the block data corresponding to the target block height to be synchronized from the sub-network of the accounting node.
In this embodiment, the node serving as the execution main body may request the sub-network of the accounting node to acquire the block data corresponding to the target block height to be synchronized only when it is determined that the number of nodes corresponding to the target block height to be synchronized is zero, that is, when none of the plurality of nodes in the sub-network of the service node stores the block data corresponding to the target block height to be synchronized, and for the sub-network of the accounting node, the flow rate of external data synchronization request may be effectively reduced, and the consensus performance of the block chain system may be improved.
In an embodiment of the application, if the number of nodes corresponding to the determined target block height to be synchronized is zero, it indicates that block volume data corresponding to the target block height to be synchronized is not stored in a plurality of nodes associated with the node as the execution subject, in this case, the node as the execution subject may further obtain a buffer mapping table corresponding to the designated node, where the designated node is a node other than the plurality of nodes, and the buffer mapping table corresponding to the designated node records the block volume data in which the target block height to be synchronized is stored, and thus, the node as the execution subject may obtain the block volume data corresponding to the target block height to be synchronized from the designated node.
In an embodiment of the present application, the plurality of nodes associated with the node as the execution subject may be selected from nodes that can be connected to as the node of the execution subject, and in this embodiment, as shown in fig. 13, the method may specifically include steps S1310 to S1320:
step S1310 obtains the sizes of the buffer mapping tables corresponding to the nodes that can be connected to.
In this embodiment, the node serving as the execution subject may establish a connection with another node in the block chain, the interconnected nodes may pull block data from each other, and the node serving as the execution subject may select a plurality of associated nodes from the nodes that can be connected to each other. In specific implementation, the sizes of the buffer mapping tables corresponding to the nodes that can be connected to the buffer mapping tables may be obtained first.
It should be noted that the size of the buffer mapping table refers to the number of block heights recorded in the buffer mapping table, for example, as shown in fig. 7, the size of the buffer mapping table corresponding to node 1 is 9 because the buffer mapping table corresponding to node 1 records block data with 9 block heights.
Step S1320, selecting a plurality of nodes associated with each other from the connectable nodes according to the size of the buffer mapping table corresponding to each connectable node.
After obtaining the sizes of the buffer mapping tables respectively corresponding to the connectable nodes, the associated nodes may be selected from the connectable nodes according to the sizes of the buffer mapping tables respectively corresponding to the connectable nodes.
In some embodiments, the selecting may be to select, as the associated plurality of nodes, a node to which the size of the buffer mapping table exceeds a first preset threshold, where the first preset threshold may be set according to actual conditions.
In an embodiment of the present application, the blockchain system may be the blockchain system shown in fig. 4A to 4C, the blockchain system includes a service node sub-network and an accounting node sub-network, a node serving as an execution subject may be a target service node in the service node sub-network, and the target service node may obtain, from the accounting node sub-network, the routing information of the service node whose size of the buffer mapping table exceeds a second preset threshold, and then establish a connection with the service node according to the routing information of the service node. The advantage of this embodiment is that it is ensured that the node as the execution subject can establish a connection according to the size of the buffer mapping table, and further it is ensured that more information is provided by the subsequently obtained buffer mapping table, which is beneficial to synchronizing the block volume data corresponding to the height of the block to be synchronized.
The following describes embodiments of the apparatus of the present application, which can be used to perform the data synchronization method of the blockchain system in the above embodiments of the present application. For details that are not disclosed in the embodiments of the apparatus of the present application, please refer to the embodiments of the data synchronization method of the blockchain system described above in the present application.
Fig. 14 shows a block diagram of a data synchronization apparatus of a blockchain system according to an embodiment of the present application, and referring to fig. 14, a data synchronization apparatus 1400 of a blockchain system according to an embodiment of the present application includes: a first obtaining unit 1402, a statistics unit 1404, a first determining unit 1406 and a first synchronization unit 1408.
The first obtaining unit 1402 is configured to obtain buffer mapping tables corresponding to a plurality of associated nodes, where the buffer mapping table corresponding to each node is used to record whether block body data of each block height is stored; the counting unit 1404 is configured to count the number of nodes storing the block data of each to-be-synchronized block height according to the buffer mapping tables corresponding to the plurality of nodes, respectively, to obtain the number of nodes corresponding to each to-be-synchronized block height; the first determining unit 1406 is configured to determine a synchronization sequence of heights of a plurality of blocks to be synchronized according to the number of nodes corresponding to the heights of the blocks to be synchronized; the first synchronization unit 1408 is configured to synchronize the block volume data corresponding to the heights of the blocks to be synchronized according to the synchronization sequence of the heights of the blocks to be synchronized.
In some embodiments of the present application, the first determining unit 1406 is configured to: and determining the synchronization sequence of the heights of the blocks to be synchronized based on the inverse correlation relationship between the synchronization priority of the blocks to be synchronized and the number of nodes corresponding to the blocks to be synchronized.
In some embodiments of the present application, the apparatus further comprises: a second obtaining unit, configured to obtain a buffer mapping table corresponding to a target node other than the plurality of nodes if the number of nodes corresponding to the determined height of the target block to be synchronized is zero; and the first re-determining unit is configured to re-determine the number of nodes corresponding to the height of each block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the target node.
In some embodiments of the present application, the second obtaining unit is further configured to: obtaining a buffer mapping table corresponding to a first node except the plurality of nodes; determining whether the first node stores block volume data of the target block height to be synchronized according to a buffer mapping table corresponding to the first node; if the first node is determined not to store the block data of the target block height to be synchronized, the buffer mapping tables corresponding to other nodes are obtained again until the target node is determined, wherein the block data of the target block height to be synchronized is stored in the target node.
In some embodiments of the present application, the first re-determination unit is further configured to: after the number of nodes corresponding to the height of each block to be synchronized is re-determined, if the number of nodes corresponding to the height of the target block to be synchronized is still zero, re-obtaining a buffer mapping table corresponding to a second node except the plurality of nodes and the target node; and re-determining the number of nodes corresponding to the height of each block to be synchronized again according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the second node.
In some embodiments of the present application, the apparatus further comprises: a third obtaining unit, configured to obtain, if the number of nodes corresponding to the determined height of the target block to be synchronized is zero, a buffer mapping table corresponding to a designated node other than the plurality of nodes, where the buffer mapping table corresponding to the designated node records and stores block volume data of the height of the target block to be synchronized; and the second re-determining unit is configured to re-determine the number of nodes corresponding to the height of each block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the designated node.
In some embodiments of the present application, the apparatus further comprises: a second determining unit, configured to determine, if the number of nodes corresponding to the determined height of the target block to be synchronized is zero, a synchronization sequence of the heights of the other blocks to be synchronized according to the number of nodes corresponding to the heights of the other blocks to be synchronized except the height of the target block to be synchronized; and the second synchronization unit is configured to synchronize the block volume data corresponding to the heights of the other blocks to be synchronized according to the synchronization sequence of the heights of the other blocks to be synchronized.
In some embodiments of the present application, the blockchain system includes a service node sub-network and a billing node sub-network, the apparatus is disposed in a target service node in the service node sub-network, the associated plurality of nodes are a plurality of service nodes in the service node sub-network associated with the target service node, the apparatus further includes: and the fourth acquisition unit is configured to acquire the block volume data corresponding to the height of the target block to be synchronized from the accounting node sub-network.
In some embodiments of the present application, the apparatus further comprises: a fifth obtaining unit, configured to obtain a buffer mapping table corresponding to a specified node except the plurality of nodes, where the buffer mapping table corresponding to the specified node records and stores block volume data of the target block height to be synchronized; a sixth obtaining unit, configured to obtain, from the designated node, block volume data corresponding to the height of the target block to be synchronized.
In some embodiments of the present application, the apparatus further comprises: a seventh obtaining unit configured to obtain sizes of buffer mapping tables respectively corresponding to the nodes that can be connected to; and a selecting unit configured to select the associated plurality of nodes from the connectable nodes according to sizes of buffer mapping tables respectively corresponding to the connectable nodes.
In some embodiments of the present application, the selection unit is configured to: and selecting the nodes with the size of the buffer mapping table exceeding a first preset threshold from the connectable nodes as the associated nodes according to the sizes of the buffer mapping tables respectively corresponding to the connectable nodes.
In some embodiments of the present application, the blockchain system includes a service node sub-network and a billing node sub-network, the apparatus is disposed in a target service node in the service node sub-network, the apparatus further includes: an eighth obtaining unit, configured to obtain, from the sub-network of accounting nodes, routing information of a service node whose size of the buffer mapping table exceeds a second preset threshold; and the establishing unit is configured to establish connection with the service node according to the routing information of the service node.
FIG. 15 illustrates a schematic structural diagram of a computer system suitable for use in implementing the electronic device of an embodiment of the present application.
It should be noted that the computer system 1500 of the electronic device shown in fig. 15 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present application.
As shown in fig. 15, the computer system 1500 includes a Central Processing Unit (CPU) 1501 which can perform various appropriate actions and processes, such as performing the methods described in the above embodiments, according to a program stored in a Read-Only Memory (ROM) 1502 or a program loaded from a storage section 1508 into a Random Access Memory (RAM) 1503. In the RAM 1503, various programs and data necessary for system operation are also stored. The CPU 1501, the ROM 1502, and the RAM 1503 are connected to each other by a bus 1504. An Input/Output (I/O) interface 1505 is also connected to bus 1504.
The following components are connected to the I/O interface 1505: an input portion 1506 including a keyboard, a mouse, and the like; an output section 1507 including a Display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and a speaker; a storage portion 1508 including a hard disk and the like; and a communication section 1509 including a Network interface card such as a LAN (Local Area Network) card, a modem, or the like. The communication section 1509 performs communication processing via a network such as the internet. A drive 1510 is also connected to the I/O interface 1505 as needed. A removable medium 1511 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 1510 as necessary, so that a computer program read out therefrom is mounted into the storage section 1508 as necessary.
In particular, according to embodiments of the application, the processes described above with reference to the flow diagrams may be implemented as computer software programs. For example, embodiments of the present application include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising a computer program for performing the method illustrated by the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 1509, and/or installed from the removable medium 1511. When the computer program is executed by a Central Processing Unit (CPU) 1501, various functions defined in the system of the present application are executed.
It should be noted that the computer readable medium shown in the embodiments of the present application may be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a Read-Only Memory (ROM), an Erasable Programmable Read-Only Memory (EPROM), a flash Memory, an optical fiber, a portable Compact Disc Read-Only Memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present application, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In this application, however, a computer readable signal medium may include a propagated data signal with a computer program embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. The computer program embodied on the computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wired, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present application. Each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present application may be implemented by software, or may be implemented by hardware, and the described units may also be disposed in a processor. Wherein the names of the elements do not in some way constitute a limitation on the elements themselves.
As another aspect, the present application also provides a computer-readable medium, which may be contained in the electronic device described in the above embodiments; or may exist separately without being assembled into the electronic device. The computer readable medium carries one or more programs which, when executed by an electronic device, cause the electronic device to implement the method described in the above embodiments.
It should be noted that although in the above detailed description several modules or units of the device for action execution are mentioned, such a division is not mandatory. Indeed, the features and functionality of two or more modules or units described above may be embodied in one module or unit, according to embodiments of the application. Conversely, the features and functions of one module or unit described above may be further divided into embodiments by a plurality of modules or units.
Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein may be implemented by software, or by software in combination with necessary hardware. Therefore, the technical solution according to the embodiments of the present application can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a usb disk, a removable hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which can be a personal computer, a server, a touch terminal, or a network device, etc.) to execute the method according to the embodiments of the present application.
Other embodiments of the present application will be apparent to those skilled in the art from consideration of the specification and practice of the embodiments disclosed herein. This application is intended to cover any variations, uses, or adaptations of the invention following, in general, the principles of the application and including such departures from the present disclosure as come within known or customary practice within the art to which the invention pertains.
It will be understood that the present application is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the application is limited only by the appended claims.

Claims (24)

1. A method for data synchronization in a blockchain system, the method comprising:
obtaining buffer mapping tables corresponding to a plurality of associated nodes respectively, wherein the buffer mapping tables corresponding to the nodes are used for recording whether block body data of each block height is stored or not;
counting the number of nodes storing the block body data of each height of the block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively to obtain the number of nodes corresponding to the height of each block to be synchronized;
determining a synchronization sequence of a plurality of block heights to be synchronized based on an inverse correlation relationship between the synchronization priority of the block heights to be synchronized and the number of nodes corresponding to the block heights to be synchronized;
and synchronizing the block volume data corresponding to the heights of the blocks to be synchronized respectively according to the synchronization sequence of the heights of the blocks to be synchronized.
2. The method of claim 1, further comprising:
if the number of the nodes corresponding to the height of the target block to be synchronized is zero, obtaining a buffer mapping table corresponding to a target node except the plurality of nodes;
and re-determining the number of nodes corresponding to the height of each block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the target node.
3. The method of claim 2, wherein obtaining a buffer mapping table corresponding to a target node other than the plurality of nodes comprises:
obtaining a buffer mapping table corresponding to a first node except the plurality of nodes;
determining whether the first node stores block volume data of the target block height to be synchronized according to a buffer mapping table corresponding to the first node;
if the first node is determined not to store the block data of the target block height to be synchronized, the buffer mapping tables corresponding to other nodes are obtained again until the target node is determined, wherein the block data of the target block height to be synchronized is stored in the target node.
4. The method according to claim 2, wherein after re-determining the number of nodes corresponding to the height of each block to be synchronized, the method further comprises:
if the number of the nodes corresponding to the height of the target block to be synchronized is still zero, re-obtaining a buffer mapping table corresponding to a second node except the plurality of nodes and the target node;
and re-determining the number of nodes corresponding to the height of each block to be synchronized again according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the second node.
5. The method of claim 1, further comprising:
if the number of the nodes corresponding to the height of the target block to be synchronized is determined to be zero, obtaining a buffer mapping table corresponding to a designated node except the plurality of nodes, wherein the buffer mapping table corresponding to the designated node records and stores block volume data of the height of the target block to be synchronized;
and re-determining the number of nodes corresponding to the height of each block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the designated node.
6. The method of claim 1, further comprising:
if the number of the nodes corresponding to the height of the target block to be synchronized is zero, determining the synchronization sequence of the heights of other blocks to be synchronized according to the number of the nodes corresponding to the heights of the other blocks to be synchronized except the height of the target block to be synchronized;
and synchronizing the block volume data corresponding to the heights of the other blocks to be synchronized according to the synchronization sequence of the heights of the other blocks to be synchronized.
7. The method of claim 6, wherein the blockchain system includes a service node sub-network and a billing node sub-network, wherein the method is performed by a target service node in the service node sub-network, wherein the associated plurality of nodes are a plurality of service nodes in the service node sub-network that are associated with the target service node, and wherein the method further comprises:
and acquiring block volume data corresponding to the height of the target block to be synchronized from the accounting node sub-network.
8. The method of claim 6, further comprising:
obtaining a buffer mapping table corresponding to a designated node except the plurality of nodes, wherein the buffer mapping table corresponding to the designated node records and stores block body data of the height of the target block to be synchronized;
and acquiring block volume data corresponding to the height of the target block to be synchronized from the designated node.
9. The method of claim 1, further comprising:
acquiring the sizes of buffer mapping tables respectively corresponding to nodes which can be connected to;
and selecting the associated nodes from the connectable nodes according to the sizes of the buffer mapping tables respectively corresponding to the connectable nodes.
10. The method according to claim 9, wherein selecting the associated plurality of nodes from the connectable nodes according to the sizes of the buffer mapping tables respectively corresponding to the connectable nodes comprises:
and selecting the nodes with the size of the buffer mapping table exceeding a first preset threshold from the connectable nodes as the associated nodes according to the sizes of the buffer mapping tables respectively corresponding to the connectable nodes.
11. The method of claim 9, wherein the blockchain system includes a service node sub-network and a billing node sub-network, wherein the method is performed by a target service node in the service node sub-network, and wherein the method further comprises:
acquiring the routing information of the service node of which the size of the buffer mapping table exceeds a second preset threshold value from the accounting node sub-network;
and establishing connection with the service node according to the routing information of the service node.
12. An apparatus for data synchronization of a blockchain system, the apparatus comprising:
the first obtaining unit is configured to obtain buffer mapping tables corresponding to a plurality of associated nodes respectively, and the buffer mapping tables corresponding to the nodes are used for recording whether block body data of each block height is stored or not;
the counting unit is configured to count the number of nodes storing the block body data of each height of the block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively, so as to obtain the number of nodes corresponding to each height of the block to be synchronized;
a first determining unit configured to determine a synchronization order of a plurality of to-be-synchronized block heights based on an inverse correlation relationship between the synchronization priority of the to-be-synchronized block height and the number of nodes corresponding to the to-be-synchronized block height;
and the first synchronization unit is configured to synchronize the block volume data corresponding to the heights of the multiple blocks to be synchronized according to the synchronization sequence of the heights of the multiple blocks to be synchronized.
13. The apparatus for data synchronization of a blockchain system according to claim 12, wherein said apparatus further comprises:
a second obtaining unit, configured to obtain a buffer mapping table corresponding to a target node other than the plurality of nodes if the number of nodes corresponding to the determined height of the target block to be synchronized is zero;
and the first re-determining unit is configured to re-determine the number of nodes corresponding to the height of each block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the target node.
14. The data synchronization device of the blockchain system according to claim 13, wherein the second obtaining unit is further configured to:
obtaining a buffer mapping table corresponding to a first node except the plurality of nodes;
determining whether the first node stores block volume data of the target block height to be synchronized according to a buffer mapping table corresponding to the first node; if the first node is determined not to store the block data of the target block height to be synchronized, the buffer mapping tables corresponding to other nodes are obtained again until the target node is determined, wherein the block data of the target block height to be synchronized is stored in the target node.
15. The data synchronization device of the blockchain system according to claim 13, wherein the first re-determining unit is further configured to:
after the number of nodes corresponding to the height of each block to be synchronized is re-determined, if the number of nodes corresponding to the height of the target block to be synchronized is still zero, re-obtaining a buffer mapping table corresponding to a second node except the plurality of nodes and the target node;
and re-determining the number of nodes corresponding to the height of each block to be synchronized again according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the second node.
16. The apparatus for data synchronization of a blockchain system according to claim 12, wherein said apparatus further comprises:
a third obtaining unit, configured to obtain, if the number of nodes corresponding to the determined height of the target block to be synchronized is zero, a buffer mapping table corresponding to a designated node other than the plurality of nodes, where the buffer mapping table corresponding to the designated node records and stores block volume data of the height of the target block to be synchronized;
and the second re-determining unit is configured to re-determine the number of nodes corresponding to the height of each block to be synchronized according to the buffer mapping tables corresponding to the plurality of nodes respectively and the buffer mapping table corresponding to the designated node.
17. The apparatus for data synchronization of a blockchain system according to claim 12, wherein said apparatus further comprises:
a second determining unit, configured to determine, if the number of nodes corresponding to the determined height of the target block to be synchronized is zero, a synchronization sequence of the heights of the other blocks to be synchronized according to the number of nodes corresponding to the heights of the other blocks to be synchronized except the height of the target block to be synchronized;
and the second synchronization unit is configured to synchronize the block volume data corresponding to the heights of the other blocks to be synchronized according to the synchronization sequence of the heights of the other blocks to be synchronized.
18. The data synchronization device of blockchain system of claim 17, wherein the blockchain system includes a service node sub-network and a billing node sub-network, the device being disposed in a target service node of the service node sub-network, the associated plurality of nodes being a plurality of service nodes of the service node sub-network associated with the target service node, the device further comprising:
and the fourth acquisition unit is configured to acquire the block volume data corresponding to the height of the target block to be synchronized from the accounting node sub-network.
19. The apparatus for data synchronization of a blockchain system according to claim 17, wherein said apparatus further comprises:
a fifth obtaining unit, configured to obtain a buffer mapping table corresponding to a specified node except the plurality of nodes, where the buffer mapping table corresponding to the specified node records and stores block volume data of the target block height to be synchronized;
a sixth obtaining unit, configured to obtain, from the designated node, block volume data corresponding to the height of the target block to be synchronized.
20. The apparatus for data synchronization of a blockchain system according to claim 12, wherein said apparatus further comprises:
a seventh obtaining unit configured to obtain sizes of buffer mapping tables respectively corresponding to the nodes that can be connected to;
a selecting unit configured to select the associated plurality of nodes from the connectable nodes according to sizes of buffer mapping tables respectively corresponding to the connectable nodes.
21. The data synchronization device of the blockchain system of claim 20, wherein the selection unit is configured to: and selecting the nodes with the size of the buffer mapping table exceeding a first preset threshold from the connectable nodes as the associated nodes according to the sizes of the buffer mapping tables respectively corresponding to the connectable nodes.
22. The data synchronization device of blockchain system of claim 20, wherein the blockchain system includes a service node sub-network and a billing node sub-network, the device being disposed in a target service node in the service node sub-network, the device further comprising:
an eighth obtaining unit, configured to obtain, from the sub-network of accounting nodes, routing information of a service node whose size of the buffer mapping table exceeds a second preset threshold;
and the establishing unit is configured to establish connection with the service node according to the routing information of the service node.
23. A computer-readable medium, on which a computer program is stored which, when being executed by a processor, carries out a method of data synchronization of a blockchain system according to any one of claims 1 to 11.
24. An electronic device, comprising:
one or more processors;
storage means for storing one or more programs which, when executed by the one or more processors, cause the one or more processors to implement the data synchronization method of the blockchain system according to any one of claims 1 to 11.
CN202011473334.2A 2020-12-15 2020-12-15 Data synchronization method and device of block chain system, readable medium and electronic equipment Active CN112287031B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011473334.2A CN112287031B (en) 2020-12-15 2020-12-15 Data synchronization method and device of block chain system, readable medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011473334.2A CN112287031B (en) 2020-12-15 2020-12-15 Data synchronization method and device of block chain system, readable medium and electronic equipment

Publications (2)

Publication Number Publication Date
CN112287031A CN112287031A (en) 2021-01-29
CN112287031B true CN112287031B (en) 2021-04-23

Family

ID=74425893

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011473334.2A Active CN112287031B (en) 2020-12-15 2020-12-15 Data synchronization method and device of block chain system, readable medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN112287031B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112765137B (en) * 2021-04-07 2021-06-22 暗链科技(深圳)有限公司 Block synchronization method based on block distributed block chain and electronic equipment
CN113098970A (en) * 2021-04-12 2021-07-09 浙江永旗区块链科技有限公司 Distributed network node data synchronization method
CN113259118B (en) * 2021-06-02 2021-09-24 支付宝(杭州)信息技术有限公司 Method for synchronizing node information lists
CN114338724A (en) * 2021-12-31 2022-04-12 支付宝(杭州)信息技术有限公司 Block synchronization method and device, electronic equipment and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107332876A (en) * 2017-05-31 2017-11-07 深圳前海微众银行股份有限公司 The synchronous method and device of block chain state
CN110099106A (en) * 2019-04-24 2019-08-06 福建方维信息科技有限公司 A kind of data synchronous method and terminal between block chain interior joint
CN111147392A (en) * 2019-12-25 2020-05-12 腾讯科技(深圳)有限公司 Data synchronization method, device and equipment based on block chain and readable storage medium
CN111475575A (en) * 2020-04-09 2020-07-31 腾讯科技(深圳)有限公司 Data synchronization method and device based on block chain and computer readable storage medium

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10417217B2 (en) * 2016-08-05 2019-09-17 Chicago Mercantile Exchange Inc. Systems and methods for blockchain rule synchronization

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107332876A (en) * 2017-05-31 2017-11-07 深圳前海微众银行股份有限公司 The synchronous method and device of block chain state
CN110099106A (en) * 2019-04-24 2019-08-06 福建方维信息科技有限公司 A kind of data synchronous method and terminal between block chain interior joint
CN111147392A (en) * 2019-12-25 2020-05-12 腾讯科技(深圳)有限公司 Data synchronization method, device and equipment based on block chain and readable storage medium
CN111475575A (en) * 2020-04-09 2020-07-31 腾讯科技(深圳)有限公司 Data synchronization method and device based on block chain and computer readable storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
节点数不同的不确定时空网络的同步研究;荣婷婷;《中国优秀硕士学位论文全文数据库 基础科学辑》;20180115(第12期);第A002-103页 *

Also Published As

Publication number Publication date
CN112287031A (en) 2021-01-29

Similar Documents

Publication Publication Date Title
CN112287031B (en) Data synchronization method and device of block chain system, readable medium and electronic equipment
CN112232823B (en) Transaction processing method, device, medium and electronic equipment of block chain system
CN110827097B (en) Tax management method, apparatus, medium and electronic device based on block chain system
CN112733174B (en) Authentication management method and system of block chain system and electronic equipment
EP4120114A1 (en) Data processing method and apparatus, smart device and storage medium
CN112231741B (en) Data processing method, device, medium and electronic equipment based on block chain system
CN112291376B (en) Data processing method and related equipment in block chain system
CN109658097B (en) Authentication management method, device, medium and electronic equipment of block chain system
CN113657900B (en) Cross-chain transaction verification method and system and cross-chain transaction system
CN112235420B (en) Data synchronization method, system and related equipment based on block chain
US20230262126A1 (en) Blockchain-based data processing method and apparatus, device, and readable storage medium
CN112231414B (en) Data synchronization method and device of block chain system, readable medium and electronic equipment
CN116150260A (en) Data processing method, device, medium and electronic equipment of block chain system
CN112532753B (en) Data synchronization method, device, medium and electronic equipment of block chain system
WO2023231558A1 (en) Blockchain consensus method and apparatus, medium, electronic device, and program product
CN112565104B (en) Flow control method, device, medium and electronic equipment of block chain system
CN112926981B (en) Transaction information processing method, device and medium for block chain and electronic equipment
CN112231415B (en) Data synchronization method and system of block chain network, electronic device and readable medium
CN116233139A (en) Data processing method, device, medium and electronic equipment of block chain system
CN116186749A (en) Block chain-based service processing method and device, electronic equipment and readable medium
CN116186786A (en) Block chain-based service processing method and device, electronic equipment and readable medium
CN116112506A (en) Transaction information processing method, device, medium and equipment based on alliance chain system
Singh et al. Distributed trust and reputation management for future wireless systems
CN116232624A (en) Data processing method and device based on block chain system, equipment and medium
CN116232625A (en) Block chain system-based account management method, device, equipment and readable medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
REG Reference to a national code

Ref country code: HK

Ref legal event code: DE

Ref document number: 40038141

Country of ref document: HK