Request processing method and device, equipment, storage medium and program product

By selecting management and auditing nodes in the blockchain based on load data, and employing quantum random number algorithms and load balancing strategies, the problem of low processing efficiency of management nodes is solved, thus achieving efficient management and security of smart contracts.

CN120856554APending Publication Date: 2025-10-28INDUSTRIAL AND COMMERCIAL BANK OF CHINA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511132254.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-13
Publication Date
2025-10-28

AI Technical Summary

Technical Problem

The low processing efficiency of management nodes in blockchain is mainly due to the large number of smart contracts they manage.

Method used

By receiving configuration requests and based on the load data of each block node in the blockchain, the management node and audit node of the target smart contract are determined. The quantum random number algorithm is used to select the target candidate node, and the load is managed by load averaging to reduce the number of contracts on each management node. The node with the lowest load is selected as the management node.

Benefits of technology

It improves the processing efficiency of management nodes, reduces the load pressure on management nodes, and enhances the security and efficiency of smart contract management.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120856554A_ABST
    Figure CN120856554A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a request processing method and device, equipment, a storage medium and a program product, and relates to the field of block chains. The method comprises the steps that a configuration request of a target smart contract is received, the configuration request is used for requesting to determine a target management node and a plurality of auditing nodes of the target smart contract, and the configuration request comprises a plurality of contract nodes corresponding to the target smart contract; based on the configuration request, determining a plurality of target to-be-selected nodes corresponding to the target smart contract according to a plurality of load data of each block node of the block chain; determining a target management node of the target smart contract in the plurality of target to-be-selected nodes according to the plurality of contract nodes; and determining a plurality of auditing nodes corresponding to the target smart contract in the plurality of block nodes according to the contract node number of the plurality of contract nodes. According to the method, the processing efficiency of the management node is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of blockchain, and more particularly to a request processing method, apparatus, device, storage medium, and program product. Background Technology

[0002] A blockchain can include multiple block nodes, and smart contracts can automatically execute agreements reached between nodes. As blockchain applications expand, the number of nodes and smart contracts on the blockchain continues to increase, necessitating the management of smart contracts to enable upgrades and maintenance.

[0003] In related technologies, multiple candidate nodes can be identified in a blockchain, and the remaining nodes can vote on these candidates to obtain voting information. Based on the voting information, a management node can be determined from among the candidate nodes. The management node can then generate and use smart contracts. However, since the management node has its own corresponding business processing, managing a large number of smart contracts may lead to low processing efficiency for the management node. Summary of the Invention

[0004] This application provides a request processing method, apparatus, device, storage medium, and program product to solve the technical problem of low processing efficiency of management nodes.

[0005] In a first aspect, this application provides a request processing method, including:

[0006] Receive a configuration request for a target smart contract. The configuration request is used to request the determination of the target management node and multiple audit nodes of the target smart contract. The configuration request includes multiple contract nodes corresponding to the target smart contract.

[0007] Based on the configuration request, and according to multiple load data of each block node of the blockchain, multiple target candidate nodes corresponding to the target smart contract are determined;

[0008] Based on the plurality of contract nodes, a target management node for the target smart contract is determined from the plurality of target candidate nodes. The target management node is used to upgrade and maintain the target smart contract.

[0009] Based on the number of contract nodes among the multiple contract nodes, multiple audit nodes corresponding to the target smart contract are determined among the multiple block nodes. The audit nodes are used to audit the legality of the target smart contract.

[0010] Secondly, this application provides a request processing apparatus, including a receiving module, a first determining module, a second determining module, and a third determining module:

[0011] The receiving module is used to receive a configuration request for a target smart contract. The configuration request is used to request the determination of the target management node and multiple audit nodes of the target smart contract. The configuration request includes multiple contract nodes corresponding to the target smart contract.

[0012] The first determining module is used to determine, based on the configuration request and according to multiple load data of each block node of the blockchain, multiple target candidate nodes corresponding to the target smart contract;

