WO2018214835A1 - Block chain service acceptance and consensus method and device - Google Patents

Block chain service acceptance and consensus method and device Download PDF

Info

Publication number
WO2018214835A1
WO2018214835A1 PCT/CN2018/087603 CN2018087603W WO2018214835A1 WO 2018214835 A1 WO2018214835 A1 WO 2018214835A1 CN 2018087603 W CN2018087603 W CN 2018087603W WO 2018214835 A1 WO2018214835 A1 WO 2018214835A1
Authority
WO
WIPO (PCT)
Prior art keywords
consensus
application
database
data
sent
Prior art date
Application number
PCT/CN2018/087603
Other languages
French (fr)
Chinese (zh)
Inventor
唐强
Original Assignee
阿里巴巴集团控股有限公司
唐强
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 阿里巴巴集团控股有限公司, 唐强 filed Critical 阿里巴巴集团控股有限公司
Priority to SG11201906166YA priority Critical patent/SG11201906166YA/en
Priority to PL18806911T priority patent/PL3550803T3/en
Priority to KR1020197019210A priority patent/KR102204256B1/en
Priority to EP21166986.6A priority patent/EP3886403B1/en
Priority to MYPI2019003821A priority patent/MY194420A/en
Priority to JP2019536261A priority patent/JP6949118B2/en
Priority to ES18806911T priority patent/ES2876943T3/en
Priority to EP18806911.6A priority patent/EP3550803B1/en
Publication of WO2018214835A1 publication Critical patent/WO2018214835A1/en
Priority to PH12019501563A priority patent/PH12019501563A1/en
Priority to US16/502,523 priority patent/US10938577B2/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3247Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials involving digital signatures
    • H04L9/3255Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials involving digital signatures using group based signatures, e.g. ring or threshold signatures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/18File system types
    • G06F16/182Distributed file systems
    • G06F16/1824Distributed file systems implemented using Network-attached Storage [NAS] architecture
    • G06F16/1827Management specifically adapted to NAS
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1097Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching
    • H04L67/5681Pre-fetching or pre-delivering data based on network characteristics
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching
    • H04L67/5682Policies or rules for updating, deleting or replacing the stored data
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/06Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols the encryption apparatus using shift registers or memories for block-wise or stream coding, e.g. DES systems or RC4; Hash functions; Pseudorandom sequence generators
    • H04L9/0618Block ciphers, i.e. encrypting groups of characters of a plain text message using fixed encryption transformation
    • H04L9/0637Modes of operation, e.g. cipher block chaining [CBC], electronic codebook [ECB] or Galois/counter mode [GCM]

