Block chain transaction processing method, related device and medium
By building the first tree data structure, efficient search of blockchain addresses is achieved, and the problem of low address acquisition efficiency in the existing technology is solved, and the efficiency of blockchain transaction processing is improved.
Patent Information
- Application Number
- CN202311372687.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-10-20
- Publication Date
- 2025-04-22
AI Technical Summary
In the blockchain system, when resource transfer and contract call, it is necessary to manually search for binary addresses bit by bit, resulting in inefficient address acquisition and affecting the overall transaction processing efficiency.
By constructing a data structure called the first tree, the target hierarchical identification segment is organized according to the hierarchical structure, and efficient search of blockchain addresses is achieved. The specific steps include receiving a blockchain transaction processing request, extracting the target hierarchical identification segment string, and finding a matching candidate hierarchical identification segment by searching the first tree layer by layer, determining the target blockchain address, and finally calling the target object body to perform transaction processing.
It improves the efficiency of blockchain address acquisition, reduces the time for manual search, and improves the overall transaction processing efficiency.
Smart Images

Figure CN119861998A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of blockchain technology, and in particular to a blockchain transaction processing method, related devices and media. Background Art
[0002] Currently, in blockchain systems, various resource pools and various types of contracts are often represented by binary addresses. When resource transfer or contract invocation occurs, manual bit-by-bit search is often required to determine the resource pool and the corresponding address of the contract in the blockchain system. This process often takes a lot of time and results in low efficiency in address acquisition, thus affecting the overall transaction processing efficiency. Summary of the invention
[0003] The embodiments of the present disclosure provide a blockchain transaction processing method, related devices and media, which can improve address acquisition efficiency and thus improve transaction processing efficiency.
[0004] According to one aspect of the present disclosure, a blockchain transaction processing method is provided, comprising:
[0005] receiving a blockchain transaction processing request, the blockchain transaction processing request being used to call a target object body recorded on the blockchain to execute the blockchain transaction processing, the blockchain transaction processing request comprising a target hierarchical identification segment string of the target object body, the target hierarchical identification segment string comprising a plurality of target hierarchical identification segments organized according to a hierarchical structure of a first tree, the first tree listing candidate hierarchical identification segments of each level, and a relationship between the candidate hierarchical identification segments and the candidate hierarchical identification segments of the next level, each of the candidate hierarchical identification segments corresponding to a candidate blockchain address in the first tree;
[0006] Searching the first tree for the target hierarchical identification segment string in descending order of the hierarchical levels to find the candidate hierarchical identification segment that matches the target hierarchical identification segment at the lowest level of the target hierarchical identification segment string;
[0007] Determine the candidate blockchain address corresponding to the candidate hierarchical identification segment matched in the first tree as the target blockchain address;
[0008] The target object body is called based on the target blockchain address to perform the blockchain transaction processing.
[0009] According to one aspect of the present disclosure, a blockchain transaction processing device is provided, comprising:
[0010] A receiving unit, configured to receive a blockchain transaction processing request, wherein the blockchain transaction processing request is used to call a target object body recorded on the blockchain to execute the blockchain transaction processing, wherein the blockchain transaction processing request includes a target hierarchical identification segment string of the target object body, wherein the target hierarchical identification segment string includes a plurality of target hierarchical identification segments organized according to a hierarchical structure of a first tree, wherein the first tree lists candidate hierarchical identification segments of each level, and a relationship between the candidate hierarchical identification segments and the candidate hierarchical identification segments of the next level, wherein each candidate hierarchical identification segment corresponds to a candidate blockchain address in the first tree;
[0011] a search unit, configured to search the first tree for the target hierarchical identification segment string in descending order of the hierarchical levels, so as to find the candidate hierarchical identification segment that matches the target hierarchical identification segment at the lowest level of the target hierarchical identification segment string;
[0012] A determination unit, configured to determine the candidate blockchain address corresponding to the candidate hierarchical identification segment matched in the first tree as a target blockchain address;
[0013] A calling unit is used to call the target object body based on the target blockchain address to perform the blockchain transaction processing.
[0014] Optionally, the first tree includes a root node, and the root node is associated with a root blockchain address;
[0015] The searching unit is specifically used for:
[0016] The root blockchain address is used as the current address, and an address mapping table corresponding to the root blockchain address is extracted as the current mapping table, wherein the address mapping table is used to indicate multiple identification paths associated with the root blockchain address, and a mapping relationship between the identification paths and the candidate blockchain address, and the identification path is used to indicate a relationship between the candidate hierarchical identification segment and the candidate hierarchical identification segment of the next level;
[0017] If, based on the identification path, it is determined that there is a candidate hierarchical identification segment that is consistent with the target hierarchical identification segment of the highest level, then, according to the mapping relationship, the candidate blockchain address corresponding to the candidate hierarchical identification segment is extracted as the updated current address, and based on the updated current address, the candidate hierarchical identification segment that matches the target hierarchical identification segment of the next level is searched in descending order of the levels until the candidate hierarchical identification segment that matches the target hierarchical identification segment of the lowest level is found;
[0018] If, based on the identification path, it is determined that there is no candidate hierarchical identification segment that is consistent with the hierarchical identification segment of the highest level, a first prompt message is generated, and the blockchain transaction processing request is rejected based on the first prompt message.
[0019] Optionally, the first tree includes a root node and leaf nodes of multiple levels; the blockchain transaction processing device further includes a generation unit, the generation unit is used to generate the first tree, and the generation unit specifically includes:
[0020] A selection request receiving unit, configured to receive an object body selection request, wherein the object body selection request is used to call a blockchain address of a first object body stored in the root node;
[0021] A root node determination unit, configured to determine the blockchain address of the first object as a candidate blockchain address corresponding to the root node;
[0022] A creation request receiving unit, configured to receive an object creation request, wherein the object creation request includes a hierarchical identification segment string of an object to be created and a blockchain address of the object to be created;
[0023] A construction unit is used to store the hierarchical identification segment string of the object body to be created and the blockchain address in the leaf node in sequence according to the order of the levels from high to low for each object body to be created, until a candidate hierarchical identification segment corresponding to the leaf node of the lowest level is generated to obtain the first tree.
[0024] Optionally, the hierarchical identification segment string of the object to be created has only one hierarchical identification segment;
[0025] The building block is specifically used for:
[0026] Acquire a first requester address, where the first requester address is an address of a user who initiates the object creation request;
[0027] Determine a first deployment address of the object to be created;
[0028] If it is determined that the first requester address is consistent with the first deployment address, the hierarchical identification segment of the object body to be created is stored in the leaf node of the first level of the first tree, and the blockchain address of the object body to be created is used as a candidate blockchain address of the leaf node of the first level.
[0029] Optionally, the hierarchical identification segment string of the object to be created includes multiple hierarchical identification segments;
[0030] The building block is specifically used for:
[0031] If it is determined that the first requester address is consistent with the first deployment address, extracting an address mapping table corresponding to the candidate hierarchical identification segment of the first level from the first tree, wherein the address mapping table is used to indicate an identification path of a candidate hierarchical identification segment of the next level associated with the candidate hierarchical identification segment of the first level, and a mapping relationship between the identification path and the candidate blockchain address;
[0032] For each of the to-be-created objects, if it is determined that there is no identification path that is consistent with the hierarchical identification segment string of the to-be-created object, then generating the candidate hierarchical identification segment of the next level of the candidate hierarchical identification segment of the first level based on the hierarchical identification segment string of the to-be-created object;
[0033] The address mapping table is updated based on the difference between the hierarchical identification segment string of the object to be created and the candidate hierarchical identification segment of the next level, and the blockchain address of the object to be created.
[0034] Optionally, the blockchain transaction processing device further includes a request rejection unit, configured to:
[0035] For each of the to-be-created objects, if it is determined that there is an identification path that is consistent with the hierarchical identification segment string of the to-be-created object, generating second prompt information;
[0036] Based on the second prompt information, the object creation request is rejected.
[0037] Optionally, the blockchain transaction processing device further includes an updating unit, and the updating unit specifically includes:
[0038] An update request receiving unit, configured to receive an object body update request, wherein the object body update request is used to instruct to update the blockchain address of the object body to be updated at a next level of the second object body; the object body update request includes the updated blockchain address of the object body to be updated and the object body association information;
[0039] A first address acquisition unit, configured to acquire a second requester address, where the second requester address is an address of a user who initiates the object update request;
[0040] A first address determining unit, configured to determine a second deployment address of the second object body;
[0041] a second address determining unit, configured to determine, if it is determined that the second requester address is consistent with the second deployment address of the second object body, a candidate blockchain address of the object body to be updated in the first tree based on the object body association information;
[0042] A first verification unit, configured to perform a first verification based on the candidate blockchain address of the object to be updated;
[0043] a third address determining unit, configured to extract a candidate blockchain address of the second object body from the first tree if it is determined that the first verification passes;
[0044] A second verification unit, configured to perform a second verification based on the candidate blockchain address of the second object;
[0045] The address updating unit is configured to update the address of the object body to be updated based on the updated blockchain address in the address mapping table of the second object body if it is determined that the second verification passes.
[0046] Optionally, the first verification unit is used to:
[0047] If it is determined that the candidate blockchain address is a contract address and the candidate blockchain address satisfies the first condition, it is determined that the first verification is passed;
[0048] If it is determined that the candidate blockchain address is not a contract address, or the candidate blockchain address does not meet the first condition, it is determined that the first verification fails.
[0049] Optionally, determining that the candidate blockchain address is a contract address is achieved by:
[0050] Extracting code information of the candidate blockchain address;
[0051] If the code information is not empty, it is determined that the candidate blockchain address is a contract address.
[0052] Optionally, the second verification unit is used to:
[0053] Obtaining an object body address of the second object body;
[0054] If the candidate blockchain address of the second object body is consistent with the object body address of the second object body, it is determined that the second verification is passed;
[0055] If the candidate blockchain address of the second object body and the object body address of the second object body are inconsistent, it is determined that the second verification fails.
[0056] Optionally, the address updating unit is used to:
[0057] Updating the identification path of the object to be updated in the address mapping table into the object association information;
[0058] The candidate blockchain address of the object to be updated in the address mapping table is replaced with the update blockchain address.
[0059] Optionally, the blockchain transaction processing device further includes a deletion unit, and the deletion unit specifically includes:
[0060] a deletion request receiving unit, configured to receive an object body deletion request, wherein the object body deletion request is used to instruct to delete the blockchain address of the object body to be deleted at a level below the third object body; the object body deletion request includes object body association information of the object body to be deleted;
[0061] A second address acquisition unit, configured to acquire an address of a third requester, wherein the address of the third requester is an address of a user who initiates the object deletion request;
[0062] a fourth address determining unit, configured to determine a third deployment address of the third object body;
[0063] a fifth address determining unit, configured to determine, if it is determined that the third requester address is consistent with the third deployment address, a candidate blockchain address of the object body to be deleted in the first tree based on the object body association information;
[0064] A third verification unit, configured to perform a third verification based on the candidate blockchain address of the object to be deleted;
[0065] a sixth address determining unit, configured to extract a candidate blockchain address of a third object based on the first tree if it is determined that the third verification passes;
[0066] a fourth verification unit, configured to perform a fourth verification based on the candidate blockchain address of the third object;
[0067] The address deleting unit is configured to delete the candidate blockchain address of the object body to be deleted from the address mapping table of the third object body if it is determined that the fourth verification passes.
[0068] Optionally, the fifth address determining unit is configured to:
[0069] Based on the address mapping table of the third object, determine all next-level object bodies associated with the third object body and candidate blockchain addresses of the next-level object bodies;
[0070] Based on the object body association information, a candidate blockchain address of the object body to be deleted is determined from the candidate blockchain addresses of the object body at the next level.
[0071] Optionally, the third verification unit is used to:
[0072] If it is determined that the candidate blockchain address is a contract address and the candidate blockchain address satisfies the second condition, it is determined that the third verification is passed;
[0073] If it is determined that the candidate blockchain address is not a contract address, or the candidate blockchain address does not satisfy the second condition, it is determined that the third verification fails.
[0074] Optionally, the fourth verification unit is used to:
[0075] Obtaining an object address of the third object;
[0076] If the candidate blockchain address of the third object is consistent with the object address of the third object, it is determined that the fourth verification is passed;
[0077] If the candidate blockchain address of the third object body and the object body address of the third object body are inconsistent, it is determined that the fourth verification fails.
[0078] Optionally, the address mapping table of the third object is generated in the following manner:
[0079] Extracting identification paths of multiple next-level object bodies associated with the third object body as keywords;
[0080] Taking the candidate blockchain address of each object at the next level as a value;
[0081] Based on the mapping relationship between the identification path and the candidate blockchain address, construct the keyword and the value into a key-value pair;
[0082] The address mapping table is generated based on the multiple key-value pairs.
[0083] According to one aspect of the present disclosure, an electronic device is provided, including a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the blockchain transaction processing method as described above is implemented.
[0084] According to one aspect of the present disclosure, a computer-readable storage medium is provided, wherein the storage medium stores a computer program, and when the computer program is executed by a processor, the blockchain transaction processing method as described above is implemented.
[0085] According to one aspect of the present disclosure, a computer program product is provided, which includes a computer program, and the computer program is read and executed by a processor of a computer device, so that the computer device executes the blockchain transaction processing method as described above.
[0086] In the disclosed embodiment, each object body recorded in the blockchain is uniquely identified by a candidate hierarchical identification segment string. At the same time, the candidate hierarchical identification segment string and the blockchain address of each object body are stored in the first tree layer by layer according to the corresponding relationship. Based on this, when a blockchain transaction processing request is received to call the target object body recorded on the blockchain to perform blockchain transaction processing, the target hierarchical identification segment string of the target object body is first extracted from the transaction processing request, and the target hierarchical identification segment string is searched in the first tree in order from high to low levels, and the candidate hierarchical identification segment matching the target hierarchical identification segment of the lowest level of the target hierarchical identification segment string is found in a layer-by-layer traversal manner, and the candidate blockchain address corresponding to the matching candidate hierarchical identification segment is used as the target blockchain address of the target object body, which can greatly improve the address search efficiency compared to the overall search method. Finally, calling the target object body based on the target blockchain address to perform blockchain transaction processing can improve transaction processing efficiency.
[0087] Other features and advantages of the present disclosure will be described in the following description, and partly become apparent from the description, or understood by practicing the present disclosure. The purpose and other advantages of the present disclosure can be realized and obtained by the structures particularly pointed out in the description, claims and drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0088] The accompanying drawings are used to provide further understanding of the technical solution of the present disclosure and constitute a part of the specification. Together with the embodiments of the present disclosure, they are used to explain the technical solution of the present disclosure and do not constitute a limitation on the technical solution of the present disclosure.
[0089] Figure 1 is a system architecture diagram of a system to which the blockchain transaction processing method according to an embodiment of the present disclosure is applied;
[0090] Figure 2A-2E A schematic diagram showing the application of a blockchain transaction processing method according to an embodiment of the present disclosure in a resource transfer scenario;
[0091] Figure 3 is a flowchart of a blockchain transaction processing method according to an embodiment of the present disclosure;
[0092] Figure 4 is a flowchart of searching a first tree according to a target hierarchical identification segment string according to an embodiment of the present disclosure;
[0093] Figure 5 is a schematic diagram of a hierarchical structure of a first tree according to an embodiment of the present disclosure;
[0094] Figure 6A-6C is a schematic diagram of the structure of multiple address mapping tables in a first tree according to an embodiment of the present disclosure;
[0095] Figure 7 is a flowchart of generating a first tree according to an embodiment of the present disclosure;
[0096] Figure 8 is a schematic diagram of an implementation process of an object creation request according to an embodiment of the present disclosure;
[0097] Fig. 9 is a flow chart of storing hierarchical identification segments to leaf nodes according to an embodiment of the present disclosure;
[0098] Fig.10 is a schematic diagram of an implementation process of storing a hierarchical identification segment to a leaf node according to an embodiment of the present disclosure;
[0099] Fig.11 is a flow chart of storing a hierarchical identification segment to a leaf node according to another embodiment of the present disclosure;
[0100] Figure 12A-12C is a schematic diagram of an implementation process of generating a first tree according to an embodiment of the present disclosure;
[0101] Fig.13 is a flowchart of updating the blockchain address of an object body in a first tree according to an embodiment of the present disclosure;
[0102] Figure 14A-14B is a schematic diagram of an implementation process of updating the blockchain address of an object in a first tree according to an embodiment of the present disclosure;
[0103] Fig.15 is a flowchart of performing a first verification based on a candidate blockchain address of an object to be updated according to an embodiment of the present disclosure;
[0104] Fig.16 is a flowchart of performing a second verification based on a candidate blockchain address of a second object according to an embodiment of the present disclosure;
[0105] Fig.17 is a flow chart of performing address update based on updating blockchain address according to one embodiment of the present disclosure;
[0106] Fig.18 It is a schematic diagram of an implementation process of updating an address based on updating a blockchain address according to an embodiment of the present disclosure;
[0107] Fig.19 is a flowchart of deleting a blockchain address of an object body in a first tree according to an embodiment of the present disclosure;
[0108] Figure 20A-20Bis a schematic diagram of an implementation process of deleting a blockchain address of an object in a first tree according to an embodiment of the present disclosure;
[0109] Fig.21 is a flowchart of determining a candidate blockchain address of an object to be deleted according to an embodiment of the present disclosure;
[0110] Fig. 22 is a flowchart of generating an address mapping table of a third object according to an embodiment of the present disclosure;
[0111] Fig.23 is a schematic diagram of an implementation process of deleting a blockchain address in a first tree according to an embodiment of the present disclosure;
[0112] Fig.24 is a module diagram of a blockchain transaction processing device according to an embodiment of the present disclosure;
[0113] Fig.25 is a terminal structure diagram of a blockchain transaction processing method according to an embodiment of the present disclosure;
[0114] Fig.26 It is a server structure diagram of a blockchain transaction processing method according to an embodiment of the present disclosure. DETAILED DESCRIPTION
[0115] In order to make the purpose, technical solution and advantages of the present disclosure more clear, the present disclosure is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present disclosure and are not used to limit the present disclosure.
[0116] Before further describing the embodiments of the present disclosure in detail, the nouns and terms involved in the embodiments of the present disclosure are described. The nouns and terms involved in the embodiments of the present disclosure are subject to the following interpretations:
[0117] Artificial Intelligence (AI) is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology in computer science that attempts to understand the essence of intelligence and produce a new intelligent machine that can respond in a similar way to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines so that machines have the functions of perception, reasoning and decision-making. Artificial intelligence technology is a comprehensive discipline that covers a wide range of fields, including both hardware-level technology and software-level technology. The basic technologies of artificial intelligence generally include sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technology, pre-trained model technology, operation / interaction system, mechatronics, etc. Among them, the pre-trained model is also called the large model or basic model. After fine-tuning, it can be widely used in downstream tasks in various major directions of artificial intelligence. Artificial intelligence software technology mainly includes computer vision technology, speech processing technology, natural language processing technology, and machine learning / deep learning. With the research and advancement of artificial intelligence technology, artificial intelligence technology has been studied and applied in many fields, such as common smart homes, smart wearable devices, virtual assistants, smart speakers, smart marketing, unmanned driving, automatic driving, drones, robots, smart medical care, smart customer service, etc. I believe that with the development of technology, artificial intelligence technology will be applied in more fields and play an increasingly important role.
[0118] Blockchain: Blockchain is a new application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, encryption algorithm, etc. Blockchain is essentially a decentralized database, a string of data blocks generated by cryptographic methods. Each data block contains a batch of transaction information, which is used to verify the validity of its information (anti-counterfeiting) and associate with the previous block.
[0119] Alliance blockchain: Alliance chain for short, is for a specific group, and only authorized nodes can join a specific blockchain network. Nodes in the alliance chain need to be authenticated and registered, and encryption is usually not involved in the consensus process. Member nodes have a common goal, but do not fully trust each other in terms of maintaining verification data. Compared with the public chain, the nodes of the alliance chain usually have good connections, higher verification and confirmation speeds, faster block times, and lower system maintenance costs. Combined with the latest technological developments in blockchain, the alliance chain can enable internal members to jointly maintain the ledger. At the same time, the registration mechanism can limit the behavior of participating nodes and flexibly handle permissions. To a certain extent, a decentralized and distributed system has been built, which gets rid of the single point of failure and other security risks brought by the only central organization, solves the trust problem, and can be applied to financial, supply chain, public welfare and other application scenarios.
[0120] Smart contract: A contract written in code that can be automatically executed on the blockchain. Smart contracts can achieve a variety of functions, such as resource transfer, identity verification, and creation of digital identities.
[0121] Currently, in blockchain systems, various resource pools and various types of contracts are often represented by binary addresses. When resource transfer or contract invocation occurs, manual bit-by-bit search is often required to determine the resource pool and the corresponding address of the contract in the blockchain system. This process often takes a lot of time and results in low efficiency in address acquisition, thus affecting the overall transaction processing efficiency.
[0122] System architecture and scenario description of the application of the embodiments of the present disclosure
[0123] Figure 1 1 is a system architecture diagram of the blockchain transaction processing method according to an embodiment of the present disclosure, which includes an object terminal 140, the Internet 130, a gateway 120, a blockchain network 110, etc.
[0124] The object terminal 140 includes various forms such as desktop computers, laptop computers, PDAs (personal digital assistants), mobile phones, vehicle-mounted terminals, home theater terminals, and dedicated terminals. In addition, it can be a single device or a collection of multiple devices. The object terminal 140 can communicate with the Internet 130 in a wired or wireless manner to exchange data. Among them, the object terminal 140 includes a transaction processing system, which is used to retrieve the corresponding execution object for transaction processing of the transaction data input by the object.
[0125] See also Figure 1The blockchain network 110 shown includes a consensus network. A consensus network refers to a network that reaches consensus on transactions to be uploaded to the blockchain and uploads them to the blockchain. It includes multiple consensus nodes. A consensus node is a blockchain node. A consensus node or a blockchain node can be a server in a blockchain network or an object terminal connected to a blockchain network. The specific form of a consensus node or a blockchain node is not limited here.
[0126] The gateway 120 is also called an internetwork connector or a protocol converter. The gateway realizes network interconnection at the transport layer and is a computer system or device that acts as a converter. The gateway is a translator between two systems that use different communication protocols, data formats or languages, or even completely different architectures. At the same time, the gateway can also provide filtering and security functions. The message sent by the object terminal 140 to the blockchain network 110 must be sent to the corresponding blockchain network 110 through the gateway 120. The message sent by the blockchain network 110 to the object terminal 140 must also be sent to the corresponding object terminal 140 through the gateway 120.
[0127] The embodiments of the present disclosure can be applied in various scenarios, such as Figure 2A-2E The resource transfer scenario shown, etc.
[0128] like Figure 2A As shown, when user A logs in to the transaction processing system on the object terminal, a prompt message "Hello, the virtual resources you currently hold are 1000" is displayed on the interface of the transaction processing system to display the number of virtual resources held by the user. In addition, multiple interactive controls are displayed on the interface, including "Add Resources", "Resource Transfer", "Query History", and "Xxxx". Among them, the "Add Resources" control is used for users to increase their investment in virtual resources. The "Resource Transfer" control is used for users to transfer virtual resources to other users or related institutions. The "Query History" control is used for users to query operation information at all times before the current time. At this time, user A clicks the "Resource Transfer" control to enter the resource transfer process.
[0129] like Figure 2BAs shown, after user A clicks the "Resource Transfer" control and enters the resource transfer process, the interface will display the prompt field "Please enter the following information", and will display the input box corresponding to the "Transfer Resource Quantity" and the input box for the "Resource Transfer Object". At this time, user A enters "500" in the input box corresponding to the "Transfer Resource Quantity" and enters "John.English.name" in the input box for the "Resource Transfer Object". Among them, "John.English.name" is John's nickname. It can be seen that user A wants to transfer 500 virtual resources to the user whose English name is John. After user A has entered the relevant information, click the "OK" button to proceed to the next step.
[0130] like Figure 2C As shown in the figure, after user A clicks the "OK" button, the server will query the actual address of the user whose English name is John based on the information entered by user A, and display a prompt field on the interface: "The actual resource pool address of John has been queried. Please confirm whether to transfer resources to this resource pool?" At the same time, two interactive buttons "Yes" and "No" are displayed on the interface. At this time, user A clicks "Yes".
[0131] like Figure 2D As shown, after user A clicks the "Yes" button, the server will perform the resource transfer operation and display a prompt field on the interface "Resources are being transferred to John's actual resource pool, please wait patiently...".
[0132] like Figure 2E As shown in FIG. 1 , after the server completes the resource transfer, a prompt field "The resource has been transferred to John's resource pool" will be displayed on the interface, and a "Confirm" button and a "Help" button will also be displayed on the interface. At this time, user A clicks the "Confirm" button to confirm that the process of transferring 500 virtual resources to John has been completed.
[0133] General description of the disclosed embodiments
[0134] According to one embodiment of the present disclosure, a blockchain transaction processing method is provided.
[0135] This blockchain transaction processing method is generally used in blockchain scenarios such as transaction on-chain, resource transfer, and contract call, for example Figure 2A-2E The resource transfer scenario shown. The disclosed embodiment provides a solution for searching for blockchain addresses layer by layer based on the first tree, and processing corresponding blockchain transactions according to the found blockchain addresses, which can improve the address search efficiency and thus improve the processing efficiency of blockchain transactions.
[0136] like Figure 3As shown, a blockchain transaction processing method according to an embodiment of the present disclosure may include:
[0137] Step 310: receiving a blockchain transaction processing request;
[0138] Step 320: Search the first tree for the target hierarchical identification segment string in descending order of levels to find a candidate hierarchical identification segment that matches the target hierarchical identification segment at the lowest level of the target hierarchical identification segment string;
[0139] Step 330: Determine the candidate blockchain address corresponding to the candidate hierarchical identification segment matched in the first tree as the target blockchain address;
[0140] Step 340: Call the target object body based on the target blockchain address to perform blockchain transaction processing.
[0141] Steps 310 - 340 are described in detail below.
[0142] In step 310, a blockchain transaction request is received.
[0143] The blockchain transaction request is used to call the target object recorded on the blockchain to perform blockchain transaction processing.
[0144] The target object refers to the smart contract recorded on the blockchain, the user's associated resource pool, etc. Among them, the smart contract is referred to as the contract in the following text.
[0145] Users refer to people and related institutions that process transactions through the blockchain system. The user's associated resource pool is generally used to store virtual resources owned by the user.
[0146] Blockchain transaction processing includes but is not limited to resource transfer, contract invocation, etc.
[0147] The blockchain transaction processing request includes the target hierarchical identification segment string of the target object body.
[0148] The target hierarchical identification segment string is used to uniquely identify the target object body. The hierarchical identification segment strings of different object bodies are different.
[0149] The target hierarchical identification segment string includes a plurality of target hierarchical identification segments organized according to the hierarchical structure of the first tree. The target hierarchical identification segments are used to distinguish feature information of the target object body at different levels.
[0150] For example, for a user Tom's associated resource pool, this associated resource pool can be regarded as a target object body, and the target hierarchical identification segment string of the associated resource pool can be expressed as "Tom, English name, name". The target hierarchical identification segment of the associated resource pool includes "name" belonging to the first level, "English name, name" belonging to the second level, and "Tom, English name, name" belonging to the third level.
[0151] It should be noted that the first tree is a multi-branch tree. The hierarchical structure of the first tree is a recursive multi-branch tree structure. Specifically, the first tree includes a root node, and the root node is located at level 0. The next level of the root node is the first level of the first tree, and the first level can include multiple leaf nodes, and each leaf node will extend downward to multiple leaf nodes, so that the first tree presents multiple levels of leaf nodes.
[0152] In the disclosed embodiment, the first tree lists the candidate hierarchical identification segments of each level and the relationship between the candidate hierarchical identification segments and the candidate hierarchical identification segments of the next level, and each candidate hierarchical identification segment corresponds to a candidate blockchain address in the first tree. Each leaf node stores a candidate hierarchical identification segment of an object body and a candidate blockchain address corresponding to the candidate hierarchical identification segment.
[0153] The candidate hierarchical identification segment refers to the hierarchical identification segment of each object body recorded in the first tree at each level, and the candidate hierarchical identification segment is used to identify the feature information of each object body in the first tree at each level.
[0154] The above relationship refers to the subordinate relationship between the candidate classification identification segment and the candidate classification identification segment of the next level. Generally, the candidate classification identification segment of the next level is subordinate to the candidate classification identification segment.
[0155] For example, the candidate hierarchical identification segment “English name, name” is a candidate hierarchical identification segment at the next level of the candidate hierarchical identification segment “name”, and “English name, name” is a refined branch of “name”.
[0156] The candidate blockchain address refers to the blockchain address of each object recorded in the first tree. The blockchain address is used to call each object. For example, when the object is a smart contract, the blockchain address is the contract address, and the smart contract can be called through the contract address to execute the corresponding function. When the object is a user's associated resource pool, the blockchain address is the resource pool address, and resources can be transferred to the associated resource pool through the resource pool address to realize resource circulation.
[0157] In order to save space, the specific implementation process of generating the first tree in the embodiment of the present disclosure will be described in detail below and will not be repeated here.
[0158] In the specific implementation of this embodiment, when a user wants to call the target object body recorded in the blockchain to complete the corresponding transaction, the specific information of the target object body and the relevant information of the transaction are often input through the front-end interface of the object terminal. Among them, the input specific information is generally a target hierarchical identification segment string that can identify the target object body, and the relevant information of the transaction generally includes resource data associated with the transaction, or various parameters associated with the transaction. Further, the object terminal will send a blockchain transaction processing request containing the specific information of the target object body and the relevant information of the transaction to the server, so that the server receives this blockchain transaction processing request and extracts the target hierarchical identification segment string of the target object body to be called from the blockchain transaction processing request.
[0159] For example, a blockchain transaction request is "Mary wants to transfer 100 virtual resources to John, and John's target hierarchical identification segment string is John.Englishname.name".
[0160] In step 320, the target hierarchical identification segment string is searched in the first tree in descending order of hierarchy to find a candidate hierarchical identification segment that matches the target hierarchical identification segment at the lowest level of the target hierarchical identification segment string.
[0161] In the specific implementation of this embodiment, first, for the target hierarchical identification segment at the highest level in the target hierarchical identification segment string, the first level below the root node of the first tree is searched to see whether there is a candidate hierarchical identification segment that is consistent with the target hierarchical identification segment at the highest level. If there is a candidate hierarchical identification segment that is consistent with the target hierarchical identification segment at the highest level, then the search is continued at the second level below the root node of the first tree according to the next level branch of the candidate hierarchical identification segment of the target hierarchical identification segment at the highest level, and when it is found that there is a candidate hierarchical identification segment at the second level that is consistent with the target hierarchical identification segment at the second highest level in the target hierarchical identification segment string, the search is continued downward in the first tree until a candidate hierarchical identification segment that is consistent with the target hierarchical identification segment at the lowest level of the target hierarchical identification segment string is found, and the candidate hierarchical identification segment that is consistent with the target hierarchical identification segment at the lowest level of the target hierarchical identification segment string is used as a matching candidate hierarchical identification segment.
[0162] To save space, the specific implementation process of searching the first tree for a candidate hierarchical identification segment that matches the target hierarchical identification segment at the lowest level of the target hierarchical identification segment string in the embodiment of the present disclosure will be described in detail below and will not be repeated here.
[0163] In step 330, the candidate blockchain address corresponding to the matching candidate hierarchical identification segment in the first tree is determined as the target blockchain address.
[0164] The target blockchain address refers to the blockchain address corresponding to the target object body, and the target object body can be called through the target blockchain address.
[0165] For example, for a smart contract K, the target blockchain address refers to the contract address of smart contract K.
[0166] In the specific implementation of this embodiment, since the candidate blockchain address corresponding to each candidate hierarchical identification segment is recorded in the first tree, the correspondence between each candidate hierarchical identification segment and the candidate blockchain address maintained in the first tree is first directly called. Then, based on the correspondence between each candidate hierarchical identification segment and the candidate blockchain address, the candidate blockchain address corresponding to the candidate hierarchical identification segment matched in the first tree is extracted. Finally, the extracted candidate blockchain address is used as the target blockchain address. Among them, the target blockchain address is the blockchain address corresponding to the target object body recorded in the first tree.
[0167] In step 340, the target object body is called based on the target blockchain address to perform blockchain transaction processing.
[0168] In the specific implementation of this embodiment, first, the target object body is searched in the blockchain according to the target blockchain address; then, the found target object body is called, and the target object body is used to perform blockchain transaction processing.
[0169] For example, when the target object is a smart contract, the corresponding smart contract can be found based on the target blockchain address, and the smart contract can be used to perform transactions such as identity authentication and resource transfer.
[0170] Through the above steps 310-340, the embodiment of the present disclosure uses a candidate hierarchical identification segment string to uniquely identify each object body recorded in the blockchain. At the same time, the candidate hierarchical identification segment string and the blockchain address of each object body are stored in the first tree layer by layer according to the corresponding relationship. Based on this, when a blockchain transaction processing request is received to call the target object body recorded on the blockchain to perform blockchain transaction processing, the target hierarchical identification segment string of the target object body is first extracted from the transaction processing request, and the target hierarchical identification segment string is searched in the first tree in order from high to low levels, and the candidate hierarchical identification segment matching the target hierarchical identification segment of the lowest level of the target hierarchical identification segment string is found in a layer-by-layer traversal manner, and the candidate blockchain address corresponding to the matching candidate hierarchical identification segment is used as the target blockchain address of the target object body, which can greatly improve the address search efficiency compared to the overall search method. Finally, calling the target object body based on the target blockchain address to perform blockchain transaction processing can improve transaction processing efficiency.
[0171] The above is a general description of steps 310 to 340. Since steps 310, 330, and 340 have been described in detail in the above general description, the specific implementation of step 320 will be described in detail below.
[0172] Detailed description of step 320
[0173] In step 320, the target hierarchical identification segment string is searched in the first tree in descending order of hierarchy to find a candidate hierarchical identification segment that matches the target hierarchical identification segment at the lowest level of the target hierarchical identification segment string.
[0174] Combine the following Figure 4 , Figure 5 ,and Figure 6A-6C The process of searching the first tree according to the target hierarchical identification segment string is described in detail.
[0175] In the disclosed embodiment, the first tree includes a root node, and the root node is associated with a root blockchain address.
[0176] The root node refers to the topmost node in the first tree. A domain name contract is stored in the root node, which is the entry point for address search based on the first tree. The root blockchain address refers to the contract address of the domain name contract stored in the root node. In order to improve the efficiency of address query, the candidate hierarchical identification segment string of the domain name contract stored in the root node is empty.
[0177] Please refer to Figure 4 In one embodiment, the process of searching the first tree according to the target hierarchical identification segment string includes but is not limited to the following steps 410-430:
[0178] Step 410: Use the root blockchain address as the current address, and extract the address mapping table corresponding to the root blockchain address as the current mapping table;
[0179] Step 420: If it is determined based on the identification path that there is a candidate hierarchical identification segment that is consistent with the target hierarchical identification segment of the highest level, then based on the mapping relationship, extract the candidate blockchain address corresponding to the candidate hierarchical identification segment as the updated current address, and search for a candidate hierarchical identification segment that matches the target hierarchical identification segment of the next level in descending order of levels based on the updated current address, until a candidate hierarchical identification segment that matches the target hierarchical identification segment of the lowest level is found;
[0180] Step 430: If it is determined based on the identification path that there is no candidate hierarchical identification segment that is consistent with the hierarchical identification segment of the highest level, a first prompt message is generated, and the blockchain transaction processing request is rejected based on the first prompt message.
[0181] Steps 410 - 430 are described in detail below.
[0182] like Figure 5 As shown, it is the specific hierarchical structure of the first tree of the embodiment of the present disclosure. Specifically, the first tree contains four levels. The first level is below the root node of the first tree. The first level contains candidate hierarchical identification segment 1 (.sol) and candidate hierarchical identification segment 2 (.name). Candidate hierarchical identification segment 1 is used to indicate the object body of the contract type, and candidate hierarchical identification segment 2 (.name) is used to indicate the object body of the associated resource pool type. Further, the next level of candidate hierarchical identification segment 1 and candidate hierarchical identification segment 2 is the second level, wherein the next level of candidate hierarchical identification segment 1 contains two different types of contracts, and the candidate hierarchical identification segments of the two contracts are candidate hierarchical identification segment 3 (A.sol) and candidate hierarchical identification segment 4 (B.sol). The next level of candidate hierarchical identification segment 2 contains two different types of associated resource pools, and the candidate hierarchical identification segments of the two associated resource pools are candidate hierarchical identification segment 5 (English.name) and candidate hierarchical identification segment 6 (Chinese.name). Further, the next level of candidate hierarchical identification segment 3, candidate hierarchical identification segment 4, candidate hierarchical identification segment 5, and candidate hierarchical identification segment 6 is the third level. Among them, the next level of candidate hierarchical identification segment 3 contains two different types of contracts, and the candidate hierarchical identification segments of the two contracts are candidate hierarchical identification segment 7 (aAsol) and candidate hierarchical identification segment 8 (bAsol). The next level of candidate hierarchical identification segment 4 contains 1 contract, and the candidate hierarchical identification segment of this contract is candidate hierarchical identification segment 9 (aBsol). The next level of candidate hierarchical identification segment 5 contains three different associated resource pools, and the candidate hierarchical identification segments of the three associated resource pools are candidate hierarchical identification segment 10 (Tom.English.name), candidate hierarchical identification segment 11 (Mary.English.name), and candidate hierarchical identification segment 12 (John.English.name). The next level of candidate hierarchical identification segment 6 contains 1 associated resource pool, and the candidate hierarchical identification segment of this associated resource pool is candidate hierarchical identification segment 13 (xx.Chinese.name). Furthermore, the next level of candidate hierarchical identification segment 8 is the fourth level. The next level of the candidate hierarchical identification segment 8 includes two different contracts, and the candidate hierarchical identification segments of the two contracts are respectively candidate hierarchical identification segment 14 (5.bAsol) and candidate hierarchical identification segment 15 (7.bAsol).
[0183] In step 410, the root blockchain address is used as the current address, and the address mapping table corresponding to the root blockchain address is extracted as the current mapping table.
[0184] The address mapping table is used to indicate multiple identification paths associated with the root blockchain address, as well as the mapping relationship between the identification paths and the candidate blockchain addresses.
[0185] The identification path is used to indicate the relationship between the candidate hierarchical identification segment and the candidate hierarchical identification segment of the next level; the identification path can be expressed as the difference between the candidate hierarchical identification segment and the candidate hierarchical identification segment of the next level.
[0186] In the specific implementation of this embodiment, first, the root blockchain address is used as the current address. Then, the address mapping table corresponding to the root blockchain address is extracted from the multiple address mapping tables maintained by the first tree, and the address mapping table corresponding to the root blockchain address is used as the current mapping table.
[0187] like Fig. 6A As shown, the smart contract G is used as the root node, and the candidate hierarchical identification segment of the root node is empty. The address mapping table of the root node will indicate the blockchain address corresponding to each candidate hierarchical identification segment of the leaf node of the next level. Specifically, there are two leaf nodes in the next level of the root node. The left leaf node stores the candidate hierarchical identification segment 1 (.sol), and the identification path of the candidate hierarchical identification segment 1 is .sol; the candidate blockchain address of the candidate hierarchical identification segment 1 is Yyyy1. The right leaf node stores the candidate hierarchical identification segment 2 (.name), and the identification path of the candidate hierarchical identification segment 2 is .name; the candidate blockchain address of the candidate hierarchical identification segment 2 is Yyyy5.
[0188] In step 420, if it is determined based on the identification path that there is a candidate hierarchical identification segment that is consistent with the target hierarchical identification segment of the highest level, then according to the mapping relationship, the candidate blockchain address corresponding to the candidate hierarchical identification segment is extracted as the updated current address, and based on the updated current address, the candidate hierarchical identification segment that matches the target hierarchical identification segment of the next level is searched in descending order of levels until a candidate hierarchical identification segment that matches the target hierarchical identification segment of the lowest level is found.
[0189] The updated current address refers to the candidate blockchain address corresponding to the candidate hierarchical identification segment that is consistent with the target hierarchical identification segment at the highest level.
[0190] When this embodiment is specifically implemented, the candidate hierarchical identification segments indicated by each identification path in the address mapping table corresponding to the root blockchain address are first compared with the target hierarchical identification segment of the highest level to implement a search operation at the first level of the first tree. If there is a candidate hierarchical identification segment that is consistent with the target hierarchical identification segment of the highest level, it indicates that there is relevant information of an object body to which the target object body belongs in the first tree. Then, according to the mapping relationship, the candidate blockchain address corresponding to the candidate hierarchical identification segment is extracted from the address mapping table as the updated current address, and further search for the target object body is implemented at the second level of the first tree from the largest object body to which the target object body belongs. Furthermore, the address mapping table corresponding to the updated current address is extracted from the multiple address mapping tables maintained by the first tree, and the address mapping table corresponding to the updated current address is used as the current mapping table. The candidate hierarchical identification segments indicated by each identification path in the address mapping table corresponding to the updated current address are compared with the target hierarchical identification segment of the second level. If there is a candidate hierarchical identification segment that is consistent with the target hierarchical identification segment of the second level, it indicates that there is a more refined object body in the largest object body to which the target object body belongs that contains the target object body. And so on. The candidate blockchain address corresponding to the candidate hierarchical identification segment that is consistent with the target hierarchical identification segment of the second level is continued to be used as the updated current address, and the candidate hierarchical identification segment that matches the target hierarchical identification segment of the next level is continued to be searched downward until the candidate hierarchical identification segment that matches the target hierarchical identification segment of the lowest level is found.
[0191] like Figure 6BAs shown, it is an address mapping table of the candidate hierarchical identification segment 1 at the next level of the root node, and the address mapping table will indicate the blockchain addresses corresponding to each candidate hierarchical identification segment of the leaf node at the next level of the candidate hierarchical identification segment 1. Specifically, there are two leaf nodes at the next level of the candidate hierarchical identification segment 1. The left leaf node stores the candidate hierarchical identification segment 3 (A.sol), and the identification path of the candidate hierarchical identification segment 3 is A; the candidate blockchain address of the candidate hierarchical identification segment 3 is Yyyy18. The right leaf node stores the candidate hierarchical identification segment 4 (B.sol), and the identification path of the candidate hierarchical identification segment 4 is B; the candidate blockchain address of the candidate hierarchical identification segment 4 is Yyyy19. Based on this, when the target candidate hierarchical identification segment string of the target object body is A.sol, the target candidate hierarchical identification segment string contains the target candidate hierarchical identification segment .sol of the highest level; and the target candidate hierarchical identification segment A.sol of the lowest level. By traversing and searching in the above manner, the target candidate hierarchical identification segment .sol is first compared with candidate hierarchical identification segment 1 and candidate hierarchical identification segment 2 respectively. After comparison, the candidate blockchain address of candidate hierarchical identification segment 1 is used as the updated current address. Continuing downward, the target candidate hierarchical identification segment A.sol is compared with candidate hierarchical identification segment 3 and candidate hierarchical identification segment 4 respectively. The candidate hierarchical identification segment 3 corresponding to the target candidate hierarchical identification segment A.sol at the lowest level is found at the second level of the first tree. Therefore, the target blockchain address of the target object body is Yyyy18.
[0192] like Figure 6C As shown, it is the address mapping table of the candidate hierarchical identification segment 2 of the next level of the root node, and the address mapping table will indicate the blockchain address corresponding to each candidate hierarchical identification segment of the leaf node of the next level of the candidate hierarchical identification segment 2. Specifically, there are two leaf nodes in the next level of the candidate hierarchical identification segment 2. The left leaf node stores the candidate hierarchical identification segment 5 (English.name), and the identification path of the candidate hierarchical identification segment 5 is English; the candidate blockchain address of the candidate hierarchical identification segment 5 is Xxxxx11. The right leaf node stores the candidate hierarchical identification segment 6 (Chinese.name), and the identification path of the candidate hierarchical identification segment 6 is Chinese; the candidate blockchain address of the candidate hierarchical identification segment 6 is Xxxxx12.
[0193] In step 430, if it is determined based on the identification path that there is no candidate hierarchical identification segment that is consistent with the hierarchical identification segment of the highest level, a first prompt message is generated, and the blockchain transaction processing request is rejected based on the first prompt message.
[0194] The first prompt information is used to indicate that there is no candidate classification identification segment that is consistent with the classification identification segment of the highest level.
[0195] In the specific implementation of this embodiment, if it is determined based on the identification path that there is no candidate hierarchical identification segment that is consistent with the hierarchical identification segment of the highest level, it indicates that the candidate blockchain address corresponding to the target object body does not exist in the first tree, and the target object body cannot be called through the first tree. The target object body may not be recorded in the blockchain, and the target object body cannot be called to perform the corresponding blockchain transaction processing. Therefore, the server will generate a first prompt message, report an error through the first prompt message, and thus reject the blockchain transaction processing request.
[0196] Through the above steps 410-430, the embodiment of the present disclosure adopts a layer-by-layer traversal method to search the first tree of the target hierarchical identification segment string in order from high to low levels, and finds a candidate hierarchical identification segment that matches the target hierarchical identification segment of the lowest level of the target hierarchical identification segment string. Compared with the overall search method used in the related art, it can better improve the search efficiency and thus improve the processing speed of blockchain transactions.
[0197] A detailed description of the first tree generated by an embodiment of the present disclosure
[0198] In order to improve the address query efficiency and improve the rationality of storage of the hierarchical identification segment string and blockchain address of each object body, the embodiment of the present disclosure provides a solution for generating a first tree in a recursive manner, which can improve the efficiency of traversing the first tree to find the blockchain address, thereby improving the efficiency of blockchain transaction processing.
[0199] Combine the following Figure 7 , Figure 8 The process of generating the first tree in a recursive manner is described in detail.
[0200] In the disclosed embodiment, the first tree includes a root node and multiple levels of leaf nodes. The leaf nodes refer to the child nodes formed by the root node extending downward, and the nodes formed by each child node extending downward. The level refers to the top-down tree structure of the first tree, wherein the level where the root node of the first tree is located is 0, and the level where the leaf nodes connected below the root node are located is the first level, and the numbers of the various levels of the first tree are incremented in order from top to bottom.
[0201] Please refer to Figure 7 In one embodiment, the process of searching the first tree according to the target hierarchical identification segment string includes but is not limited to the following steps 710-740:
[0202] Step 710: receiving an object selection request;
[0203] Step 720: Determine the blockchain address of the first object as the candidate blockchain address corresponding to the root node;
[0204] Step 730: receiving an object creation request;
[0205] Step 740: For each object to be created, store the hierarchical identification segment string and blockchain address of the object to be created in the leaf node in order from high to low levels, until the candidate hierarchical identification segment corresponding to the leaf node of the lowest level is generated, and the first tree is obtained.
[0206] Steps 710-740 are described in detail below.
[0207] In step 710, an object selection request is received.
[0208] The object body selection request is used to call the blockchain address of the first object body stored in the root node.
[0209] The first object is an object stored in the root node of the first tree. The first object is usually a domain name contract. The blockchain address refers to the contract address of the domain name contract as the first object.
[0210] In the specific implementation of this embodiment, when generating the first tree, the root node of the first tree needs to be determined first. Based on this, the object terminal will receive the contract address of the domain name contract set by the user as the root node; then, the object terminal will generate an object body selection request according to the received contract address of the domain name contract, and send the object body selection request to the server. Therefore, the server will receive the object body selection request, thereby determining the domain name contract as the root node of the first tree, and the contract address of the domain name contract, and the contract address of the domain name contract is its blockchain address.
[0211] In step 720, the blockchain address of the first object is determined as a candidate blockchain address corresponding to the root node.
[0212] In the specific implementation of this embodiment, the first object body is first used as the root node, and the first object body is the entrance of the entire first tree. Then, the blockchain address of the first object body is determined as the candidate blockchain address corresponding to the root node.
[0213] It should be noted that the blockchain address of the first object is public, and when the first tree needs to be called, the first tree can be obtained by directly obtaining the blockchain address of the first object. Based on this, in the embodiment of the present disclosure, the hierarchical identification segment string of the root node is set to a null value.
[0214] In step 730, an object body creation request is received.
[0215] An object creation request is a request generated when the relevant information of a new resource pool or a new contract needs to be recorded in the blockchain.
[0216] It should be noted that the object creation request includes the hierarchical identification segment string of the object to be created and the blockchain address of the object to be created.
[0217] For example, when a new resource transfer contract needs to be defined in the blockchain, the user will input the object creation request through the object terminal. Then, the object terminal will send the object creation request to the server, so that the server receives the object creation request and records the hierarchical identification segment string and blockchain address of the object to be created into the first tree according to the object creation request.
[0218] like Figure 8 The figure shows a schematic diagram of an object creation request. Specifically, the object creation request will instruct to create Mary's associated resource pool information in the blockchain, wherein the candidate hierarchical identification segment string of Mary's associated resource pool is represented by Mary's English name, and the candidate hierarchical identification segment string is specifically Mary.English.name; the blockchain address of the associated resource pool is 8888k. The blockchain address of Mary's associated resource pool can be queried through the candidate hierarchical identification segment string, and the queried blockchain address can be used to transfer resources to Mary's associated resource pool or verify the resource pool.
[0219] In step 740, for each object body to be created, the hierarchical identification segment string and the blockchain address of the object body to be created are stored in the leaf nodes in order from high to low levels, until the candidate hierarchical identification segment corresponding to the leaf node of the lowest level is generated, and the first tree is obtained.
[0220] In the specific implementation of this embodiment, for each object body to be created, in order from high to low levels, first store the hierarchical identification segment of the highest level of the object body to be created to the leaf node of the next level (first level) of the root node. Then, store the hierarchical identification segment of the next level of the highest level of the object body to be created to the leaf node of the next level (second level) of the leaf node of the first level, and so on, until the hierarchical identification segment of the lowest level of the object body to be created is stored in the leaf node of the lowest level in the corresponding entire storage path, and the mapping relationship between the hierarchical identification segment of the lowest level and the blockchain address of the object body to be created is stored in the first tree, and the blockchain address of the object body to be created is used as the candidate blockchain address corresponding to the hierarchical identification segment of the lowest level. Repeat the above process, store the hierarchical identification segment strings and blockchain addresses of all object bodies to be created, and you can get a complete first tree.
[0221] In order to save space, the specific implementation process of recording the hierarchical identification segment string and blockchain address of the object to be created into the first tree in the embodiment of the present disclosure will be described in detail below and will not be repeated here.
[0222] Through the above steps 710-740, the embodiment of the present disclosure recursively constructs a first tree containing multiple levels, and the first tree lists the candidate hierarchical identification segments of the object body at each level, as well as the subordinate relationship between the candidate hierarchical identification segments of different levels, so that the relevant information of multiple object bodies can be systematically stored. At the same time, the first tree also records the corresponding relationship between the candidate hierarchical identification segments of each object body and the blockchain address, which can effectively improve the storage rationality of the hierarchical identification segment strings and blockchain addresses of each object body, thereby realizing the search for the blockchain address by traversing the first tree, and improving the efficiency of blockchain transaction processing.
[0223] Combine the following Fig. 9 , Fig.10 The process of recording the hierarchical identification segment string and the blockchain address of the object to be created into the first tree is described in detail.
[0224] Please refer to Fig. 9 In one embodiment, when the hierarchical identification segment string of the object body to be created has only one hierarchical identification segment, the process of searching the first tree according to the target hierarchical identification segment string includes but is not limited to the following steps 910-930:
[0225] Step 910: Obtain the address of the first requesting party;
[0226] Step 920: Determine the first deployment address of the object to be created;
[0227] Step 930: If it is determined that the first requester address and the first deployment address are consistent, the hierarchical identification segment of the object body to be created is stored in the leaf node of the first level of the first tree, and the blockchain address of the object body to be created is used as the candidate blockchain address of the leaf node of the first level.
[0228] Steps 910 - 930 are described in detail below.
[0229] In step 910, the first requesting party address is obtained.
[0230] The first requester address is the address of the user who initiates the object body creation request.
[0231] When this embodiment is implemented specifically, the first requesting party address can be obtained by reading the terminal address of the target terminal with the authorization of the user, and using the terminal address as the first requesting party address.
[0232] In step 920, a first deployment address of the object body to be created is determined.
[0233] The first deployment address generally refers to the address of the owner of the object body to which the object body to be created belongs.
[0234] It should be noted that, when the hierarchical identification segment string of the object to be created has only one hierarchical identification segment, the object to be created does not belong to any object, and at this time, the first deployment address is the address of the owner of the object to be created. When the hierarchical identification segment string of the object to be created contains more than one hierarchical identification segment, the first deployment address is the address of the owner of the object to which the object to be created belongs.
[0235] For example, if the object to be created is contract A, and contract A is a subcontract of contract B, then the first deployment address is the address of the user who owns contract B. If the object to be created is contract C, but contract C is not subordinate to any contract, then the first deployment address is the address of the user who owns contract C.
[0236] In the specific implementation of this embodiment, when initiating an object creation request, it is first confirmed at which level of the object the object to be created needs to be added. Based on this, the object terminal receives additional information sent along with the object creation request, the additional information is used to indicate at which level of the object the object to be created needs to be added, and sends this additional information to the server. The server determines the object to which the object to be created belongs based on this additional information, and calls the address of the owner of this object as the first deployment address if authorized.
[0237] For example, the additional information attached to the object creation request indicates that contract A is to be created at the next level of contract B, that is, contract A is recorded as a child contract of contract B. Based on this, the server will call the address of the owner of contract B as the first deployment address. The first deployment address is used to determine whether the user who sends the object creation request has the authority to continue to create a new object under contract B.
[0238] In step 930, if it is determined that the first requester address and the first deployment address are consistent, the hierarchical identification segment of the object body to be created is stored in the leaf node of the first level of the first tree, and the blockchain address of the object body to be created is used as the candidate blockchain address of the leaf node of the first level.
[0239] In the specific implementation of this embodiment, if it is determined that the first requester address is consistent with the first deployment address, it indicates that the user who sends the object creation request has the authority to create the object to be created, and the hierarchical identification segment and blockchain address of the object to be created are allowed to be recorded in the first tree. Based on this, the hierarchical identification segment of the object to be created is stored in the leaf node of the first level of the first tree, and the blockchain address of the object to be created is used as the candidate blockchain address of the leaf node of the first level.
[0240] like Fig.10As shown, the object body to be created includes a contract and an associated resource pool, wherein the contract is not subordinate to any contract, and the associated resource pool is not subordinate to a certain resource pool. Therefore, both the contract and the associated resource pool are stored in the leaf node of the next level of the root node. Specifically, the candidate hierarchical identification segment (.sol) of the contract is stored in the left leaf node, and the candidate hierarchical identification segment (.name) of the associated resource pool is stored in the right leaf node. In addition, the contract address of the contract is used as the candidate blockchain address corresponding to the candidate hierarchical identification segment in the left leaf node, and the resource pool address of the associated resource pool is used as the candidate blockchain address corresponding to the candidate hierarchical identification segment in the right leaf node.
[0241] Through the above steps 910-930, the embodiment of the present disclosure determines the level of the object to be created according to the number of hierarchical identification segments contained in the hierarchical identification segment string of the object to be created, and records the relevant information of the object to be created with only one hierarchical identification segment at the first level of the first tree, so as to realize the construction of the candidate hierarchical identification segments of the first level of the first tree and the candidate blockchain addresses of the candidate hierarchical identification segments, so that the specific information of the object to be created with a higher level is recorded at a higher position of the first tree, and the specific information of the object to be created belonging to the high-level object is recorded at a lower position of the first tree, so as to realize the hierarchical storage of the hierarchical identification segment strings and blockchain addresses of each object, and improve the rationality of address storage.
[0242] Combine the following Fig.11 , Figure 12A-12C The process of recording the hierarchical identification segment string and the blockchain address of the object to be created into the first tree is described in detail.
[0243] Please refer to Fig.11 In one embodiment, when the hierarchical identification segment string of the object body to be created includes multiple hierarchical identification segments, the process of searching the first tree according to the target hierarchical identification segment string includes but is not limited to the following steps 1110-1130:
[0244] Step 1110: If it is determined that the first requester address is consistent with the first deployment address, extracting an address mapping table corresponding to the first-level candidate hierarchical identification segment from the first tree;
[0245] Step 1120: for each object to be created, if it is determined that there is no identification path that is consistent with the hierarchical identification segment string of the object to be created, then based on the hierarchical identification segment string of the object to be created, generate a candidate hierarchical identification segment of the next level of the candidate hierarchical identification segment of the first level;
[0246] Step 1130: Update the address mapping table based on the difference between the hierarchical identification segment string of the object to be created and the candidate hierarchical identification segment of the next level, and the blockchain address of the object to be created.
[0247] Steps 1110 - 1130 are described in detail below.
[0248] In step 1110, if it is determined that the first requester address is consistent with the first deployment address, an address mapping table corresponding to the candidate hierarchical identification segment of the first level is extracted from the first tree.
[0249] The address mapping table is used to indicate the identification path of the candidate hierarchical identification segment of the next level associated with the candidate hierarchical identification segment of the first level, and the mapping relationship between the identification path and the candidate blockchain address.
[0250] In the specific implementation of this embodiment, if it is determined that the first requester address is consistent with the first deployment address, it indicates that the user who sent the object body creation request has the authority to modify the object body to which the object body to be created belongs, and is allowed to add a next-level object body to the object body to which the object body to be created belongs. Based on this, the address mapping table corresponding to the candidate hierarchical identification segment of the first level is extracted from the first tree. The address mapping table will record all the sub-object bodies of the object body indicated by the candidate hierarchical identification segment belonging to the first level. It can be determined whether the object body to be created already exists in the first tree based on the address mapping table.
[0251] In step 1120, for each object body to be created, if it is determined that there is no identification path that is consistent with the hierarchical identification segment string of the object body to be created, then based on the hierarchical identification segment string of the object body to be created, a candidate hierarchical identification segment of the next level of the candidate hierarchical identification segment of the first level is generated.
[0252] In the specific implementation of this embodiment, for each object body to be created, the address mapping table corresponding to the candidate hierarchical identification segment of the first level is extracted in the first tree for search, and it is determined whether there is an identification path consistent with the hierarchical identification segment string of the object body to be created in the address mapping table. If it is determined that there is no identification path consistent with the hierarchical identification segment string of the object body to be created, it indicates that the object body to be created does not exist in the first tree. Based on this, the hierarchical identification segment of the lowest level in the hierarchical identification segment string of the object body to be created is used as the candidate hierarchical identification segment of the next level of the candidate hierarchical identification segment of the first level.
[0253] It should be noted that, when the candidate hierarchical identification segment of the lowest level of the object body to which the object body to be created belongs is not the candidate hierarchical identification segment of the first level of the first tree, the level where the candidate hierarchical identification segment of the lowest level of the object body to which the object body to be created belongs is located is regarded as the first level described above, and the object body is created according to the address mapping table of the candidate hierarchical identification segment of the lowest level of the object body to which the object body to be created belongs. The specific implementation process is similar to the above-mentioned steps 1110-1120 and will not be repeated here to save space.
[0254] like Fig. 12A As shown, it is a first tree formed according to the selected root node blockchain address, and multiple associated resource pools and contracts recorded in the blockchain. Specifically, the first tree contains four levels, the first level is below the root node of the first tree, and the first level contains candidate hierarchical identification segment 1 (.sol) and candidate hierarchical identification segment 2 (.name). Candidate hierarchical identification segment 1 is used to indicate the object body of the contract type, and candidate hierarchical identification segment 2 (.name) is used to indicate the object body of the associated resource pool type. Further, the next level of candidate hierarchical identification segment 1 and candidate hierarchical identification segment 2 is the second level, wherein the next level of candidate hierarchical identification segment 1 contains two different types of sub-contracts, and the candidate hierarchical identification segments of the two contracts are candidate hierarchical identification segment 3 (A.sol) and candidate hierarchical identification segment 4 (B.sol). The next level of candidate hierarchical identification segment 2 contains two different types of sub-associated resource pools, and the candidate hierarchical identification segments of the two associated resource pools are candidate hierarchical identification segment 5 (English.name) and candidate hierarchical identification segment 6 (Chinese.name). Further, the next level of candidate hierarchical identification segment 3, candidate hierarchical identification segment 4, candidate hierarchical identification segment 5, and candidate hierarchical identification segment 6 is the third level. Among them, the next level of candidate hierarchical identification segment 3 contains two sub-contracts of different types, and the candidate hierarchical identification segments of the two contracts are candidate hierarchical identification segment 7 (aAsol) and candidate hierarchical identification segment 8 (bAsol). The next level of candidate hierarchical identification segment 4 contains 1 sub-contract, and the candidate hierarchical identification segment of this contract is candidate hierarchical identification segment 9 (aBsol). The next level of candidate hierarchical identification segment 5 contains two different sub-associated resource pools, and the candidate hierarchical identification segments of the three associated resource pools are candidate hierarchical identification segment 10 (Mary.English.name) and candidate hierarchical identification segment 11 (John.English.name). The next level of candidate hierarchical identification segment 6 contains 1 sub-associated resource pool, and the candidate hierarchical identification segment of this associated resource pool is candidate hierarchical identification segment 12 (xx.Chinese.name). Further, the next level of candidate hierarchical identification segment 8 is the fourth level. Among them, the next level of the candidate hierarchical identification segment 8 contains two different sub-contracts, and the candidate hierarchical identification segments of these two contracts are candidate hierarchical identification segment 13 (5.bAsol) and candidate hierarchical identification segment 14 (7.bAsol) respectively.
[0255] like Fig. 12BAs shown, the object body creation request will instruct the creation of Tom's associated resource pool information and contract information of contract A on the blockchain. Among them, the candidate hierarchical identification segment string of Tom's associated resource pool is specifically "Tom.English.name"; the blockchain address of the associated resource pool is 1234567k. The candidate hierarchical identification segment string of contract A is specifically "K.5.bAsol"; the blockchain address is xxxx1234. In addition, Tom's associated resource pool information needs to be created under the associated resource pool with the candidate hierarchical identification segment string as "English.name", and the contract information of contract A needs to be created under the contract with the candidate hierarchical identification segment string as "5.bAsol".
[0256] like Fig. 12C As shown, first, the address of the initiator of the object body creation request is compared with the address of the owner of the associated resource pool whose candidate hierarchical identification segment string is "English.name", and the address of the initiator of the object body creation request is compared with the address of the owner of the contract whose candidate hierarchical identification segment string is "5.bAsol". After comparison, the three addresses are the same address, so the initiator of the object body creation request can create Tom's associated resource pool information and contract information of contract A in the first tree. Next, the address mapping table of the associated resource pool whose candidate hierarchical identification segment string is "English.name" and the address mapping table of the contract whose candidate hierarchical identification segment string is "5.bAsol" are called. After searching the address mapping table, it is found that the hierarchical identification segments "Tom.English.name" and "K.5.bAsol" do not exist in the address mapping table. Therefore, the hierarchical identification segment "Tom.English.name" is recorded in the leaf node of the next level of the candidate hierarchical identification segment "English.name", and the blockchain address "1234567k" corresponding to the hierarchical identification segment "Tom.English.name" is recorded in the address mapping table of the associated resource pool of the candidate hierarchical identification segment string "English.name". Similarly, the hierarchical identification segment "K.5.bAsol" is recorded in the leaf node of the next level of the candidate hierarchical identification segment "5.bAsol", and the blockchain address "xxxx1234" corresponding to the hierarchical identification segment "K.5.bAsol" is recorded in the address mapping table of the contract of the candidate hierarchical identification segment string "5.bAsol".
[0257] In step 1130, the address mapping table is updated based on the difference between the hierarchical identification segment string of the object to be created and the candidate hierarchical identification segment of the next level, and the blockchain address of the object to be created.
[0258] The difference between the hierarchical identification segment string and the candidate hierarchical identification segment of the next level refers to the part of the hierarchical identification segment string that is different from the candidate hierarchical identification segment.
[0259] For example, if the hierarchical identification segment string of the object to be created is B.sol, then the hierarchical identification segments included in the hierarchical identification segment string are (.B.sol) and (.sol). The first-level candidate hierarchical identification segment is (.sol), so the difference between the two is B, and the concatenation of the difference and the first-level candidate hierarchical identification segment is the lowest-level hierarchical identification segment (.B.sol) of the object to be created.
[0260] In the specific implementation of this embodiment, the difference between the hierarchical identification segment string of the object to be created and the candidate hierarchical identification segment of the next level is first used as the identification path of the object to be created. Then, the blockchain address of the object to be created is used as the candidate blockchain address corresponding to the hierarchical identification segment of the lowest level. Finally, the identification path and the candidate blockchain address are stored as a pair of key-value pairs in the address mapping table. Among them, the identification path is the keyword key, and the candidate blockchain address is the value value.
[0261] In another embodiment, after extracting the address mapping table of the first-level candidate hierarchical identification segments from the first tree, the blockchain transaction processing method further includes but is not limited to the following steps:
[0262] For each object body to be created, if it is determined that there is an identification path that is consistent with the hierarchical identification segment string of the object body to be created, generating second prompt information;
[0263] Based on the second prompt information, the object creation request is rejected.
[0264] The second prompt information is used to prompt that the candidate hierarchy indicated by the identification path existing in the first tree is consistent with the hierarchy identification segment string of the object body to be created.
[0265] When this embodiment is implemented, the address mapping table corresponding to the candidate hierarchical identification segment of the first level is extracted from the first tree for searching, and it is determined whether there is an identification path in the address mapping table that is consistent with the hierarchical identification segment string of the object body to be created. If it is determined that there is an identification path that is consistent with the hierarchical identification segment string of the object body to be created, it indicates that the object body to be created already exists in the first tree, and the hierarchical identification segment string of the object body to be created exists at the next level of the candidate hierarchical identification segment of the first level, therefore, the second prompt information is generated, and the object body creation request is rejected.
[0266] Through the above steps 1110-1130, the embodiment of the present disclosure, when recording the hierarchical identification segment string and blockchain address of the object body to be created in the first tree, takes into account the need to verify whether the requester has the creation authority. After determining that the requester has the creation authority, it is also verified whether the object body to be created already exists in the first tree. The object body is created only when it is determined that there is no object body to be created in the first tree. This can improve the security of object body creation and reduce the risk of repeatedly recording the hierarchical identification segment string and blockchain address of the same object body.
[0267] A detailed description of an embodiment of the present disclosure on updating the address of an object body of a first tree
[0268] Since the address of the user's associated resource pool and the contract address of the contract often change due to various reasons, if the blockchain address recorded in the first tree is not updated for a long time, the found address will often be wrong or unavailable, which will affect the normal processing of blockchain transactions and make the transaction processing efficiency low. Based on this, the embodiment of the present disclosure provides a solution for updating the address of the object body of the first tree, which can improve the information validity of the first tree, thereby enabling various blockchain transactions to be processed normally and improving the transaction processing efficiency.
[0269] Combine the following Fig.13 , Figure 14A-14B The process of updating the blockchain address of the object body of the first tree is described in detail.
[0270] Please refer to Fig.13 In one embodiment, the process of updating the blockchain address of the object body of the first tree includes but is not limited to the following steps 1310-1380:
[0271] Step 1310: receiving an object body update request;
[0272] Step 1320: Obtain the address of the second requesting party;
[0273] Step 1330: determine a second deployment address of a second object;
[0274] Step 1340: If it is determined that the second requester address is consistent with the second deployment address of the second object body, determine a candidate blockchain address of the object body to be updated in the first tree based on the object body association information;
[0275] Step 1350: Perform a first verification based on the candidate blockchain address of the object to be updated;
[0276] Step 1360: If it is determined that the first verification passes, extract the candidate blockchain address of the second object in the first tree;
[0277] Step 1370: Perform a second verification based on the candidate blockchain address of the second object.
[0278] Step 1380: If it is determined that the second verification passes, in the address mapping table of the second object body, the address of the object body to be updated is updated based on the updated blockchain address.
[0279] Steps 1310-1380 are described in detail below.
[0280] In step 1310, an object body update request is received.
[0281] The object body update request is used to instruct to update the blockchain address of the object body to be updated at the next level of the second object body.
[0282] The object update request includes the update blockchain address of the object to be updated and the object association information.
[0283] The update blockchain address is the latest blockchain address of the object to be updated.
[0284] For example, for a user A's associated resource pool K, the associated resource pool used by user A three months ago was a resource pool hosted by institution 1. The blockchain address 1 of the associated resource pool K will be bound to institution 1, and the blockchain address 1 will often be accompanied by the identification information of institution 1. However, user A now hands over the associated resource pool K to institution 2 for management, and the blockchain address will become blockchain address 2. The blockchain address 2 of the associated resource pool K needs to be bound to institution 2, and the blockchain address 2 will often be accompanied by the identification information of institution 2. In order for user A's resource exchange to proceed normally, the blockchain address 1 recorded in the blockchain needs to be updated to blockchain address 2.
[0285] The object association information is used to indicate the lowest level hierarchical identification segment in the hierarchical identification segment string of the object body to be updated. For example, for the object body to be updated whose candidate hierarchical identification segment string is "bAsol", the object association information is "b".
[0286] In addition, the object body update request will also indicate which object body the object body to be updated belongs to, as well as information such as a candidate hierarchical identification segment string and a blockchain address of the object body to which the object body to be updated belongs. In the disclosed embodiment, the object body update request will indicate that the object body to be updated is a lower-level object body of the second object body, and the object body to be updated is subordinate to the second object body.
[0287] The specific implementation process of step 1310 is similar to the specific implementation process of the above step 730. The difference is that the request in step 730 is to create a new object body, while step 1310 is to update the address of a certain object body, and the requirements of the two are different. To save space, it will not be repeated.
[0288] In step 1320, the second requesting party address is obtained.
[0289] The second requester address is the address of the user who initiates the object body update request.
[0290] The specific implementation process of step 1320 is similar to the specific implementation process of the above step 910. The difference is that the address obtained in step 910 is the address of the user who initiated the object body creation request; the address obtained in step 1320 is the address of the user who initiated the object body update request. To save space, it will not be repeated.
[0291] In step 1330, a second deployment address of the second object volume is determined.
[0292] The second deployment address refers to the address of the owner of the second object body.
[0293] The specific implementation process of step 1330 is similar to the specific implementation process of step 920. The difference is that the deployment address of the user who owns the object to be created in step 920 is obtained; the address obtained in step 1320 is the deployment address of the user who owns the second object. To save space, it will not be repeated.
[0294] In step 1340, if it is determined that the second requester address is consistent with the second deployment address of the second object body, a candidate blockchain address of the object body to be updated is determined in the first tree based on the object body association information.
[0295] In the specific implementation of this embodiment, if it is determined that the second requesting party address is consistent with the second deployment address of the second object body, it indicates that the user who initiated the object body update request is the actual owner of the second object body and has the authority to modify the second object body. Based on this, the object body association information and the candidate hierarchical identification segment of the lowest level in the candidate hierarchical identification segment string of the second object body are first spliced to form a longer candidate hierarchical identification segment, which is the candidate hierarchical identification segment of the lowest level of the object body to be updated. Then, the address mapping table of the second object body is called from the first tree with authorization permission, and the identification path consistent with the object body association information is searched in the called address mapping table. If there is an identification path consistent with the object body association information in the address mapping table, the candidate blockchain address corresponding to the identification path consistent with the object body association information is used as the candidate blockchain address of the object body to be updated.
[0296] Furthermore, if there is no identification path consistent with the object association information in the address mapping table, it indicates that the next level object of the second object does not contain the object to be updated, and the address update cannot be achieved. At this time, the server will generate an error message and reject the object update request.
[0297] In step 1350, a first verification is performed based on the candidate blockchain address of the object to be updated.
[0298] The first verification is used to determine whether the candidate blockchain address of the object to be updated is a contract address, and whether the object to be updated has the function of implementing a predetermined method.
[0299] In order to save space, the specific implementation process of the first verification based on the candidate blockchain address of the object to be updated in the embodiment of the present disclosure will be described in detail below and will not be repeated here.
[0300] In step 1360, if it is determined that the first verification passes, a candidate blockchain address of the second object body is extracted from the first tree.
[0301] In the specific implementation of this embodiment, if it is determined that the first verification is passed, the address mapping table maintained in the first tree is searched according to the candidate hierarchical identification segment string of the second object body indicated by the object body update request. Then, after searching, the candidate blockchain address corresponding to the candidate hierarchical identification segment of the lowest level in the candidate hierarchical identification segment string is determined, and the determined candidate blockchain address is the candidate blockchain address of the second object body.
[0302] In step 1370, a second verification is performed based on the candidate blockchain address of the second object.
[0303] The second verification is used to determine whether the object body update request initiated by the user meets the requirements, wherein the requirement to be met is generally that the second object body indicated by the user in the object body update request is the same as the second object body recorded in the first tree.
[0304] In order to save space, the specific implementation process of performing the second verification based on the candidate blockchain address of the second object in the embodiment of the present disclosure will be described in detail below and will not be repeated here.
[0305] In step 1380, if it is determined that the second verification passes, the address of the object to be updated is updated based on the updated blockchain address in the address mapping table of the second object.
[0306] In the specific implementation of this embodiment, if it is determined that the second verification is passed, it indicates that the address of the object to be updated can be updated. Therefore, the candidate blockchain address of the object to be updated stored in the address mapping table of the second object can be updated to the update blockchain address.
[0307] In order to save space, the specific implementation process of updating the address of the object to be updated based on updating the blockchain address in the embodiment of the present disclosure will be described in detail below and will not be repeated here.
[0308] like Fig.14AThe figure is a schematic diagram of an object body update request. Specifically, the object body update request indicates to update the address of contract K with the candidate hierarchical identification segment string "bAsol" under contract M, and the new blockchain address of contract K is "qqq176". It can be seen that the candidate hierarchical identification segment string of the second object body to which contract K belongs is "A.sol".
[0309] like Fig. 14B As shown, first, the address of the initiator of the object body update request is compared with the address of the owner of the contract whose candidate hierarchical identification segment string is "A.sol". After comparison, the address of the initiator and the address of the owner of the contract are the same address, so the initiator of the object body update request can update the contract information of contract K in the first tree. Next, the address mapping table of the contract whose candidate hierarchical identification segment string is "A.sol" is called. After searching the address mapping table, it is found that there is a hierarchical identification segment "bAsol" in the address mapping table. Therefore, it is continued to verify whether the candidate blockchain address corresponding to the hierarchical identification segment "bAsol" is the contract address, and whether contract K has the function of verifying that the contract M indicated by the object body update request is the same as the contract M recorded in the first tree. When it is determined that the candidate blockchain address is a contract address and contract K has the above function, it is verified whether the contract M indicated by the object body update request is the same as the contract M recorded in the first tree. When the address of the contract M indicated by the object body update request is consistent with the candidate blockchain address of the contract M recorded in the first tree, it is considered that the verification is passed. At this time, the candidate blockchain address of contract K is updated to "qqq176" in the address mapping table of contract M.
[0310] Through the above steps 1310-1380, the embodiment of the present disclosure updates the address of the object body of the first tree based on the address mapping table of each object body maintained in the first tree, and can timely identify the object body that needs to update the blockchain address, which is conducive to improving the information validity of the first tree, thereby enabling various blockchain transactions to be processed normally and improving transaction processing efficiency. In addition, in the process of address update, the embodiment of the present disclosure takes into account the verification of the candidate blockchain address of the object body to be updated and the verification of the candidate blockchain address of the second object body, and uses a multiple verification method to determine whether the blockchain address of each object body can be updated, which can improve the reliability and accuracy of address update.
[0311] Please refer to Fig.15 In one embodiment, the process of performing the first verification based on the candidate blockchain address of the object to be updated includes but is not limited to the following steps 1510-1520:
[0312] Step 1510: If it is determined that the candidate blockchain address is a contract address and the candidate blockchain address satisfies the first condition, it is determined that the first verification is passed;
[0313] Step 1520: If it is determined that the candidate blockchain address is not a contract address, or the candidate blockchain address does not meet the first condition, it is determined that the first verification fails.
[0314] Steps 1510-1520 are described in detail below.
[0315] The first condition is used to limit the contract indicated by the candidate blockchain address to implement a predetermined method. The predetermined method refers to a method defined in the writing of various code programs. In the embodiment of the present disclosure, the predetermined method may be a function for the contract to determine whether the candidate blockchain address of the second object body (the blockchain address of the parent contract of the contract recorded in the first tree) and the object body address of the second object body (the actual contract address of the parent contract of the contract) are consistent.
[0316] In step 1510, since each contract address has a contract code, based on this, when determining whether the candidate blockchain address is a contract address, it is possible to first determine whether the candidate blockchain address is a contract address, and then extract the code information of the candidate blockchain address to determine whether the contract code in the code information is empty. If the code information indicates that the contract code is not empty, the candidate blockchain address is determined to be a contract address. In addition, when the contract indicated by the candidate blockchain address has a function of determining whether the candidate blockchain address of the parent contract of the contract is consistent with the actual contract address of the parent contract, the candidate blockchain address is considered to meet the first condition. Therefore, when the candidate blockchain address is a contract address and the candidate blockchain address meets the first condition, it is determined that the first verification is passed.
[0317] In step 1520, determining that the first verification fails includes the following situations:
[0318] (1) If the code information representing the contract code is empty, it is determined that the candidate blockchain address is not a contract address, and the first verification is determined to be passed.
[0319] (2) If the contract indicated by the candidate blockchain address does not have the function of determining whether the candidate blockchain address of the parent contract of the contract is consistent with the actual contract address of the parent contract, it is considered that the candidate blockchain address does not meet the first condition, and the first verification is determined to have failed.
[0320] (3) If the contract code represented by the code information is empty, and the contract indicated by the candidate blockchain address does not have the function of determining whether the candidate blockchain address of the parent contract of the contract is consistent with the actual contract address of the parent contract, then it is determined that the first verification fails.
[0321] It should be noted that when the first verification fails, the address of the object to be updated can be directly updated in the address mapping table of the second object based on the updated blockchain address, and the specific implementation process is similar to the specific implementation process of the above step 1380. To save space, it will not be repeated.
[0322] Through the above steps 1510-1520, the embodiment of the present disclosure verifies the address update according to whether the candidate blockchain address is a contract address and whether the contract indicated by the candidate blockchain address implements a predetermined method. When the candidate blockchain address is a contract address and implements the predetermined method, it is considered that the verification is passed and further verification is taken. In other cases, it is considered that the verification fails and the address is directly updated. It is possible to judge whether the address update is implemented based on different situations, thereby achieving comprehensive verification and judgment of the address update, and improving verification efficiency and accuracy.
[0323] Please refer to Fig.16 In one embodiment, the process of performing the second verification based on the candidate blockchain address of the second object includes but is not limited to the following steps 1610-1630:
[0324] Step 1610: Obtain the object address of the second object;
[0325] Step 1620: If the candidate blockchain address of the second object body is consistent with the object body address of the second object body, it is determined that the second verification is passed;
[0326] Step 1630: If the candidate blockchain address of the second object body and the object body address of the second object body are inconsistent, it is determined that the second verification fails.
[0327] Steps 1610-1630 are described in detail below.
[0328] The object body address of the second object body refers to the blockchain address of the second object body input by the user along with the object body update request. When the second object body is a contract, the object body address refers to the contract address input by the user along with the object body update request. When the second object body is an associated resource pool, the object body address refers to the resource pool address input by the user along with the object body update request.
[0329] In step 1610, since the user confirms the second object body and synchronously enters the object body address of the second object body that he thinks is when inputting the object body update request, the object terminal will receive the object body address input by the user together with the object body update request, and send the object body update request and the object body address to the server, so the server can obtain the object body address of the second object body through data interaction with the object terminal.
[0330] It should be noted that, since the object body address of the second object body is input by the user, the object body address is not necessarily accurate and often needs to be verified. Therefore, the embodiment of the present disclosure provides a second verification link to verify the object body address of the second object body.
[0331] In step 1620, since the object body address of the second object body input by the user is not necessarily consistent with the candidate blockchain address of the second object body. Therefore, the embodiment of the present disclosure takes into account the need to perform address verification on the second object body. Specifically, the candidate blockchain address of the second object body and the object body address of the second object body are first compared. If the candidate blockchain address of the second object body and the object body address of the second object body are consistent, it indicates that the second object body that the user wants to perform the update operation on meets the requirements for address update, and therefore, it is determined that the second verification is passed.
[0332] In step 1630, if the candidate blockchain address of the second object body and the object body address of the second object body are inconsistent, it indicates that the second object body that the user wants to perform the update operation on is inconsistent with the second object body recorded in the blockchain, and the second object body that the user wants to perform the update operation on does not meet the address update requirements. Therefore, it is determined that the second verification fails.
[0333] Through the above steps 1610-1630, the embodiment of the present disclosure verifies the address of the second object based on the candidate blockchain address of the second object and the object address of the second object, thereby determining whether the second object that the user wants to perform an update operation on is the second object recorded in the blockchain. This method has a simple verification process and can effectively improve the verification efficiency. When the candidate blockchain address and the object address are inconsistent, the update operation is not allowed, which can effectively reduce the risks brought by malicious update transactions, thereby improving the reliability and security of address updates and reducing the risk of arbitrary tampering of the blockchain address in the first tree.
[0334] Since in the first tree, the blockchain address of each object body is often recorded in the address mapping table through a mapping relationship with the identification path of the object body, the embodiment of the present disclosure provides an address update scheme based on the address mapping table, which can improve the address update efficiency.
[0335] Please refer to Fig.17 In one embodiment, the process of updating the address of the object to be updated based on the updated blockchain address includes but is not limited to the following steps 1710-1720:
[0336] Step 1710: Update the identification path of the object to be updated in the address mapping table into object association information;
[0337] Step 1720: Replace the candidate blockchain address of the object to be updated in the address mapping table with the update blockchain address.
[0338] Steps 1710-1720 are described in detail below.
[0339] In step 1710, the address mapping table of the second object is first called, and then the identification path of the object to be updated is updated into the object association information.
[0340] It should be noted that, generally, the object body association information and the identification path in the address mapping table are consistent, and the identification path of the object body to be updated recorded in the address mapping table will not change.
[0341] In step 1720, the address mapping table of the second object is first called. Then, the candidate blockchain address in the address mapping table is replaced with the updated blockchain address to implement the update of the blockchain address.
[0342] like Fig.18 As shown, the blockchain address of the contract K with the candidate hierarchical identification segment string "bAsol" is updated to "qqq176" in response to the object body update request. First, the address mapping table of the second object body with the candidate hierarchical identification segment string "A.sol" is extracted, and the record with the identification path "b" is found in the address table. In the address mapping table, the candidate blockchain address corresponding to the identification path "b" is updated from "Xxx88" to "qqq176". Based on this, when querying the address of the target object body with the target hierarchical identification segment string "bAsol", the blockchain address found from the first tree will be "qqq176".
[0343] Through the above steps 1710-1720, in the embodiment of the present disclosure, when updating the address of the object to be updated, it is often only necessary to update the candidate blockchain address corresponding to the identification path in the address mapping table to achieve the address update, which can achieve the address update with high efficiency, which is beneficial to improving the validity and update timeliness of the blockchain address.
[0344] A detailed description of deleting an object body of the first tree according to an embodiment of the present disclosure
[0345] As time goes by and needs change, the user's associated resource pool, the frequency of use of the contract, and the security level often change. For example, after a user stops an associated resource pool, if the relevant information of the associated resource pool continues to be recorded in the blockchain, it will often occupy a part of the storage space, reducing the effective utilization rate of the blockchain's storage space. Based on this, the embodiment of the present disclosure provides a solution for deleting the address of the object body of the first tree, which can timely clean up unnecessary address information in the first tree and improve the utilization rate of the blockchain's storage space.
[0346] Combine the following Fig.19 , Figure 20A-20B The process of deleting the blockchain address of the object body of the first tree is described in detail.
[0347] Please refer to Fig.19 In one embodiment, the process of deleting the blockchain address of the object body of the first tree includes but is not limited to the following steps 1910-1980:
[0348] Step 1910: receiving an object deletion request;
[0349] Step 1920: Obtain the address of the third requesting party;
[0350] Step 1930: determine a third deployment address of a third object;
[0351] Step 1940: If it is determined that the third requester address and the third deployment address are consistent, determine a candidate blockchain address of the object body to be deleted in the first tree based on the object body association information;
[0352] Step 1950: Perform a third verification based on the candidate blockchain address of the object to be deleted;
[0353] Step 1960: If it is determined that the third verification passes, extract the candidate blockchain address of the third object based on the first tree;
[0354] Step 1970: Perform a fourth verification based on the candidate blockchain address of the third object.
[0355] Step 1980: If it is determined that the fourth verification passes, the candidate blockchain address of the object to be deleted is deleted from the address mapping table of the third object.
[0356] Steps 1910-1980 are described in detail below.
[0357] In step 1910, an object deletion request is received.
[0358] The object body deletion request is used to instruct to delete the blockchain address of the object body to be deleted at the next level of the third object body.
[0359] The object body deletion request includes the object body association information of the object body to be deleted.
[0360] The object association information is used to indicate the lowest level hierarchical identification segment in the hierarchical identification segment string of the object body to be updated. For example, for the object body to be updated whose candidate hierarchical identification segment string is "bAsol", the object association information is "b".
[0361] The specific implementation process of step 1910 is similar to the specific implementation process of the above step 730. The difference is that the request in step 730 is to create a new object body, while step 1310 is to delete the address of a certain object body, and the requirements of the two are different. To save space, it will not be repeated.
[0362] In step 1920, the address of the third requester is obtained.
[0363] The third requester address is the address of the user who initiates the object deletion request.
[0364] The specific implementation process of step 1920 is similar to the specific implementation process of the above step 910. The difference is that the address obtained in step 910 is the address of the user who initiated the object body creation request; the address obtained in step 1920 is the address of the user who initiated the object body deletion request. To save space, it will not be repeated.
[0365] In addition, the object body deletion request will also indicate which object body the object body to be deleted belongs to, as well as information such as a candidate hierarchical identification segment string and a blockchain address of the object body to which the object body to be deleted belongs. In the disclosed embodiment, the object body deletion request will indicate that the object body to be deleted is a lower-level object body of the third object body, and the object body to be deleted is subordinate to the second object body.
[0366] In step 1930, a third deployment address of the third object volume is determined.
[0367] The third deployment address refers to the address of the owner of the third object.
[0368] The specific implementation process of step 1930 is similar to the specific implementation process of step 920. The difference is that the deployment address of the user who owns the object to be created in step 920 is obtained; the address obtained in step 1920 is the deployment address of the user who owns the third object. To save space, it will not be repeated.
[0369] In step 1940, if it is determined that the third requester address and the third deployment address are consistent, a candidate blockchain address of the object body to be deleted is determined in the first tree based on the object body association information.
[0370] In the specific implementation of this embodiment, if it is determined that the third requester address is consistent with the third deployment address of the third object body, it indicates that the user who initiates the object body update request is the actual owner of the third object body and has the authority to modify the third object body. Based on this, the address mapping table of the third object body is first called from the first tree with authorization and permission, and the identification path consistent with the object body association information is searched in the called address mapping table. If there is an identification path consistent with the object body association information in the address mapping table, the candidate blockchain address corresponding to the identification path consistent with the object body association information is used as the candidate blockchain address of the object body to be deleted.
[0371] Furthermore, if there is no identification path consistent with the object association information in the address mapping table, it indicates that the object to be deleted is not included in the next level object of the third object, and the address cannot be deleted. At this time, the server will generate an error message and reject the object deletion request.
[0372] In step 1950, a third verification is performed based on the candidate blockchain address of the object to be deleted.
[0373] The third verification is used to determine whether the candidate blockchain address of the object to be deleted is a contract address, and whether the object to be deleted has the function of implementing the predetermined method.
[0374] In the specific implementation of this embodiment, the process of performing the third verification based on the candidate blockchain address of the object to be deleted includes but is not limited to the following steps:
[0375] If it is determined that the candidate blockchain address is a contract address and the candidate blockchain address satisfies the second condition, then it is determined that the third verification is passed;
[0376] If it is determined that the candidate blockchain address is not a contract address, or the candidate blockchain address does not meet the second condition, it is determined that the third verification fails.
[0377] When this embodiment is implemented, the specific implementation process of step 1950 is similar to the specific implementation process of the above step 1370. The difference is that step 1350 performs the first verification based on the candidate blockchain address of the object to be updated, while step 1950 performs the third verification based on the candidate blockchain address of the object to be deleted, and the candidate blockchain addresses to be verified by the two are different. To save space, it will not be repeated.
[0378] In step 1960, if it is determined that the third verification passes, a candidate blockchain address of the third object body is extracted based on the first tree.
[0379] The specific implementation process of step 1960 is similar to the specific implementation process of the above step 1360. The difference is that step 1360 is to extract the candidate blockchain address of the second object body; step 1960 is to extract the candidate blockchain address of the third object body. To save space, it will not be repeated.
[0380] In step 1970, a fourth verification is performed based on the candidate blockchain address of the third object.
[0381] The fourth verification is used to determine whether the object body deletion request initiated by the user meets the requirements, wherein the requirement to be met is generally that the third object body indicated by the user in the object body deletion request is the same as the third object body recorded in the first tree.
[0382] In the specific implementation of this embodiment, the process of performing the fourth verification based on the candidate blockchain address of the third object includes but is not limited to the following steps:
[0383] Get the object address of the third object;
[0384] If the candidate blockchain address of the third object is consistent with the object address of the third object, it is determined that the fourth verification is passed;
[0385] If the candidate blockchain address of the third object body and the object body address of the third object body are inconsistent, it is determined that the fourth verification fails.
[0386] When this embodiment is implemented, the specific implementation process of step 1970 is similar to the specific implementation process of the above step 1370. The difference is that step 1370 performs the second verification based on the candidate blockchain address of the second object, while step 1970 performs the fourth verification based on the candidate blockchain address of the third object, and the candidate blockchain addresses used for the two verifications are different. To save space, it will not be repeated.
[0387] In step 1980, if it is determined that the fourth verification passes, the candidate blockchain address of the object body to be deleted is deleted from the address mapping table of the third object body.
[0388] In the specific implementation of this embodiment, if it is determined that the second verification is passed, it indicates that the address of the object to be deleted can be deleted. Therefore, the candidate blockchain address of the object to be deleted stored in the address mapping table of the third object can be deleted, and the identification path of the object to be deleted stored in the address mapping table can be deleted.
[0389] like Fig. 20AThe figure is a schematic diagram of an object body deletion request. Specifically, the object body deletion request indicates to delete the address of contract S whose candidate hierarchical identification segment string is "5.bAsol" under contract K. It can be seen that the third object body to which contract S belongs is contract K, and the candidate hierarchical identification segment string of contract K is "bAsol".
[0390] like Fig. 20B As shown, first, the address of the initiator of the object body deletion request is compared with the address of the owner of the contract whose candidate hierarchical identification segment string is "bAsol". After comparison, the address of the initiator and the address of the owner of the contract are the same address, so the initiator of the object body deletion request can delete the contract information of contract S in the first tree. Next, the address mapping table of the contract whose candidate hierarchical identification segment string is "bAsol" is called. After searching the address mapping table, it is found that there is a hierarchical identification segment "5.bAsol" in the address mapping table. Therefore, it is continued to verify whether the candidate blockchain address corresponding to the hierarchical identification segment "5.bAsol" is the contract address, and whether contract S has the function of verifying that the contract K indicated by the object body deletion request is the same as the contract K recorded in the first tree. When it is determined that the candidate blockchain address is a contract address and contract S has the above function, it is verified whether the contract K indicated by the object body deletion request is the same as the contract K recorded in the first tree. When the address of the contract K indicated by the object body deletion request is consistent with the candidate blockchain address of the contract K recorded in the first tree, it is considered that the verification is passed. At this time, the candidate blockchain address and identification path of contract S are deleted from the address mapping table of contract K; and the leaf node corresponding to contract K is deleted from the first tree.
[0391] Through the above steps 1910-1980, the embodiment of the present disclosure deletes the candidate blockchain address in the first tree according to the user's object body deletion request, which can timely clean up unnecessary address information in the first tree and improve the utilization rate of the storage space of the blockchain. In addition, the embodiment of the present disclosure adopts a multiple verification method when deleting the blockchain address of the object body, which can determine whether to delete the address based on different situations, can verify more comprehensively, can improve the verification efficiency and verification accuracy, and thus reduce the risk of accidental deletion of the address.
[0392] Please refer to Fig.21 In one embodiment, the process of determining the candidate blockchain address of the object body to be deleted in the first tree based on the object body association information includes but is not limited to the following steps 2110-2120:
[0393] Step 2110: Based on the address mapping table of the third object, determine all the next-level objects associated with the third object and the candidate blockchain addresses of the next-level objects;
[0394] Step 2120: Based on the object body association information, determine the candidate blockchain address of the object body to be deleted from the candidate blockchain addresses of the object body at the next level.
[0395] Steps 2110-2120 are described in detail below.
[0396] In step 2110, the address mapping table of the third object body is first called from the first tree. Then, all the next-level object bodies associated with the third object body are determined according to the identification path recorded in the address mapping table, and the candidate blockchain addresses of all the next-level object bodies are determined according to the candidate blockchain addresses recorded in the address mapping table.
[0397] In step 2120, the object body association information and the identification paths of the objects at each next level are first compared. Then, the candidate blockchain address of the object body that is consistent with the identification path and the object body association information is deleted from the address mapping table, and the identification path that is consistent with the object body association information is deleted.
[0398] Through the above steps 2110-2120, the embodiment of the present disclosure determines the candidate blockchain address of the object body to be deleted recorded in the first tree based on querying the address mapping table of the third object body, thereby deleting the found candidate blockchain address, which can effectively improve the address search efficiency and deletion efficiency, and is conducive to improving the overall transaction processing efficiency of the blockchain.
[0399] Please refer to Fig. 22 In one embodiment, the process of generating the address mapping table of the third object includes but is not limited to the following steps 2210-2240:
[0400] Step 2210: extracting identification paths of multiple next-level objects associated with the third object as keywords;
[0401] Step 2220: Use the candidate blockchain address of each next-level object as a value;
[0402] Step 2230: Based on the mapping relationship between the identification path and the candidate blockchain address, construct the keyword and the value into a key-value pair;
[0403] Step 2240: Generate an address mapping table based on multiple key-value pairs.
[0404] Steps 2210-2240 are described in detail below.
[0405] In step 2210, for each object body at the next level associated with the third object body, first, the candidate hierarchical identification segment at the lowest level of the third object body is compared with the candidate hierarchical identification segment at the lowest level of the object body at the next level, and the difference between the two candidate hierarchical identification segments is taken as the identification path. Then, the identification path is used as the keyword key.
[0406] In step 2220, for each next-level object associated with the third object, first, a candidate blockchain address of each next-level object is determined, and the candidate blockchain address is used as the value value.
[0407] In step 2230, since there is a unique mapping relationship between the identification path of each next-level object body and the candidate blockchain address, the keywords and values of each next-level object body are grouped together to form a key-value pair.
[0408] In step 2240, multiple key-value pairs are integrated into a table to form an address mapping table of the third object.
[0409] like Fig.23 As shown, according to the object body deletion request: "Delete the associated resource pool address with the candidate hierarchical identification segment string "Mary.English.name", and delete the contract address of contract J with the candidate hierarchical identification segment string "5.bAsol". Specifically, in the address mapping table of the smart contract P with the candidate hierarchical identification segment string "bAsol", the identification path "5" and the candidate blockchain address "Lllllq" of contract J are deleted; in the address mapping table of the first type of associated resource pool with the candidate hierarchical identification segment string "English.name", Mary's identification path "Mary" and the candidate blockchain address "Kkk125" are deleted.
[0410] Through the above steps 2210-2240, the embodiment of the present disclosure stores the identification paths of multiple next-level object bodies associated with the third object body and the candidate blockchain address in the form of key-value pairs, which can effectively improve the query efficiency of the address and the convenience of maintaining the address mapping table, which is conducive to improving the transaction processing efficiency of the blockchain.
[0411] Description of the apparatus and device of the present disclosure
[0412] It is to be understood that, although the steps in the above-mentioned flowcharts are sequentially displayed according to the characterization of arrows, these steps are not necessarily executed in sequence according to the order of arrow characterization. Unless there is a clear description in the present embodiment, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a portion of the steps in the above-mentioned flowcharts can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a portion of the steps or stages in other steps.
[0413] It should be noted that in each specific implementation of the present application, when it comes to the need to perform relevant processing based on data related to the characteristics of the target object such as the target object attribute information or attribute information set, the permission or consent of the target object will be obtained first, and the collection, use and processing of these data will comply with relevant laws, regulations and standards. In addition, when the embodiment of the present application needs to obtain the attribute information of the target object, the separate permission or separate consent of the target object will be obtained through a pop-up window or jump to a confirmation page. After clearly obtaining the separate permission or separate consent of the target object, the necessary target object-related data used to enable the normal operation of the embodiment of the present application is obtained.
[0414] Fig.24 A schematic diagram of the structure of a blockchain transaction processing device 2400 provided in an embodiment of the present disclosure. The blockchain transaction processing device 2400 includes:
[0415] A receiving unit 2410 is configured to receive a blockchain transaction processing request, the blockchain transaction processing request is used to call a target object body recorded on the blockchain to perform blockchain transaction processing, the blockchain transaction processing request includes a target hierarchical identification segment string of the target object body, the target hierarchical identification segment string includes multiple target hierarchical identification segments organized according to a hierarchical structure of a first tree, the first tree lists candidate hierarchical identification segments of each level, and a relationship between a candidate hierarchical identification segment and a candidate hierarchical identification segment of a next level, each candidate hierarchical identification segment corresponds to a candidate blockchain address in the first tree;
[0416] A searching unit 2420 is configured to search the first tree for the target hierarchical identification segment string in descending order of hierarchy, so as to find a candidate hierarchical identification segment that matches the target hierarchical identification segment of the lowest hierarchy of the target hierarchical identification segment string;
[0417] A determining unit 2430 is used to determine the candidate blockchain address corresponding to the candidate hierarchical identification segment matched in the first tree as the target blockchain address;
[0418] The calling unit 2440 is used to call the target object body based on the target blockchain address to perform blockchain transaction processing.
[0419] Optionally, the first tree includes a root node, and the root node is associated with a root blockchain address;
[0420] The search unit 2420 is specifically used for:
[0421] The root blockchain address is used as the current address, and the address mapping table corresponding to the root blockchain address is extracted as the current mapping table, wherein the address mapping table is used to indicate multiple identification paths associated with the root blockchain address, and the mapping relationship between the identification paths and the candidate blockchain addresses, and the identification path is used to indicate the relationship between the candidate hierarchical identification segment and the candidate hierarchical identification segment of the next level;
[0422] If, based on the identification path, it is determined that there is a candidate hierarchical identification segment that is consistent with the target hierarchical identification segment of the highest level, then according to the mapping relationship, the candidate blockchain address corresponding to the candidate hierarchical identification segment is extracted as the updated current address, and based on the updated current address, the candidate hierarchical identification segment that matches the target hierarchical identification segment of the next level is searched in descending order of levels until the candidate hierarchical identification segment that matches the target hierarchical identification segment of the lowest level is found;
[0423] If, based on the identification path, it is determined that there is no candidate hierarchical identification segment that is consistent with the hierarchical identification segment of the highest level, a first prompt message is generated, and the blockchain transaction processing request is rejected based on the first prompt message.
[0424] Optionally, the first tree includes a root node and leaf nodes of multiple levels; the blockchain transaction processing device 2400 further includes a generation unit (not shown), the generation unit (not shown) is used to generate the first tree, and the generation unit (not shown) specifically includes:
[0425] A selection request receiving unit (not shown), configured to receive an object body selection request, wherein the object body selection request is used to call a blockchain address of a first object body stored in a root node;
[0426] A root node determination unit (not shown), configured to determine the blockchain address of the first object as a candidate blockchain address corresponding to the root node;
[0427] A creation request receiving unit (not shown), configured to receive an object creation request, wherein the object creation request includes a hierarchical identification segment string of an object to be created and a blockchain address of the object to be created;
[0428] A construction unit (not shown) is used to store the hierarchical identification segment string and blockchain address of each object body to be created in order from high to low levels to the leaf nodes, until a candidate hierarchical identification segment corresponding to the leaf node of the lowest level is generated to obtain a first tree.
[0429] Optionally, the hierarchical identification segment string of the object body to be created has only one hierarchical identification segment;
[0430] A construction unit (not shown) is specifically used to:
[0431] Obtaining a first requester address, where the first requester address is an address of a user who initiates an object creation request;
[0432] Determine a first deployment address of the object to be created;
[0433] If it is determined that the first requester address and the first deployment address are consistent, the hierarchical identification segment of the object body to be created is stored in the leaf node of the first level of the first tree, and the blockchain address of the object body to be created is used as the candidate blockchain address of the leaf node of the first level.
[0434] Optionally, the hierarchical identification segment string of the object body to be created includes multiple hierarchical identification segments;
[0435] A construction unit (not shown) is specifically used to:
[0436] If it is determined that the first requester address and the first deployment address are consistent, extracting an address mapping table corresponding to the candidate hierarchical identification segment of the first level from the first tree, wherein the address mapping table is used to indicate an identification path of a candidate hierarchical identification segment of the next level associated with the candidate hierarchical identification segment of the first level, and a mapping relationship between the identification path and the candidate blockchain address;
[0437] For each object body to be created, if it is determined that there is no identification path that is consistent with the hierarchical identification segment string of the object body to be created, then based on the hierarchical identification segment string of the object body to be created, a candidate hierarchical identification segment of the next level of the candidate hierarchical identification segment of the first level is generated;
[0438] The address mapping table is updated based on the difference between the hierarchical identification segment string of the object to be created and the candidate hierarchical identification segment of the next level, and the blockchain address of the object to be created.
[0439] Optionally, the blockchain transaction processing apparatus 2400 further includes a request rejection unit (not shown) configured to:
[0440] For each object body to be created, if it is determined that there is an identification path that is consistent with the hierarchical identification segment string of the object body to be created, generating second prompt information;
[0441] Based on the second prompt information, the object creation request is rejected.
[0442] Optionally, the blockchain transaction processing device 2400 further includes an updating unit (not shown), and the updating unit (not shown) specifically includes:
[0443] An update request receiving unit (not shown), configured to receive an object body update request, wherein the object body update request is used to indicate that the blockchain address of the object body to be updated at the next level of the second object body is updated; the object body update request includes an updated blockchain address of the object body to be updated and object body association information;
[0444] A first address acquisition unit (not shown), used to acquire a second requester address, where the second requester address is an address of a user who initiates an object body update request;
[0445] A first address determining unit (not shown), configured to determine a second deployment address of a second object body;
[0446] A second address determining unit (not shown) is configured to determine, if it is determined that the second requester address is consistent with the second deployment address of the second object body, a candidate blockchain address of the object body to be updated in the first tree based on the object body association information;
[0447] A first verification unit (not shown), configured to perform a first verification based on a candidate blockchain address of an object to be updated;
[0448] A third address determination unit (not shown), configured to extract a candidate blockchain address of the second object body in the first tree if it is determined that the first verification passes;
[0449] A second verification unit (not shown), configured to perform a second verification based on the candidate blockchain address of the second object;
[0450] The address updating unit (not shown) is used to update the address of the object to be updated based on the updated blockchain address in the address mapping table of the second object if it is determined that the second verification is passed.
[0451] Optionally, a first verification unit (not shown) is used to:
[0452] If it is determined that the candidate blockchain address is a contract address and the candidate blockchain address satisfies the first condition, it is determined that the first verification is passed;
[0453] If it is determined that the candidate blockchain address is not a contract address, or the candidate blockchain address does not meet the first condition, it is determined that the first verification fails.
[0454] Optionally, determining whether a candidate blockchain address is a contract address is achieved by:
[0455] Extract code information of candidate blockchain addresses;
[0456] If the code information is not empty, it is determined that the candidate blockchain address is a contract address.
[0457] Optionally, a second verification unit (not shown) is used to:
[0458] Get the object address of the second object;
[0459] If the candidate blockchain address of the second object body is consistent with the object body address of the second object body, it is determined that the second verification is passed;
[0460] If the candidate blockchain address of the second object body and the object body address of the second object body are inconsistent, it is determined that the second verification fails.
[0461] Optionally, an address updating unit (not shown) is used to:
[0462] Update the identification path of the object to be updated in the address mapping table into object association information;
[0463] Replace the candidate blockchain address of the object to be updated in the address mapping table with the update blockchain address.
[0464] Optionally, the blockchain transaction processing device 2400 further includes a deletion unit (not shown), and the deletion unit (not shown) specifically includes:
[0465] a deletion request receiving unit (not shown), configured to receive an object body deletion request, wherein the object body deletion request is used to instruct to delete the blockchain address of the object body to be deleted at the next level of the third object body; the object body deletion request includes object body association information of the object body to be deleted;
[0466] A second address acquisition unit (not shown), used to acquire a third requester address, where the third requester address is an address of a user who initiates an object deletion request;
[0467] a fourth address determining unit (not shown), configured to determine a third deployment address of a third object body;
[0468] a fifth address determining unit (not shown), configured to determine, if it is determined that the third requester address and the third deployment address are consistent, a candidate blockchain address of the object body to be deleted in the first tree based on the object body association information;
[0469] A third verification unit (not shown), configured to perform a third verification based on a candidate blockchain address of the object to be deleted;
[0470] a sixth address determination unit (not shown), configured to extract a candidate blockchain address of a third object body based on the first tree if it is determined that the third verification passes;
[0471] a fourth verification unit (not shown), configured to perform a fourth verification based on the candidate blockchain address of the third object;
[0472] An address deleting unit (not shown) is configured to delete the candidate blockchain address of the object body to be deleted from the address mapping table of the third object body if it is determined that the fourth verification passes.
[0473] Optionally, a fifth address determining unit (not shown) is configured to:
[0474] Based on the address mapping table of the third object, determine all next-level object bodies associated with the third object body and candidate blockchain addresses of the next-level object bodies;
[0475] Based on the object body association information, a candidate blockchain address of the object body to be deleted is determined from the candidate blockchain addresses of the object body at the next level.
[0476] Optionally, a third verification unit (not shown) is used to:
[0477] If it is determined that the candidate blockchain address is a contract address and the candidate blockchain address satisfies the second condition, then it is determined that the third verification is passed;
[0478] If it is determined that the candidate blockchain address is not a contract address, or the candidate blockchain address does not meet the second condition, it is determined that the third verification fails.
[0479] Optionally, a fourth verification unit (not shown) is used to:
[0480] Get the object address of the third object;
[0481] If the candidate blockchain address of the third object is consistent with the object address of the third object, it is determined that the fourth verification is passed;
[0482] If the candidate blockchain address of the third object body and the object body address of the third object body are inconsistent, it is determined that the fourth verification fails.
[0483] Optionally, the address mapping table of the third object body is generated in the following manner:
[0484] Extracting identification paths of multiple next-level object bodies associated with the third object body as keywords;
[0485] Take the candidate blockchain address of each next-level object as the value;
[0486] Based on the mapping relationship between the identification path and the candidate blockchain address, the keywords and values are constructed into key-value pairs;
[0487] Generate an address mapping table based on multiple key-value pairs.
[0488] Reference Fig.25 , Fig.25 The structural block diagram of the terminal part of the blockchain transaction processing method for implementing the embodiment of the present disclosure includes: Radio Frequency (RF) circuit 2510, memory 2515, input unit 2530, display unit 2540, sensor 2550, audio circuit 2560, wireless fidelity (WiFi) module 2570, processor 2580, and power supply 2590. Those skilled in the art can understand that Fig.25 The terminal structure shown does not constitute a limitation on the mobile phone or computer, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.
[0489] RF circuit 2510 can be used for receiving and sending signals during information transmission or calls. In particular, after receiving the downlink information from the base station, it is sent to processor 2580 for processing; in addition, the designed uplink data is sent to the base station.
[0490] The memory 2515 may be used to store software programs and modules. The processor 2580 executes various functional applications and data processing of the target terminal by running the software programs and modules stored in the memory 2515 .
[0491] The input unit 2530 may be used to receive input digital or character information and generate key signal input related to the setting and function control of the target terminal. Specifically, the input unit 2530 may include a touch panel 2531 and other input devices 2532.
[0492] The display unit 2540 may be used to display input information or provided information and various menus of the target terminal. The display unit 2540 may include a display panel 2541.
[0493] The audio circuit 2560, the speaker 2561, and the microphone 2562 can provide an audio interface.
[0494] In this embodiment, the processor 2580 included in the terminal can execute the blockchain transaction processing method of the previous embodiment.
[0495] The terminals of the embodiments of the present disclosure include but are not limited to mobile phones, computers, intelligent voice interaction devices, smart home appliances, vehicle terminals, aircraft, etc. The embodiments of the present invention can be applied to various scenarios, including but not limited to data security, blockchain, data storage, information technology, etc.
[0496] Fig.26A block diagram of the structure of a portion of a server for implementing the blockchain transaction processing method of an embodiment of the present disclosure. The server may have relatively large differences due to different configurations or performances, and may include one or more central processing units (CPUs) 2622 (e.g., one or more processors) and memory 2632, and one or more storage media 2630 (e.g., one or more mass storage devices) storing application programs 2642 or data 2644. Among them, the memory 2632 and the storage medium 2630 may be short-term storage or permanent storage. The program stored in the storage medium 2630 may include one or more modules (not shown in the figure), each of which may include a series of instruction operations on the server. Furthermore, the central processing unit 2622 may be configured to communicate with the storage medium 2630 and execute a series of instruction operations in the storage medium 2630 on the server.
[0497] The server may also include one or more power supplies 2626, one or more wired or wireless network interfaces 2650, one or more input and output interfaces 2658, and / or one or more operating systems 2641, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, etc.
[0498] The central processor 2622 in the server can be used to execute the blockchain transaction processing method of the embodiment of the present disclosure.
[0499] The embodiments of the present disclosure also provide a computer-readable storage medium, which is used to store program code, and the program code is used to execute the blockchain transaction processing method of each of the aforementioned embodiments.
[0500] The embodiment of the present disclosure also provides a computer program product, which includes a computer program. A processor of a computer device reads and executes the computer program, so that the computer device executes and implements the above-mentioned transaction on-chain.
[0501] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of the present disclosure and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present disclosure described herein can, for example, be implemented in an order other than those illustrated or described herein. In addition, the terms "comprises" and "comprising" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0502] It should be understood that in the present disclosure, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.
[0503] It should be understood that in the description of the embodiments of the present disclosure, the meaning of multiple (or multiple items) is more than two, greater than, less than, exceed, etc. are understood to not include the number, and above, below, within, etc. are understood to include the number.
[0504] In the several embodiments provided in the present disclosure, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0505] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0506] In addition, each functional unit in each embodiment of the present disclosure may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0507] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present disclosure is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the various embodiments of the present disclosure. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, referred to as ROM), random access memory (Random Access Memory, referred to as RAM), disk or optical disk and other media that can store program codes.
[0508] It should also be understood that the various implementations provided in the embodiments of the present disclosure can be combined arbitrarily to achieve different technical effects.
[0509] The above is a specific description of the implementation methods of the present disclosure, but the present disclosure is not limited to the above implementation methods. Technical personnel familiar with the art can also make various equivalent modifications or substitutions without violating the spirit of the present disclosure. These equivalent modifications or substitutions are all included in the scope defined by the claims of the present disclosure.
Claims
1. A blockchain transaction processing method, characterized in that: include: receiving a blockchain transaction processing request, the blockchain transaction processing request being used to call a target object body recorded on the blockchain to execute the blockchain transaction processing, the blockchain transaction processing request comprising a target hierarchical identification segment string of the target object body, the target hierarchical identification segment string comprising a plurality of target hierarchical identification segments organized according to a hierarchical structure of a first tree, the first tree listing candidate hierarchical identification segments of each level, and a relationship between the candidate hierarchical identification segments and the candidate hierarchical identification segments of the next level, each of the candidate hierarchical identification segments corresponding to a candidate blockchain address in the first tree; Searching the first tree for the target hierarchical identification segment string in descending order of the hierarchical levels to find the candidate hierarchical identification segment that matches the target hierarchical identification segment at the lowest level of the target hierarchical identification segment string; Determine the candidate blockchain address corresponding to the candidate hierarchical identification segment matched in the first tree as the target blockchain address; The target object body is called based on the target blockchain address to perform the blockchain transaction processing.
2. The method according to claim 1, characterized in that The first tree includes a root node, and the root node is associated with a root blockchain address; The step of searching the first tree for the target hierarchical identification segment string in descending order of the levels includes: The root blockchain address is used as the current address, and an address mapping table corresponding to the root blockchain address is extracted as the current mapping table, wherein the address mapping table is used to indicate multiple identification paths associated with the root blockchain address, and a mapping relationship between the identification paths and the candidate blockchain address, and the identification path is used to indicate a relationship between the candidate hierarchical identification segment and the candidate hierarchical identification segment of the next level; If, based on the identification path, it is determined that there is a candidate hierarchical identification segment that is consistent with the target hierarchical identification segment of the highest level, then, according to the mapping relationship, the candidate blockchain address corresponding to the candidate hierarchical identification segment is extracted as the updated current address, and based on the updated current address, the candidate hierarchical identification segment that matches the target hierarchical identification segment of the next level is searched in descending order of the levels until the candidate hierarchical identification segment that matches the target hierarchical identification segment of the lowest level is found; If, based on the identification path, it is determined that there is no candidate hierarchical identification segment that is consistent with the hierarchical identification segment of the highest level, a first prompt message is generated, and the blockchain transaction processing request is rejected based on the first prompt message.
3. The method according to claim 1, characterized in that The first tree includes a root node and leaf nodes at multiple levels. The method further includes generating the first tree, specifically including: receiving an object body selection request, the object body selection request being used to call a blockchain address of a first object body stored in the root node; Determine the blockchain address of the first object as the candidate blockchain address corresponding to the root node; Receive an object creation request, wherein the object creation request includes a hierarchical identification segment string of an object to be created and a blockchain address of the object to be created; For each of the objects to be created, the hierarchical identification segment string and the blockchain address of the object to be created are stored in the leaf nodes in sequence in the order of the levels from high to low, until a candidate hierarchical identification segment corresponding to the leaf node of the lowest level is generated, thereby obtaining the first tree.
4. The method according to claim 3, characterized in that The hierarchical identification segment string of the object to be created has only one hierarchical identification segment; For each of the objects to be created, storing the hierarchical identification segment string of the object to be created and the blockchain address in the leaf node in order from high to low levels, including: Acquire a first requester address, where the first requester address is an address of a user who initiates the object creation request; Determine a first deployment address of the object to be created; If it is determined that the first requester address is consistent with the first deployment address, the hierarchical identification segment of the object body to be created is stored in the leaf node of the first level of the first tree, and the blockchain address of the object body to be created is used as a candidate blockchain address of the leaf node of the first level.
5. The method according to claim 4, characterized in that The hierarchical identification segment string of the object to be created includes a plurality of hierarchical identification segments; For each of the objects to be created, storing the hierarchical identification segment string of the object to be created and the blockchain address in the leaf node in order from high to low levels, including: If it is determined that the first requester address is consistent with the first deployment address, extracting an address mapping table corresponding to the candidate hierarchical identification segment of the first level from the first tree, wherein the address mapping table is used to indicate an identification path of a candidate hierarchical identification segment of the next level associated with the candidate hierarchical identification segment of the first level, and a mapping relationship between the identification path and the candidate blockchain address; For each of the to-be-created objects, if it is determined that there is no identification path that is consistent with the hierarchical identification segment string of the to-be-created object, then generating the candidate hierarchical identification segment of the next level of the candidate hierarchical identification segment of the first level based on the hierarchical identification segment string of the to-be-created object; The address mapping table is updated based on the difference between the hierarchical identification segment string of the object to be created and the candidate hierarchical identification segment of the next level, and the blockchain address of the object to be created.
6. The method according to claim 5, characterized in that After extracting the address mapping table of the first-level candidate hierarchical identification segments from the first tree, the method further includes: For each of the to-be-created objects, if it is determined that there is an identification path that is consistent with the hierarchical identification segment string of the to-be-created object, generating second prompt information; Based on the second prompt information, the object creation request is rejected.
7. The method according to claim 3, characterized in that After generating the first tree, the method further includes: receiving an object body update request, the object body update request being used to instruct to update a blockchain address of an object body to be updated at a next level of the second object body; the object body update request comprising an updated blockchain address of the object body to be updated and object body association information; Acquire a second requester address, where the second requester address is an address of a user who initiates the object body update request; Determining a second deployment address of the second object; If it is determined that the second requester address is consistent with the second deployment address of the second object body, determining a candidate blockchain address of the object body to be updated in the first tree based on the object body association information; Performing a first verification based on the candidate blockchain address of the object to be updated; If it is determined that the first verification passes, extracting a candidate blockchain address of the second object in the first tree; Performing a second verification based on the candidate blockchain address of the second object; If it is determined that the second verification passes, in the address mapping table of the second object body, the address of the object body to be updated is updated based on the updated blockchain address.
8. The method according to claim 7, characterized in that The performing a second verification based on the candidate blockchain address of the second object includes: Obtaining an object body address of the second object body; If the candidate blockchain address of the second object body is consistent with the object body address of the second object body, it is determined that the second verification is passed; If the candidate blockchain address of the second object body and the object body address of the second object body are inconsistent, it is determined that the second verification fails.
9. The method according to claim 7, characterized in that: The updating the address of the object to be updated based on the updated blockchain address includes: Updating the identification path of the object to be updated in the address mapping table into the object association information; The candidate blockchain address of the object to be updated in the address mapping table is replaced with the update blockchain address.
10. The method according to claim 7, characterized in that The first verification based on the candidate blockchain address of the object to be updated includes: If it is determined that the candidate blockchain address is a contract address and the candidate blockchain address satisfies the first condition, it is determined that the first verification is passed; If it is determined that the candidate blockchain address is not a contract address, or the candidate blockchain address does not meet the first condition, it is determined that the first verification fails.
11. The method according to claim 10, characterized in that Determining that the candidate blockchain address is a contract address is achieved by: Extracting code information of the candidate blockchain address; If the code information is not empty, it is determined that the candidate blockchain address is a contract address.
12. The method according to claim 3, characterized in that After generating the first tree, the method further includes: receiving an object body deletion request, the object body deletion request being used to instruct to delete a blockchain address of an object body to be deleted at a next level of the third object body; the object body deletion request comprising object body association information of the object body to be deleted; Acquire a third requester address, where the third requester address is an address of a user who initiates the object deletion request; Determining a third deployment address of the third object; If it is determined that the third requester address is consistent with the third deployment address, determining a candidate blockchain address of the object body to be deleted in the first tree based on the object body association information; Performing a third verification based on the candidate blockchain address of the object to be deleted; If it is determined that the third verification passes, extracting a candidate blockchain address of a third object based on the first tree; Performing a fourth verification based on the candidate blockchain address of the third object; If it is determined that the fourth verification passes, the candidate blockchain address of the object to be deleted is deleted from the address mapping table of the third object.
13. The method according to claim 12, characterized in that The determining, in the first tree based on the object association information, a candidate blockchain address of the object to be deleted includes: Based on the address mapping table of the third object, determine all next-level object bodies associated with the third object body and candidate blockchain addresses of the next-level object bodies; Based on the object body association information, a candidate blockchain address of the object body to be deleted is determined from the candidate blockchain addresses of the object body at the next level.
14. The method according to claim 12, characterized in that The third verification based on the candidate blockchain address of the object to be deleted includes: If it is determined that the candidate blockchain address is a contract address and the candidate blockchain address satisfies the second condition, then it is determined that the third verification is passed; If it is determined that the candidate blockchain address is not a contract address, or the candidate blockchain address does not satisfy the second condition, it is determined that the third verification fails.
15. The method according to claim 12, characterized in that The performing a fourth verification based on the candidate blockchain address of the third object includes: Obtaining an object address of the third object; If the candidate blockchain address of the third object is consistent with the object address of the third object, it is determined that the fourth verification is passed; If the candidate blockchain address of the third object body and the object body address of the third object body are inconsistent, it is determined that the fourth verification fails.
16. The method according to claim 13, characterized in that The address mapping table of the third object is generated in the following manner: Extracting identification paths of multiple next-level object bodies associated with the third object body as keywords; Taking the candidate blockchain address of each object at the next level as a value; Based on the mapping relationship between the identification path and the candidate blockchain address, construct the keyword and the value into a key-value pair; The address mapping table is generated based on the multiple key-value pairs.
17. A blockchain transaction processing device, characterized in that: The blockchain transaction processing device comprises: A receiving unit, configured to receive a blockchain transaction processing request, wherein the blockchain transaction processing request is used to call a target object body recorded on the blockchain to execute the blockchain transaction processing, wherein the blockchain transaction processing request includes a target hierarchical identification segment string of the target object body, wherein the target hierarchical identification segment string includes a plurality of target hierarchical identification segments organized according to a hierarchical structure of a first tree, wherein the first tree lists candidate hierarchical identification segments of each level, and a relationship between the candidate hierarchical identification segments and the candidate hierarchical identification segments of the next level, wherein each candidate hierarchical identification segment corresponds to a candidate blockchain address in the first tree; a search unit, configured to search the first tree for the target hierarchical identification segment string in descending order of the hierarchical levels, so as to find the candidate hierarchical identification segment that matches the target hierarchical identification segment at the lowest level of the target hierarchical identification segment string; A determination unit, configured to determine the candidate blockchain address corresponding to the candidate hierarchical identification segment matched in the first tree as a target blockchain address; A calling unit is used to call the target object body based on the target blockchain address to perform the blockchain transaction processing.
18. An electronic device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the blockchain transaction processing method described in any one of claims 1 to 16 is implemented.
19. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the blockchain transaction processing method according to any one of claims 1 to 16 is implemented.
20. A computer program product, comprising a computer program, wherein the computer program is read and executed by a processor of a computer device, so that the computer device executes the blockchain transaction processing method according to any one of claims 1 to 16.