[0013] The second determining module is used to determine, based on the plurality of contract nodes, the target management node of the target smart contract from the plurality of target candidate nodes, wherein the target management node is used to upgrade and maintain the target smart contract;

[0014] The third determining module is used to determine, based on the number of contract nodes among the multiple contract nodes, multiple audit nodes corresponding to the target smart contract among the multiple block nodes, and the audit nodes are used to audit the legality of the target smart contract.

[0015] Thirdly, embodiments of this application provide an electronic device, including: a memory and a processor;

[0016] The memory stores computer-executed instructions;

[0017] The processor executes computer execution instructions stored in the memory, causing the processor to perform the first aspect and / or various possible implementations of the first aspect as described above.

[0018] Fourthly, embodiments of this application provide a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, are used to implement the first aspect and / or various possible implementations of the first aspect.

[0019] Fifthly, embodiments of this application provide a computer program product, including a computer program that, when executed by a processor, implements the first aspect and / or various possible implementations of the first aspect.

[0020] The request processing method, apparatus, device, storage medium, and program products provided in this application can determine the management node and multiple audit nodes corresponding to a target smart contract based on a configuration request. By determining the management node corresponding to different smart contracts, the management load can be evenly distributed across multiple management nodes, reducing the number of smart contracts managed by each management node. Furthermore, by determining the management node based on the load data of each block node, nodes with lower load pressure are selected as management nodes. By reducing the number of contracts per management node and selecting block nodes with lower loads, the processing efficiency of the management nodes can be improved. Attached Figure Description

[0021] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0022] Figure 1 A schematic diagram illustrating an application scenario provided in an embodiment of this application;

[0023] Figure 2 A flowchart illustrating a request processing method provided in an embodiment of this application;

[0024] Figure 3 A flowchart illustrating the process of determining target candidate nodes is provided for an embodiment of this application;

[0025] Figure 4 A schematic diagram of the architecture of a request processing method provided in an embodiment of this application;

[0026] Figure 5 A schematic diagram of the architecture of a request processing device provided in an embodiment of this application;

[0027] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application.

[0028] The accompanying drawings illustrate specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art through reference to particular embodiments. Detailed Implementation

[0029] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.

[0030] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties. Furthermore, the collection, storage, use, processing, transmission, provision, disclosure, and application of the relevant data all comply with the relevant laws, regulations, and standards of the relevant countries and regions, have taken necessary confidentiality measures, do not violate public order and good morals, and provide corresponding operation access points for users to choose to authorize or refuse.

[0031] Furthermore, the technical solution involved in this application, which involves big data analysis of user information (including but not limited to personal biometrics, identity data, consumption data, asset data, electronic terminal operation data, etc.) and the use of artificial intelligence technology for automated decision-making, and makes decisions that have a significant impact on personal rights based on the results of automated decision-making, provides users with corresponding operation entry points for users to choose to agree to or reject the results of automated decision-making; if the user chooses to reject, the process will proceed to the expert decision-making process.

[0032] It should be noted that the request processing method, apparatus, device, storage medium and program product provided in this application can be used in the blockchain field, or in any field other than the blockchain field. The application field of the request processing method, apparatus, device, storage medium and program product in this application is not limited.

[0033] Figure 1 This is a schematic diagram illustrating an application scenario provided by an embodiment of this application. Please refer to [link / reference]. Figure 1 Blockchain 100 may include multiple block nodes 101 and processing nodes 102.

[0034] Users can upload the contract code and deployment information of a target smart contract to any block node 101. The deployment information includes multiple contract nodes, which can be one of multiple block nodes 101. The block node 101 can generate a configuration request based on the contract code and deployment information and send the configuration request to the processing node 102.

[0035] Processing node 102 can receive configuration requests and broadcast them among multiple block nodes 101. Based on the configuration requests, processing node 102 can determine multiple target candidate nodes corresponding to the target smart contract according to multiple load data of each block node 101 in the blockchain.