Definitions

  • the present application relates to the field of information technology, and in particular, to a blockchain service acceptance and business consensus method and apparatus.
  • blockchain technology As an emerging technology, has become a key technology because of its openness, inability to modify, and decentralization.
  • each consensus node in the blockchain network can accept the service request sent by the client.
  • a consensus node when the consensus node receives the service request, it can first determine the corresponding service data according to the service request. The consensus node can then broadcast the business data to other consensus nodes. After the consensus node receives the pre-processing block sent by other consensus nodes, the pre-processing can be quickly verified by consensus, and the pre-processing block can be stored after the verification is passed.
  • the consensus node After the service node receives the service request, the consensus node generally stores the service data corresponding to the service request in the cache of the consensus node. After the subsequent verification of the service data is passed, the service data is released from the cache. Similarly, the service data sent by other consensus nodes can also be stored in the cache and released after passing the consensus check.
  • the data that is not stored in the blockchain is temporarily stored in the cache of the consensus node.
  • the consensus check is performed, the number of service data that can be verified is limited by the cache capacity of the consensus node. The efficiency of consensus verification is limited.
  • the cache space of the consensus node is insufficient, the consensus node is also difficult to process the received service request.
  • the embodiment of the present application provides a blockchain service acceptance and service consensus method, which is used to solve the problem of low efficiency of service execution in the existing blockchain technology.
  • the embodiment of the present application provides a blockchain service acceptance and service consensus device, which is used to solve the problem of low efficiency of service execution in the existing blockchain technology.
  • a blockchain service acceptance method includes a first application, a second application, and a database, including:
  • the first application stores the service data to be sent in the database
  • the second application or the first application sends the service data to be sent from the database to other consensus node storage.
  • a blockchain business consensus method the first consensus node includes a first application, a second application, and a first database, including:
  • the first application receives consensus data and stores it in the first database
  • the second application extracts the consensus data from the first database, and performs consensus verification
  • the second application adds the verification result to the consensus data and stores it to the first database, and sends the verification result to other consensus nodes to continue the consensus check.
  • a blockchain service receiving device includes a device, a second application, and a database, and the device includes:
  • the receiving module receives the service request sent by the client, and determines corresponding service data to be sent according to the service request;
  • the second application or the sending module sends the service data to be sent from the database to other consensus node storage.
  • a blockchain service consensus device the first consensus node includes a receiving module, a processing sending module, and a first database, and the device includes:
  • the receiving module receives consensus data and stores it in the first database
  • the processing sending module extracts the consensus data from the first database, and performs consensus verification
  • the processing sending module adds the verification result to the consensus data and stores the result to the first database, and sends the verification result to other consensus nodes to continue the consensus verification.
  • the first application, the second application, and the database exist in the consensus node.
  • the database is used to store the business data processed by the first application and the second application, so as to reduce the cache pressure of the consensus node. It can be seen that, by using the method provided by the embodiment of the present application, since the consensus node only needs to determine the service data corresponding to the service request, the service data can be stored in the database and waiting to be sent to other consensus nodes, so the cache occupancy rate of the consensus node is compared. low. The number of services that the consensus node can process in a unit time is increased, thereby improving the efficiency of the consensus node for performing consensus verification and processing the service request.
  • FIG. 1 is a blockchain service acceptance process according to an embodiment of the present application
  • FIG. 2 is a blockchain business consensus process according to an embodiment of the present application
  • FIG. 3 is a schematic structural diagram of a blockchain service receiving apparatus according to an embodiment of the present disclosure.
  • FIG. 4 is a schematic structural diagram of a blockchain service consensus apparatus according to an embodiment of the present disclosure.
  • FIG. 1 is a blockchain consensus process according to an embodiment of the present disclosure.
  • the consensus node includes a first application, a second application, and a database, and specifically includes the following steps:
  • the first application receives a service request sent by the client, and determines corresponding service data to be sent according to the service request.
  • the consensus node may include one or more blockchain applications and a database.
  • the blockchain application can accept the service request and perform consensus verification on the pre-processing block, and the database is used to store the service data determined by the blockchain application (for example, the data generated during the consensus verification process is generated after the service request is accepted). Data, etc.).
  • the consensus node can receive the service request sent by the client and perform subsequent steps according to the service request.
  • the consensus node can receive the service request sent by multiple clients, and perform service processing according to each service request.
  • the consensus node can be a terminal, such as a mobile phone, a tablet, a personal computer, or the like.
  • the consensus node may also be a server, and the server may be a single device or a system composed of multiple devices, for example, a distributed server. This application does not specifically limit the specific node of the consensus node.
  • the first application installed in the consensus node may receive the service request. And in the subsequent step, the first application determines the corresponding business logic according to the service request, and allocates the thread to execute the service.
  • the application installed in the consensus node may also have multiple (for example, the second application), and each application may separately receive the service request sent by different clients, and perform subsequent operations separately.
  • the first application and the second application are included in the consensus node as an example, but there is no limitation that there are more applications in the consensus node.
  • the consensus node may also be a system composed of multiple devices, and each device correspondingly installs a blockchain application, and each device may separately receive service requests sent by different clients through the installed blockchain application, and independently follow up.
  • the consensus node can be regarded as a node that accepts service requests and can initiate consensus in the blockchain network. How the specific consensus nodes are constructed can be configured as needed. For example, when the operating pressure of the consensus node is large and there are often business requests queued for processing, more applications or more devices can be configured for the consensus node.
  • the service processing result may be used as the service data.
  • the first application may also determine that the status of the service data is a pending status. The service data and its corresponding pending status are stored in a database.
  • the first application may add an identifier to be sent for the service data after determining the service data.
  • the service data to which the identifier to be sent is added is stored in the database as the service data to be sent.
  • the second application may determine, according to the identifier to be sent, the service data as the service data to be sent.
  • the present application does not limit the manner in which the consensus node determines the status of the service data. As long as each application or each device in the consensus node can determine the state of the stored service data when accessing the database.
  • the service request sent by the user may carry the identity information of the transaction parties, the transaction amount, and the account information of the paying party.
  • the first application of the consensus node can determine and create a corresponding transaction service according to the data carried in the service request. After determining the service data, the first application adds an identifier to be sent for the service data.
  • the to-be-sent identifier may also be added to the service data as a service attribute in the service data, for example, the structure of the service data shown in Table 1.
  • Business attribute content Business identifier Unique identifier in the blockchain version Service creation blockchain version identifier Timestamp Timestamp when the business was created Business information Specific content of the business Status identifier ID to be sent
  • the status identifier in the structure diagram of the service data shown in Table 1 may be added to the service data by the first application of the consensus node. Through the status identifier, any application in the consensus node can determine that the current status of the service data is the pending status. Then, when the service data is operated, according to the status identifier, it may be determined that the service data needs to be sent to other consensus nodes.
  • the content of the service data specifically included in the embodiment of the present application, and the specific attributes included in the service attribute are not specifically limited.
  • S102 The first application stores the service data to be sent in the database.
  • the service data process to be sent determined in step S101 depends on the cache of the consensus node, so the service data is also stored in the cache.
  • the first application can also dump the business data to the database in the consensus node to free up the cache space for performing other services.
  • the database may be a storage device used by the consensus node for storing data, and may be a storage device using a non-volatile memory.
  • the database and the consensus node may be located in the same device (for example, the database may be located in the hard disk of the personal computer), or may be located in a different device (for example, an external mobile hard disk), which is not specifically limited in this application.
  • each application can separately receive service requests sent by different clients.
  • the respective determined business data is stored in the database.
  • the database can be regarded as a database shared by each application, and each application can have the right to access the database. That is to say, the second application can also determine the service data to be transmitted and store it in the database.
  • each device of the consensus node can access the database, and the database is in the database.
  • the consensus node can be regarded as a storage device shared by each device.
  • the first application of the consensus node stores the service data to be sent in the database, and releases the cache space occupied by the service data for performing other services.
  • This consensus node can accept more service requests without increasing the hardware configuration of the consensus node.
  • the first application of the consensus node may continue to receive the service request sent by other clients. And performing the same operations as step S101 and step S102 (the second application of the same consensus node can also perform the same operations of step S101 and step S102 simultaneously). Therefore, the database corresponding to the consensus node can store a plurality of service data to be sent. In order for other consensus nodes to perform consensus verification normally, the service data stored in the database of the consensus node also needs to be sent to other consensus nodes for storage.
  • the first or second application of the consensus node may also retrieve the service data to be sent from the database and send it to other consensus nodes for storage, so that other consensus nodes may follow the consensus. check. And, for each service data to be sent, after the service data to be sent is sent, the service data to be sent may also be updated as the sent service data.
  • At least one of the first application or the second application in the consensus node may determine whether the preset condition has been met according to the current state of the consensus node. If yes, the first application and/or the second application fetches the service data to be sent and sends, and if not, does not fetch.
  • the current state of the consensus node meets the preset condition when the number of the service data to be sent stored in the database of the consensus node reaches a preset threshold. Or, according to the sending period of the consensus node, when the specified time arrives, it is determined that the preset condition is met, that is, the service data to be sent in the data is periodically retrieved, and the like.
  • the preset conditions can also be set according to actual needs.
  • the preset conditions may also change with time factors and business volume.
  • time e.g, 4:00 to 4 o'clock
  • the interval between fishing data is increased, and when the traffic increases, the fishing amount is reduced.
  • the time interval of the service data and the like are not specifically limited in this application.
  • all the service data to be sent in the database corresponding to the consensus node may be extracted and sent.
  • a specified number of service data to be sent may also be retrieved, which is not specifically limited in this application. Further, the above conditions may be used alternatively or in any combination.
  • the service data to be sent may be retrieved according to the chronological order of the service data to be sent.
  • the collected business data to be sent is sent to other consensus nodes in the order of retrieval.
  • the consensus node may retrieve and send each service data to be sent one by one, or may collect and package each service data to be sent, and then send it to other consensus nodes.
  • first application or the second application may further update the sent service data to be sent to each sent service data.
  • the status corresponding to the service data F in the database may be updated to the sent status.
  • the status identifier in the service attribute of the service data F is updated to the sent identifier. That is to say, the first application can update the status identifier of the service data F when the service data F is called.
  • the first application or the second application may also update the status identifier of the service data according to the response information when receiving the response information for the sent service data returned by the other consensus node.
  • Which method is specifically adopted is not specifically limited in this application.
  • the consensus node can include the first application, the second application, and the database.
  • the database is used to store the business data processed by the first application and the second application, so as to reduce the buffer pressure of the consensus node.
  • the consensus node can continue to receive service requests and accept services even while waiting for the consensus phase, without causing service waiting due to insufficient cache space.
  • the consensus node can expand the number of installed applications as needed. The consensus node can receive and process more service requests at the same time, and improve the working efficiency of the consensus node.
  • the first or second application in the consensus node may be used to retrieve the service data to be sent stored in the database, and send the data to the other consensus node for storage. It can be seen that, by the method provided by the present application, the operating efficiency of the consensus node is no longer limited by the cache size. Moreover, since each application in the consensus node can accept the service request and send the service data, the consensus node can send the service data to be sent through some applications, and the other part applies the service request, and the consensus node is used for the consensus check and the service. The efficiency of requesting processing.
  • the status of the service data may be updated to the sent status, so that the service data received and stored by other consensus nodes is The status has been sent. Therefore, when other consensus nodes perform consensus verification according to the service data, the service data sent by the first or second application is not missed.
  • the first application may also check the service data to be sent according to the hash value of the service data and the specific content of the service data. And after the verification is passed, the business data is stored in the database.
  • step S101 of the present application the consensus node can verify the data required for performing the service processing carried in the service request when determining the service request. Then, after the verification is passed, operations such as subsequent creation of services and business processing are continued. Specifically, the verification process and the implementation details may be consistent with the prior art, and details are not described herein again.
  • the consensus node may return response information corresponding to the service request to the client, so that the client determines that the consensus node has accepted the service request. It should be noted that when the consensus node determines the service data according to the service request, it can be regarded as the consensus node accepting the service request.
  • the execution bodies of the steps of the method provided by the embodiment of the present application may all be the same device, or the method may also be performed by different devices.
  • the execution body of step S101 and step S102 may be device 1
  • the execution body of step S103 may be device 2
  • the execution body of step S101 may be device 1
  • the execution body of step S102 and step S103 may be device 2 ;and many more.
  • the embodiment of the present application further provides a method for the blockchain service consensus, as shown in FIG. 2 .
  • the first consensus node includes a first application, a second application, and a first database, and specifically includes the following steps:
  • S201 The first application receives consensus data and stores it in the first database.
  • the first consensus node includes a first application, a second application, and a first database. Moreover, more applications may be included in the first consensus node, which is not limited in this application. For the convenience of the following description, the first application and the second application are taken as an example in the embodiment of the present application.
  • each consensus node in the blockchain network can determine the consensus node that initiates the consensus according to the consensus mechanism of the blockchain.
  • the first application of the first consensus node can receive the consensus data and store the consensus data in the first database.
  • the consensus node may determine whether to store consensus data according to the verification results of other consensus nodes. For example, in some consensus algorithms, for each consensus node, the consensus node needs to determine whether more than 50% of the consensus node check results in the consensus node of the entire network pass, and if so, the consensus node stores the pre-processing Block, if no, it is not stored.
  • the verification result can also be regarded as a kind of consensus data
  • the consensus data in the present application may include: data that needs to be subjected to consensus verification (usually fast preprocessing) and corresponding verification result.
  • the first application can store the consensus data in the first database.
  • S202 The second application extracts the consensus data from the first database, and performs consensus verification.
  • the second application may extract consensus data from the first database and verify the consensus data for subsequent operations.
  • the second application may obtain consensus data (specifically, a pre-processing block) from the first database, and service data of the sent status in the first database, and perform consensus prediction on the consensus data according to the service data of the sent status. Check and determine the verification result.
  • consensus data specifically, a pre-processing block
  • S203 The second application adds the verification result to the consensus data and stores the result to the first database, and sends the verification result to other consensus nodes to continue the consensus verification.
  • the verification result may be stored in the first database and sent to other consensus nodes to continue the consensus verification.
  • the order in which the second application stores and transmits the verification data is not limited in this application.
  • the consensus mechanism of the blockchain may be a practical Byzantine Fault Tolerance (PBFT), and the consensus nodes in the blockchain network may be according to the formula: ID/M, determines the master node in each consensus node, and the master node initiates a consensus.
  • the consensus node may first determine the current period (ie, View) of the consensus node, and the View ID represents the identifier of the current period determined by the consensus node.
  • the period is identified by a number between 0 and M-1, and M is the total number of consensus nodes in the blockchain network.
  • the second consensus node is the main node and a consensus is initiated
  • the first consensus node is a consensus check of the slave node as an example.
  • the second consensus node includes a third application, a fourth application, and a second database.
  • the third application creates a pre-processing block based on the service data of the sent status in the second database, and stores the pre-processed block in the second database.
  • the fourth application extracts the pre-processing block from the second database and sends it to each consensus node except the second consensus node.
  • the third application of the second consensus node can determine that the second consensus node is the master node by using the current View ID. Then, the third application may extract, from the second database, each sent service data that needs to be consensus according to a pre-set consensus condition.
  • the preset consensus condition may be set according to requirements, and the application does not specifically limit this. For example, the business data for which consensus is selected is selected in chronological order, or each transmitted service data that satisfies the capacity is selected according to the capacity of the pre-processing block, and the like.
  • the third application can create a corresponding pre-processing block according to each of the sent service data. For example, determining the order in which the service data has been sent in the pre-processing block, determining the header hash value of the pre-processing block by Merkle trees, and the like.
  • the process of creating a pre-processing block may be the same as the prior art, which is not specifically limited in this application.
  • the third application can determine the Per-Perpared information corresponding to the pre-processing block according to the first stage of the PBFT three-phase protocol, in the same manner as the prior art, wherein the format of the Per-Perpared information Can be ⁇ Per-Perpared, v, n, d>, where v represents the number of the current View ID, n represents the identity of the pre-processing block, and d is the digest of the pre-processing block.
  • the third application can sign the Per-Perpared information, the Per-Perpared information and the pre-processing block are stored in the second database.
  • the fourth application can extract Per-Perpared information and pre-processing blocks from the database and send them to the consensus nodes except the second consensus node. So that other consensus nodes check the Per-Perpared information. Then, as described in step S201, the first application may receive the Per-Perpared information and the pre-processing block as consensus data, and store it in the first database.
  • the second application may retrieve consensus data from the first database (eg, the second application may retrieve Per-Perpared information and pre-processing blocks) and perform consensus verification. Specifically, the second application may verify the signature of the Per-Perpared information, and determine that the Per-Perpared information is sent by the second consensus node. The digest of the Per-Perpared information is also verified according to the service data in the pre-processing block, and the digest correspondence in the pre-processing block and the Per-Perpared information is determined. At the same time, it is also possible to judge whether the n in the Per-Perpared information meets the preset water mark, and whether the v in the Per-Perpared information is consistent with the v at which the first consensus node is currently located.
  • the second application may retrieve consensus data from the first database (eg, the second application may retrieve Per-Perpared information and pre-processing blocks) and perform consensus verification. Specifically, the second application may verify the signature of the Per-Perpared information, and determine
  • the next phase ie, the second phase
  • the Per-Perpared information can be obtained after the second application verifies the Per-Perpared information.
  • the pre-processing block and the received response information are stored in the first database, and preparation information (Perpared information) is created as a verification result.
  • the format of the Perpared information can be ⁇ Perpared, v, n, d, i>, where i is the identity of the consensus node that created the Perpared information.
  • the second application can also store the Perpared information in the first database.
  • the second application can then send the Perpared information to other consensus nodes to continue the consensus check.
  • other consensus nodes that verify the Per-Perpared information can also broadcast the Perpared information created by itself and then broadcast it.
  • each consensus node in the blockchain network can receive the Perpared information sent by the consensus node that verifies the Per-Perpared information, and for each consensus node, the consensus node can receive the other
  • the Perpared information sent by the consensus node is stored in its own database.
  • the first application of the first consensus node may again receive the verification result sent by other consensus nodes (that is, the Perpared information sent by other consensus nodes), and store it in the first database.
  • the second application may verify the v, n, signature, and digest of each Perpared information stored in the first database.
  • the next stage ie, the third stage
  • the preset number is the same as the prior art, and is determined by the PBFT calculation for the consensus node, and is not described herein again.
  • confirmation information (Commit information) may be created, and Commit information may be sent to other consensus nodes.
  • the third or fourth application of the second consensus node may also send Commit information when determining to perform the third phase.
  • the first application may receive Commit information sent by other consensus nodes and store it in the first database.
  • the Commit information format may be ⁇ Commit, v, n, D, i>, where D is a summary of the pre-processing block created by the consensus node.
  • the second application may verify the v, n, signature, and digest of the Commit information sent by the other consensus nodes stored in the first database, and determine the pre-determination when it is determined that the Commit information of the verification is greater than or equal to the preset quantity.
  • the processing block passes the consensus check.
  • the consensus node in each phase of the three-phase protocol receives data from other consensus nodes, creates information, and the like, and generates data during consensus verification. Stored in the database corresponding to the consensus node.
  • the steps performed by the second application may be performed by the first application, and vice versa.
  • the steps performed by the third application can also be performed by the fourth application, and vice versa.
  • each consensus node since the consensus nodes need to send and receive information of other consensus nodes during the execution of the three-phase protocol, and the information may be transmitted through the network, network delay may occur, so in the three-phase protocol At each stage, each consensus node can wait for a period of time to receive information. Thus, during the execution of the three-phase protocol, the consensus node can store the created and received information in the database first. At the end of each phase of the waiting time, based on the information stored in the database, determine whether to proceed to the next stage.
  • the second consensus node ie, the master node
  • the consensus nodes that receive the Per-Perpared information can create a pre-processing block according to the hash value of each service data. And compare and verify with the pre-processing block sent by the master node.
  • the consensus node is consistent with the prior art when performing consensus verification, and the consensus nodes may also perform verification according to the consensus condition and the consensus node, ie, It is determined whether the primary node sends each service data as service data that can perform consensus verification. If yes, the subsequent consensus verification is continued, and if not, the consensus verification is stopped.
  • the first consensus node includes a first application, a second application, and a first database.
  • the first application receives the consensus data and stores the data in the first database.
  • the second application retrieves the consensus data from the first database and performs consensus verification.
  • the second application adds the verification result to the consensus data and stores it to the first database, and sends the verification result to other consensus nodes to continue the consensus. check.
  • the third application of the second consensus node that initiates the consensus creates the pre-processing block as the consensus data is stored in the second data according to the sent service data stored in the second database, and the fourth application obtains the consensus from the second database.
  • the data is sent to each consensus node other than the second consensus node.
  • the consensus node can use the three-phase protocol of the PBFT to implement the consensus, and store the data generated in each stage in the database, reduce the cache occupancy rate during the consensus check, and improve the cache utilization. This improves the efficiency of the consensus node for consensus checking and processing of business requests.
  • the execution bodies of the steps of the method provided by the embodiment of the present application may all be the same device, or the method may also be performed by different devices.
  • the execution body of step S201 and step S202 may be device 1
  • the execution body of step S203 may be device 2
  • the execution body of step S201 may be device 1
  • the execution body of step S202 and step S203 may be device 2 ;and many more.
  • the embodiment of the present application further provides a blockchain service receiving device, as shown in FIG.
  • FIG. 3 is a schematic structural diagram of a blockchain service receiving apparatus according to an embodiment of the present disclosure, where the consensus node includes the device, a second application, and a database, and the device includes:
  • the receiving module 301 receives a service request sent by the client, and determines corresponding service data to be sent according to the service request;
  • the storage module 302 stores the service data to be sent in the database
  • the second application or sending module 303 extracts the service data to be sent from the database and sends it to other consensus node storage.
  • the storage module 302 determines that the status of the service data to be sent is a to-be-sent state, and stores the service data and its corresponding to-be-sent status in the storage module.
  • the sending module 303 extracts a specified number of service data to be sent from the database.
  • the device also includes:
  • the update module 304 updates the status of the transmitted service data in the database to the sent status.
  • the blockchain service receiving device may be located in the consensus node, and the consensus node may be a terminal.
  • the consensus node can also be a server.
  • a single server or a system consisting of multiple servers.
  • the embodiment of the present application further provides a blockchain service consensus device, as shown in FIG. 4 .
  • the first consensus node includes a first application, the device, and a first database, where the device includes:
  • the receiving module 401 receives the consensus data and stores it in the first database
  • the verification module 402 extracts the consensus data from the first database, and performs consensus verification;
  • the storage sending module 403 adds the verification result to the consensus data and stores it to the first database, and sends the verification result to other consensus nodes to continue the consensus verification.
  • the receiving module 401 receives the consensus data sent by other consensus nodes, or receives the verification result sent by other consensus nodes, as the consensus data.
  • the verification module 402 extracts the consensus data and the service data of the sent status in the first database from the first database, and performs consensus on the consensus data according to the service data of the sent status. Check and determine the verification result.
  • the second consensus node includes a third application, a fourth application, and a second database.
  • the third application determines the consensus data according to the service data of the sent state in the second database.
  • the fourth application extracts the consensus data from the second database, and sends the consensus data to each consensus node except the second consensus node.
  • the consensus check uses the Byzantine fault tolerance algorithm PBFT.
  • a blockchain service receiving apparatus as shown in FIG. 4 may be located in a consensus node, and the consensus node may be a terminal.
  • the consensus node may also be a server.
  • PLD Programmable Logic Device
  • FPGA Field Programmable Gate Array
  • HDL Hardware Description Language
  • the controller can be implemented in any suitable manner, for example, the controller can take the form of, for example, a microprocessor or processor and a computer readable medium storing computer readable program code (eg, software or firmware) executable by the (micro)processor.
  • computer readable program code eg, software or firmware
  • examples of controllers include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, The Microchip PIC18F26K20 and the Silicone Labs C8051F320, the memory controller can also be implemented as part of the memory's control logic.
  • the controller can be logically programmed by means of logic gates, switches, ASICs, programmable logic controllers, and embedding.
  • Such a controller can therefore be considered a hardware component, and the means for implementing various functions included therein can also be considered as a structure within the hardware component.
  • a device for implementing various functions can be considered as a software module that can be both a method of implementation and a structure within a hardware component.
  • the system, device, module or unit illustrated in the above embodiments may be implemented by a computer chip or an entity, or by a product having a certain function.
  • a typical implementation device is a computer.
  • the computer can be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or A combination of any of these devices.
  • embodiments of the present invention can be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment, or a combination of software and hardware. Moreover, the invention can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) including computer usable program code.
  • computer-usable storage media including but not limited to disk storage, CD-ROM, optical storage, etc.
  • the computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing device to operate in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture comprising the instruction device.
  • the apparatus implements the functions specified in one or more blocks of a flow or a flow and/or block diagram of the flowchart.
  • These computer program instructions can also be loaded onto a computer or other programmable data processing device such that a series of operational steps are performed on a computer or other programmable device to produce computer-implemented processing for execution on a computer or other programmable device.
  • the instructions provide steps for implementing the functions specified in one or more of the flow or in a block or blocks of a flow diagram.
  • a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
  • processors CPUs
  • input/output interfaces network interfaces
  • memory volatile and non-volatile memory
  • the memory may include non-persistent memory, random access memory (RAM), and/or non-volatile memory in a computer readable medium, such as read only memory (ROM) or flash memory.
  • RAM random access memory
  • ROM read only memory
  • Memory is an example of a computer readable medium.
  • Computer readable media includes both permanent and non-persistent, removable and non-removable media.
  • Information storage can be implemented by any method or technology.
  • the information can be computer readable instructions, data structures, modules of programs, or other data.
  • Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read only memory. (ROM), electrically erasable programmable read only memory (EEPROM), flash memory or other memory technology, compact disk read only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, Magnetic tape cartridges, magnetic tape storage or other magnetic storage devices or any other non-transportable media can be used to store information that can be accessed by a computing device.
  • computer readable media does not include temporary storage of computer readable media, such as modulated data signals and carrier waves.
  • embodiments of the present application can be provided as a method, system, or computer program product.
  • the present application can take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment in combination of software and hardware.
  • the application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) including computer usable program code.
  • the application can be described in the general context of computer-executable instructions executed by a computer, such as a program module.
  • program modules include routines, programs, objects, components, data structures, and the like that perform particular tasks or implement particular abstract data types.
  • the present application can also be practiced in distributed computing environments where tasks are performed by remote processing devices that are connected through a communication network.
  • program modules can be located in both local and remote computer storage media including storage devices.

Abstract

Disclosed are a block chain service acceptance and consensus method and device. A consensus node comprises a first application, a second application, and a database, and the database is used for storing service data processed by the first application and the second application in order to reduce cache pressure of the consensus node. Hence, based on the method provided by embodiments of the invention, as long as the consensus node determines service data corresponding to a service request, the service data can be stored into the database to wait for being sent to other consensus nodes, so that an occupancy rate of the cache of the consensus node is low, the number of services which can be processed by the consensus node in unit time is increased, and efficiency of carrying out consensus verification on the consensus node and processing the service request can be improved.

Description

