[go: up one dir, main page]

HK40013969A - Event-driven blockchain workflow processing - Google Patents

Event-driven blockchain workflow processing Download PDF

Info

Publication number
HK40013969A
HK40013969A HK62020003306.1A HK62020003306A HK40013969A HK 40013969 A HK40013969 A HK 40013969A HK 62020003306 A HK62020003306 A HK 62020003306A HK 40013969 A HK40013969 A HK 40013969A
Authority
HK
Hong Kong
Prior art keywords
nodes
workflow
node
subset
processing node
Prior art date
Application number
HK62020003306.1A
Other languages
Chinese (zh)
Other versions
HK40013969B (en
Inventor
王吉元
Original Assignee
创新先进技术有限公司
Filing date
Publication date
Application filed by 创新先进技术有限公司 filed Critical 创新先进技术有限公司
Publication of HK40013969A publication Critical patent/HK40013969A/en
Publication of HK40013969B publication Critical patent/HK40013969B/en

Links

Description

Event-driven blockchain workflow processing
Background
Distributed Ledger System (DLS), which may also be referred to as a consensus network and/or a blockchain network, enables participating entities to securely and tamperproof store data. Without reference to any particular use case (e.g., cryptocurrency), DLS is often referred to as a blockchain network. Exemplary types of blockchain networks may include public blockchain networks, private blockchain networks, and federated blockchain networks. The public blockchain network opens all entities to use DLS and participates in consensus processing. A private blockchain network is provided for a particular entity that centrally controls read and write permissions. A federated blockchain network is provided for a selected group of entities that controls the consensus process and includes an access control layer.
In a private blockchain network, multi-party collaboration can be challenging and resource consuming. In a traditional blockchain environment, a large number of nodes may perform the same task. For example, when executing a script (e.g., a smart contract) stored in a blockchain, each node participating in the blockchain network may execute the same instructions in the script in parallel. Such a configuration may be beneficial for achieving a consensus on the outcome of the instruction, but may be inefficient in terms of the resources consumed to achieve this consensus.
Disclosure of Invention
Embodiments herein include a computer-implemented method for event-driven blockchain workflow processing. More particularly, embodiments herein relate to event-driven processing in which workflow nodes manage the processing of tasks originating from blockchains by specifically allocating the tasks to a plurality of other nodes in a blockchain network.
In some embodiments: the actions include: receiving, at a workflow processing node in the blockchain network, a request from a client to execute a workflow program, wherein the workflow program is stored in a blockchain maintained by the blockchain network; identifying, by the workflow processing node, an operation associated with the workflow program; assigning, by the workflow processing node, the identified operation to a subset of the plurality of nodes in the blockchain network, wherein each node in the subset of nodes is configured to perform the operation separately from other nodes in the subset of nodes; identifying, by the workflow processing node, processing results of the performed operation associated with nodes of the subset of nodes, each processing result being associated with a particular node of the subset of nodes and representing a result of the performed operation generated by the particular node; and determining, by the workflow processing node, a consensus result of the operation based on the identified processing results associated with a number of nodes greater than or equal to a consensus threshold matching the consensus result.
Other embodiments include corresponding systems, apparatus, and computer programs, configured to perform the actions of the methods, and encoded on computer storage devices.
These and other embodiments may each optionally include one or more of the following features:
in some cases, the method may include: storing the consensus result of the operation in the blockchain.
In some embodiments, the operation is a first operation, the method further comprising identifying, by the workflow processing node, a final operation associated with the workflow program, wherein the final operation is separate from the first operation and occurs at the end of an ordered instruction set associated with the workflow program; assigning, by the workflow processing node, the final operation to a subset of the nodes; identifying, by the workflow processing node, a processing result of the final operation associated with a node of the subset of nodes; determining a consensus result of the final operation based on the identified processing result; and sending, by the workflow processing node, a response to the client indicating that the workflow program has successfully completed execution.
In some cases, the operation is a first operation, and the method further comprises: identifying, by the workflow processing node, a second operation associated with the workflow program, wherein the second operation is separate from the first operation; assigning, by the workflow processing node, the second operation to the subset of nodes; identifying, by the workflow processing node, a processing result of the second operation associated with a node of the subset of nodes; and determining that there is no consensus result of the second operation based on the number of nodes associated with the same processing result being less than the consensus threshold.
In some embodiments, the method may comprise: sending, by the workflow processing node, a response to the client indicating that the workflow program was not successfully executed.
In some cases, each identified processing result is digitally signed by the associated node.
In some aspects, the workflow program comprises executable bytecode configured to be executed by the plurality of nodes.
In some cases, wherein assigning the identified operation to the subset of nodes comprises: performing, by the workflow processing node, a remote procedure call associated with the operation on each node in the subset of nodes.
In some embodiments, the blockchain is an etherhouse (Ethereum) blockchain and the workflow program is an intelligent contract program.
In some aspects, each node in the blockchain network has associated with it one of a plurality of entities participating in the blockchain network.
In some embodiments, the subset of nodes includes at least one node associated with each of the plurality of entities participating in the blockchain network.
Also provided herein are one or more non-transitory computer-readable storage media coupled to one or more processors and having instructions stored thereon, which, when executed by the one or more processors, cause the one or more processors to perform operations in accordance with embodiments of the methods provided herein.
Also provided herein are systems for implementing the methods provided herein. The system includes one or more processors and a computer-readable storage medium coupled to the one or more processors and having instructions stored thereon that, when executed by the one or more processors, cause the one or more processors to perform operations in accordance with embodiments of the methods provided herein.
It should be appreciated that methods in accordance with the present disclosure may include any combination of the aspects and features described herein. That is, methods according to the present disclosure are not limited to the combinations of aspects and features specifically described herein, but also include any combination of the aspects and features provided.
The details of one or more embodiments of the disclosure are set forth in the accompanying drawings and the description below. Other features and advantages will be apparent from the text and drawings, and from the claims.
Drawings
FIG. 1 depicts an exemplary environment that can be used to implement embodiments herein.
Fig. 2 depicts an exemplary conceptual architecture according to embodiments herein.
Fig. 3 depicts an exemplary system for event-driven blockchain workflow processing according to embodiments herein.
FIG. 4 depicts an exemplary process for executing a workflow program according to embodiments herein.
FIG. 5 depicts an exemplary process for executing a workflow program according to embodiments herein.
FIG. 6 depicts an exemplary process that may be performed in accordance with embodiments herein.
Like reference symbols in the various drawings indicate like elements.
Detailed Description
Embodiments herein include a computer-implemented method for event-driven blockchain workflow processing. More particularly, embodiments herein relate to event-driven blockchain workflow processing. In some implementations, the actions include: receiving, at a workflow processing node in a blockchain network, a request from a client to execute a workflow program, wherein the workflow program is stored in a blockchain maintained by the blockchain network; identifying, by a workflow processing node, an operation associated with a workflow program; assigning, by the workflow processing node, the identified operation to a subset of the plurality of nodes in the blockchain network, wherein each node in the subset of nodes is configured to perform the operation separately from other nodes in the subset of nodes; identifying, by the workflow processing node, processing results of the performed operations associated with the nodes in the subset of nodes, each processing result being associated with a particular node in the subset of nodes and representing a result of the performed operation generated by the particular node; and determining a consensus result of the operation based on the identified processing results associated with a number of nodes greater than or equal to a consensus threshold matching the consensus result.
Further background is provided for embodiments herein, and as noted above, a Distributed Ledger System (DLS), which may also be referred to as a consensus network (e.g., consisting of point-to-point nodes) and a blockchain network, enables participating entities to securely and non-tamperproof conduct transactions and store data. Although the term "blockchain" is typically associated with various cryptocurrency networks, blockchains as used herein generally refer to DLS without reference to any particular use case.
The blockchain is a data structure that stores transactions in a manner that allows future transactions to be verified to remain consistent with all previous transaction activities. Thus, the transactions recorded on the blockchain are reliable and trustworthy. A block chain includes one or more blocks. Each block in the chain is linked to the previous block immediately preceding it in the chain by a cryptographic hash value (cryptographichhash) contained in the previous block. Each tile also includes a timestamp, its own cryptographic hash value, and one or more transactions. Transactions that have been verified by nodes in the blockchain network are hashed and compiled into merkel (Merkle) trees. A Merkle tree is a data structure in which data at leaf nodes of the tree is hashed and all hash values in each branch of the tree are concatenated at the root of the branch. This process continues down the tree until the root of the entire tree, where hash values representing all of the data in the tree are stored. By determining whether the hash value is consistent with the structure of the tree, it may be quickly verified whether the hash value is a hash value of a transaction stored in the tree.
A blockchain is a data structure used to store transactions, while a blockchain network is a network of computing nodes used to manage, update, and maintain a particular blockchain. As described above, the blockchain network may be provided as a public blockchain network, a private blockchain network, or a federated blockchain network. In a public blockchain network, the consensus process is controlled by nodes of the consensus network. For example, hundreds, thousands, or even millions of entities may cooperate in a public blockchain network, each entity operating at least one node in the public blockchain network. Thus, a public blockchain network may be considered a public network with respect to participating entities. In some examples, most entities (nodes) must sign each block to make the block valid and be added to the blockchain (distributed ledger) of the blockchain network. Exemplary public blockchain networks include various cryptocurrency networks that are point-to-point payment networks. As noted above, the term blockchain is generally used to refer to a distributed ledger, without specifying any particular cryptocurrency network.
Typically, public blockchain networks support open transactions. The open transaction is shared by all nodes within the public blockchain network and stored in the global blockchain. A global blockchain is a chain of blocks that is replicated across all nodes. That is, all nodes are in a fully-consensus state with respect to the global blockchain. To achieve consensus (e.g., agree to add blocks to a blockchain), a consensus protocol is implemented within the public blockchain network. Exemplary consensus protocols include, but are not limited to, proof of work volume (POW) implemented in cryptocurrency networks.
Typically, a private blockchain network is provided for a particular entity that centrally controls read and write permissions. The entity controls which nodes can participate in the blockchain network. Thus, private blockchain networks are often referred to as authority networks, which limit who is allowed to participate in the network, as well as their level of participation (e.g., only in certain transactions). Various types of access control mechanisms may be used (e.g., existing participants vote to add a new entity, and regulatory authorities may control permissions).
Typically, a federated blockchain network is private between the participating entities. In a federated blockchain network, consensus processes are controlled by a set of authorized nodes, one or more of which are operated by respective entities (e.g., financial institutions, insurance companies). For example, a federation of ten (10) entities (e.g., financial institutions, insurance companies) may operate a federated blockchain network, and each entity may operate at least one node in the federated blockchain network. Thus, a federated blockchain network can be considered a private network associated with the participating entities. In some examples, each entity (node) must sign each chunk in order for the chunk to be valid and added to the chain of chunks. In some examples, at least a subset of the entities (nodes) (e.g., at least 7 entities) must sign each tile in order for the tile to be valid and added to the tile chain.
Embodiments herein will be further described in detail with reference to private blockchain networks in which restrictions are placed on who may be allowed to participate in the network. However, it is contemplated that embodiments herein may be implemented in any suitable type of blockchain network.
In view of the above background, embodiments herein will be described in further detail. More particularly, as described above, embodiments herein relate to event-driven processing in which workflow nodes manage the processing of tasks originating from blockchains by specifically allocating the tasks to a plurality of other nodes in a blockchain network.
The techniques described herein represent a technical solution to the distributed processing of poorly performing technical problems for tasks in blockchain networks, while maintaining a consensus mechanism that is one of the key benefits of blockchain techniques. For example, rather than each node competing to complete each operation as in conventional implementations, the present techniques are particularly directed to managing which nodes in a blockchain network perform a particular operation. The technique also maintains a consensus mechanism by sending the same operation to multiple nodes and configuring a threshold for the number of nodes that must achieve a consensus result. Furthermore, the event-driven basic features of the present technology (e.g., workflow processing nodes sending specific messages to nodes to allocate operations) also improve performance because nodes may simply wait for events from workflow processing nodes to begin processing, rather than periodically polling the blockchain for updates.
FIG. 1 depicts an example of an environment 100 that may be used to perform embodiments herein. In some examples, the exemplary environment 100 enables entities to participate in the private blockchain network 102. The exemplary environment 100 includes computing devices 106, 108 and a network 110. In some examples, the network 110 includes a Local Area Network (LAN), a Wide Area Network (WAN), the internet, or a combination thereof, and connects network sites, user devices (e.g., computing devices), and backend systems. In some examples, network 110 may be accessed through wired and/or wireless communication links. In some examples, network 110 enables communication with private blockchain network 102 and communication within private blockchain network 102. In general, the network 110 represents one or more communication networks.
In the depicted example, the computing systems 106, 108 may each comprise any suitable computing system capable of participating as a node in the private blockchain network 102. Exemplary computing devices include, but are not limited to, servers, desktop computers, laptop computers, tablet computing devices, and smart phones. In some examples, the computing systems 106, 108 carry one or more computer-implemented services for interacting with the private blockchain network 102. For example, the computing system 106 may host a computer-implemented service, such as a transaction management system, of a first entity (e.g., user a) that the first entity uses to manage its transactions with one or more other entities (e.g., other users). The computing system 108 may host a computer-implemented service, such as a transaction management system, of a second entity (e.g., user B), for example, that the second entity uses to manage its transactions with one or more other entities (e.g., other users). In the example of fig. 1, private blockchain network 102 is represented as a Peer-to-Peer network of nodes (Peer-to-Peer network), and computing systems 106, 108 provide nodes of first and second entities, respectively, participating in private blockchain network 102.
Fig. 2 depicts an exemplary architecture 200 according to embodiments herein. The exemplary conceptual architecture 200 includes a physical layer 202, a bearer service layer 204, and a blockchain network layer 206. In the depicted example, the entity layer 202 includes three entities, entity _1(E1), entity _2(E2), entity _3(E3), each having a respective transaction management system 208.
In the depicted example, the bearer service layer 204 includes an interface 210 for each transaction management system 208. In some examples, each transaction management system 208 communicates with its corresponding interface 210 over a network (e.g., network 110 of fig. 1) using a protocol (e.g., hypertext transfer security protocol (HTTPS)). In some examples, each interface 210 provides a communication connection between the respective transaction management system 208 and the blockchain network layer 206. More specifically, the interface 210 communicates with a blockchain network 212 in the blockchain network layer 206. In some examples, communication between the interface 210 and the blockchain network layer 206 is performed using Remote Procedure Calls (RPCs). In some examples, the interface 210 "carries" blockchain network nodes for the respective transaction management systems 208. For example, interface 210 provides an Application Programming Interface (API) for accessing blockchain network 212.
As described herein, the blockchain network 212 is provided as a point-to-point network that includes a plurality of nodes 214, the plurality of nodes 214 tamper-tightly recording information in blockchain 216. Although a single blockchain 216 is schematically depicted, multiple copies of blockchain 216 are provided and maintained on blockchain network 212. For example, each node 214 stores one copy of the block chain. In some implementations, blockchain 216 stores information associated with transactions conducted between two or more entities participating in a private blockchain network.
Fig. 3 depicts an exemplary system for event-driven blockchain workflow processing according to embodiments herein. As shown, the system includes a workflow processing node 305 in communication with other nodes 315a-315c and 320a, 320b participating in the blockchain network. The blockchain network includes blockchains 316. The program 325 is stored in the blockchain 316 and includes a plurality of operations or instructions 330. The client 340 communicates with the workflow processing node 305.
In operation, the client 340 sends a request to the workflow processing node 305 to execute the workflow program 305 stored in the blockchain 316. The workflow processing node 305 reads the program 325 from the blockchain 316 and identifies an operation 330 to be performed as part of the program 325. The workflow processing node 305 then selects a plurality of nodes in the blockchain network to perform the identified operation 330. In the example depicted in FIG. 3, the workflow processing node 305 has selected the assigned nodes 315a-315c, while the unassigned nodes 320a, 320b will not process instructions. Once the workflow processing node 305 has selected the nodes 315a-315c to perform the operation, the assigned nodes 315a-315c each perform the operation and return the results of the operation to the workflow processing node 305. Because the nodes 315a-315c each independently perform the operation 330, the nodes 315a-315c each provide the results of the operation to the workflow processing node 305. The workflow processing node 305 analyzes the received results to determine whether the nodes 315a-315c have achieved a consensus result for operation 330. This process will be described in more detail with respect to fig. 4 and 5.
Fig. 4 depicts an exemplary process 400 for executing a workflow program (e.g., program 325 in fig. 3) according to embodiments herein. As shown, this process involves interaction between workflow processing node 305 and nodes 315a-315c in FIG. 3.
At 405, the workflow processing node 305 receives a client request. In some implementations, the request may be received by the workflow processing node 305 over a network, such as a private Internet Protocol (IP) network, a public IP network such as the internet, or other network. The request may be formatted according to a network communication protocol, such as hypertext transfer protocol (HTTP), Remote Procedure Call (RPC), or other protocol. The request may include an identification of a workflow program for execution by a node in the blockchain network. In some embodiments, the request may include a location within the blockchain where the workflow program is stored.
At 410, the workflow processing node retrieves the requested workflow program from the blockchain. In some cases, the workflow program is an intelligent contract program stored in a blockchain. The workflow program may also be a set of bytecodes (e.g., Java bytecodes) stored in a blockchain. The workflow program may also be an instruction set of any programming language that is configured to be executed by the nodes 315a-315c under the direction of the workflow processing node 305.
At 415a-415c, the workflow processing node assigns a first operation from the retrieved workflow program to a node 315a-315 c. At 420a-420c, the nodes 315a-315c independently perform the assigned first operation. At 425a-425c, the nodes 315a-315c each send results obtained from performing the first operation. For example, the result may represent an updated execution state of the workflow program after the operation is performed, including, for example, an updated value of a memory space associated with the workflow program, an updated program counter, or other information about the state of the workflow program after the operation is completed.
At 430, the workflow processing node 305 analyzes the results from the nodes 315a-315c to determine if a consensus result has been achieved. As shown, the workflow processing node 305 may be configured with a consensus threshold that specifies the number of nodes required to return the same result in order to achieve a consensus result. As shown, if the number of consistent results is greater than or equal to this threshold, the workflow processing node 305 determines that consensus has been achieved. In the exemplary process 400, the threshold is 3 and the results from all 3 nodes 315a-315c are the same, indicating that consensus has been achieved.
At 435, the workflow processing node 305 determines that consensus has been achieved based on the analysis. The workflow processing node 305 adds the result of the first operation to the blockchain and repeats the process 400 starting at 415a with the next operation of the workflow program.
Fig. 5 depicts an exemplary process 500 for executing a workflow program according to embodiments herein. Process 500 provides an example of how the workflow processing node 305 may process the results of different operations received from the assigned nodes 315a-315 c.
At 505, the workflow processing node 305 receives a client request. In some implementations, the request may be received by the workflow processing node 305 over a network, such as a private IP network, a public IP network such as the internet, or other network. The request may be formatted according to a network communication protocol, such as HTTP, RPC, or other protocol. The request may include an identification of a workflow program for execution by a node of the blockchain network. In some embodiments, the request may include a location within the blockchain where the workflow program is stored.
At 510, the workflow processing node retrieves the requested workflow program from the blockchain. In some cases, the workflow program is an intelligent contract program stored in a blockchain. The workflow program may also be a set of bytecodes (e.g., Java bytecodes) stored in a blockchain. The workflow program may also be an instruction set of any programming language that is configured to be executed by the nodes 315a-315c under the direction of the workflow processing node 305.
At 515a-515c, the workflow processing node assigns a first operation from the retrieved workflow program to a node 315a-315 c. At 520a-520c, the nodes 315a-315c independently perform the assigned first operation. At 525a-525c, the nodes 315a-315c each send results obtained from performing the first operation. For example, the result may represent an updated execution state of the workflow program after the operation is performed, including, for example, an updated value of a memory space associated with the workflow program, an updated program counter, or other information about the state of the workflow program after the operation is completed.
At 530, the workflow processing node 305 analyzes the results from the nodes 315a-315c to determine if a consensus result has been achieved. As shown, the results from node 315c are different than the results from nodes 315a, 315 b. Thus, only two of the three nodes return the same result. Considering that the consensus threshold is 3 as described above, the number of nodes returning the same result (2) is less than the threshold, indicating that no consensus is achieved for the result of the operation.
At 535, based on determining that the consensus has not been reached, the workflow processing node 305 terminates execution of the workflow program. In some implementations, the workflow processing node 305 may send an indication to the client 340 that the requested workflow program has been terminated due to a lack of consensus. In some cases, the workflow processing node 305 may "roll back" to any previous operation in the program by removing the transaction from the blockchain or submitting additional transactions to undo the effect of the previous operation (e.g., credit any account to return funds paid out (debit) for the operation of the terminated program).
In some embodiments, it is determined that consensus has not formed if the number of nodes agreeing on the result after a predetermined time has elapsed is less than a threshold.
Fig. 6 depicts an exemplary process 600 that may be performed in accordance with embodiments herein. In some implementations, exemplary process 600 may be performed using one or more computer-executable programs executed using one or more computing devices.
At 605, a workflow processing node in a blockchain network receives a request from a client to execute a workflow program, wherein the workflow program is stored in a blockchain maintained by the blockchain network. In some cases, the blockchain is an etherhouse (Ethereum) blockchain, and the workflow process is an intelligent contract process.
At 610, the workflow processing node identifies an operation associated with the workflow program. In some cases, the workflow program includes executable bytecode configured to be executed by a plurality of nodes.
At 615, the workflow processing node assigns the identified operation to a subset of the plurality of nodes in the blockchain network, wherein each node in the subset of nodes is configured to perform the operation separately from other nodes in the subset of nodes. In some cases, assigning the identified operation to the subset of nodes includes performing, by the workflow processing node, a remote procedure call associated with the operation on each node in the subset of nodes. In some cases, each node in the blockchain network has associated therewith one of a plurality of entities participating in the blockchain network, and the subset of nodes includes at least one node associated with each of the plurality of entities participating in the blockchain network.
At 620, the workflow processing node identifies processing results of the performed operations associated with the nodes in the subset of nodes, each processing result being associated with a particular node in the subset of nodes and representing a result of the performed operation generated by the particular node. In some cases, each identified processing result is digitally signed by the associated node.
At 625, the workflow processing node determines a consensus result for the operation based on the identified processing results associated with the plurality of nodes, the number of the plurality of nodes being greater than or equal to a consensus threshold that matches the consensus result. In some embodiments, the workflow processing node stores the consensus results of the operations in the blockchain.
In some cases, the operation described above is a first operation, and process 600 includes: identifying, by the workflow processing node, a final operation associated with the workflow program, wherein the final operation is separate from the first operation and occurs at the end of the ordered set of instructions associated with the workflow program; assigning, by the work processing node, the final operation to the subset of nodes; identifying, by the workflow processing node, a processing result of a final operation associated with a node in the subset of nodes; determining a consensus result of the final operation based on the identified processing result; and sending, by the workflow processing node, a response to the client indicating that the workflow program has successfully completed execution.
In an embodiment, the above operation is a first operation, and process 600 includes: identifying, by the workflow processing node, a second operation associated with the workflow program, wherein the second operation is separate from the first operation; assigning, by the workflow processing node, the second operation to the subset of nodes; identifying, by the workflow processing node, a processing result of a second operation associated with a node in the subset of nodes; and determining that there is no consensus result of the second operation based on the number of nodes associated with the same processing result being less than the consensus threshold. In some cases, the workflow processing node sends a response to the client indicating that the workflow program was not successfully executed.
Implementations of the subject matter, acts, and operations described herein may be implemented in digital electronic circuitry, tangibly embodied computer software or firmware, computer hardware, including the structures disclosed herein and structural equivalents thereof, or combinations of one or more of them. Implementations of the subject matter described herein may be implemented as one or more computer programs, e.g., one or more modules of computer program instructions, encoded on a computer program carrier for execution by, or to control the operation of, data processing apparatus. The carrier may be a tangible, non-transitory computer storage medium. Alternatively or additionally, the carrier may be an artificially generated propagated signal, e.g., a machine-generated electrical, optical, or electromagnetic signal, that is generated to encode information for transmission to suitable receiver apparatus for execution by the data processing apparatus. The computer storage medium may be or be partially a machine-readable storage device, a machine-readable storage substrate, a random or serial access memory device, or a combination of one or more of them. Computer storage media is not a propagated signal.
The term "data processing apparatus" includes all types of apparatus, devices, and machines for processing data, including by way of example a programmable processor, a computer, or multiple processors or computers. The data processing apparatus may comprise special purpose logic circuitry, e.g., an FPGA (field programmable gate array), an ASIC (application-specific integrated circuit), or a GPU (graphics processing unit). In addition to hardware, the apparatus can include code that creates an execution environment for the computer program, e.g., code that constitutes processor firmware, a protocol stack, a database management system, an operating system, or a combination of one or more of them.
A computer program can also be referred to or described as a program, software application, app, module, software module, engine, script, or code and can be written in any form of programming language, including compiled or interpreted languages, declarative or procedural languages; it can be deployed in any form, including as a stand-alone program or as a module, component, engine, subroutine, or other unit suitable for execution in a computing environment, which may include one or more computers interconnected by a communications data network at one or more locations.
A computer program may, but need not, correspond to a file in a file system. The computer program may be stored in: a portion of a file that holds other programs or data, e.g., one or more scripts stored in a markup language document; a single file dedicated to the program in question; or multiple coordinated files, such as files that store one or more modules, sub programs, or portions of code.
The processes and logic flows described herein can be performed by one or more computers executing one or more computer programs to perform operations by operating on input data and generating output. The processes and logic flows can also be performed by, and in combination with, special purpose logic circuitry, e.g., an FPGA, an ASIC, a GPU, etc., and one or more programmed computers.
A computer suitable for executing a computer program may be based on a general and/or special purpose microprocessor, or any other kind of central processing unit. Generally, a central processing unit will receive instructions and data from a read-only memory and/or a random access memory. Elements of a computer may include a central processing unit for executing instructions and one or more memory devices for storing instructions and data. The central processing unit and the memory can be supplemented by, or integrated in, special purpose logic circuitry.
Generally, a computer can be coupled to one or more non-transitory computer-readable storage media (also can be referred to as computer-readable memory). The storage medium coupled to the computer may be internal components of the computer (e.g., an integrated hard drive) or external components (e.g., a Universal Serial Bus (USB) hard drive or a network-accessible storage system). The storage medium may be, for example, a magnetic disk, a magneto-optical disk, an optical disk, a solid state drive, a network storage resource such as a cloud storage system, or other types of storage media. However, a computer need not have such devices. Moreover, a computer may be embedded in another device, e.g., a mobile telephone, a Personal Digital Assistant (PDA), a mobile audio or video player, a game console, a Global Positioning System (GPS) receiver, or a portable storage device, e.g., a Universal Serial Bus (USB) flash drive, to name a few.
To provide for interaction with a user, embodiments of the subject matter described herein can be implemented on or configured to communicate with a computer having: a display device, e.g., an LCD (liquid crystal display) monitor, for displaying information to a user; and input devices through which a user may provide input to the computer, such as a keyboard and a pointing device, such as a mouse, trackball or touch pad. Other types of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback, such as visual feedback, auditory feedback, or tactile feedback; and may receive any form of input from the user, including acoustic, speech, or tactile input. Further, the computer may interact with the user by sending and receiving documents to and from the device used by the user; for example, by sending a web page to a web browser on the user device in response to a request received from the web browser, or by interacting with an application (app) running on the user device, such as a smartphone or electronic tablet. In addition, the computer may interact with the user by sending a text message or other form of message to a personal device (e.g., a smartphone running a messaging application) and receiving a response message from the user in return.
The term "configured" is used herein in connection with systems, apparatuses, and computer program components. For a system of one or more computers configured to perform particular operations or actions, it is meant that the system has installed thereon software, firmware, hardware, or a combination thereof that, when executed, causes the system to perform the operations or actions. For one or more computer programs configured to perform specific operations or actions, it is meant that the one or more programs include instructions, which when executed by a data processing apparatus, cause the apparatus to perform the operations or actions. By dedicated logic circuitry configured to perform a particular operation or action is meant that the circuitry has electronic logic to perform the operation or action.
While this document contains many specific implementation details, these should not be construed as limitations on the scope of what is claimed, as defined by the claims themselves, but rather as descriptions of specific features of particular embodiments. Certain features that are described herein in the context of separate embodiments can also be implemented in combination in a single embodiment. Conversely, various features that are described in the context of a single embodiment can also be implemented in multiple embodiments separately or in any suitable subcombination. Furthermore, although features may be described above as acting in certain combinations and even initially claimed as such, one or more features from a claimed combination can in some cases be excised from the combination, and the claimed combination may be directed to a subcombination or variation of a subcombination.
Similarly, while operations are depicted in the drawings and recited in the claims in a particular order, this should not be understood as: it may be desirable to perform the operations in the particular order shown, or in sequence, or to perform all of the operations shown, in order to achieve desirable results. In some cases, multitasking and parallel processing may be advantageous. Moreover, the division of the various system modules and components in the embodiments described above should not be understood as requiring such division in all embodiments, and it should be understood that the described program components and systems can generally be integrated together in a single software product or packaged into multiple software products.
Specific embodiments of the subject matter have been described. Other embodiments are within the scope of the following claims. For example, the actions recited in the claims can be performed in a different order and still achieve desirable results. As one example, the processes depicted in the accompanying figures do not require the particular order shown, or sequence, to achieve desirable results. In some cases, multitasking and parallel processing may be advantageous.

Claims (20)

1. A computer-implemented method for event-driven workflow processing in a blockchain network comprising a plurality of nodes, the method comprising:
receiving, at a workflow processing node in the blockchain network, a request from a client to execute a workflow program, wherein the workflow program is stored in a blockchain maintained by the blockchain network;
identifying, by the workflow processing node, an operation associated with the workflow program;
assigning, by the workflow processing node, the identified operation to a subset of the plurality of nodes in the blockchain network, wherein each node in the subset of nodes is configured to perform the operation separately from other nodes in the subset of nodes;
identifying, by the workflow processing node, processing results of the performed operation associated with nodes of the subset of nodes, each processing result being associated with a particular node of the subset of nodes and representing a result of the performed operation generated by the particular node; and
determining, by the workflow processing node, a consensus result of the operation based on the identified processing results associated with a number of nodes greater than or equal to a consensus threshold matching the consensus result.
2. The computer-implemented method of claim 1, further comprising:
storing the consensus result of the operation in the blockchain.
3. The computer-implemented method of claim 1, wherein the operation is a first operation, the method further comprising:
identifying, by the workflow processing node, a final operation associated with the workflow program, wherein the final operation is separate from the first operation and occurs at the end of an ordered instruction set associated with the workflow program;
assigning, by the workflow processing node, the final operation to a subset of the nodes;
identifying, by the workflow processing node, a processing result of the final operation associated with a node of the subset of nodes;
determining a consensus result of the final operation based on the identified processing result; and
sending, by the workflow processing node, a response to the client indicating that the workflow program has successfully completed execution.
4. The computer-implemented method of claim 1, wherein the operation is a first operation, the method further comprising:
identifying, by the workflow processing node, a second operation associated with the workflow program, wherein the second operation is separate from the first operation;
assigning, by the workflow processing node, the second operation to the subset of nodes;
identifying, by the workflow processing node, a processing result of the second operation associated with a node of the subset of nodes; and
determining that there is no consensus result for the second operation based on the number of nodes associated with the same processing result being less than the consensus threshold.
5. The computer-implemented method of claim 4, further comprising:
sending, by the workflow processing node, a response to the client indicating that the workflow program was not successfully executed.
6. The computer-implemented method of claim 1, wherein each identified processing result is digitally signed by the associated node.
7. The computer-implemented method of claim 1, wherein the workflow program comprises executable bytecode configured to be executed by the plurality of nodes.
8. The computer-implemented method of claim 1, wherein assigning the identified operation to the subset of nodes comprises:
performing, by the workflow processing node, a remote procedure call associated with the operation on each node in the subset of nodes.
9. The computer-implemented method of claim 1,
the blockchain is an Ether Fang blockchain, and
the workflow program is an intelligent contract program.
10. The computer-implemented method of claim 1, wherein each node in the blockchain network has associated with it one of a plurality of entities participating in the blockchain network.
11. The computer-implemented method of claim 10, wherein the subset of nodes comprises at least one node associated with each of the plurality of entities participating in the blockchain network.
12. A non-transitory computer-readable storage medium coupled to one or more computers and configured with instructions executable by the one or more computers for:
receiving, at a workflow processing node in the blockchain network, a request from a client to execute a workflow program, wherein the workflow program is stored in a blockchain maintained by the blockchain network;
identifying, by the workflow processing node, an operation associated with the workflow program;
assigning, by the workflow processing node, the identified operation to a subset of a plurality of nodes in the blockchain network, wherein each node in the subset of nodes is configured to perform the operation separately from other nodes in the subset of nodes;
identifying, by the workflow processing node, processing results of performed operations associated with nodes in the subset of nodes, each processing result being associated with a particular node in the subset of nodes and representing a result of the performed operation generated by the particular node; and
determining, by the workflow processing node, a consensus result of the operation based on the identified processing results associated with a number of nodes greater than or equal to a consensus threshold matching the consensus result.
13. The non-transitory computer readable storage medium of claim 12, further comprising: storing the consensus result of the operation in the blockchain.
14. The non-transitory computer-readable storage medium of claim 12, wherein the operation is a first operation, and the storage medium is further configured with instructions executable by the one or more computers to:
identifying, by the workflow processing node, a final operation associated with the workflow program, wherein the final operation is separate from the first operation and occurs at a last of an ordered set of instructions associated with the workflow program;
assigning, by the workflow processing node, the final operation to a subset of the nodes;
identifying, by the workflow processing node, a processing result of the final operation associated with a node of the subset of nodes;
determining a consensus result of the final operation based on the identified processing result; and
sending, by the workflow processing node, a response to the client indicating that the workflow program has successfully completed execution.
15. The non-transitory computer-readable storage medium of claim 12, wherein the operation is a first operation, and the storage medium is further configured with instructions executable by the one or more computers to:
identifying, by the workflow processing node, a second operation associated with the workflow program, wherein the second operation is separate from the first operation;
assigning, by the workflow processing node, the second operation to the subset of nodes;
identifying, by the workflow processing node, a processing result of the second operation associated with a node of the subset of nodes; and
determining that there is no consensus result for the second operation based on the number of nodes associated with the same processing result being less than the consensus threshold.
16. The non-transitory computer-readable storage medium of claim 15, further configured with instructions executable by the one or more computers to: sending, by the workflow processing node, a response to the client indicating that the workflow program was not successfully executed.
17. The non-transitory computer-readable storage medium of claim 12, wherein each identified processing result is digitally signed by the associated node.
18. The non-transitory computer-readable storage medium of claim 12, wherein the workflow program comprises executable bytecode configured to be executed by the plurality of nodes.
19. The non-transitory computer-readable storage medium of claim 12, wherein assigning the identified operation to the subset of nodes comprises: performing, by the workflow processing node, a remote procedure call associated with the operation on each node in the subset of nodes.
20. A system, comprising:
one or more computers; and
one or more computer-readable memories coupled to the one or more computers and configured with instructions executable by the one or more computers for:
receiving, at a workflow processing node in the blockchain network, a request from a client to execute a workflow program, wherein the workflow program is stored in a blockchain maintained by the blockchain network;
identifying, by the workflow processing node, an operation associated with the workflow program;
assigning, by the workflow processing node, the identified operation to a subset of a plurality of nodes in the blockchain network, wherein each node in the subset of nodes is configured to perform the operation separately from other nodes in the subset of nodes;
identifying, by the workflow processing node, processing results of performed operations associated with nodes in the subset of nodes, each processing result being associated with a particular node in the subset of nodes and representing a result of the performed operation generated by the particular node; and
determining, by the workflow processing node, a consensus result of the operation based on the identified processing results associated with a number of nodes greater than or equal to a consensus threshold matching the consensus result.
HK62020003306.1A 2018-12-13 Event-driven blockchain workflow processing HK40013969B (en)

Publications (2)

Publication Number Publication Date
HK40013969A true HK40013969A (en) 2020-08-14
HK40013969B HK40013969B (en) 2023-09-22

Family

ID=

Similar Documents

Publication Publication Date Title
US10678597B2 (en) Event-driven blockchain workflow processing
CN110088793B (en) Data isolation in blockchain networks
KR102289612B1 (en) Parallel execution of transactions in a distributed ledger system
KR102247658B1 (en) Processing of blockchain data based on smart contract behavior executed in a trusted execution environment
KR102282770B1 (en) Visual Blockchain Browser
EP3560143B1 (en) Data isolation in a blockchain network
CN111095326A (en) Parallel execution of transactions in a distributed ledger system
CN113711536A (en) Extract data from blockchain network
JP2020525877A (en) Processing and storing blockchain data in a trusted execution environment
US9589153B2 (en) Securing integrity and consistency of a cloud storage service with efficient client operations
CN110998633A (en) Method and apparatus for avoiding double-flower problem in block chain technology based on read-write set model
US12425186B2 (en) Reducing transaction aborts in execute-order-validate blockchain models
HK40013969A (en) Event-driven blockchain workflow processing
Shrivastava et al. Secure Storage and Data Sharing Scheme Using Private Blockchain-Based HDFS Data Storage for Cloud Computing
AU2020452837A1 (en) Provision of remote application action feed cards
HK40013969B (en) Event-driven blockchain workflow processing
HK40028647A (en) A method and apparatus to avoid the double-spending problem in blockchain technology
HK40017316A (en) Parallel execution of transactions in blockchain network
HK40017316B (en) Parallel execution of transactions in blockchain network
HK40020410A (en) Data isolation in a blockchain network
HK40020410B (en) Data isolation in a blockchain network
HK40016603A (en) Blockchain-based crowd sourcing of map applications