[0036] Processing node 102 can determine the target management node for the target smart contract from among multiple target candidate nodes, based on multiple contract nodes. The target management node is used to upgrade and maintain the target smart contract. Based on the number of contract nodes among multiple contract nodes, multiple audit nodes corresponding to the target smart contract are determined from among multiple block nodes. The audit nodes are used to audit the legality of the target smart contract.

[0037] In related technologies, multiple candidate nodes can be identified in a blockchain, and the remaining nodes can vote on these candidates to obtain voting information. Based on the voting information, a management node can be determined from among the candidate nodes. The management node can then generate and use smart contracts. However, since the management node has its own corresponding business processing, managing a large number of smart contracts may lead to low processing efficiency for the management node.

[0038] The request processing method provided in this application can determine the management node and multiple review nodes corresponding to the target smart contract based on the configuration request. By determining the management node for different smart contracts, the management load can be evenly distributed across multiple management nodes, reducing the number of smart contracts managed by each node. Furthermore, by using the load data of each block node to determine the management node, nodes with lower load pressure are selected as management nodes. By reducing the number of contracts per management node and selecting block nodes with lower loads, the processing efficiency of the management nodes can be improved.

[0039] The technical solution of this application and how the technical solution of this application solves the above-mentioned technical problems are described in detail below with specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of this application will now be described with reference to the accompanying drawings.

[0040] Figure 2 This is a flowchart illustrating a request processing method provided in an embodiment of this application. Please refer to [link / reference]. Figure 2 The method may include:

[0041] S201. Receive the configuration request of the target smart contract.

[0042] The execution entity in this application embodiment can be a processing node or a request processing device disposed in the processing node. The request processing device can be implemented by software or by a combination of software and hardware.

[0043] Configuration requests can be used to request the target management node and multiple audit nodes of the target smart contract.

[0044] The target management node can be used to upgrade and maintain the target smart contract, while the audit node can be used to audit the legality of the target smart contract.

[0045] The configuration request can include multiple contract nodes corresponding to the target smart contract. Contract nodes can be nodes in the blockchain that participate in the execution, storage, or verification of the target smart contract.

[0046] S202. Based on the configuration request, determine multiple target candidate nodes corresponding to the target smart contract according to multiple load data of each block node in the blockchain.

[0047] Multiple load data may include data on at least two of the following load characteristics: Central Processing Unit (CPU) load, Memory (MEM) utilization, network load, available buffers, application system load, and current status information of various other system resources.

[0048] The target candidate node can be a block node whose load data meets the preset conditions.

[0049] In some possible implementations, a quantum random number algorithm can be used to determine multiple initial candidate nodes corresponding to the target smart contract among the block nodes of the blockchain; and based on multiple load data of each initial candidate node, multiple target candidate nodes can be determined among the multiple initial candidate nodes.

[0050] Quantum random number algorithms are techniques that utilize the inherent unpredictability of quantum mechanics (e.g., quantum superposition, measurement collapse, photon noise, etc.) to generate truly random numbers. Unlike classical pseudo-random number algorithms (PRNG), the randomness of quantum random number algorithms stems from the non-determinism of the physical world, exhibiting characteristics of unpredictability, non-periodicity, and resistance to interference.

[0051] For example, assuming there are 10 block nodes in the blockchain, namely nodes 1-10, the quantum random number algorithm can determine 4 initial candidate nodes as nodes 1, 3, 4 and 7. Based on multiple load data of each initial candidate node, nodes 1 and 4 can be determined as target candidate nodes.

[0052] In this application, multiple initial candidate nodes are determined by a quantum random number algorithm. From these initial candidate nodes, multiple target candidate nodes are determined, which makes each target candidate node random and unpredictable, thus mitigating cheating and improving the security of smart contract management.

[0053] S203. Based on multiple contract nodes, determine the target management node of the target smart contract from among multiple target candidate nodes.

[0054] Specifically, determine whether there is at least one target candidate node among multiple contract nodes; if so, determine the target management node among at least one target candidate node; if not, obtain multiple load data of each target candidate node, and determine the target management node based on the multiple load data of each target candidate node.