一种区块链业务受理及业务共识方法及装置Blockchain business acceptance and business consensus method and device 技术领域Technical field
本申请涉及信息技术领域,尤其涉及一种区块链业务受理及业务共识方法及装置。The present application relates to the field of information technology, and in particular, to a blockchain service acceptance and business consensus method and apparatus.
背景技术Background technique
随着信息技术的发展,区块链技术作为新兴技术,由于具有的开放性、不可篡改性、去中心化等优点,已成为人们重点关注的技术。With the development of information technology, blockchain technology, as an emerging technology, has become a key technology because of its openness, inability to modify, and decentralization.
在现有区块链技术中,区块链网络中的每个共识节点,均可受理客户端发送的业务请求。以一个共识节点为例进行说明,当共识节点接收到业务请求后,可先根据该业务请求,确定对应的业务数据。之后共识节点可将业务数据广播给其他共识节点。当共识节点接收到其他共识节点发送的预处理块后,还可对该预处理快进行共识校验,并可在校验通过后存储该预处理块。In the existing blockchain technology, each consensus node in the blockchain network can accept the service request sent by the client. Taking a consensus node as an example, when the consensus node receives the service request, it can first determine the corresponding service data according to the service request. The consensus node can then broadcast the business data to other consensus nodes. After the consensus node receives the pre-processing block sent by other consensus nodes, the pre-processing can be quickly verified by consensus, and the pre-processing block can be stored after the verification is passed.
其中,共识节点在受理业务请求后,通常将业务请求对应的业务数据存储在该共识节点的缓存中。在后续对业务数据进行共识校验通过后,从缓存中释放该业务数据。类似的,对于其他共识节点发送的业务数据,也可同样存储在缓存中,并在通过共识校验后释放。After the service node receives the service request, the consensus node generally stores the service data corresponding to the service request in the cache of the consensus node. After the subsequent verification of the service data is passed, the service data is released from the cache. Similarly, the service data sent by other consensus nodes can also be stored in the cache and released after passing the consensus check.
对于共识节点来说,未存储在区块链中的数据通常均暂存在共识节点的缓存中,导致进行共识校验时,可校验的业务数据的数量受该共识节点缓存容量的限制,使得共识校验的效率受限。并且,当共识节点的缓存空间不足时,共识节点也难以对接收到的业务请求进行处理。For the consensus node, the data that is not stored in the blockchain is temporarily stored in the cache of the consensus node. When the consensus check is performed, the number of service data that can be verified is limited by the cache capacity of the consensus node. The efficiency of consensus verification is limited. Moreover, when the cache space of the consensus node is insufficient, the consensus node is also difficult to process the received service request.
发明内容Summary of the invention
本申请实施例提供一种区块链业务受理及业务共识方法,用于解决在现有区块链技术中业务执行效率低的问题。The embodiment of the present application provides a blockchain service acceptance and service consensus method, which is used to solve the problem of low efficiency of service execution in the existing blockchain technology.
本申请实施例提供一种区块链业务受理及业务共识装置,用于解决在现有区块链技术中业务执行效率低的问题。The embodiment of the present application provides a blockchain service acceptance and service consensus device, which is used to solve the problem of low efficiency of service execution in the existing blockchain technology.
本申请实施例采用下述技术方案:The embodiments of the present application adopt the following technical solutions:
一种区块链业务受理方法,共识节点中包括第一应用、第二应用以及数据库,包括:A blockchain service acceptance method includes a first application, a second application, and a database, including:
所述第一应用接收客户端发送的业务请求,并根据该业务请求确定对应的待发送的业务数据;Receiving, by the first application, a service request sent by the client, and determining corresponding service data to be sent according to the service request;
所述第一应用将所述待发送的业务数据存储在所述数据库中;The first application stores the service data to be sent in the database;
当满足预设条件时,所述第二应用或者所述第一应用,从所述数据库中捞取待发送的业务数据发送至其他共识节点存储。When the preset condition is met, the second application or the first application sends the service data to be sent from the database to other consensus node storage.
一种区块链业务共识方法,第一共识节点中包括第一应用、第二应用以及第一数据库,包括:A blockchain business consensus method, the first consensus node includes a first application, a second application, and a first database, including:
所述第一应用接收共识数据,并存储在所述第一数据库中;The first application receives consensus data and stores it in the first database;
所述第二应用从所述第一数据库中捞取所述共识数据,进行共识校验;The second application extracts the consensus data from the first database, and performs consensus verification;
所述第二应用将校验结果添加到所述共识数据中并存储至所述第一数据库,并将所述校验结果发送至其他共识节点继续进行共识校验。The second application adds the verification result to the consensus data and stores it to the first database, and sends the verification result to other consensus nodes to continue the consensus check.
一种区块链业务受理装置,共识节点中包括所述装置,第二应用以及数据库,所述装置包括:A blockchain service receiving device includes a device, a second application, and a database, and the device includes:
接收模块,接收客户端发送的业务请求,并根据该业务请求确定对应的待发送的业务数据;The receiving module receives the service request sent by the client, and determines corresponding service data to be sent according to the service request;
存储模块,将所述待发送的业务数据存储在所述数据库中;a storage module, where the service data to be sent is stored in the database;
当满足预设条件时,所述第二应用或者发送模块,从所述数据库中捞取待发送的业务数据发送至其他共识节点存储。When the preset condition is met, the second application or the sending module sends the service data to be sent from the database to other consensus node storage.
一种区块链业务共识装置,第一共识节点中包括接收模块、处理发送模块以及第一数据库,所述装置包括:A blockchain service consensus device, the first consensus node includes a receiving module, a processing sending module, and a first database, and the device includes:
所述接收模块,接收共识数据,并存储在所述第一数据库中;The receiving module receives consensus data and stores it in the first database;
所述处理发送模块,从所述第一数据库中捞取所述共识数据,进行共识校验;The processing sending module extracts the consensus data from the first database, and performs consensus verification;
所述处理发送模块,将校验结果添加到所述共识数据中并存储至所述第一数据库,并将所述校验结果发送至其他共识节点继续进行共识校验。The processing sending module adds the verification result to the consensus data and stores the result to the first database, and sends the verification result to other consensus nodes to continue the consensus verification.
本申请实施例采用的上述至少一个技术方案能够达到以下有益效果:The above at least one technical solution adopted by the embodiment of the present application can achieve the following beneficial effects:
共识节点中存在第一应用、第二应用以及数据库。该数据库用于存储由第一应用以及第二应用处理后的业务数据,以便减少共识节点的缓存压力。可见,通过本申请实施例提供的方法,由于共识节点只要确定业务请求对应的业务数据,便可将该业务数据存储在数据库中,等待发送给其他共识节点,所以共识节点的缓存的占用率较低。使得共识节点在单位时间内可处理的业务的数量增加,从而提高了共识节点进行共识校验以及对业务请求进行处理的效率。The first application, the second application, and the database exist in the consensus node. The database is used to store the business data processed by the first application and the second application, so as to reduce the cache pressure of the consensus node. It can be seen that, by using the method provided by the embodiment of the present application, since the consensus node only needs to determine the service data corresponding to the service request, the service data can be stored in the database and waiting to be sent to other consensus nodes, so the cache occupancy rate of the consensus node is compared. low. The number of services that the consensus node can process in a unit time is increased, thereby improving the efficiency of the consensus node for performing consensus verification and processing the service request.
附图说明DRAWINGS
此处所说明的附图用来提供对本申请的进一步理解,构成本申请的一部分,本申请的示意性实施例及其说明用于解释本申请,并不构成对本申请的不当限定。在附图中:The drawings described herein are intended to provide a further understanding of the present application, and are intended to be a part of this application. In the drawing:
图1为本申请实施例提供的一种区块链业务受理过程;FIG. 1 is a blockchain service acceptance process according to an embodiment of the present application;
图2为本申请实施例提供的一种区块链业务共识过程;FIG. 2 is a blockchain business consensus process according to an embodiment of the present application;
图3为本申请实施例提供的一种区块链业务受理装置的结构示意图;FIG. 3 is a schematic structural diagram of a blockchain service receiving apparatus according to an embodiment of the present disclosure;
图4为本申请实施例提供的一种区块链业务共识装置的结构示意图。FIG. 4 is a schematic structural diagram of a blockchain service consensus apparatus according to an embodiment of the present disclosure.
具体实施方式detailed description
为使本申请的目的、技术方案和优点更加清楚,下面将结合本申请具体实施例及相应的附图对本申请技术方案进行清楚、完整地描述。显然,所描述的实施例仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施 例,都属于本申请保护的范围。The technical solutions of the present application will be clearly and completely described in the following with reference to the specific embodiments of the present application and the corresponding drawings. It is apparent that the described embodiments are only a part of the embodiments of the present application, and not all of them. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments of the present application without departing from the inventive scope are the scope of the present application.
以下结合附图,详细说明本申请各实施例提供的技术方案。The technical solutions provided by the embodiments of the present application are described in detail below with reference to the accompanying drawings.
图1为本申请实施例提供的一种区块链共识过程,其中,共识节点中包括第一应用、第二应用以及数据库,具体可包括以下步骤:FIG. 1 is a blockchain consensus process according to an embodiment of the present disclosure. The consensus node includes a first application, a second application, and a database, and specifically includes the following steps:
S101:所述第一应用接收客户端发送的业务请求,并根据业务请求确定对应的待发送的业务数据。S101: The first application receives a service request sent by the client, and determines corresponding service data to be sent according to the service request.
在本申请实施例中,对于区块链网络中的各共识节点,共识节点中可以包含一个或者多个区块链应用以及数据库。其中,区块链应用可受理业务请求并对预处理块进行共识校验,数据库用于存储区块链应用确定的业务数据(如,进行共识校验过程中产生的数据、受理业务请求后产生的数据等等)。In the embodiment of the present application, for each consensus node in the blockchain network, the consensus node may include one or more blockchain applications and a database. The blockchain application can accept the service request and perform consensus verification on the pre-processing block, and the database is used to store the service data determined by the blockchain application (for example, the data generated during the consensus verification process is generated after the service request is accepted). Data, etc.).
进一步地,用户通常需要通过客户端发送指令或者请求。后续,共识节点可接收客户端发送的业务请求,并根据业务请求执行后续的步骤。Further, the user usually needs to send an instruction or request through the client. Subsequently, the consensus node can receive the service request sent by the client and perform subsequent steps according to the service request.
其中,共识节点可接收多个客户端发送的业务请求,并根据各业务请求进行业务处理。该共识节点可以是终端,例如,手机、平板电脑、个人电脑等设备。该共识节点也可以是服务器,并且该服务器可以是单独的一台设备,也可以是由多台设备组成的系统,例如,分布式服务器。本申请对共识节点具体为何种设备不做具体限定。The consensus node can receive the service request sent by multiple clients, and perform service processing according to each service request. The consensus node can be a terminal, such as a mobile phone, a tablet, a personal computer, or the like. The consensus node may also be a server, and the server may be a single device or a system composed of multiple devices, for example, a distributed server. This application does not specifically limit the specific node of the consensus node.
具体的,在共识节点接收业务请求时,可以是共识节点中安装的第一应用接收业务请求。并且在后续步骤中,由第一应用根据业务请求确定对应的业务逻辑,并分配线程执行业务。当然,在共识节点中安装的应用程序还可以有多个(如,第二应用),则各应用程序可分别接收不同客户端发送的业务请求,并分别进行后续操作。为方便描述,在本申请实施例中,仅以共识节点中包含第一应用以及第二应用为例进行说明,但并不限制共识节点中存在更多的应用。Specifically, when the consensus node receives the service request, the first application installed in the consensus node may receive the service request. And in the subsequent step, the first application determines the corresponding business logic according to the service request, and allocates the thread to execute the service. Certainly, the application installed in the consensus node may also have multiple (for example, the second application), and each application may separately receive the service request sent by different clients, and perform subsequent operations separately. For convenience of description, in the embodiment of the present application, only the first application and the second application are included in the consensus node as an example, but there is no limitation that there are more applications in the consensus node.
进一步地,共识节点也可以由多台设备组成的系统,并且每台设备对应安装区块链应用,则各设备可通过安装的区块链应用分别接收不同客户端发送的业务请求,并独立的进行后续操作。Further, the consensus node may also be a system composed of multiple devices, and each device correspondingly installs a blockchain application, and each device may separately receive service requests sent by different clients through the installed blockchain application, and independently Follow up.
另外,无论共识节点中安装多个应用程序还是由多个设备组成,该共识节点在区块链网络中可视为是一个受理业务请求并可发起共识的节点。具体的共识节点如何构成,可由根据需要进行配置。例如,当共识节点的运行压力较大,经常有业务请求排队等待处理时,可为共识节点配置更多的应用或者配置更多的设备。In addition, regardless of whether multiple applications are installed in the consensus node or composed of multiple devices, the consensus node can be regarded as a node that accepts service requests and can initiate consensus in the blockchain network. How the specific consensus nodes are constructed can be configured as needed. For example, when the operating pressure of the consensus node is large and there are often business requests queued for processing, more applications or more devices can be configured for the consensus node.
更进一步地,在本申请实施例中,第一应用在对接收的业务请求进行业务处理后,可将业务处理结果作为业务数据。并且,由于该业务数据尚未发送至其他共识节点,所以第一应用还可以确定该业务数据的状态为待发送状态。并将该业务数据及其对应的待发送状态存储在数据库中。Further, in the embodiment of the present application, after the first application applies the service processing to the received service request, the service processing result may be used as the service data. Moreover, since the service data has not been sent to other consensus nodes, the first application may also determine that the status of the service data is a pending status. The service data and its corresponding pending status are stored in a database.
或者,第一应用可以在确定业务数据之后,为该业务数据添加待发送标识。再将添加了待发送标识的业务数据,作为待发送的业务数据存储在数据库中。则第二应用可以根据待发送标识确定该业务数据为待发送的业务数据。Alternatively, the first application may add an identifier to be sent for the service data after determining the service data. The service data to which the identifier to be sent is added is stored in the database as the service data to be sent. The second application may determine, according to the identifier to be sent, the service data as the service data to be sent.
本申请并不限定共识节点确定业务数据的状态的方式,只要共识节点中的各应用或者各设备,在访问数据库时可以确定存储的业务数据的状态即可。The present application does not limit the manner in which the consensus node determines the status of the service data. As long as each application or each device in the consensus node can determine the state of the stored service data when accessing the database.
例如,若用户要进行交易业务,用户发送的业务请求中可携带有交易双方的身份信息、交易金额、支出方的账号信息等数据。共识节点的第一应用可以根据业务请求中携带的数据,确定并创建对应的交易业务。第一应用在确定业务数据之后,为该业务数据添加待发送的标识。For example, if the user wants to conduct a transaction service, the service request sent by the user may carry the identity information of the transaction parties, the transaction amount, and the account information of the paying party. The first application of the consensus node can determine and create a corresponding transaction service according to the data carried in the service request. After determining the service data, the first application adds an identifier to be sent for the service data.
其中,待发送标识也可作为业务数据中的一种业务属性被添加在业务数据中,例如,表1所示的业务数据的结构示意。The to-be-sent identifier may also be added to the service data as a service attribute in the service data, for example, the structure of the service data shown in Table 1.
业务属性Business attribute 内容content
业务标识Business identifier 在区块链中的唯一标识Unique identifier in the blockchain
版本version 业务创建时区块链版本标识Service creation blockchain version identifier
时间戳Timestamp 业务创建时的时间戳Timestamp when the business was created
业务信息Business information 业务的具体内容Specific content of the business
状态标识Status identifier 待发送的标识ID to be sent
表1Table 1
在表1所示的业务数据的结构示意中的状态标识,可以是由共识节点的第一应用添加在业务数据中的。通过状态标识,共识节点中的任一应用可以确定该业务数据当前的状态为待发送状态。则下一步在对业务数据进行操作时,根据该状态标识可确定需要将该业务数据发送至其他共识节点。The status identifier in the structure diagram of the service data shown in Table 1 may be added to the service data by the first application of the consensus node. Through the status identifier, any application in the consensus node can determine that the current status of the service data is the pending status. Then, when the service data is operated, according to the status identifier, it may be determined that the service data needs to be sent to other consensus nodes.
当然,在本申请实施例中业务数据具体包括哪些内容,以及业务属性中具体包括哪些属性本申请并不做具体限定。Certainly, the content of the service data specifically included in the embodiment of the present application, and the specific attributes included in the service attribute are not specifically limited.
S102:所述第一应用将所述待发送的业务数据存储在所述数据库中。S102: The first application stores the service data to be sent in the database.
在本申请实施例中,步骤S101中确定的待发送的业务数据过程依赖于共识节点的缓存,所以该业务数据也存储在缓存中。于是,第一应用还可将该业务数据转存至该在共识节点的数据库中,以释放缓存空间用于执行其他业务。In the embodiment of the present application, the service data process to be sent determined in step S101 depends on the cache of the consensus node, so the service data is also stored in the cache. Thus, the first application can also dump the business data to the database in the consensus node to free up the cache space for performing other services.
具体的,数据库可以是共识节点用于存储数据的存储设备,并且可以是采用非易失性存储器的存储设备。当然,数据库与共识节点可以位于同一台设备内(如,数据库可以位于个人电脑的硬盘中),也可以位于不同的设备内(如,外接移动硬盘),本申请对此并不做具体限定。Specifically, the database may be a storage device used by the consensus node for storing data, and may be a storage device using a non-volatile memory. Of course, the database and the consensus node may be located in the same device (for example, the database may be located in the hard disk of the personal computer), or may be located in a different device (for example, an external mobile hard disk), which is not specifically limited in this application.
另外,当共识节点中安装有多个区块链应用时,各应用可分别接收不同客户端发送的业务请求。并将各自分别确定的业务数据存储在数据库中。则数据库可视为是各应用共用的数据库,各应用均可具有访问数据库的权限。也就是说,第二应用也可确定待发送的业务数据并存储在数据库中。In addition, when multiple blockchain applications are installed in the consensus node, each application can separately receive service requests sent by different clients. The respective determined business data is stored in the database. The database can be regarded as a database shared by each application, and each application can have the right to access the database. That is to say, the second application can also determine the service data to be transmitted and store it in the database.
进一步地,由于在步骤S101中所述的,共识节点可以是由多台设备组成的系统,所以当共识节点为多台设备组成的系统时,共识节点的各设备均可访问数据库,该数据库在共识节点内可视为是各设备共享的存储设备。Further, since the consensus node may be a system composed of multiple devices, in the step S101, when the consensus node is a system composed of multiple devices, each device of the consensus node can access the database, and the database is in the database. The consensus node can be regarded as a storage device shared by each device.
于是,共识节点的第一应用通过将待发送的业务数据存储在数据库中,释放业务数据占用的缓存空间,用于执行其他业务。使得在不增加共识节点的硬件配置的情况下,该共识节点可以受理更多的业务请求。Therefore, the first application of the consensus node stores the service data to be sent in the database, and releases the cache space occupied by the service data for performing other services. This consensus node can accept more service requests without increasing the hardware configuration of the consensus node.
S103:当满足预设条件时,所述第二应用或者所述第一应用,从所述数据 库中捞取待发送的业务数据发送至其他共识节点存储。S103: When the preset condition is met, the second application or the first application sends the service data to be sent from the database to other consensus node storage.
在本申请实施例中,共识节点的第一应用在将待发送的业务数据存储在数据库中后,共识节点的第一应用可继续接收其他客户端发送的业务请求。并执行如步骤S101以及步骤S102相同的操作(同理共识节点的第二应用也可以同步执行步骤S101以及步骤S102相同的操作)。于是,共识节点对应的数据库中可存储若干待发送的业务数据。为了使其他共识节点正常进行共识校验,该共识节点的数据库中存储的业务数据还需要发送至其他共识节点中进行存储。In the embodiment of the present application, after the first application of the consensus node stores the service data to be sent in the database, the first application of the consensus node may continue to receive the service request sent by other clients. And performing the same operations as step S101 and step S102 (the second application of the same consensus node can also perform the same operations of step S101 and step S102 simultaneously). Therefore, the database corresponding to the consensus node can store a plurality of service data to be sent. In order for other consensus nodes to perform consensus verification normally, the service data stored in the database of the consensus node also needs to be sent to other consensus nodes for storage.
于是,在本申请实施例中,当满足预先条件时,还可由共识节点的第一或者第二应用从数据库中,捞取待发送的业务数据发送至其他共识节点存储,以便其他共识节点后续进行共识校验。并且,针对每个待发送的业务数据,当待发送的业务数据被发送之后,还可更新待发送的业务数据为已发送的业务数据。Therefore, in the embodiment of the present application, when the pre-condition is met, the first or second application of the consensus node may also retrieve the service data to be sent from the database and send it to other consensus nodes for storage, so that other consensus nodes may follow the consensus. check. And, for each service data to be sent, after the service data to be sent is sent, the service data to be sent may also be updated as the sent service data.
具体的,共识节点中的第一应用或者第二应用中的至少一个,可以根据该共识节点当前的状态,判断是否已经满足预设的条件。若是,则第一应用和/或第二应用捞取各待发送的业务数据并发送,若否,则不捞取。Specifically, at least one of the first application or the second application in the consensus node may determine whether the preset condition has been met according to the current state of the consensus node. If yes, the first application and/or the second application fetches the service data to be sent and sends, and if not, does not fetch.
其中,当共识节点的数据库中存储的待发送的业务数据的数量达到预设阈值时,确定共识节点当前的状态满足预设的条件。或者,根据共识节点的发送周期,当指定时刻到达时确定满足预设的条件,即,周期性的捞取数据中的各待发送的业务数据,等等。The current state of the consensus node meets the preset condition when the number of the service data to be sent stored in the database of the consensus node reaches a preset threshold. Or, according to the sending period of the consensus node, when the specified time arrives, it is determined that the preset condition is met, that is, the service data to be sent in the data is periodically retrieved, and the like.
当然,预设的条件也可根据实际需要进行设置。如,预设的条件也可以随着时间因素以及业务量的变化而变化,当时间为夜间时(如,24点至4点)增加捞取业务数据的间隔时间,当业务量增加时减少捞取的业务数据的时间间隔等等,本申请对此不做具体限定。Of course, the preset conditions can also be set according to actual needs. For example, the preset conditions may also change with time factors and business volume. When the time is night (eg, 4:00 to 4 o'clock), the interval between fishing data is increased, and when the traffic increases, the fishing amount is reduced. The time interval of the service data and the like are not specifically limited in this application.
另外,当第一应用或者第二应用在捞取各待发送的业务数据时,可以将共识节点对应的数据库中的各待发送的业务数据全部捞取并发送。也可以捞取指定数量的待发送的业务数据,本申请不做具体限定。并且,上述条件可以择一使用,或者任意组合使用。In addition, when the first application or the second application is capturing the service data to be sent, all the service data to be sent in the database corresponding to the consensus node may be extracted and sent. A specified number of service data to be sent may also be retrieved, which is not specifically limited in this application. Further, the above conditions may be used alternatively or in any combination.
进一步地,第一应用或者第二应用在从数据库中捞取待发送的业务数据时,可以根据各待发送的业务数据的生成时间先后顺序,捞取各待发送的业务数据。并将捞取的各待发送的业务数据按照捞取的先后顺序发送至其他共识节点。具体的,共识节点可以逐一捞取并发送各待发送的业务数据,也可将捞取各待发送的业务数据并打包之后,再一并发送至其他共识节点。Further, when the first application or the second application extracts the service data to be sent from the database, the service data to be sent may be retrieved according to the chronological order of the service data to be sent. The collected business data to be sent is sent to other consensus nodes in the order of retrieval. Specifically, the consensus node may retrieve and send each service data to be sent one by one, or may collect and package each service data to be sent, and then send it to other consensus nodes.
更进一步地,第一应用或者第二应用还可将发送后的各待发送的业务数据,更新为各已发送的业务数据。Further, the first application or the second application may further update the sent service data to be sent to each sent service data.
例如,第一应用从数据库中捞取业务数据F并发送后,可以将数据库中业务数据F对应的状态更新为已发送状态。或者,将业务数据F的业务属性中的状态标识,更新为已发送的标识。也就是说,第一应用可以在调用业务数据F时,便更新业务数据F的状态标识。For example, after the first application retrieves the service data F from the database and sends it, the status corresponding to the service data F in the database may be updated to the sent status. Alternatively, the status identifier in the service attribute of the service data F is updated to the sent identifier. That is to say, the first application can update the status identifier of the service data F when the service data F is called.
当然,由于网络延时或者设备故障等问题,所以可能出现业务数据发送失败的情况。于是,在本申请实施例中,第一应用或者第二应用也可以在接收到其他共识节点返回的针对发送的业务数据的响应信息时,再根据响应信息更新该业务数据的状态标识。具体采用何种方法本申请对此不做具体限定。Of course, due to problems such as network delay or device failure, service data transmission failure may occur. Therefore, in the embodiment of the present application, the first application or the second application may also update the status identifier of the service data according to the response information when receiving the response information for the sent service data returned by the other consensus node. Which method is specifically adopted is not specifically limited in this application.
基于图1所示的区块链业务受理方法,可见共识节点中可包括第一应用、第二应用以及数据库。该数据库用于存储第一应用以及第二应用进行业务处理后的业务数据,以便减少共识节点的缓存压力。共识节点即使在等待共识阶段也可以持续接收业务请求以及受理业务,而不会因为缓存空间不足而造成业务等待。同时,由于业务数据均存储在数据库中,所以共识节点可以根据需要扩展安装的应用数量。使得共识节点可以同时接收处理更多的业务请求,提高共识节点的工作效率。并且,当满足预设条件时,可由共识节点中第一或者第二应用,捞取数据库中存储的待发送的业务数据,并发送至其他共识节点存储。可见,通过本申请提供的方法,共识节点的运行效率不再受限于缓存大小。并且,由于共识节点中各应用都可以受理业务请求、发送业务数据,使得共识节点可以通过部分应用发送待发送的业务数据,同时另一部分应用受理业务请求, 提高共识节点进行共识校验以及对业务请求进行处理的效率。Based on the blockchain service acceptance method shown in FIG. 1, it can be seen that the consensus node can include the first application, the second application, and the database. The database is used to store the business data processed by the first application and the second application, so as to reduce the buffer pressure of the consensus node. The consensus node can continue to receive service requests and accept services even while waiting for the consensus phase, without causing service waiting due to insufficient cache space. At the same time, since the business data is stored in the database, the consensus node can expand the number of installed applications as needed. The consensus node can receive and process more service requests at the same time, and improve the working efficiency of the consensus node. Moreover, when the preset condition is met, the first or second application in the consensus node may be used to retrieve the service data to be sent stored in the database, and send the data to the other consensus node for storage. It can be seen that, by the method provided by the present application, the operating efficiency of the consensus node is no longer limited by the cache size. Moreover, since each application in the consensus node can accept the service request and send the service data, the consensus node can send the service data to be sent through some applications, and the other part applies the service request, and the consensus node is used for the consensus check and the service. The efficiency of requesting processing.
另外,在本申请实施例中,该第一或第二应用在发送待发送的业务数据时,可以先将该业务数据的状态更新为已发送状态,使得其他共识节点接收并存储的业务数据处于已发送状态。以使得其他共识节点在根据业务数据进行共识校验时,不会遗漏该第一或第二应用发送的业务数据。In addition, in the embodiment of the present application, when the first or second application sends the service data to be sent, the status of the service data may be updated to the sent status, so that the service data received and stored by other consensus nodes is The status has been sent. Therefore, when other consensus nodes perform consensus verification according to the service data, the service data sent by the first or second application is not missed.
进一步地,在本申请实施例中,第一应用在接收到其他共识节点发送的业务数据之后,也可根据业务数据的哈希值以及业务数据的具体内容,对待发送的业务数据进行校验。并且在校验通过后,再将业务数据作为存储在数据库。Further, in the embodiment of the present application, after receiving the service data sent by other consensus nodes, the first application may also check the service data to be sent according to the hash value of the service data and the specific content of the service data. And after the verification is passed, the business data is stored in the database.
更进一步的,在本申请步骤S101中,与现有技术相同,共识节点在确定业务请求时,可对业务请求中携带的进行业务处理所需的数据进行校验。并且,在校验通过之后,继续进行后续创建业务、进行业务处理等操作。具体的,校验过程以及实施细节可与现有技术中一致,本申请不再赘述。Further, in step S101 of the present application, as in the prior art, the consensus node can verify the data required for performing the service processing carried in the service request when determining the service request. Then, after the verification is passed, operations such as subsequent creation of services and business processing are continued. Specifically, the verification process and the implementation details may be consistent with the prior art, and details are not described herein again.
另外,在本申请实施例中,共识节点在确定待发送的业务数据之后,便可向客户端返回对应于业务请求的响应信息,以使得客户端确定共识节点已经受理了业务请求。需要说明的是,当共识节点根据业务请求确定了业务数据时,便可视为共识节点受理了业务请求。In addition, in the embodiment of the present application, after determining the service data to be sent, the consensus node may return response information corresponding to the service request to the client, so that the client determines that the consensus node has accepted the service request. It should be noted that when the consensus node determines the service data according to the service request, it can be regarded as the consensus node accepting the service request.
需要说明的是,本申请实施例所提供方法的各步骤的执行主体均可以是同一设备,或者,该方法也由不同设备作为执行主体。比如,步骤S101和步骤S102的执行主体可以为设备1,步骤S103的执行主体可以为设备2;又比如,步骤S101的执行主体可以为设备1,步骤S102和步骤S103的执行主体可以为设备2;等等。It should be noted that the execution bodies of the steps of the method provided by the embodiment of the present application may all be the same device, or the method may also be performed by different devices. For example, the execution body of step S101 and step S102 may be device 1, and the execution body of step S103 may be device 2; for example, the execution body of step S101 may be device 1, and the execution body of step S102 and step S103 may be device 2 ;and many more.
基于图1所示区块链业务受理方法,本申请实施例还对应提供一种区块链业务共识的方法,如图2所示。Based on the blockchain service acceptance method shown in FIG. 1, the embodiment of the present application further provides a method for the blockchain service consensus, as shown in FIG. 2 .
图2为本申请实施例提供的一种区块链业务共识的过程,其中,第一共识节点中包括第一应用、第二应用以及第一数据库,具体包括以下步骤:2 is a process of a blockchain service consensus process according to an embodiment of the present disclosure, where the first consensus node includes a first application, a second application, and a first database, and specifically includes the following steps:
S201:所述第一应用接收共识数据,并存储在所述第一数据库中。S201: The first application receives consensus data and stores it in the first database.
在本申请实施例中,与图1所示的区块链业务受理过程中所述的共识节点类似,第一共识节点包括第一应用、第二应用以及第一数据库。并且,第一共识节点中也可包含更多的应用,本申请对此不做限定。但为方便后续描述,在本申请实施例中以第一应用、第二应用为例进行说明。In the embodiment of the present application, similar to the consensus node described in the blockchain service acceptance process shown in FIG. 1, the first consensus node includes a first application, a second application, and a first database. Moreover, more applications may be included in the first consensus node, which is not limited in this application. For the convenience of the following description, the first application and the second application are taken as an example in the embodiment of the present application.
通常,区块链网络中的各共识节点可以根据区块链的共识机制,确定发起共识的共识节点。于是,第一共识节点的第一应用可接收共识数据,并将共识数据存储在第一数据库中。Generally, each consensus node in the blockchain network can determine the consensus node that initiates the consensus according to the consensus mechanism of the blockchain. Thus, the first application of the first consensus node can receive the consensus data and store the consensus data in the first database.
另外,在某些共识算法中,共识节点可根据其他共识节点的校验结果,确定是否存储共识数据。例如,在一些共识算法中,对每个共识节点来说,该共识节点需要判断全网的共识节点中是否有超过50%的共识节点校验结果为通过,若是,则该共识节点存储预处理块,若否,则不存储。In addition, in some consensus algorithms, the consensus node may determine whether to store consensus data according to the verification results of other consensus nodes. For example, in some consensus algorithms, for each consensus node, the consensus node needs to determine whether more than 50% of the consensus node check results in the consensus node of the entire network pass, and if so, the consensus node stores the pre-processing Block, if no, it is not stored.
于是,校验结果也可以视为是一种共识数据,则本申请中共识数据可以包括:需要进行共识校验的数据(通常为预处理快)以及对应的校验结果。Therefore, the verification result can also be regarded as a kind of consensus data, and the consensus data in the present application may include: data that needs to be subjected to consensus verification (usually fast preprocessing) and corresponding verification result.
当然,无论第一应用接收到何种形式的共识数据,第一应用均可将共识数据存储在第一数据库中。Of course, regardless of the form of consensus data received by the first application, the first application can store the consensus data in the first database.
S202:所述第二应用从所述第一数据库中捞取所述共识数据,进行共识校验。S202: The second application extracts the consensus data from the first database, and performs consensus verification.
在本申请实施例中,第二应用可从第一数据库中,捞取共识数据并对共识数据进行校验,以进行后续操作。In the embodiment of the present application, the second application may extract consensus data from the first database and verify the consensus data for subsequent operations.
具体的,第二应用可以从第一数据库中捞取共识数据(具体可以是预处理块)以及第一数据库中的已发送状态的业务数据,根据已发送状态的业务数据,对共识数据进行共识校验,并确定校验结果。Specifically, the second application may obtain consensus data (specifically, a pre-processing block) from the first database, and service data of the sent status in the first database, and perform consensus prediction on the consensus data according to the service data of the sent status. Check and determine the verification result.
S203:所述第二应用将校验结果添加到所述共识数据中并存储至所述第一数据库,并将所述校验结果发送至其他共识节点继续进行共识校验。S203: The second application adds the verification result to the consensus data and stores the result to the first database, and sends the verification result to other consensus nodes to continue the consensus verification.
在本申请实施例中,当第二应用确定了校验结果之后,便可将校验结果存储在第一数据库中,并发送至其他共识节点继续进行共识校验。其中,第二应 用存储校及发送校验数据的先后顺序本申请并不限定。In the embodiment of the present application, after the second application determines the verification result, the verification result may be stored in the first database and sent to other consensus nodes to continue the consensus verification. The order in which the second application stores and transmits the verification data is not limited in this application.
另外,在本申请实施例步骤S201~步骤S203中,区块链的共识机制可以是实用拜占庭容错算法(Practical Byzantine Fault Tolerance,PBFT),则区块链网络中的各共识节点可以根据公式:View ID/M,确定各共识节点中的主节点,并且由主节点发起共识。针对每个共识节点,共识节点可先确定共识节点当前所处的周期(即,View),View ID表示共识节点确定的当期周期的标识。通常周期的标识为0至M-1之间的数字,M表示在区块链网络中的共识节点的总个数。In addition, in step S201 to step S203 of the embodiment of the present application, the consensus mechanism of the blockchain may be a practical Byzantine Fault Tolerance (PBFT), and the consensus nodes in the blockchain network may be according to the formula: ID/M, determines the master node in each consensus node, and the master node initiates a consensus. For each consensus node, the consensus node may first determine the current period (ie, View) of the consensus node, and the View ID represents the identifier of the current period determined by the consensus node. Usually the period is identified by a number between 0 and M-1, and M is the total number of consensus nodes in the blockchain network.
具体的,以第二共识节点为主节点并发起共识,第一共识节点为从节点进行共识校验为例进行说明。其中,第二共识节点中包括第三应用、第四应用以及第二数据库。第三应用根据第二数据库中已发送状态的业务数据创建预处理块,并将预处理块存储在第二数据库中。第四应用从第二数据库中捞取预处理块,并发送至除第二共识节点以外的各共识节点。Specifically, the second consensus node is the main node and a consensus is initiated, and the first consensus node is a consensus check of the slave node as an example. The second consensus node includes a third application, a fourth application, and a second database. The third application creates a pre-processing block based on the service data of the sent status in the second database, and stores the pre-processed block in the second database. The fourth application extracts the pre-processing block from the second database and sends it to each consensus node except the second consensus node.
首先,第二共识节点的第三应用通过当前所处的View ID,可确定该第二共识节点为主节点。则第三应用可根据预先设置的共识条件,从第二数据库中捞取需要进行共识的各已发送的业务数据。其中,预设的共识条件可以是根据需求设置的,本申请对此不做具体限定。例如,按照时间顺序选择进行共识的业务数据,或者按照预处理块的容量,选择满足容量的各已发送的业务数据,等等。First, the third application of the second consensus node can determine that the second consensus node is the master node by using the current View ID. Then, the third application may extract, from the second database, each sent service data that needs to be consensus according to a pre-set consensus condition. The preset consensus condition may be set according to requirements, and the application does not specifically limit this. For example, the business data for which consensus is selected is selected in chronological order, or each transmitted service data that satisfies the capacity is selected according to the capacity of the pre-processing block, and the like.
其次,第三应用可根据捞取的各已发送的业务数据,创建对应的预处理块。如,确定预处理块中各已发送的业务数据的排列顺序,通过梅克尔数(Merkle trees)确定预处理块的头哈希值,等等。具体的,在本申请实施例中,预处理块的创建过程可以采用与现有技术相同的方法,本申请对此不做具体限定。Secondly, the third application can create a corresponding pre-processing block according to each of the sent service data. For example, determining the order in which the service data has been sent in the pre-processing block, determining the header hash value of the pre-processing block by Merkle trees, and the like. Specifically, in the embodiment of the present application, the process of creating a pre-processing block may be the same as the prior art, which is not specifically limited in this application.
再次,第三应用可以根据PBFT的三阶段协议中的第一阶段,采用与现有技术相同的方式,确定预处理块对应的预准备(Per-Perpared)信息,其中,Per-Perpared信息的格式可为<Per-Perpared,v,n,d>,其中v表示当前View  ID的数字,n表示预处理块的标识,d为预处理块的摘要。第三应用可对Per-Perpared信息进行签名后,将Per-Perpared信息以及预处理块存储在第二数据库中。Thirdly, the third application can determine the Per-Perpared information corresponding to the pre-processing block according to the first stage of the PBFT three-phase protocol, in the same manner as the prior art, wherein the format of the Per-Perpared information Can be <Per-Perpared, v, n, d>, where v represents the number of the current View ID, n represents the identity of the pre-processing block, and d is the digest of the pre-processing block. After the third application can sign the Per-Perpared information, the Per-Perpared information and the pre-processing block are stored in the second database.
从次,第四应用可从数据库中捞取Per-Perpared信息以及预处理块,并发送至除第二共识节点以外的各共识节点。以使得其他共识节点对Per-Perpared信息进项校验。则如在步骤S201中所述的,第一应用可接收Per-Perpared信息以及预处理块作为共识数据,并存储在第一数据库中。From time to time, the fourth application can extract Per-Perpared information and pre-processing blocks from the database and send them to the consensus nodes except the second consensus node. So that other consensus nodes check the Per-Perpared information. Then, as described in step S201, the first application may receive the Per-Perpared information and the pre-processing block as consensus data, and store it in the first database.
再后,如在步骤S202中所述的,第二应用可以从第一数据库中捞取共识数据(如,第二应用可以捞取Per-Perpared信息以及预处理块),并进行共识校验。具体的,第二应用可以对Per-Perpared信息的签名进行校验,确定Per-Perpared信息是由第二共识节点发送的。还根据预处理块中的业务数据,对Per-Perpared信息的摘要进行校验,确定预处理块以及Per-Perpared信息中的摘要对应。同时也可对Per-Perpared信息中的n进行判断确定是否符合预设的水位值(water mark),Per-Perpared信息中的v是否与第一共识节点当前所处的v一致。Then, as described in step S202, the second application may retrieve consensus data from the first database (eg, the second application may retrieve Per-Perpared information and pre-processing blocks) and perform consensus verification. Specifically, the second application may verify the signature of the Per-Perpared information, and determine that the Per-Perpared information is sent by the second consensus node. The digest of the Per-Perpared information is also verified according to the service data in the pre-processing block, and the digest correspondence in the pre-processing block and the Per-Perpared information is determined. At the same time, it is also possible to judge whether the n in the Per-Perpared information meets the preset water mark, and whether the v in the Per-Perpared information is consistent with the v at which the first consensus node is currently located.
由于在PBFT中确定Per-Perpared信息校验通过的共识节点,将自动执行下一阶段(即,第二阶段),所以当第二应用对Per-Perpared信息校验通过后可以将Per-Perpared信息、预处理块以及接收到的响应信息,存储在第一数据库中,并创建准备信息(Perpared信息)作为校验结果。Perpared信息的格式可为<Perpared,v,n,d,i>,其中i为创建Perpared信息的共识节点的标识。于是,第二应用还可将Perpared信息也存储在第一数据库中。Since the consensus node for the Per-Perpared information check is determined in the PBFT, the next phase (ie, the second phase) will be automatically executed, so the Per-Perpared information can be obtained after the second application verifies the Per-Perpared information. The pre-processing block and the received response information are stored in the first database, and preparation information (Perpared information) is created as a verification result. The format of the Perpared information can be <Perpared, v, n, d, i>, where i is the identity of the consensus node that created the Perpared information. Thus, the second application can also store the Perpared information in the first database.
然后,第二应用可将Perpared信息发送至其他共识节点继续进行共识校验。并且,其他通过对Per-Perpared信息校验的共识节点也可将自身创建的Perpared信息签名后进行广播。于是,在区块链网络中的各共识节点,均可接收到通过对Per-Perpared信息校验的共识节点发送的Perpared信息,并且,针对每个共识节点,该共识节点可将接收到的其他共识节点发送的Perpared信息 存储在自身的数据库中。The second application can then send the Perpared information to other consensus nodes to continue the consensus check. Moreover, other consensus nodes that verify the Per-Perpared information can also broadcast the Perpared information created by itself and then broadcast it. Thus, each consensus node in the blockchain network can receive the Perpared information sent by the consensus node that verifies the Per-Perpared information, and for each consensus node, the consensus node can receive the other The Perpared information sent by the consensus node is stored in its own database.
于是,在本申请实施例中,第一共识节点的第一应用可再次接收其他共识节点发送的校验结果(即,其他共识节点发送的Perpared信息),并存储在第一数据库中。第二应用可对第一数据库中存储的各Perpared信息的v、n、签名以及摘要进行校验。当第二应用判断第一数据库中存储的通过校验的各Perpared信息的数量大于等于预设的数量时,自动执行下一阶段(即,第三阶段)。其中,预设的数量与现有技术相同,为共识节点通过PBFT计算确定的,本申请不再赘述。Therefore, in the embodiment of the present application, the first application of the first consensus node may again receive the verification result sent by other consensus nodes (that is, the Perpared information sent by other consensus nodes), and store it in the first database. The second application may verify the v, n, signature, and digest of each Perpared information stored in the first database. When the second application determines that the number of pieces of Perpared information stored in the first database stored by the verification is greater than or equal to a preset number, the next stage (ie, the third stage) is automatically executed. The preset number is the same as the prior art, and is determined by the PBFT calculation for the consensus node, and is not described herein again.
之后,在三阶段协议的第三阶段,当第二应用确定进行第三阶段时,可创建确认信息(Commit信息),并向其他共识节点发送Commit信息。同理,第二共识节点的第三或者第四应用,在确定进行第三阶段时,也可发送Commit信息。第一应用可接收其他共识节点发送的Commit信息并存储在第一数据库中。其中,Commit信息格式可为<Commit,v,n,D,i>,其中D为共识节点创建的预处理块的摘要。Thereafter, in the third phase of the three-phase protocol, when the second application determines to perform the third phase, confirmation information (Commit information) may be created, and Commit information may be sent to other consensus nodes. Similarly, the third or fourth application of the second consensus node may also send Commit information when determining to perform the third phase. The first application may receive Commit information sent by other consensus nodes and store it in the first database. The Commit information format may be <Commit, v, n, D, i>, where D is a summary of the pre-processing block created by the consensus node.
最后,第二应用可对第一数据库中存储的其他共识节点发送的Commit信息的v、n、签名以及摘要进行校验,当确定通过校验的Commit信息大于等于预设的数量时,确定预处理块通过共识校验。Finally, the second application may verify the v, n, signature, and digest of the Commit information sent by the other consensus nodes stored in the first database, and determine the pre-determination when it is determined that the Commit information of the verification is greater than or equal to the preset quantity. The processing block passes the consensus check.
其中,针对区块链网络中的每个共识节点,该共识节点在三阶段协议的每个阶段中,在接收到其他共识节点的信息、创建信息等进行共识校验时产生的数据,均可存储在该共识节点对应的数据库中。Wherein, for each consensus node in the blockchain network, the consensus node in each phase of the three-phase protocol receives data from other consensus nodes, creates information, and the like, and generates data during consensus verification. Stored in the database corresponding to the consensus node.
当然,需要说明的是本申请实施例中,上述由第二应用执行的步骤均可以由第一应用执行,反之亦然。同理,由该第三应用执行的步骤也均可由第四应用执行,反之亦然。Of course, it should be noted that in the embodiment of the present application, the steps performed by the second application may be performed by the first application, and vice versa. Similarly, the steps performed by the third application can also be performed by the fourth application, and vice versa.
另外,针对每个共识节点,由于在三阶段协议执行过程中,各共识节点都需要发送和接收其他共识节点的信息,而信息在通过网络传输时,可能出现网络延时,所以在三阶段协议的每个阶段,各共识节点都可等待一段时间以接收 信息。于是,在执行三阶段协议过程中,共识节点可将创建的以及接收的信息先存储在数据库中。并在每个阶段的等待时间结束时,再根据数据库中存储的信息,确定是否进行下一阶段。In addition, for each consensus node, since the consensus nodes need to send and receive information of other consensus nodes during the execution of the three-phase protocol, and the information may be transmitted through the network, network delay may occur, so in the three-phase protocol At each stage, each consensus node can wait for a period of time to receive information. Thus, during the execution of the three-phase protocol, the consensus node can store the created and received information in the database first. At the end of each phase of the waiting time, based on the information stored in the database, determine whether to proceed to the next stage.
进一步地,在本申请实施例中,在三阶段协议的第一阶段(也就是Per-Perpared的阶段),发起共识的第二共识节点(即,主节点)可将预处理块,以及预处理块中各业务数据的哈希值一并发送至出第二共识节点的各共识节点,而接收到Per-Perpared信息的各共识节点,可以根据各业务数据的哈希值,创建一个预处理块,并与主节点发送的预处理块进行对比校验。Further, in the embodiment of the present application, in the first phase of the three-phase protocol (that is, the phase of Per-Perpared), the second consensus node (ie, the master node) that initiates the consensus may preprocess the block, and preprocess The hash values of the service data in the block are sent to the consensus nodes of the second consensus node, and the consensus nodes that receive the Per-Perpared information can create a pre-processing block according to the hash value of each service data. And compare and verify with the pre-processing block sent by the master node.
更进一步地,在本申请实施例中,针对每个共识节点,该共识节点在进行共识校验时,与现有技术一致各共识节点还可以根据共识条件,以及共识节点进行校验,即,判断是否主节点发送各业务数据是可进行共识校验的业务数据,若是,则继续后续共识校验,若否,则停止共识校验。Further, in the embodiment of the present application, for each consensus node, the consensus node is consistent with the prior art when performing consensus verification, and the consensus nodes may also perform verification according to the consensus condition and the consensus node, ie, It is determined whether the primary node sends each service data as service data that can perform consensus verification. If yes, the subsequent consensus verification is continued, and if not, the consensus verification is stopped.
基于图2所示的区块链业务共识方法,第一共识节点中包括第一应用、第二应用以及第一数据库,在进行共识时,第一应用接收共识数据,并存储在第一数据库中,第二应用从第一数据库中捞取共识数据,进行共识校验,第二应用将校验结果添加到共识数据中并存储至第一数据库,并将校验结果发送至其他共识节点继续进行共识校验。其中,发起共识的第二共识节点的第三应用根据第二数据库中存储的已发送的业务数据,创建预处理块作为共识数据存储在第二数据中,第四应用从第二数据库中捞取共识数据并发送至出第二共识节点以外的各共识节点。可见,由于在本申请实施例中,共识节点可以采用PBFT的三阶段协议进行共识,并且将每一阶段产生的数据存储在数据库中,减少共识校验时对缓存占用率,提高缓存利用率。从而提高了共识节点进行共识校验以及对业务请求进行处理的效率。Based on the blockchain service consensus method shown in FIG. 2, the first consensus node includes a first application, a second application, and a first database. When the consensus is performed, the first application receives the consensus data and stores the data in the first database. The second application retrieves the consensus data from the first database and performs consensus verification. The second application adds the verification result to the consensus data and stores it to the first database, and sends the verification result to other consensus nodes to continue the consensus. check. The third application of the second consensus node that initiates the consensus creates the pre-processing block as the consensus data is stored in the second data according to the sent service data stored in the second database, and the fourth application obtains the consensus from the second database. The data is sent to each consensus node other than the second consensus node. It can be seen that, in the embodiment of the present application, the consensus node can use the three-phase protocol of the PBFT to implement the consensus, and store the data generated in each stage in the database, reduce the cache occupancy rate during the consensus check, and improve the cache utilization. This improves the efficiency of the consensus node for consensus checking and processing of business requests.
需要说明的是,本申请实施例所提供方法的各步骤的执行主体均可以是同一设备,或者,该方法也由不同设备作为执行主体。比如,步骤S201和步骤S202的执行主体可以为设备1,步骤S203的执行主体可以为设备2;又比如, 步骤S201的执行主体可以为设备1,步骤S202和步骤S203的执行主体可以为设备2;等等。It should be noted that the execution bodies of the steps of the method provided by the embodiment of the present application may all be the same device, or the method may also be performed by different devices. For example, the execution body of step S201 and step S202 may be device 1, and the execution body of step S203 may be device 2; for example, the execution body of step S201 may be device 1, and the execution body of step S202 and step S203 may be device 2 ;and many more.
基于图1所示区块链业务受理方法,本申请实施例还对应提供一种区块链业务受理装置,如图3所示。Based on the blockchain service receiving method shown in FIG. 1, the embodiment of the present application further provides a blockchain service receiving device, as shown in FIG.
图3为本申请实施例提供的一种区块链业务受理装置的结构示意图,共识节点中包括所述装置,第二应用以及数据库,所述装置包括:FIG. 3 is a schematic structural diagram of a blockchain service receiving apparatus according to an embodiment of the present disclosure, where the consensus node includes the device, a second application, and a database, and the device includes:
接收模块301,接收客户端发送的业务请求,并根据该业务请求确定对应的待发送的业务数据;The receiving module 301 receives a service request sent by the client, and determines corresponding service data to be sent according to the service request;
存储模块302,将所述待发送的业务数据存储在所述数据库中;The storage module 302 stores the service data to be sent in the database;
当满足预设条件时,所述第二应用或者发送模块303,从所述数据库中捞取待发送的业务数据发送至其他共识节点存储。When the preset condition is met, the second application or sending module 303 extracts the service data to be sent from the database and sends it to other consensus node storage.
所述存储模块302,确定所述待发送的业务数据的状态为待发送状态,将所述业务数据及其对应的待发送状态存储在所述存储模块中。The storage module 302 determines that the status of the service data to be sent is a to-be-sent state, and stores the service data and its corresponding to-be-sent status in the storage module.
当指定时刻到达时,确定满足预设的条件。When the specified time arrives, it is determined that the preset condition is satisfied.
所述发送模块303,从所述数据库中捞取指定数量的待发送的业务数据。The sending module 303 extracts a specified number of service data to be sent from the database.
所述装置还包括:The device also includes:
更新模块304,将所述数据库中已发送的业务数据的状态更新为已发送状态。The update module 304 updates the status of the transmitted service data in the database to the sent status.
具体的,该区块链业务受理装置可位于共识节点中,该共识节点可以是终端。如,手机、平板电脑、个人电脑等设备。或者,该共识节点也可以是服务器。如,单独一台服务器,或者由多台服务器组成的系统。Specifically, the blockchain service receiving device may be located in the consensus node, and the consensus node may be a terminal. For example, mobile phones, tablets, personal computers and other equipment. Alternatively, the consensus node can also be a server. For example, a single server, or a system consisting of multiple servers.
基于图2所示区块链业务共识方法,本申请实施例还对应提供一种区块链业务共识装置,如图4所示。Based on the blockchain service consensus method shown in FIG. 2, the embodiment of the present application further provides a blockchain service consensus device, as shown in FIG. 4 .
图4为本申请实施例提供的一种区块链业务共识装置的结构示意图,第一共识节点中包括第一应用、所述装置以及第一数据库,所述装置包括:4 is a schematic structural diagram of a blockchain service consensus device according to an embodiment of the present disclosure. The first consensus node includes a first application, the device, and a first database, where the device includes:
接收模块401,接收共识数据,并存储在所述第一数据库中;The receiving module 401 receives the consensus data and stores it in the first database;
校验模块402,从所述第一数据库中捞取所述共识数据,进行共识校验;The verification module 402: extracts the consensus data from the first database, and performs consensus verification;
存储发送模块403,将校验结果添加到所述共识数据中并存储至所述第一数据库,并将所述校验结果发送至其他共识节点继续进行共识校验。The storage sending module 403 adds the verification result to the consensus data and stores it to the first database, and sends the verification result to other consensus nodes to continue the consensus verification.
所述接收模块401,接收其他共识节点发送的共识数据,或者,接收其他共识节点发送的校验结果,作为共识数据。The receiving module 401 receives the consensus data sent by other consensus nodes, or receives the verification result sent by other consensus nodes, as the consensus data.
所述校验模块402,从所述第一数据库中捞取所述共识数据以及所述第一数据库中已发送状态的业务数据,根据所述已发送状态的业务数据对所述共识数据进行共识校验,并确定校验结果。The verification module 402 extracts the consensus data and the service data of the sent status in the first database from the first database, and performs consensus on the consensus data according to the service data of the sent status. Check and determine the verification result.
第二共识节点中包括第三应用、第四应用以及第二数据库,所述接收模块401接收共识数据之前,所述第三应用根据所述第二数据库中已发送状态的业务数据,确定共识数据,并存储在所述第二数据库中,所述第四应用从所述第二数据库中捞取所述共识数据,并发送至除所述第二共识节点以外的各共识节点。The second consensus node includes a third application, a fourth application, and a second database. Before the receiving module 401 receives the consensus data, the third application determines the consensus data according to the service data of the sent state in the second database. And stored in the second database, the fourth application extracts the consensus data from the second database, and sends the consensus data to each consensus node except the second consensus node.
所述共识校验采用拜占庭容错算法PBFT。The consensus check uses the Byzantine fault tolerance algorithm PBFT.
具体的,如图4所示的一种区块链业务受理装置可位于共识节点中,该共识节点可以是终端。如,手机、平板电脑、个人电脑等设备。或者,该共识节点也可以是服务器。如,单独一台服务器,或者由多台服务器组成的系统。Specifically, a blockchain service receiving apparatus as shown in FIG. 4 may be located in a consensus node, and the consensus node may be a terminal. For example, mobile phones, tablets, personal computers and other equipment. Alternatively, the consensus node can also be a server. For example, a single server, or a system consisting of multiple servers.
在20世纪90年代,对于一个技术的改进可以很明显地区分是硬件上的改进(例如,对二极管、晶体管、开关等电路结构的改进)还是软件上的改进(对于方法流程的改进)。然而,随着技术的发展,当今的很多方法流程的改进已经可以视为硬件电路结构的直接改进。设计人员几乎都通过将改进的方法流程编程到硬件电路中来得到相应的硬件电路结构。因此,不能说一个方法流程的改进就不能用硬件实体模块来实现。例如,可编程逻辑器件(Programmable Logic Device,PLD)(例如现场可编程门阵列(Field Programmable Gate Array,FPGA))就是这样一种集成电路,其逻辑功能由用户对器件编程来确定。由设计人员自行编程来把一个数字系统“集成”在一片PLD上,而不需要请芯片制造 厂商来设计和制作专用的集成电路芯片。而且,如今,取代手工地制作集成电路芯片,这种编程也多半改用“逻辑编译器(logic compiler)”软件来实现,它与程序开发撰写时所用的软件编译器相类似,而要编译之前的原始代码也得用特定的编程语言来撰写,此称之为硬件描述语言(Hardware Description Language,HDL),而HDL也并非仅有一种,而是有许多种,如ABEL(Advanced Boolean Expression Language)、AHDL(Altera Hardware Description Language)、Confluence、CUPL(Cornell University Programming Language)、HDCal、JHDL(Java Hardware Description Language)、Lava、Lola、MyHDL、PALASM、RHDL(Ruby Hardware Description Language)等,目前最普遍使用的是VHDL(Very-High-Speed Integrated Circuit Hardware Description Language)与Verilog。本领域技术人员也应该清楚,只需要将方法流程用上述几种硬件描述语言稍作逻辑编程并编程到集成电路中,就可以很容易得到实现该逻辑方法流程的硬件电路。In the 1990s, improvements to a technology could clearly distinguish between hardware improvements (eg, improvements to circuit structures such as diodes, transistors, switches, etc.) or software improvements (for process flow improvements). However, as technology advances, many of today's method flow improvements can be seen as direct improvements in hardware circuit architecture. Designers almost always get the corresponding hardware circuit structure by programming the improved method flow into the hardware circuit. Therefore, it cannot be said that the improvement of a method flow cannot be implemented by hardware entity modules. For example, a Programmable Logic Device (PLD) (such as a Field Programmable Gate Array (FPGA)) is an integrated circuit whose logic function is determined by the user programming the device. Designers program themselves to "integrate" a digital system on a single PLD without having to ask the chip manufacturer to design and fabricate a dedicated integrated circuit chip. Moreover, today, instead of manually making integrated circuit chips, this programming is mostly implemented using "logic compiler" software, which is similar to the software compiler used in programming development, but before compiling The original code has to be written in a specific programming language. This is called the Hardware Description Language (HDL). HDL is not the only one, but there are many kinds, such as ABEL (Advanced Boolean Expression Language). AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, RHDL (Ruby Hardware Description Language), etc., are currently the most commonly used VHDL (Very-High-Speed Integrated Circuit Hardware Description Language) and Verilog. It should also be apparent to those skilled in the art that the hardware flow for implementing the logic method flow can be easily obtained by simply programming the method flow into the integrated circuit with a few hardware description languages.
控制器可以按任何适当的方式实现,例如,控制器可以采取例如微处理器或处理器以及存储可由该(微)处理器执行的计算机可读程序代码(例如软件或固件)的计算机可读介质、逻辑门、开关、专用集成电路(Application Specific Integrated Circuit,ASIC)、可编程逻辑控制器和嵌入微控制器的形式,控制器的例子包括但不限于以下微控制器:ARC 625D、Atmel AT91SAM、Microchip PIC18F26K20以及Silicone Labs C8051F320,存储器控制器还可以被实现为存储器的控制逻辑的一部分。本领域技术人员也知道,除了以纯计算机可读程序代码方式实现控制器以外,完全可以通过将方法步骤进行逻辑编程来使得控制器以逻辑门、开关、专用集成电路、可编程逻辑控制器和嵌入微控制器等的形式来实现相同功能。因此这种控制器可以被认为是一种硬件部件,而对其内包括的用于实现各种功能的装置也可以视为硬件部件内的结构。或者甚至,可以将用于实现各种功能的装置视为既可以是实现方法的软件模块又可以是硬件部件内的结构。The controller can be implemented in any suitable manner, for example, the controller can take the form of, for example, a microprocessor or processor and a computer readable medium storing computer readable program code (eg, software or firmware) executable by the (micro)processor. In the form of logic gates, switches, application specific integrated circuits (ASICs), programmable logic controllers, and embedded microcontrollers, examples of controllers include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, The Microchip PIC18F26K20 and the Silicone Labs C8051F320, the memory controller can also be implemented as part of the memory's control logic. Those skilled in the art will also appreciate that in addition to implementing the controller in purely computer readable program code, the controller can be logically programmed by means of logic gates, switches, ASICs, programmable logic controllers, and embedding. The form of a microcontroller or the like to achieve the same function. Such a controller can therefore be considered a hardware component, and the means for implementing various functions included therein can also be considered as a structure within the hardware component. Or even a device for implementing various functions can be considered as a software module that can be both a method of implementation and a structure within a hardware component.
上述实施例阐明的系统、装置、模块或单元,具体可以由计算机芯片或实体实现,或者由具有某种功能的产品来实现。一种典型的实现设备为计算机。具体的,计算机例如可以为个人计算机、膝上型计算机、蜂窝电话、相机电话、智能电话、个人数字助理、媒体播放器、导航设备、电子邮件设备、游戏控制台、平板计算机、可穿戴设备或者这些设备中的任何设备的组合。The system, device, module or unit illustrated in the above embodiments may be implemented by a computer chip or an entity, or by a product having a certain function. A typical implementation device is a computer. Specifically, the computer can be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or A combination of any of these devices.
为了描述的方便,描述以上装置时以功能分为各种单元分别描述。当然,在实施本申请时可以把各单元的功能在同一个或多个软件和/或硬件中实现。For the convenience of description, the above devices are described separately by function into various units. Of course, the functions of each unit may be implemented in the same software or software and/or hardware when implementing the present application.
本领域内的技术人员应明白,本发明的实施例可提供为方法、系统、或计算机程序产品。因此,本发明可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本发明可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、CD-ROM、光学存储器等)上实施的计算机程序产品的形式。Those skilled in the art will appreciate that embodiments of the present invention can be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment, or a combination of software and hardware. Moreover, the invention can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) including computer usable program code.
本发明是参照根据本发明实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present invention has been described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (system), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flowchart illustrations and/or FIG. These computer program instructions can be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing device to produce a machine for the execution of instructions for execution by a processor of a computer or other programmable data processing device. Means for implementing the functions specified in one or more of the flow or in a block or blocks of the flow chart.
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。The computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing device to operate in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture comprising the instruction device. The apparatus implements the functions specified in one or more blocks of a flow or a flow and/or block diagram of the flowchart.
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个 流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded onto a computer or other programmable data processing device such that a series of operational steps are performed on a computer or other programmable device to produce computer-implemented processing for execution on a computer or other programmable device. The instructions provide steps for implementing the functions specified in one or more of the flow or in a block or blocks of a flow diagram.
在一个典型的配置中,计算设备包括一个或多个处理器(CPU)、输入/输出接口、网络接口和内存。In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
内存可能包括计算机可读介质中的非永久性存储器,随机存取存储器(RAM)和/或非易失性内存等形式,如只读存储器(ROM)或闪存(flash RAM)。内存是计算机可读介质的示例。The memory may include non-persistent memory, random access memory (RAM), and/or non-volatile memory in a computer readable medium, such as read only memory (ROM) or flash memory. Memory is an example of a computer readable medium.
计算机可读介质包括永久性和非永久性、可移动和非可移动媒体可以由任何方法或技术来实现信息存储。信息可以是计算机可读指令、数据结构、程序的模块或其他数据。计算机的存储介质的例子包括,但不限于相变内存(PRAM)、静态随机存取存储器(SRAM)、动态随机存取存储器(DRAM)、其他类型的随机存取存储器(RAM)、只读存储器(ROM)、电可擦除可编程只读存储器(EEPROM)、快闪记忆体或其他内存技术、只读光盘只读存储器(CD-ROM)、数字多功能光盘(DVD)或其他光学存储、磁盒式磁带,磁带磁磁盘存储或其他磁性存储设备或任何其他非传输介质,可用于存储可以被计算设备访问的信息。按照本文中的界定,计算机可读介质不包括暂存电脑可读媒体(transitory media),如调制的数据信号和载波。Computer readable media includes both permanent and non-persistent, removable and non-removable media. Information storage can be implemented by any method or technology. The information can be computer readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read only memory. (ROM), electrically erasable programmable read only memory (EEPROM), flash memory or other memory technology, compact disk read only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, Magnetic tape cartridges, magnetic tape storage or other magnetic storage devices or any other non-transportable media can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary storage of computer readable media, such as modulated data signals and carrier waves.
还需要说明的是,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、商品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、商品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、商品或者设备中还存在另外的相同要素。It is also to be understood that the terms "comprises" or "comprising" or "comprising" or any other variations are intended to encompass a non-exclusive inclusion, such that a process, method, article, Other elements not explicitly listed, or elements that are inherent to such a process, method, commodity, or equipment. An element defined by the phrase "comprising a ..." does not exclude the presence of additional equivalent elements in the process, method, item, or device including the element.
本领域技术人员应明白,本申请的实施例可提供为方法、系统或计算机程序产品。因此,本申请可采用完全硬件实施例、完全软件实施例或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、CD-ROM、 光学存储器等)上实施的计算机程序产品的形式。Those skilled in the art will appreciate that embodiments of the present application can be provided as a method, system, or computer program product. Thus, the present application can take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment in combination of software and hardware. Moreover, the application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) including computer usable program code.
本申请可以在由计算机执行的计算机可执行指令的一般上下文中描述,例如程序模块。一般地,程序模块包括执行特定任务或实现特定抽象数据类型的例程、程序、对象、组件、数据结构等等。也可以在分布式计算环境中实践本申请,在这些分布式计算环境中,由通过通信网络而被连接的远程处理设备来执行任务。在分布式计算环境中,程序模块可以位于包括存储设备在内的本地和远程计算机存储介质中。The application can be described in the general context of computer-executable instructions executed by a computer, such as a program module. Generally, program modules include routines, programs, objects, components, data structures, and the like that perform particular tasks or implement particular abstract data types. The present application can also be practiced in distributed computing environments where tasks are performed by remote processing devices that are connected through a communication network. In a distributed computing environment, program modules can be located in both local and remote computer storage media including storage devices.
本说明书中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于系统实施例而言,由于其基本相似于方法实施例,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。The various embodiments in the specification are described in a progressive manner, and the same or similar parts between the various embodiments may be referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the description of the method embodiment.
以上所述仅为本申请的实施例而已,并不用于限制本申请。对于本领域技术人员来说,本申请可以有各种更改和变化。凡在本申请的精神和原理之内所作的任何修改、等同替换、改进等,均应包含在本申请的权利要求范围之内。The above description is only an embodiment of the present application and is not intended to limit the application. Various changes and modifications can be made to the present application by those skilled in the art. Any modifications, equivalents, improvements, etc. made within the spirit and scope of the present application are intended to be included within the scope of the appended claims.