[0055] For example, suppose the target smart contract corresponds to 5 contract nodes, namely nodes 1-5, and there are 3 target candidate nodes, namely nodes 2, 3 and 6. Then, among the multiple contract nodes, there is at least one target candidate node, namely nodes 2 and 3. The target management node can be determined from nodes 2 and 3.

[0056] For example, suppose the target smart contract corresponds to 5 contract nodes, namely nodes 1-5, and there are 3 target candidate nodes, namely nodes 6, 7 and 8. If there is no target candidate node among the multiple contract nodes, then the target management node is determined from nodes 6, 7 and 8.

[0057] Optionally, when determining the target management node from at least one target candidate node, the following execution process can be followed: Based on at least one target candidate node, generate a voting mechanism; according to the voting mechanism, send voting information to multiple voting nodes and receive voting feedback from multiple voting nodes; based on the voting feedback, determine the target management node. Here, the voting nodes can be block nodes in the blockchain, or contract nodes corresponding to the target smart contract.

[0058] The target management node is determined based on multiple load data from each contract node, as can be found in step S202, or the execution process of the following embodiments, which will not be repeated here.

[0059] In this application, it is possible to determine whether there is at least one target candidate node among multiple contract nodes. If so, a target management node can be determined from at least one target candidate node. The target management node is the contract node of the target smart contract, which facilitates the management of the target smart contract and can improve management efficiency.

[0060] S204. Based on the number of contract nodes in multiple contract nodes, determine the multiple audit nodes corresponding to the target smart contract among multiple block nodes.

[0061] The more contract nodes there are, the more audit nodes there will be.

[0062] For example, if the number of contract nodes in a multi-contract node system is 20, then 2 audit nodes can be determined from the multiple block nodes; if the number of contract nodes in a multi-contract node system is 30, then 3 audit nodes can be determined from the multiple block nodes.

[0063] In a blockchain, multiple block nodes can be divided into multiple block groups, and each block group is responsible for handling its corresponding tasks.

[0064] Similarly, among the multiple contract nodes corresponding to the target smart contract, the multiple contract nodes are divided into multiple contract groups according to the tasks corresponding to each contract node. Multiple contract group nodes in each contract group can handle the same task. At least one contract group node can be determined in each contract group to obtain multiple audit nodes.

[0065] Specifically, multiple contract groups corresponding to the target smart contract can be identified; among the multiple contract group nodes corresponding to each contract group, at least one audit node corresponding to each contract group can be identified; and at least one audit node corresponding to each block group can be identified as multiple audit nodes.

[0066] If a contract group has a large number of contract nodes, multiple audit nodes can be determined within that contract group. If a contract group has a small number of contract nodes, only one audit node can be determined within that contract group.

[0067] In this application, by determining at least one audit node in each contract group, multiple audit nodes corresponding to the target smart contract can be obtained. The audit rights can be distributed to nodes corresponding to different tasks, which can improve the security of auditing the target smart contract.

[0068] In some possible implementations, for any contract group, at least one audit node can be determined from multiple contract group nodes by verifying a random function; or, at least one audit node can be determined from multiple contract group nodes according to a voting mechanism.

[0069] It is worth noting that, in addition to verifying the random function, at least one audit node can also be determined through other random methods.

[0070] In this application, at least one audit node can be determined from multiple contract group nodes through voting or random selection, which can reduce cheating and improve the effectiveness of determining the audit node.

[0071] The request processing method provided in this application can determine the management node and multiple review nodes corresponding to the target smart contract based on the configuration request. By determining the management node for different smart contracts, the management load can be evenly distributed across multiple management nodes, reducing the number of smart contracts managed by each node. Furthermore, by using the load data of each block node to determine the management node, nodes with lower load pressure are selected as management nodes. By reducing the number of contracts per management node and selecting block nodes with lower loads, the processing efficiency of the management nodes can be improved.

[0072] Based on the above embodiments, the following is combined with Figure 3 The specific execution process for determining the target candidate node provided in the embodiments of this application will be described.

[0073] Figure 3 This is a schematic flowchart illustrating a process for determining target candidate nodes, provided as an embodiment of this application. Please refer to... Figure 3 The method may include:

[0074] S301. Determine the scale and workload of the blockchain.

[0075] The size can be determined based on the number of block nodes. For example, assuming there are 100 block nodes, the size is 100.

[0076] The load factor can be determined based on the blockchain's network load. The higher the blockchain's network load, the greater the load factor.

[0077] Network load can be measured by the average block fill rate of multiple block nodes, the size of the pending transaction pool, and the average block generation time. A higher average block fill rate indicates a greater load on the blockchain; a larger pending transaction pool size also indicates a greater load on the blockchain; and a longer average block generation time also indicates a greater load on the blockchain.

[0078] The corresponding load quantity can be determined by looking up the average block fill rate, the size of the pending transaction pool, and the average block production time in a preset load quantity table. The preset load quantity table can include multiple correspondences, namely, the fill rate range corresponding to the average block fill rate, the transaction pool size range corresponding to the pending transaction pool size, the duration range corresponding to the average block production time, and the load quantity.

[0079] S302. Process the data on the scale and load to obtain the target number of multiple initial candidate nodes.

[0080] The target quantity can be determined by comprehensively considering both the scale and the load.

[0081] In some possible implementations, the average of the size quantity and the load quantity can be determined as the target quantity.

[0082] In some possible embodiments, a first weight corresponding to the scale quantity and a second weight corresponding to the load quantity can be obtained; the product of the first quantity and the first weight, and the sum of the product of the second quantity and the second weight, are used to determine the target quantity.

[0083] The sum of the first weight and the second weight is 1.

[0084] For example, assuming the scale quantity is 30, the load quantity is 40, the first weight is 0.4, and the second weight is 0.6, the target quantity can be determined to be 36. Alternatively, assuming the first weight is 0.5 and the second weight is 0.5, the average of the scale quantity and the load quantity can be used to determine the target quantity, which would be 35.

[0085] It is worth noting that the actual values ​​of the first and second weights can be adjusted according to the actual application process, and no specific restrictions are imposed here.

[0086] In this application, the target number can be determined based on the first weight corresponding to the scale and the second weight corresponding to the load. The number of blocks and the load in the blockchain can be considered simultaneously. The larger the scale, the greater the target number. The greater the load of each block node, the greater the target number. It is possible to dynamically determine the target number of multiple initial candidate nodes based on the blockchain.

[0087] S303. Using a quantum random number algorithm, multiple block nodes are randomly processed based on the target number of multiple initial candidate nodes to obtain multiple initial candidate nodes.

[0088] Multiple initial candidate nodes can be obtained by inputting a list of multiple block nodes and a target number of multiple initial candidate nodes into the quantum random number algorithm.

[0089] S304. Obtain the preset threshold corresponding to each load data.

[0090] For example, assuming there are three load characteristics corresponding to load data, including CPU load, MEM utilization, and network load, then the preset threshold corresponding to CPU load can be set as threshold 1, the preset threshold corresponding to MEM utilization as threshold 2, and the preset threshold corresponding to network load as threshold 3.

[0091] S305. For any initial candidate node, determine the satisfaction rate of each load data of the initial candidate node that meets the preset conditions.

[0092] The preset condition can be that the load data is less than or equal to its corresponding preset threshold.

[0093] For example, suppose multiple load data include CPU load data, MEM utilization load data, and network load data. Suppose the CPU load data is less than its corresponding preset threshold, the MEM utilization load data is less than its corresponding preset threshold, and the network load data is greater than its corresponding preset threshold, then the satisfaction rate is 66.7%.

[0094] S306. Initial candidate nodes whose satisfaction ratio is greater than a preset ratio are identified as target candidate nodes, thereby identifying multiple target candidate nodes.