Claims (20)

  1. 一种区块链业务受理方法,共识节点中包括第一应用、第二应用以及数据库,所述方法包括:A blockchain service acceptance method includes a first application, a second application, and a database, and the method includes:
    所述第一应用接收客户端发送的业务请求,并根据该业务请求确定对应的待发送的业务数据;Receiving, by the first application, a service request sent by the client, and determining corresponding service data to be sent according to the service request;
    所述第一应用将所述待发送的业务数据存储在所述数据库中;The first application stores the service data to be sent in the database;
    当满足预设条件时,所述第二应用或者所述第一应用,从所述数据库中捞取待发送的业务数据发送至其他共识节点存储。When the preset condition is met, the second application or the first application sends the service data to be sent from the database to other consensus node storage.
  2. 如权利要求1所述的方法,所述第一应用将所述待发送的业务数据存储在所述数据库中之前,所述方法还包括:The method of claim 1, before the first application stores the service data to be sent in the database, the method further includes:
    所述第一应用确定所述待发送的业务数据的状态为待发送状态;Determining, by the first application, a state of the service data to be sent as a to-be-sent state;
    将所述业务数据及其对应的待发送状态存储在所述数据库中。The service data and its corresponding to-be-sent status are stored in the database.
  3. 如权利要求1所述的方法,满足预设条件,具体包括:The method of claim 1, wherein the predetermined condition is met, specifically comprising:
    当指定时刻到达时,确定满足预设的条件。When the specified time arrives, it is determined that the preset condition is satisfied.
  4. 如权利要求1所述方法,从所述数据库中捞取待发送的业务数据,具体包括:The method of claim 1, the method for extracting service data to be sent from the database, specifically comprising:
    从所述数据库中捞取指定数量的待发送的业务数据。A specified amount of business data to be sent is retrieved from the database.
  5. 如权利要求1所述的方法,其特征在于,所述方法还包括:The method of claim 1 wherein the method further comprises:
    将所述数据库中已发送的业务数据的状态更新为已发送状态。The status of the transmitted service data in the database is updated to the sent status.
  6. 一种区块链业务共识方法,第一共识节点中包括第一应用、第二应用以及第一数据库,所述方法包括:A blockchain service consensus method includes a first application, a second application, and a first database, where the method includes:
    所述第一应用接收共识数据,并存储在所述第一数据库中;The first application receives consensus data and stores it in the first database;
    所述第二应用从所述第一数据库中捞取所述共识数据,进行共识校验;The second application extracts the consensus data from the first database, and performs consensus verification;
    所述第二应用将校验结果添加到所述共识数据中并存储至所述第一数据库,并将所述校验结果发送至其他共识节点继续进行共识校验。The second application adds the verification result to the consensus data and stores it to the first database, and sends the verification result to other consensus nodes to continue the consensus check.
  7. 如权利要求6所述的方法,所述第一应用确定共识数据,具体包括:The method of claim 6, wherein the determining, by the first application, the consensus data comprises:
    所述第一应用接收其他共识节点发送的共识数据;或者The first application receives consensus data sent by other consensus nodes; or
    所述第一应用接收其他共识节点发送的校验结果,作为共识数据。The first application receives the verification result sent by other consensus nodes as the consensus data.
  8. 如权利要求6所述的方法,所述第二应用从所述第一数据库中捞取所述共识数据,进行共识校验,具体包括:The method of claim 6, wherein the second application extracts the consensus data from the first database and performs consensus verification, which specifically includes:
    所述第二应用从所述第一数据库中捞取所述共识数据以及所述第一数据库中已发送状态的业务数据;The second application extracts the consensus data and the service data of the sent status in the first database from the first database;
    根据所述已发送状态的业务数据对所述共识数据进行共识校验,并确定校验结果。Performing consensus verification on the consensus data according to the service data of the sent status, and determining a verification result.
  9. 如权利要求6所述的方法,第二共识节点中包括第三应用、第四应用以及第二数据库;The method according to claim 6, wherein the second consensus node includes a third application, a fourth application, and a second database;
    所述第一应用接收共识数据之前,所述方法还包括:Before the first application receives the consensus data, the method further includes:
    所述第三应用根据所述第二数据库中已发送状态的业务数据,确定共识数据,并存储在所述第二数据库中;The third application determines the consensus data according to the service data of the sent status in the second database, and stores the data in the second database;
    所述第四应用从所述第二数据库中捞取所述共识数据,并发送至除所述第二共识节点以外的各共识节点。The fourth application extracts the consensus data from the second database and sends the consensus data to the consensus nodes except the second consensus node.
  10. 如权利要求6至9任一项所述的方法,所述共识校验采用拜占庭容错算法PBFT。The method according to any one of claims 6 to 9, wherein the consensus check uses a Byzantine fault tolerance algorithm PBFT.
  11. 一种区块链业务受理装置,共识节点中包括所述装置,第二应用以及数据库,所述装置包括:A blockchain service receiving device includes a device, a second application, and a database, and the device includes:
    接收模块,接收客户端发送的业务请求,并根据该业务请求确定对应的待发送的业务数据;The receiving module receives the service request sent by the client, and determines corresponding service data to be sent according to the service request;
    存储模块,将所述待发送的业务数据存储在所述数据库中;a storage module, where the service data to be sent is stored in the database;
    当满足预设条件时,所述第二应用或者发送模块,从所述数据库中捞取待发送的业务数据发送至其他共识节点存储。When the preset condition is met, the second application or the sending module sends the service data to be sent from the database to other consensus node storage.
  12. 如权利要求11所述的装置,所述存储模块,确定所述待发送的业务数据的状态为待发送状态,将所述业务数据及其对应的待发送状态存储在所述 存储模块中。The device of claim 11, wherein the storage module determines that the status of the service data to be sent is a to-be-sent state, and stores the service data and its corresponding to-be-sent status in the storage module.
  13. 如权利要求11所述的装置,当指定时刻到达时,确定满足预设的条件。The apparatus according to claim 11, wherein when the specified time arrives, it is determined that the predetermined condition is satisfied.
  14. 如权利要求11所述的装置,所述发送模块从所述数据库中捞取指定数量的待发送的业务数据。The apparatus of claim 11, said transmitting module extracting a specified amount of service data to be transmitted from said database.
  15. 如权利要求11所述的装置,所述装置还包括:The device of claim 11 further comprising:
    更新模块,将所述数据库中已发送的业务数据的状态更新为已发送状态。The update module updates the status of the sent service data in the database to the sent status.
  16. 一种区块链业务共识装置,第一共识节点中包括第一应用、所述装置以及第一数据库,所述装置包括:A blockchain service consensus device includes a first application, the device, and a first database, where the device includes:
    接收模块,接收共识数据,并存储在所述第一数据库中;Receiving module, receiving consensus data, and storing in the first database;
    校验模块,从所述第一数据库中捞取所述共识数据,进行共识校验;a verification module, extracting the consensus data from the first database, and performing consensus verification;
    存储发送模块,将校验结果添加到所述共识数据中并存储至所述第一数据库,并将所述校验结果发送至其他共识节点继续进行共识校验。The storage module adds a verification result to the consensus data and stores the result to the first database, and sends the verification result to other consensus nodes to continue the consensus verification.
  17. 如权利要求16所述的装置,所述接收模块,接收其他共识节点发送的共识数据,或者,接收其他共识节点发送的校验结果,作为共识数据。The apparatus according to claim 16, wherein the receiving module receives the consensus data sent by the other consensus nodes, or receives the verification result sent by the other consensus nodes as the consensus data.
  18. 如权利要求16所述的装置,所述校验模块,从所述第一数据库中捞取所述共识数据以及所述第一数据库中已发送状态的业务数据,根据所述已发送状态的业务数据对所述共识数据进行共识校验,并确定校验结果。The apparatus according to claim 16, wherein the verification module extracts the consensus data and the service data of the transmitted state in the first database from the first database, and according to the service data of the sent status Consensus verification is performed on the consensus data, and the verification result is determined.
  19. 如权利要求16所述的装置,第二共识节点中包括第三应用、第四应用以及第二数据库,所述接收模块接收共识数据之前,所述第三应用根据所述第二数据库中已发送状态的业务数据,确定共识数据,并存储在所述第二数据库中,所述第四应用从所述第二数据库中捞取所述共识数据,并发送至除所述第二共识节点以外的各共识节点。The apparatus according to claim 16, wherein the second consensus node includes a third application, a fourth application, and a second database, and before the receiving module receives the consensus data, the third application is sent according to the second database Status data, determining consensus data, and storing in the second database, the fourth application extracting the consensus data from the second database and transmitting to each of the second consensus nodes Consensus node.
  20. 如权利要求16至19任一项所述的装置,所述共识校验采用拜占庭容错算法PBFT。The apparatus according to any one of claims 16 to 19, wherein the consensus check uses a Byzantine fault tolerance algorithm PBFT.