[0095] For example, suppose there are 20 initial candidate nodes, namely nodes 1-20. If the satisfaction rate of nodes 1-10 is greater than the preset rate, then nodes 1-10 can be determined as target candidate nodes.

[0096] The request processing method provided in this application can determine the satisfaction ratio of each load data of the initial candidate nodes according to preset conditions, and determine the target candidate nodes. The preset conditions are that the load data is less than or equal to its corresponding preset threshold. The initial candidate nodes with higher load satisfaction ratios are determined as the target candidate nodes, which improves the processing efficiency of the selected target candidate nodes and thus improves the processing efficiency of the target management nodes. In addition, the target number of multiple initial candidate nodes is dynamically determined by the scale and load of the blockchain. When the scale and load of the blockchain are large, the target number can be expanded, thereby increasing the range of target management nodes to be selected and improving the effectiveness of determining the target management nodes.

[0097] Figure 4 This is a schematic diagram illustrating the architecture of a request processing method provided in an embodiment of this application. Please refer to [link / reference]. Figure 4 The blockchain comprises multiple interval nodes. After receiving a configuration request from a target smart contract, it determines the corresponding scale and load of the blockchain. Data processing is performed on the scale and load to obtain a target number of initial candidate nodes. Using a quantum random number algorithm, multiple block nodes are randomly processed based on the target number of initial candidate nodes to obtain multiple initial candidate nodes.

[0098] Based on the load data of each initial candidate node, multiple target candidate nodes are determined from among them. The configuration request includes multiple contract nodes corresponding to the target smart contract, where each contract node is one of multiple block nodes. If at least one target candidate node exists among the multiple contract nodes, the target management node can be determined from that at least one target candidate node; if no at least one target candidate node exists among the multiple contract nodes, the target management node is determined based on the load data of each target candidate node.

[0099] Multiple contract groups corresponding to the target smart contract can be identified, and each contract group includes multiple contract group nodes among multiple contract nodes; among the multiple contract group nodes corresponding to each contract group, at least one audit node corresponding to each contract group is identified; and at least one audit node corresponding to each contract group is identified as multiple audit nodes.

[0100] Figure 5This is a schematic diagram of the architecture of a request processing device provided in an embodiment of this application. Please refer to [link / reference]. Figure 5 The request processing device 500 may include a receiving module 501, a first determining module 502, a second determining module 503, and a third determining module 504.

[0101] The receiving module 501 is used to receive a configuration request for the target smart contract. The configuration request is used to request the determination of the target management node and multiple audit nodes of the target smart contract. The configuration request includes multiple contract nodes corresponding to the target smart contract.

[0102] The first determining module 502 is used to determine multiple target candidate nodes corresponding to the target smart contract based on the configuration request and multiple load data of each block node in the blockchain.

[0103] The second determining module 503 is used to determine the target management node of the target smart contract from multiple target candidate nodes based on multiple contract nodes. The target management node is used to upgrade and maintain the target smart contract.

[0104] The third determining module 504 is used to determine multiple audit nodes corresponding to the target smart contract among multiple block nodes based on the number of contract nodes among multiple contract nodes. The audit nodes are used to audit the legality of the target smart contract.

[0105] In some possible embodiments, the first determining module 502 is specifically used for:

[0106] Using a quantum random number algorithm, multiple initial candidate nodes corresponding to the target smart contract are determined among the various block nodes of the blockchain;

[0107] Based on the load data of each initial candidate node, multiple target candidate nodes are determined from among the multiple initial candidate nodes.

[0108] In some possible embodiments, the first determining module 502 is specifically used for:

[0109] Obtain the preset thresholds corresponding to each load data;

[0110] For any initial candidate node, determine the satisfaction rate of each load data of the initial candidate node that meets the preset conditions. The preset conditions are that the load data is less than or equal to its corresponding preset threshold.

[0111] Initial candidate nodes whose satisfaction rate is greater than a preset rate are identified as target candidate nodes, thereby identifying multiple target candidate nodes.

[0112] In some possible embodiments, the first determining module 502 is specifically used for:

[0113] Determine the scale and load capacity of the blockchain. The scale is determined based on the number of multiple block nodes, and the load capacity is determined based on the network load of the blockchain.

[0114] Data processing is performed on the scale and load to obtain the target number of multiple initial candidate nodes;

[0115] By using a quantum random number algorithm, multiple block nodes are randomly processed based on the target number of multiple initial candidate nodes to obtain multiple initial candidate nodes.

[0116] In some possible embodiments, the first determining module 502 is specifically used for:

[0117] Obtain the first weight corresponding to the number of scales and the second weight corresponding to the number of loads. The sum of the first weight and the second weight is 1.

[0118] The target quantity is determined by summing the product of the first quantity and the first weight with the product of the second quantity and the second weight.

[0119] In some possible embodiments, the third determining module 504 is specifically used for:

[0120] Identify multiple contract groups corresponding to the target smart contract, where each contract group includes multiple contract group nodes from multiple contract nodes;

[0121] Among the multiple contract group nodes corresponding to each contract group, at least one audit node corresponding to each contract group is determined.

[0122] At least one audit node corresponding to each contract group is identified as multiple audit nodes.

[0123] In some possible embodiments, for any contract group; the third determining module 504 is specifically used for:

[0124] By verifying the random function, at least one audit node is determined among multiple contract group nodes;

[0125] Alternatively, based on a voting mechanism, at least one audit node can be determined from among multiple contract group nodes.

[0126] In some possible embodiments, the second determining module 503 is specifically used for:

[0127] Determine whether there is at least one target candidate node among multiple contract nodes;

[0128] If so, then determine the target management node from at least one target candidate node;

[0129] If not, obtain multiple load data for each target candidate node, and determine the target management node based on the multiple load data for each target candidate node.

[0130] The request processing device provided in this embodiment can execute the method provided in the above method embodiment. Its implementation principle and technical effect are similar, and will not be described in detail here.

[0131] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Please refer to... Figure 6 The electronic device 600 may include a processor 601 and a memory 602. Exemplarily, the processor 601 and the memory 602 are interconnected via a bus 603.

[0132] Memory 602 stores computer-executed instructions;

[0133] The processor 601 executes computer execution instructions stored in the memory 602, causing the processor 601 to perform the request processing method as shown in the above method embodiment.

[0134] Accordingly, embodiments of this application provide a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, are used to implement the request processing method of the above-described method embodiments.

[0135] Accordingly, embodiments of this application may also provide a computer program product, including a computer program, which, when executed by a processor, can implement the request processing method shown in the above method embodiments.

[0136] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0137] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0138] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0139] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0140] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0141] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.

[0142] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.

[0143] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.

[0144] The above are merely embodiments of this application and are not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.

Claims

1. A request processing method, characterized in that, include: Receive a configuration request for a target smart contract. The configuration request is used to request the determination of the target management node and multiple audit nodes of the target smart contract. The configuration request includes multiple contract nodes corresponding to the target smart contract. Based on the configuration request, and according to the load data of each block node in the blockchain, multiple target candidate nodes corresponding to the target smart contract are determined. Based on the plurality of contract nodes, a target management node for the target smart contract is determined from the plurality of target candidate nodes. The target management node is used to upgrade and maintain the target smart contract. Based on the number of contract nodes among the multiple contract nodes, multiple audit nodes corresponding to the target smart contract are determined among multiple block nodes. The audit nodes are used to audit the legality of the target smart contract.

2. The method according to claim 1, characterized in that, Based on the load data of various block nodes in the blockchain, multiple target candidate nodes corresponding to the target smart contract are determined, including: Using a quantum random number algorithm, multiple initial candidate nodes corresponding to the target smart contract are determined among the block nodes of the blockchain. Based on the load data of each initial candidate node, the multiple target candidate nodes are determined from among the multiple initial candidate nodes.