PCT/CN2018/087603 2017-05-22 2018-05-21 Block chain service acceptance and consensus method and device WO2018214835A1 (en)

Priority Applications (10)

Application Number Priority Date Filing Date Title
SG11201906166YA SG11201906166YA (en) 2017-05-22 2018-05-21 Blockchain service acceptance and consensus method and devices
PL18806911T PL3550803T3 (en) 2017-05-22 2018-05-21 Block chain service acceptance and consensus method and device
KR1020197019210A KR102204256B1 (en) 2017-05-22 2018-05-21 Blockchain service acceptance and agreement method and device
EP21166986.6A EP3886403B1 (en) 2017-05-22 2018-05-21 Block chain service acceptance and consensus method and device
MYPI2019003821A MY194420A (en) 2017-05-22 2018-05-21 Blockchain service acceptance and consensus method and devices
JP2019536261A JP6949118B2 (en) 2017-05-22 2018-05-21 Blockchain service acceptance and consensus methods and devices
ES18806911T ES2876943T3 (en) 2017-05-22 2018-05-21 Blockchain services acceptance and consensus procedure and device
EP18806911.6A EP3550803B1 (en) 2017-05-22 2018-05-21 Block chain service acceptance and consensus method and device
PH12019501563A PH12019501563A1 (en) 2017-05-22 2019-07-02 Blockchain service acceptance and consensus method and devices
US16/502,523 US10938577B2 (en) 2017-05-22 2019-07-03 Blockchain service acceptance and consensus method and devices

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201710362162.3 2017-05-22
CN201710362162.3A CN107395665B (en) 2017-05-22 2017-05-22 Block chain service acceptance and service consensus method and device

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US16/502,523 Continuation US10938577B2 (en) 2017-05-22 2019-07-03 Blockchain service acceptance and consensus method and devices

Publications (1)

Publication Number Publication Date
WO2018214835A1 true WO2018214835A1 (en) 2018-11-29

Family

ID=60338958

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/087603 WO2018214835A1 (en) 2017-05-22 2018-05-21 Block chain service acceptance and consensus method and device

Country Status (12)

Country Link
US (1) US10938577B2 (en)
EP (2) EP3886403B1 (en)
JP (1) JP6949118B2 (en)
KR (1) KR102204256B1 (en)
CN (1) CN107395665B (en)
ES (1) ES2876943T3 (en)
MY (1) MY194420A (en)
PH (1) PH12019501563A1 (en)
PL (1) PL3550803T3 (en)
SG (2) SG11201906166YA (en)
TW (1) TWI679547B (en)
WO (1) WO2018214835A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110430101A (en) * 2019-08-28 2019-11-08 杭州领智云画科技有限公司 Service indication collecting method, device, equipment and system applied to CDN
CN112954009A (en) * 2021-01-27 2021-06-11 咪咕音乐有限公司 Block chain consensus method, device and storage medium

Families Citing this family (29)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107395665B (en) * 2017-05-22 2020-04-24 创新先进技术有限公司 Block chain service acceptance and service consensus method and device
CN108009824A (en) * 2017-11-28 2018-05-08 北京博晨技术有限公司 Data common recognition method, apparatus and electronic equipment
CN107992356B (en) * 2017-12-13 2021-09-14 深圳壹账通智能科技有限公司 Block chain transaction block processing method, electronic device and readable storage medium
CN108848056B (en) * 2018-05-03 2021-05-04 南京理工大学 Block chain consensus method based on verification
CN108965398B (en) * 2018-06-22 2021-01-19 北京格瑞空间科技有限公司 Control method of Internet of things equipment based on block chain
CN109039750B (en) * 2018-08-13 2021-06-15 浙商银行股份有限公司 Method for improving multi-city multi-park deployment disaster recovery capability of block chain application system
CN109462631B (en) * 2018-08-31 2021-11-19 腾讯科技(深圳)有限公司 Data processing method, data processing device, storage medium and electronic device
CN109345194A (en) * 2018-09-12 2019-02-15 北京东港瑞宏科技有限公司 A kind of electronic bill flow system
CN111080287B (en) * 2018-10-18 2023-06-16 华为技术有限公司 Service data processing method, related equipment and system
KR20200078002A (en) * 2018-12-21 2020-07-01 주식회사 밀리언써클 Method and system for selecting a winner among weighted candidates based on a blockchain
CN111382119B (en) * 2018-12-29 2023-08-22 华为技术有限公司 Block data archiving method and related equipment
CN112612856B (en) * 2019-07-09 2024-03-29 创新先进技术有限公司 Block chain-based data processing method and device
KR102304953B1 (en) * 2019-08-30 2021-09-27 주식회사 미디움 Peer node and method for processing information thereof, and blockchain platform systems
CN110727731B (en) 2019-09-05 2021-12-21 创新先进技术有限公司 Method for adding node in block chain network and block chain system
CN110730204B (en) * 2019-09-05 2022-09-02 创新先进技术有限公司 Method for deleting nodes in block chain network and block chain system
CN112769878B (en) * 2019-11-01 2022-09-20 中国电信股份有限公司 Service implementation system and method based on block chain
CN111369358B (en) * 2020-02-10 2023-09-12 杭州溪塔科技有限公司 Block chain consensus method and device and electronic equipment
KR102315226B1 (en) 2020-03-16 2021-10-20 이정우 Block chain system based on consensus algorithm of proof-of-rule and method thereof
CN111464633B (en) * 2020-03-31 2023-03-21 成都质数斯达克科技有限公司 Consensus method and system for transaction information of block chain
CN111654415B (en) * 2020-05-28 2021-09-10 腾讯科技(深圳)有限公司 Block chain based information processing method, device, equipment and readable storage medium
CN113256426B (en) * 2020-05-29 2023-08-04 支付宝(杭州)信息技术有限公司 Data processing method, device, equipment and medium
CN111522683B (en) 2020-07-03 2020-10-02 支付宝(杭州)信息技术有限公司 Consensus node changing method and related device for badger Byzantine fault-tolerant consensus mechanism
WO2022094068A1 (en) * 2020-10-30 2022-05-05 Intel Corporation Providing on-demand localized services via hosting networks in fifth-generation (5g) systems
KR20220120247A (en) * 2021-02-23 2022-08-30 (주)제이앤피메디 System and method for collecting of clinical trial data based on block-chain
CN113541957A (en) * 2021-07-08 2021-10-22 中国工商银行股份有限公司 Business supervision method, device and equipment based on block chain
CA3231084A1 (en) * 2021-09-07 2023-03-16 Mohammad JALALZAI Methods and systems for fast consensus within distributed ledgers
CN114281605B (en) * 2022-03-07 2022-06-21 杭州费尔斯通科技有限公司 Calculation method and system based on block chain partitioned storage
CN115412464B (en) * 2022-11-01 2023-03-24 江苏荣泽信息科技股份有限公司 Dynamic expansion method of block chain based on flow
CN115883315B (en) * 2023-03-01 2023-07-28 中国信息通信研究院 Node joining method, device, electronic equipment and storage medium in blockchain network

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105404701A (en) * 2015-12-31 2016-03-16 浙江图讯科技股份有限公司 Peer-to-peer network-based heterogeneous database synchronization method
CN105976231A (en) * 2016-06-24 2016-09-28 深圳前海微众银行股份有限公司 Asset management method based on intelligent block chain contracts and nodes
US20160321676A1 (en) * 2015-05-01 2016-11-03 Monegraph, Inc. Sharing content within social network services
CN106611061A (en) * 2016-12-29 2017-05-03 北京众享比特科技有限公司 Database write-in method and system based on block chain network
WO2017079218A1 (en) * 2015-11-05 2017-05-11 Mastercard International Incorporated Method and system for processing of a blockchain transaction in a transaction processing network
CN107395665A (en) * 2017-05-22 2017-11-24 阿里巴巴集团控股有限公司 A kind of block chain service handling and business common recognition method and device