3. The method according to claim 2, characterized in that, Based on multiple load data points of each initial candidate node, the multiple target candidate nodes are determined from among the multiple initial candidate nodes, including: Obtain the preset thresholds corresponding to each load data; For any initial candidate node, determine the satisfaction ratio of each load data of the initial candidate node that meets a preset condition, wherein the preset condition is that the load data is less than or equal to its corresponding preset threshold. The initial candidate nodes whose satisfaction ratio is greater than a preset ratio are determined as the target candidate nodes, thereby determining the plurality of target candidate nodes.

4. The method according to claim 2, characterized in that, Using a quantum random number algorithm, multiple initial candidate nodes corresponding to the target smart contract are determined from the plurality of block nodes, including: The size and load of the blockchain are determined, wherein the size is determined based on the number of the plurality of block nodes, and the load is determined based on the network load of the blockchain; Data processing is performed on the scale quantity and the load quantity to obtain the target number of the plurality of initial candidate nodes; The quantum random number algorithm is used to randomly process the multiple block nodes according to the target number of the multiple initial candidate nodes to obtain the multiple initial candidate nodes.

5. The method according to claim 4, characterized in that, Data processing is performed on the scale quantity and the load quantity to obtain the target number of the plurality of initial candidate nodes, including: Obtain the first weight corresponding to the scale quantity and the second weight corresponding to the load quantity, wherein the sum of the first weight and the second weight is 1; The target quantity is determined by summing the product of the first quantity and the first weight, and the product of the second quantity and the second weight.

6. The method according to claim 1, characterized in that, Based on the number of contract nodes among the multiple contract nodes, multiple audit nodes corresponding to the target smart contract are determined from multiple block nodes, including: Identify multiple contract groups corresponding to the target smart contract, where each contract group includes multiple contract group nodes among the multiple contract nodes; Among the multiple contract group nodes corresponding to each contract group, at least one audit node corresponding to each contract group is determined; At least one audit node corresponding to each contract group is identified as one of the multiple audit nodes.

7. The method according to claim 6, characterized in that, For any given contract group; among the multiple contract group nodes corresponding to the contract group, determine the at least one audit node, including: By verifying a random function, at least one audit node is determined among the plurality of contract group nodes; Alternatively, based on a voting mechanism, at least one audit node may be determined among the plurality of contract group nodes.

8. The method according to claim 1, characterized in that, Based on the plurality of contract nodes, the target management node of the target smart contract is determined from the plurality of target candidate nodes, including: Determine whether there is at least one target candidate node among the multiple contract nodes; If so, then the target management node is determined from the at least one target candidate node; If not, then obtain multiple load data for each target candidate node, and determine the target management node based on the multiple load data for each target candidate node.

9. A request processing apparatus, characterized in that, It includes a receiving module, a first determining module, a second determining module, and a third determining module: The receiving module is used to receive a configuration request for a target smart contract. The configuration request is used to request the determination of the target management node and multiple audit nodes of the target smart contract. The configuration request includes multiple contract nodes corresponding to the target smart contract. The first determining module is used to determine, based on the configuration request and according to multiple load data of each block node in the blockchain, multiple target candidate nodes corresponding to the target smart contract; The second determining module is used to determine, based on the plurality of contract nodes, the target management node of the target smart contract from the plurality of target candidate nodes, wherein the target management node is used to upgrade and maintain the target smart contract; The third determining module is used to determine multiple audit nodes corresponding to the target smart contract among multiple block nodes based on the number of contract nodes among the multiple contract nodes. The audit nodes are used to audit the legality of the target smart contract.

10. An electronic device, characterized in that, include: A processor, and a memory communicatively connected to the processor; The memory stores computer-executable instructions; The processor executes computer execution instructions stored in the memory to implement the method as described in any one of claims 1 to 8.

11. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, are used to implement the method as described in any one of claims 1 to 8.

12. A computer program product, characterized in that, Includes a computer program that, when executed by a processor, implements the method of any one of claims 1 to 8.