Family Cites Families (43)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7543300B2 (en) * 2004-11-16 2009-06-02 International Business Machines Corporation Interface for application components
US7409485B1 (en) * 2005-10-27 2008-08-05 Cisco Technology, Inc. Optimized data transfer for a data bus
US20080155224A1 (en) * 2006-12-21 2008-06-26 Unisys Corporation System and method for performing input/output operations on a data processing platform that supports multiple memory page sizes
US7783666B1 (en) * 2007-09-26 2010-08-24 Netapp, Inc. Controlling access to storage resources by using access pattern based quotas
CN101414917B (en) 2007-10-19 2011-03-16 华为技术有限公司 Method for saving internal memory space, data management network element and network system
JP5491800B2 (en) * 2009-09-04 2014-05-14 フェリカネットワークス株式会社 Management server, information processing apparatus, program, and information processing system
US8621634B2 (en) * 2011-01-13 2013-12-31 F-Secure Oyj Malware detection based on a predetermined criterion
US9049238B2 (en) * 2011-04-26 2015-06-02 Jeffrey Scuba System for creating anonymous social gatherings
US10552804B2 (en) * 2011-04-29 2020-02-04 Verizon Patent And Licensing Inc. Methods and systems for providing subsidized access to network content by way of a secure connection
US9251633B2 (en) * 2011-06-22 2016-02-02 Honeywell International Inc. Monitoring access to a location
US9619668B2 (en) * 2013-09-16 2017-04-11 Axis Ab Managing application data in distributed control systems
US9462044B1 (en) * 2013-11-25 2016-10-04 Ca, Inc. Secure user, device, application registration protocol
US20160026983A1 (en) * 2014-07-25 2016-01-28 Cisco Technology, Inc. System and method for brokering electronic data in a network environment
US9531749B2 (en) * 2014-08-07 2016-12-27 International Business Machines Corporation Prevention of query overloading in a server application
CN105700819B (en) * 2014-11-28 2019-04-12 国际商业机器公司 Method and system for network data storage
CN104679830A (en) 2015-01-30 2015-06-03 乐视网信息技术(北京)股份有限公司 File processing method and device
US9436923B1 (en) * 2015-02-26 2016-09-06 Skuchain, Inc. Tracking unitization occurring in a supply chain
JP6277988B2 (en) * 2015-03-25 2018-02-14 コニカミノルタ株式会社 Image forming apparatus, consumable management apparatus, system, and program
JP6603485B2 (en) * 2015-06-11 2019-11-06 株式会社日立製作所 Electricity business profit and loss calculation system
US9716710B2 (en) * 2015-06-26 2017-07-25 Intel Corporation Technologies for virtualized access to security services provided by a converged manageability and security engine
WO2017010455A1 (en) * 2015-07-13 2017-01-19 日本電信電話株式会社 Contract agreement method, agreement verification method, contract agreement system, agreement verification device, contract agreement device, contract agreement program and agreement verification program
JP6948261B2 (en) 2015-07-15 2021-10-13 国立大学法人大阪大学 Method for cryopreserving pluripotent stem cells or cardiomyocytes derived from adipose tissue or bone marrow-derived mesenchymal stem cells
US10466970B2 (en) * 2015-10-20 2019-11-05 Sap Se Jurisdiction based localizations as a service
US10567499B1 (en) * 2015-12-02 2020-02-18 Amazon Technologies, Inc. Unsupervised round robin catch up algorithm
WO2017149149A1 (en) * 2016-03-03 2017-09-08 Cadami Ug (Haftungsbeschränkt) Identification coding device and identification coding device for data distribution in networks, and network elements comprising such devices
CN109313763B (en) * 2016-03-31 2023-02-28 比特飞翔区块链株式会社 Hierarchical network system and node for hierarchical network system
CN106228446B (en) * 2016-05-12 2019-09-13 北京众享比特科技有限公司 Transaction in assets plateform system and method based on privately owned block chain
US20170374568A1 (en) * 2016-06-27 2017-12-28 Able Device, Inc. Adaptive network access service
CN106372868B (en) * 2016-09-06 2020-02-18 联动优势科技有限公司 Verification method and device for transaction data written into block chain
CN106411774A (en) * 2016-09-06 2017-02-15 联动优势科技有限公司 Method and device for controlling transaction data volume
CN106446067B (en) 2016-09-06 2020-02-18 联动优势科技有限公司 Method and device for acquiring transaction data
US10581615B2 (en) * 2016-09-18 2020-03-03 Cloudminds (Shenxhen) Robotics) Systems Co., Ltd. Blockchain-based identity authentication method, device, node and system
CN106385319B (en) * 2016-09-29 2020-11-27 江苏通付盾科技有限公司 Method and system for verifying information in block chain network
US10360191B2 (en) * 2016-10-07 2019-07-23 International Business Machines Corporation Establishing overlay trust consensus for blockchain trust validation system
CN106534273B (en) * 2016-10-31 2022-04-15 中金云金融(北京)大数据科技股份有限公司 Block chain metadata storage system and storage method and retrieval method thereof
CN106650494B (en) 2016-12-16 2019-07-16 杭州嘉楠耘智信息科技有限公司 Data processing method and device
US11190360B2 (en) * 2016-12-23 2021-11-30 Cloudminds (Shanghai) Robotics Co., Ltd. Method, apparatus, node, signature device and system for generating block of blockchain
US10621150B2 (en) * 2017-03-05 2020-04-14 Jonathan Sean Callan System and method for enforcing the structure and content of databases synchronized over a distributed ledger
CN107391320B (en) * 2017-03-10 2020-07-10 创新先进技术有限公司 Consensus method and device
US10757103B2 (en) * 2017-04-11 2020-08-25 Xage Security, Inc. Single authentication portal for diverse industrial network protocols across multiple OSI layers
CN107392040B (en) * 2017-04-28 2019-08-09 阿里巴巴集团控股有限公司 A kind of method and device of common recognition verifying
CN107392623B (en) * 2017-05-22 2020-09-11 创新先进技术有限公司 Service execution method and device
CN107590738A (en) * 2017-08-24 2018-01-16 阿里巴巴集团控股有限公司 Processing method, device and the server of selection common recognition node

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160321676A1 (en) * 2015-05-01 2016-11-03 Monegraph, Inc. Sharing content within social network services
WO2017079218A1 (en) * 2015-11-05 2017-05-11 Mastercard International Incorporated Method and system for processing of a blockchain transaction in a transaction processing network
CN105404701A (en) * 2015-12-31 2016-03-16 浙江图讯科技股份有限公司 Peer-to-peer network-based heterogeneous database synchronization method
CN105976231A (en) * 2016-06-24 2016-09-28 深圳前海微众银行股份有限公司 Asset management method based on intelligent block chain contracts and nodes
CN106611061A (en) * 2016-12-29 2017-05-03 北京众享比特科技有限公司 Database write-in method and system based on block chain network
CN107395665A (en) * 2017-05-22 2017-11-24 阿里巴巴集团控股有限公司 A kind of block chain service handling and business common recognition method and device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110430101A (en) * 2019-08-28 2019-11-08 杭州领智云画科技有限公司 Service indication collecting method, device, equipment and system applied to CDN
CN112954009A (en) * 2021-01-27 2021-06-11 咪咕音乐有限公司 Block chain consensus method, device and storage medium

Also Published As

Publication number Publication date
TWI679547B (en) 2019-12-11
US10938577B2 (en) 2021-03-02
US20190327097A1 (en) 2019-10-24
CN107395665A (en) 2017-11-24
KR102204256B1 (en) 2021-01-19
EP3886403B1 (en) 2023-07-05
PH12019501563A1 (en) 2020-02-24
MY194420A (en) 2022-11-30
ES2876943T3 (en) 2021-11-15
TW201901478A (en) 2019-01-01
EP3550803A4 (en) 2020-02-19
JP2020512610A (en) 2020-04-23
SG10202101555QA (en) 2021-03-30
CN107395665B (en) 2020-04-24
SG11201906166YA (en) 2019-08-27
PL3550803T3 (en) 2021-09-20
KR20190092483A (en) 2019-08-07
EP3550803B1 (en) 2021-04-07
EP3550803A1 (en) 2019-10-09
JP6949118B2 (en) 2021-10-13
EP3886403A1 (en) 2021-09-29

Similar Documents

Publication Publication Date Title
WO2018214835A1 (en) Block chain service acceptance and consensus method and device
WO2018177235A1 (en) Block chain consensus method and device
KR102340223B1 (en) Blockchain consensus method and device
WO2018214898A1 (en) Method and device for writing service data in block chain system
CN111917864B (en) Service verification method and device
CN109189835B (en) Method and device for generating data wide table in real time
WO2018177239A1 (en) Service processing and consensus method and device
WO2018177250A1 (en) Block chain based data processing method and device
WO2018171539A1 (en) Method and device for processing service request
US9043383B2 (en) Stream processing using a client-server architecture
WO2019157929A1 (en) File processing method, device, and equipment
WO2016206600A1 (en) Information flow data processing method and device
WO2018177245A1 (en) Block chain-based data processing method and equipment
TWI694342B (en) Data cache method, device and system
US11201870B2 (en) Using commit tokens to coordinate permissions submissions to address transaction conflict in blockchain systems
WO2019196551A1 (en) Payment process configuration and execution method, apparatus and device
WO2019062691A1 (en) Virtual card opening method and system, payment system, and card issuing system
US20160196188A1 (en) Failure recovery of a task state in batch-based stream processing
TW201918878A (en) Task execution method and apparatus
TW202008763A (en) Data processing method and apparatus, and client
CN113256426B (en) Data processing method, device, equipment and medium
US9473561B2 (en) Data transmission for transaction processing in a networked environment
CN111294377B (en) Dependency network request sending method, terminal device and storage medium
WO2017124935A1 (en) Affair processing method and system
CN113986134B (en) Method for storing data, method and device for reading data

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18806911

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 20197019210

Country of ref document: KR

Kind code of ref document: A

Ref document number: 2019536261

Country of ref document: JP

Kind code of ref document: A

ENP Entry into the national phase

Ref document number: 2018806911

Country of ref document: EP

Effective date: 20190702

NENP Non-entry into the national phase

Ref country code: DE