Resource data processing method and device based on block chain and computer equipment
Through smart contract query and generation of settlement vouchers in the blockchain network, the cumbersome process in cross-border resource interaction processing is solved, and efficient resource data settlement processing is achieved.
Patent Information
- Application Number
- CN202410006610.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-01-02
- Publication Date
- 2025-07-04
AI Technical Summary
The efficiency of cross-border resource interaction processing in the existing technology is low, and the procedures involving resource management institutions are cumbersome, resulting in inefficient resource data interaction.
The process document information of resource interaction settlement request is queried through smart contracts in the blockchain network, a settlement voucher is generated, and the resource interaction settlement request is executed based on the settlement voucher, and the settlement processing is directly completed.
It improves the efficiency of resource interactive settlement processing, reduces process processing procedures, and improves processing efficiency.
Smart Images

Figure CN120258969A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular, to a method, device, computer device, storage medium, and computer program product for processing resource data based on blockchain. Background Art
[0002] With the development of computer technology and network technology, blockchain technology has emerged. Blockchain is a new application mode of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, and encryption algorithm. Blockchain, in essence, is a decentralized database, a string of data blocks generated by using cryptographic methods. Each data block contains information about a batch of network transactions, which is used to verify the validity of the information (anti-counterfeiting) and generate the next block. Blockchain can include the blockchain underlying platform, the platform product service layer, and the application service layer. Currently, blockchain can be applied to the interactive processing of various resource data.
[0003] Currently, for cross-border resource interactive processing, it is generally achieved by resource owners with the help of third-party institutions through methods such as affiliation or agency. However, when conducting settlement processing related to resources in this way, it involves the process handling procedures of various resource management institutions during the resource interaction process, as well as relevant process documents, and the efficiency of executing resource data interaction is relatively low. Summary of the Invention
[0004] Based on this, in view of the above technical problems, it is necessary to provide a method, device, computer device, computer-readable storage medium, and computer program product for processing resource data based on blockchain that can improve the efficiency of resource interaction during cross-border settlement processing.
[0005] In a first aspect, the present application provides a method for processing resource data based on blockchain, including:
[0006] Obtain a resource interaction settlement request and identify the resource interaction information in the resource interaction settlement request;
[0007] Based on the settlement type characterized by the resource interaction information, call a voucher generation smart contract to query the process document information of the resource interaction settlement request in the blockchain network;
[0008] Generate a settlement voucher for the resource interaction settlement request based on the process document information;
[0009] Based on the settlement voucher, execute the resource interaction settlement request through the blockchain network to obtain a resource interaction settlement result.
[0010] In a second aspect, the present application further provides a device for processing resource data based on blockchain, including:
[0011] A request acquisition module, configured to acquire a resource interaction settlement request and identify resource interaction information in the resource interaction settlement request;
[0012] A data query module, configured to call a voucher generation smart contract to query process document information of the resource interaction settlement request in a blockchain network based on the settlement type represented by the resource interaction information;
[0013] A voucher generation module, configured to generate a settlement voucher for the resource interaction settlement request based on the process document information;
[0014] A request processing module, configured to execute the resource interaction settlement request through the blockchain network based on the settlement voucher to obtain a resource interaction settlement result.
[0015] In a third aspect, the present application further provides a computer device, including a memory and a processor. The memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:
[0016] Acquire a resource interaction settlement request and identify resource interaction information in the resource interaction settlement request;
[0017] Based on the settlement type represented by the resource interaction information, call a voucher generation smart contract to query process document information of the resource interaction settlement request in a blockchain network;
[0018] Generate a settlement voucher for the resource interaction settlement request based on the process document information;
[0019] Based on the settlement voucher, execute the resource interaction settlement request through the blockchain network to obtain a resource interaction settlement result.
[0020] In a fourth aspect, the present application further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the following steps are implemented:
[0021] Acquire a resource interaction settlement request and identify resource interaction information in the resource interaction settlement request;
[0022] Based on the settlement type represented by the resource interaction information, call a voucher generation smart contract to query process document information of the resource interaction settlement request in a blockchain network;
[0023] Generate a settlement voucher for the resource interaction settlement request based on the process document information;
[0024] Based on the settlement voucher, execute the resource interaction settlement request through the blockchain network to obtain a resource interaction settlement result.
[0025] In a fifth aspect, the present application further provides a computer program product, including a computer program, which when executed by a processor, implements the following steps:
[0026] Obtain a resource interaction settlement request and identify the resource interaction information in the resource interaction settlement request;
[0027] Based on the settlement type represented by the resource interaction information, call a voucher generation smart contract to query the process document information of the resource interaction settlement request in the blockchain network;
[0028] Generate a settlement voucher for the resource interaction settlement request based on the process document information;
[0029] Based on the settlement voucher, execute the resource interaction settlement request through the blockchain network to obtain a resource interaction settlement result.
[0030] The above-mentioned resource data processing method, device, computer device, storage medium and computer program product based on blockchain, after obtaining a resource interaction settlement request, identify the resource interaction information in the resource interaction settlement request to obtain the basic data required for the resource data processing process, and then based on the settlement type represented by the resource interaction information, call a voucher generation smart contract to query the process document information of the resource interaction settlement request in the blockchain network. According to the settlement type that requires resource settlement processing, directly query the relevant process document information through the blockchain network, and then for the handling process of resource processing, a settlement voucher for the resource interaction settlement request can be generated based on the process document information; and based on the settlement voucher, execute the resource interaction settlement request through the blockchain network to obtain a resource interaction settlement result, thereby reducing the process handling procedures involved in the resource settlement process and improving the processing efficiency of the resource data settlement process. The present application uses a smart contract method through the blockchain network to query the process documents involved in the resource interaction process and generate voucher information for the resource interaction process. Directly complete the settlement processing of the resource interaction process, which can effectively improve the processing efficiency of the resource interaction settlement processing. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] In order to more clearly illustrate the technical solutions in the embodiments of the present application or related technologies, the following will briefly introduce the drawings required for use in the description of the embodiments or related technologies. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0032] Figure 1 It is a schematic structural diagram of a distributed system applied to a blockchain system in an embodiment;
[0033] Figure 2 Schematic diagram of a block structure in an embodiment
[0034] Figure 3 Flow schematic diagram of a blockchain-based resource data processing method in an embodiment
[0035] Figure 4 Schematic diagram of the structure of a blockchain node in an embodiment
[0036] Figure 5 Structural block diagram of a blockchain-based resource data processing process in an embodiment
[0037] Figure 6 Structural block diagram of a blockchain-based permission audit processing process in an embodiment
[0038] Figure 7 Structural block diagram of a blockchain-based resource data processing process in another embodiment
[0039] Figure 8 Flow schematic diagram of a blockchain-based resource data processing method in another embodiment
[0040] Figure 9 Structural block diagram of a blockchain-based resource data processing device in an embodiment
[0041] Figure 10 Internal structure diagram of a computer device in an embodiment Detailed implementation manners
[0042] In order to make the objectives, technical solutions and advantages of the present application clearer and more understandable, the present application will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0043] In this document, it is necessary to understand the following terms:
[0044] Blockchain: Blockchain technology is a distributed ledger technology in the field of information technology. Generally, it consists of consensus, transaction blocks and state data storage, cryptographic identity security, etc. Since the ledger is distributedly stored and the blocks are consensus-based, it has features such as immutability, traceability, and co-maintenance.
[0045] Smart contract: A smart contract is a computer protocol designed to spread, verify or execute a contract in an informatized manner. Smart contracts allow for trusted transactions without a third party, and these transactions are traceable and irreversible.
[0046] Resource Interaction Pool: The blockchain resource interaction pool refers to a buffer for storing resource interaction data that has not been packaged into blocks in the blockchain network. Resource interactions in the resource interaction pool need to be verified before being packaged into the blockchain. That is, the execution process of resource interactions in the resource interaction pool is as follows: Verify resource interaction information -> Invoke the smart contract to execute resource interaction -> Package a new block -> Broadcast the new block.
[0047] The system involved in the embodiments of this application can be a distributed system formed by connecting a client and multiple nodes (any form of computing device connected to the network, such as a server, user terminal) through network communication.
[0048] Taking the distributed system as a blockchain system as an example, see Figure 1 , Figure 1 FIG. 100 is an optional structural schematic diagram of the distributed system 100 provided by the embodiments of the present invention applied to a blockchain system, formed by multiple nodes 200 (any form of computing device connected to the network, such as a server, user terminal) and a client 300. A peer-to-peer network is formed between the nodes. The peer-to-peer protocol is an application layer protocol running on top of the Transmission Control Protocol (TCP). In a distributed system, any machine such as a server or terminal can join and become a node. A node includes a hardware layer, an intermediate layer, an operating system layer, and an application layer.
[0049] See Figure 1 The functions of each node in the blockchain system shown, the functions involved include:
[0050] 1) Routing, a basic function of a node, used to support communication between nodes.
[0051] In addition to the routing function, a node can also have the following functions:
[0052] 2) Application, used to be deployed in the blockchain, implement specific services according to actual business needs, record data related to the implemented functions to form record data, carry a digital signature in the record data to indicate the source of the task data, and send the record data to other nodes in the blockchain system. When other nodes verify the source and integrity of the record data successfully, they add the record data to the temporary block.
[0053] For example, the services implemented by the application include:
[0054] 2.1) Wallet, which is used to provide the function of resource interaction, including initiating resource interaction (that is, sending the resource interaction record of the current resource interaction to other nodes in the blockchain system. After successful verification by other nodes, as a response to acknowledging the effectiveness of the resource interaction, the record data of the resource interaction is stored in the temporary block of the blockchain. Of course, the wallet also supports querying the remaining resource amount in the resource address;
[0055] 2.2) Shared ledger, which is used to provide functions such as storage, query, and modification of account data. It sends the record data of the operation on the account data to other nodes in the blockchain system. After other nodes verify its effectiveness, as a response to acknowledging the effectiveness of the account data, the record data is stored in the temporary block, and it can also send a confirmation to the node that initiated the operation.
[0056] 2.3) Smart contract, a computerized protocol that can execute the terms of a certain contract. It is implemented through code deployed on the shared ledger and executed when certain conditions are met. According to actual business requirements, the code is used to complete automated resource interaction, such as querying the logistics status of the goods purchased by the buyer and transferring the corresponding resources of the buyer to the merchant's address after the buyer signs for the goods. Of course, smart contracts are not limited to executing contracts for resource interaction, but can also execute contracts for processing received information.
[0057] 3) Blockchain, which includes a series of blocks (Block) connected in sequence according to the chronological order of generation. Once a new block is added to the blockchain, it will not be removed again. The block records the record data submitted by nodes in the blockchain system.
[0058] See Figure 2 , Figure 2 is an optional schematic diagram of the block structure provided by the embodiment of the present invention. Each block includes the hash value of the resource interaction record stored in this block (the hash value of this block) and the hash value of the previous block. Each block is connected through the hash value to form a blockchain. In addition, the block may also include information such as the timestamp when the block is generated. Blockchain, essentially a decentralized database, is a string of data blocks associated using cryptographic methods. Each data block contains relevant information for verifying the effectiveness of its information (anti-counterfeiting) and generating the next block.
[0059] This application is applicable to resource data processing based on the above blockchain network and can be achieved through, for example Figure 1The implementation of the blockchain node 200 shown in the figure is as follows. First, the user submits a resource interaction settlement request to the blockchain node 200 in the blockchain network through the client 300. The blockchain node 200 obtains the resource interaction settlement request and identifies the resource interaction information in the resource interaction settlement request. Based on the settlement type represented by the resource interaction information, it calls the voucher generation smart contract to query the process document information of the resource interaction settlement request in the blockchain network. It generates a settlement voucher for the resource interaction settlement request based on the process document information. Based on the settlement voucher, it executes the resource interaction settlement request through the blockchain network to obtain the resource interaction settlement result.
[0060] In an exemplary embodiment, as Figure 3 shown, a method for processing resource data based on blockchain is provided. Taking the method applied to Figure 1 the blockchain node 200 in the figure as an example, it includes the following steps 302 to step 308. Among them:
[0061] Step 302, obtain the resource interaction settlement request and identify the resource interaction information in the resource interaction settlement request.
[0062] Among them, the resource interaction settlement request refers to the request submitted by the target object to the blockchain node 200 through the client 300 to request the blockchain node 200 to implement the corresponding resource interaction settlement processing on the basis of the blockchain network. The resource interaction settlement request contains various types of resource interaction information, specifically including information such as business number, settlement type, settlement object, and settlement resource quantity. The business number refers to the number information of various processing processes involved in the current resource interaction settlement process. Since the resource interaction process may involve various audit processes, and after the audit is completed, the corresponding business number will be saved. Therefore, when processing resource interaction, the business number can be used as proof of process processing. The settlement type refers to the processing type corresponding to the resource interaction settlement request. Different settlement types correspond to different smart contracts in the blockchain network, and the corresponding smart contract can be found based on the settlement type for resource settlement. The settlement object refers to the two parties involved in the resource interaction settlement request, including the target object party that submits the resource interaction settlement request and the interaction object party involved in the resource interaction. The settlement resource quantity refers to the relevant resource quantity involved in the resource interaction process, which can include physical resources and virtual digital resources, etc.
[0063] Exemplarily, when the target object needs to process relevant resource interaction settlement requests to efficiently implement resource settlement processing, the corresponding resource interaction settlement requests can be submitted by the client 300 to the blockchain node 200, so as to process the resource interaction settlement through the blockchain network on the blockchain node 200, complete the information review, voucher generation, and resource interaction and other processings in the resource interaction settlement process, thereby improving the processing efficiency of the resource interaction settlement process. The target object first generates a resource interaction settlement request on the client 300 according to various information involved in the resource interaction settlement process. Then, the resource interaction settlement request is submitted to the blockchain node 200 through the client 300. The blockchain node 200 parses the resource interaction settlement request, identifies the resource interaction information contained therein, and then makes a resource interaction settlement request based on the resource interaction information. In one embodiment, the target object is a user who needs to conduct resource interaction settlement. The user can submit a settlement application to the blockchain node 200 through the client 300. Then, the blockchain 200 feeds back a corresponding resource interaction information form to the client 300, and the user can fill in various types of resource interaction information on the resource interaction information form.
[0064] Step 304: Based on the settlement type characterized by the resource interaction information, call the voucher generation smart contract to query the process document information of the resource interaction settlement request in the blockchain network.
[0065] Among them, different settlement types correspond to different processing flows, and the process documents, settlement vouchers, and smart contracts involved in the resource interaction settlement process are all different. The settlement type can specifically include the resource collection and settlement type and the resource exchange settlement type, etc. The resource collection and settlement type refers to requesting the corresponding resources from the interaction object party involved in the resource interaction in the form of collection through the blockchain network. The resource exchange settlement type is for different types of resources held by the target object party and the interaction object party, and performs resource exchange processing according to the resource type exchange rules. The voucher generation smart contract refers to the smart contract used to generate the voucher information required in the resource interaction processing process. The process document information refers to the proof document information generated during various processings that have been executed in this resource interaction process. The process document information can prove that the resource interaction processing application involved in the resource interaction result request has passed the review of the corresponding process items and can perform subsequent resource interaction processing.
[0066] Exemplarily, after obtaining the resource interaction information, the blockchain node 200 first needs to determine whether the information on the resource interaction process involved in the current resource interaction information is complete. At this time, for the information completion of the resource interaction process, it can be discussed separately according to different settlement types. Different settlement types correspond to different settlement processes, and the process document information involved is also different, and the smart contracts required for processing are also different. Therefore, according to the settlement type represented by the resource interaction information, the corresponding type of voucher generation smart contract can be called, and then the process document information can be queried and processed by executing the smart contract. For example, for the resource interaction settlement request of the resource swap settlement type, the resource swap voucher generation contract is called. For the resource interaction settlement request of the resource collection settlement type, the resource collection voucher generation contract is called. By calling the voucher generation smart contract, it can be searched in the blockchain network based on the business number in the resource interaction information to obtain the process documents corresponding to each business number, and summarizing these process documents can obtain the process document information of the resource interaction settlement request. In one embodiment, the audit terminal required in the resource interaction processing process is connected to the blockchain network, and the process information and document information related to the audit result are saved in the blocks of the blockchain. At this time, for the search process of the process document information, the voucher generation smart contract can be directly called to find the process document information corresponding to the business number in the blocks of the blockchain network. In another embodiment, the audit terminal required in the resource interaction processing process is connected to the blockchain network. At this time, the voucher generation smart contract can be called to search for the business query port of each business process in the blockchain network, and then the process document information can be queried based on the business number through the business query port.
[0067] Step 306, generate a settlement voucher for the resource interaction settlement request based on the process document information.
[0068] Among them, the settlement voucher refers to the voucher information required for the current resource interaction settlement request, and the settlement voucher contains various types of information required to prove the legality of the current resource interaction settlement process. The blockchain network can determine whether to perform the resource interaction settlement process based on whether the resource interaction settlement request contains a settlement voucher.
[0069] Exemplarily, after obtaining the process document information, blockchain node 200 can generate a settlement voucher for the resource interaction settlement request based on this process document information to prove whether the resource settlement processing process requested by the current resource interaction settlement request is legal. In one embodiment, for the process of generating the settlement voucher, it is also necessary to audit the legality of the resource interaction information based on the process document information, including determining whether the process document information and the resource interaction information are exactly corresponding. For example, whether the applicant of the process document information is consistent with the target object party that submits the resource interaction settlement request, and whether the resource interaction type of the process document information is consistent with the settlement type represented by the resource interaction information. For example, whether the resource quantity in the process document information corresponds to the resource quantity in the resource interaction information, etc. Only when the audit is passed will the corresponding settlement voucher be generated, thereby ensuring the legality and compliance of the resource interaction settlement.
[0070] Step 308: Based on the settlement voucher, execute the resource interaction settlement request through the blockchain network to obtain the resource interaction settlement result.
[0071] Exemplarily, after obtaining the settlement voucher, the settlement voucher and the resource interaction settlement request can be uploaded together to the resource interaction pool of the blockchain network. The resource settlement pool applicable to resource settlement processing will execute the corresponding resource interaction settlement request in the blockchain network according to the settlement voucher, and perform corresponding resource settlement processing on both parties of the resource interaction settlement. First, the smart contract applicable to resource interaction settlement service in the blockchain network will confirm the settlement voucher. After the confirmation is completed, according to the settlement object in the resource interaction settlement request, determine the two parties involved in the resource interaction, and then adjust the resource quantities stored by the two parties in the blockchain network respectively according to the resource interaction type and the settlement resource quantity to complete the processing process of resource interaction settlement. In one embodiment, the settlement type of the present application includes the resource collection and settlement type. At this time, the corresponding resource quantity can be collected from the interaction object party of the resource interaction settlement according to the resource interaction type and the settlement resource quantity, and the settlement processing of the resource quantity can be completed according to the requirements of the target object party that submits the resource interaction settlement request. In another embodiment, the settlement type of the present application includes the resource exchange settlement type. At this time, the resource types and quantities involved in the interaction process can be determined respectively from the request party and the interaction object party of the resource interaction settlement according to the resource interaction type and the settlement resource quantity as the interaction resources, and then the interaction resources of both parties are exchanged to complete the resource interaction. Then, generate the corresponding resource interaction settlement result according to the result of the interaction, and perform message feedback and subsequent block generation processing.
[0072] The above blockchain-based resource data processing method, after obtaining a resource interaction settlement request, identifies the resource interaction information in the resource interaction settlement request to obtain the basic data required for the resource data processing process, and then based on the settlement type represented by the resource interaction information, calls a voucher generation smart contract to query the process document information of the resource interaction settlement request in the blockchain network. According to the settlement type that requires resource settlement processing, directly query the relevant process document information through the blockchain network, and then for the processing process of resource processing, a settlement voucher for the resource interaction settlement request can be generated based on the process document information; and based on the settlement voucher, execute the resource interaction settlement request through the blockchain network to obtain the resource interaction settlement result, thereby reducing the process handling procedures involved in the resource settlement process and improving the processing efficiency of the resource data settlement process. This application uses the blockchain network to query the process documents involved in the resource interaction process in the form of a smart contract and generate the voucher information for the resource interaction process. Directly completing the settlement processing of the resource interaction process can effectively improve the processing efficiency of the resource interaction settlement processing.
[0073] In an exemplary embodiment, the settlement type includes a resource collection and settlement type, and the voucher generation smart contract includes a resource collection voucher generation contract. Step 304 includes: when the settlement type represented by the resource interaction information is the resource collection and settlement type, determining the business process information involved in the resource collection in the resource collection information; based on the business process information, calling the resource collection voucher generation contract to query the process document information of the resource interaction settlement request.
[0074] Among them, the resource collection and settlement type refers to the settlement type that realizes the resource collection service through the blockchain network. When the target object party that submits the resource interaction settlement request conducts resource interaction with the interaction object party involved in the resource interaction, for example, in the embodiment of cross-border trade, the interaction object party and the target object party are cross-border objects to each other. When the interaction object party purchases a specified product from the target object party with the resources attached to the interaction object party through the platform of the blockchain network, first, during the process that the target object party receives the request and mails the specified product to the interaction object party, these products need to pass the review of various government affairs processes. After these products pass the cross-border review and are shipped to the interaction object party, the target object party can initiate a resource interaction settlement request based on various program documents, order information, and shipping information involved in the review process to request the execution of the settlement processing of the resource interaction in the blockchain network. At this time, the request for resource collection and settlement processing in the cross-border trade process through the blockchain network is the resource collection and settlement type. And the smart contract in the blockchain network used to realize the resource collection service is the resource collection voucher generation contract. The resource collection voucher generation contract can automatically search for various types of documentary evidence required for resource collection and settlement based on the resource interaction settlement request provided by the target object, and obtain the process document information as the basic data for voucher generation.
[0075] Exemplarily, the settlement type specifically includes the resource collection and settlement type. At this time, the requester of the resource interaction settlement request requests the blockchain node to perform the collection and settlement process for the resource interaction settlement process specified by the resource interaction information through the blockchain network. After the blockchain node determines that the settlement type represented by the resource interaction information is the resource collection and settlement type, it can determine the business process information involved in the resource collection in the resource collection information. For example, for the resource collection and settlement type of cross-border trade, its business process information may include the warehouse management process and the review processes of various government departments. When determining the business process information involved in the resource collection in the resource collection information, for each process involved in the business process information, the resource collection voucher generation contract can be called to query the process document information of the resource interaction settlement request, so as to collect the process document information involved in the resource interaction settlement process. In one embodiment, this application is applied to perform the resource collection and settlement process for cross-border trade. At this time, the business processes involved in cross-border trade can be determined, such as the warehouse out-of-stock process and the government compliance review processes of departments such as taxation, customs, and foreign exchange control. Then, for these processes, the resource collection voucher generation contract is called to query each process, and the process document information of the resource interaction settlement request is obtained. In this embodiment, for the resource interaction information of the resource collection and settlement type, by determining the business process information involved in the resource collection and then automatically querying the process document information for the business process, the processing efficiency of the resource collection and settlement process can be effectively improved.
[0076] In an exemplary embodiment, based on the business process information, calling the resource collection voucher generation contract to query the process document information of the resource interaction settlement request includes: finding the business numbers of each business process in the business process information based on the resource interaction information, and determining the business query ports of each business process; calling the resource collection voucher generation contract to access the business query ports, and finding the business handling information corresponding to the business number at the business query port, and determining the process document information of the resource interaction settlement request in the business handling information.
[0077] Among them, the service number refers to the processing number corresponding to the resource interaction settlement request in different business processes, which can be found through the resource interaction information. In one embodiment, the service number is included in the resource interaction information, and the resource interaction information can be directly obtained by parsing the resource interaction settlement request. In another embodiment, the resource interaction information may include the retrieval information or address information of the service number, and the service numbers of each business process can be found through this information. The service query port is the data publicly released in each link involved in the resource interaction settlement. The service query port can be accessed through the network, and the specific business handling information of each business link of the service query port can be obtained by using the service number as the retrieval keyword, such as the service processing time, service processing location, and the process document information of the business process, etc.
[0078] Exemplarily, for the process of obtaining the process document information, a contract for generating a resource collection voucher can be used to automatically access the corresponding business process port. In order to obtain the corresponding business handling information and process document information from the business process port, when it is necessary to query the process document information, the service numbers corresponding to different business processes in the business process information can be determined first. At the same time, for each business process, its corresponding service query port can also be docked. Then, by calling the contract for generating a resource collection voucher, these service query ports are accessed in sequence, so as to obtain the business handling information corresponding to the service number from the service query port. Then, the process document information involved in the corresponding resource interaction settlement process is extracted from the business handling information. In this embodiment, by finding the service number and the service query port, and then obtaining the corresponding process document information through the service query port to perform the resource interaction settlement process under the resource collection settlement type, the legality and compliance of the resource interaction process can be effectively improved, thereby ensuring the processing efficiency of the overall resource interaction settlement process.
[0079] In an exemplary embodiment, the settlement type includes a resource exchange settlement type, and the voucher generation smart contract includes a resource exchange voucher generation contract. Step 304 includes: when the settlement type represented by the resource interaction information is the resource exchange settlement type, determining the resource categories of both parties in the resource exchange in the resource interaction information; calling the resource exchange voucher generation contract to query the process document information of the resource category.
[0080] Among them, the resource exchange settlement type refers to the exchange process of a certain type of resource held by the target object party that submits a resource interaction settlement request and another type of resource of the interaction object party involved in the resource interaction. The ratio of the exchange of the two types of resources is specified by the resource management section. Therefore, for the resource exchange settlement type, it is necessary to determine the resource categories of both parties involved in the resource exchange in the resource interaction information, and then determine the exchange ratio and information such as process documents involved in the resource exchange process through the resource categories, so as to perform more accurate resource interaction processing.
[0081] Exemplarily, in addition to performing the resource collection process for the resource interaction process, the blockchain network can also be applied to implement the resource exchange process between both parties. At this time, for the smart contract process of voucher generation, it is necessary to first identify the specific categories of resources that the two parties involved in the exchange need to exchange when determining that the settlement type represented by the resource interaction information is the resource exchange settlement type. After determining the resource categories, the process document information corresponding to the resource categories can be determined. For example, different types of resource categories correspond to different qualification information, and when performing resource exchange processing, qualification information is required for proof. At this time, after determining the resource categories of both parties involved in the resource exchange, the voucher generation contract for resource exchange can be used to query whether the target object party and the interaction object party have the qualification to perform resource exchange under the current resource category. In one embodiment, specifically, the process document information left by the target object party and the interaction object party in the qualification review process can be queried as the qualification information for the resource interaction process. In this embodiment, for the settlement type of resource exchange, the process document information is queried through the resource categories of both parties involved in the resource exchange, so as to generate vouchers during the process, which can effectively ensure the legality and compliance of the resource interaction process, and thus ensure the processing efficiency of the overall resource interaction settlement process.
[0082] In an exemplary embodiment, step 306 includes: searching for the document review smart contract of the process document information; based on the process document information, performing compliance review processing on the resource interaction information through the document review smart contract to obtain a review result; and when the review result indicates that the resource interaction information passes the review, generating a settlement voucher for the resource interaction settlement request based on the process document information.
[0083] Among them, the document review smart contract is used to review whether the queried process document information is valid, and can also review whether each piece of queried process document information is consistent with the resource interaction information, so as to implement the compliance review processing of the resource interaction information.
[0084] Exemplarily, after querying the process document information, it is also necessary to review and process whether the current process document information matches the resource interaction information. For example, for the resource interaction settlement request in cross-border trade, it can be reviewed whether the waybill number corresponding to the resource interaction information is consistent with the process document information in the warehouse process, and whether the resource type and commodity type in the resource interaction information are consistent with the resource type and commodity type in the government review process, etc. The specific review rules can be set according to the specific links and specific content involved in the resource interaction process and incorporated into the document review smart contract of the blockchain network. The document review smart contract will conduct a separate review for each process document information. Specifically, it can judge whether the process document content of each processing process in the resource interaction settlement process matches the relevant content in the resource interaction information, and judge whether there are situations such as missing processes or inconsistent goods and documents. Then, according to the specific review results, it is judged whether to generate a settlement voucher for corresponding resource interaction processing. Only when the review is completely passed will a settlement voucher for the resource interaction settlement request be generated, thus effectively ensuring the compliance of the resource interaction settlement process. In this embodiment, generating a settlement voucher through the compliance review and processing of the process document information and the resource interaction information can effectively ensure the legality and compliance of the resource interaction process, thereby ensuring the processing efficiency of the overall resource interaction settlement process.
[0085] In one embodiment, step 302 includes: obtaining a resource interaction settlement request; performing signature verification processing on the resource interaction settlement request to obtain a signature verification result; in the case where the signature verification result indicates that the signature verification is passed, performing identity verification processing on the resource interaction settlement request to obtain an identity verification result; in the case where the signature verification result indicates that the signature verification is passed, identifying the resource interaction information in the resource interaction settlement request.
[0086] Among them, the signature data is the digital signature of the blockchain, specifically referring to a segment of characters for signature. In the blockchain network, each node has a public-private key pair. When a node sends a request, it first uses its private key to sign the request content and attach the signature to the request. After other nodes receive the broadcast message, they first verify the digital signature attached to the request. After completing the message integrity check and the verification of the identity legality of the message sender, the request will trigger the subsequent processing process. For permission verification, different objects correspond to different permissions of the blockchain. For example, only objects not on the blacklist can call the smart contract involved in the resource interaction processing process. Therefore, the received resource interaction settlement request can be verified through permission verification to determine whether the user sending the request is on the blockchain blacklist.
[0087] Exemplarily, when the target object needs to implement resource interaction settlement processing through the blockchain, it can submit a resource interaction settlement request to the blockchain node, and attach resource interaction information and the signature data of the current object to the request. When the blockchain node receives the resource interaction settlement request, it will first extract the signature data contained therein, and then perform signature verification processing on the resource interaction settlement request based on the signature data to determine whether the object submitting the request exists. When the signature verification passes and the object is determined to exist, then perform permission verification processing on the resource interaction settlement request that has passed the signature verification processing to determine whether the object is on the blacklist of the blockchain. When the resource interaction settlement request passes the permission verification, the resource interaction information in the resource interaction settlement request can be identified to perform resource interaction processing. In this embodiment, the resource interaction settlement request is verified through signature verification and permission verification, thereby ensuring the legality and compliance of the resource interaction settlement request during the resource interaction settlement processing, and ensuring the effectiveness and efficiency of the resource data interaction settlement processing process.
[0088] In an exemplary embodiment, step 308 includes: uploading the settlement voucher and the resource interaction request to the resource interaction pool of the blockchain network; when the block generation condition is met, calling the resource interaction contract through the blockchain network to execute the resource interaction request in the resource interaction pool to obtain the resource interaction settlement result.
[0089] Exemplarily, for the specific process of resource interaction settlement processing, after completing the review of the process document information and generating the settlement voucher of the resource interaction settlement request, the settlement voucher and the resource interaction request can be uploaded to the resource interaction pool of the blockchain network, and then the processing of these resource interaction requests can be completed in the resource interaction pool. When uploading, the settlement voucher and the resource interaction request can be combined into a new request. For the request data in the resource interaction pool, when the block generation condition is met, the blockchain node will read out all the requests in the resource interaction pool at one time, and perform corresponding resource interaction settlement and resource transfer processing on the resource interaction settlement requests among them. In one embodiment, the block generation can be triggered periodically, for example, triggering the block generation process at a certain time interval. In another embodiment, the block generation can be based on the request volume of the resource interaction pool. When the resource volume threshold is reached, the block generation can be directly triggered. After triggering the block generation, the resource interaction contract can be called through the blockchain network to execute the resource interaction requests in the resource interaction pool to obtain the resource interaction settlement result. Thereby ensuring the efficiency and accuracy of the block generation process.
[0090] In an exemplary embodiment, the method further includes: generating a next block of the blockchain network based on the resource interaction settlement result; sending the next block to each block node of the blockchain network for consensus processing to obtain a consensus result; performing a consensus verification process based on the consensus result; and when the consensus verification process passes, performing a storage process on the next block.
[0091] Among them, consensus processing is a way to process newly generated blocks through a consensus mechanism. As a data structure that stores data in chronological order, the blockchain can support different consensus mechanisms. The consensus mechanism is an important component of blockchain technology. The goal of the blockchain consensus mechanism is to enable all honest nodes to maintain a consistent view of the blockchain while satisfying two properties: Consistency. The prefix parts of the blockchains saved by all honest nodes are exactly the same. Validity. The information released by a certain honest node will eventually be recorded in the blockchains of all other honest nodes.
[0092] Exemplarily, when the request is processed and the next block is generated, in order to store the newly generated block in the blockchain, it is necessary for the nodes on the blockchain to complete the consensus processing of the newly generated block. At this time, the next block is sent to each block node of the blockchain network for consensus processing to obtain the consensus result of each block node on the newly generated next block. After obtaining the consensus results feedback by each block node, a consensus verification process can be performed based on the consensus results; if the consensus verification process passes, the next block can be stored to update the blockchain. If the consensus verification fails, information indicating the failure of the consensus verification is directly feedback. In this embodiment, the generated next block is verified through consensus verification, so that the result obtained from the resource interaction settlement is saved in the blockchain, forming a complete data processing chain, and ensuring the traceability of the resource interaction settlement request processing process.
[0093] In one of the embodiments, the detailed structure of the blockchain node for implementing resource data processing based on the blockchain in the present application can be referred to as shown in FIG. 4, including:
[0094] A network module, which is a module for the blockchain node to interact with other blockchain nodes in the blockchain network; the network module exposes a unified port externally to provide an access method. It can implement the functions of request on-chain and data query. Request on-chain can transmit the resource interaction settlement request to the module of the blockchain network. Data query refers to querying the data in the blockchain based on the query statement sent by the user and providing feedback.
[0095] An authentication module, which is a module for the blockchain node to verify the permissions of the request. It includes a signature verification module, which is a module for the blockchain node to verify the signature of the request. It also includes a permission verification module, which is a module for the blockchain node to judge the permissions of the requester's identity, that is, whether there is permission to perform the request operation.
[0096] Resource interaction pool module, a module for caching various requests and executing them.
[0097] Smart contract execution module, used to execute various smart contracts in the blockchain network. For example, based on the settlement type characterized by the resource interaction information, it calls the voucher generation smart contract to query the process document information of the resource interaction settlement request in the blockchain network. And when the block generation condition is met, it calls the resource interaction contract through the blockchain network to execute the resource interaction request in the resource interaction pool, and obtains the resource interaction settlement result. That is, data processing is performed by executing smart contracts.
[0098] Block generation module, a module for generating a new block after executing all requests in the current block.
[0099] Consensus module, a module for blockchain nodes to conduct consensus voting.
[0100] Storage module, a module for blockchain nodes to store blockchain data. It includes a state database, a database for storing the latest variable states. It also includes a block ledger, a text file for storing blocks.
[0101] In an exemplary embodiment, the method further includes: obtaining a permission review request for a target object; querying the resource interaction settlement result corresponding to the target object based on the blockchain network, and performing a review process on the permission review request; when the review is passed, performing a permission update process on the target object, and saving the updated permission information of the target object to the blockchain network.
[0102] Among them, the permission review request refers to a request submitted by the target object to the blockchain network when it hopes to change its own permissions. For example, when the target object hopes to improve its own permissions to request an increase in the amount of resources it can process in the blockchain network or the services associated with the blockchain network, it can submit a corresponding permission review request to the blockchain node through the client, so as to improve its permissions in the blockchain network or the services associated with the blockchain network through permission review and permission change. And corresponding to the permission review request, it is necessary to review whether the target object has the qualification for permission change. At this time, specifically, the resource interaction settlement result corresponding to the target object can be queried through the blockchain network, and the permission review request can be reviewed by comprehensively considering the various resource interaction settlement results corresponding to the target object.
[0103] Exemplarily, after completing the resource interaction settlement request, if the target object still wishes to change its own permissions in the blockchain network or the services associated with the blockchain network, it can directly initiate a permission review request to the blockchain node to change its own permissions. When the blockchain node obtains the permission review request for the target object, it can query the resource interaction settlement result corresponding to the target object based on the blockchain network for the target object. Since each executed resource interaction settlement request will be correspondingly saved to the nodes of the blockchain network. Therefore, by querying in the blocks of the blockchain network, for the target object, the resource interaction settlement result corresponding to the target object can be directly retrieved. Then, after retrieving the resource interaction settlement result, the permission review request can be reviewed based on the resource interaction settlement result to determine whether the target object has the corresponding permission qualifications. When the review is passed, the permissions of the target object can be updated, and the updated permission information of the target object can be saved to the blockchain network. When the review fails, a corresponding permission change failure message can be feedback to the target object. For the process of block generation and block saving, specifically, a permission update request for the target object can be generated based on the query record, query result, and review result for the permission review request; the permission update request is executed through the blockchain network to generate a record block corresponding to the permission update request, thereby ensuring the traceability of the permission change process. In one embodiment, the blockchain network can assign different permission levels to target objects with different permissions, and the limits for resource interaction settlement processing under different permission levels are different. When the target object wishes to upgrade its permission level to increase the processing volume of resource interaction settlement processing, it can request to upgrade its own permission level from the blockchain network through a permission review request.
[0104] In another embodiment, the associated services of the blockchain network may share the permission levels of the blockchain network and provide different services to target objects with different permission levels. For example, for the resource lending service, different amounts of resource lending services are provided to target objects with different permission levels. At this time, the target object can request to upgrade its own permission level through a permission review request so as to receive a higher amount of resource lending services. At this time, for the process of permission review, specifically, based on the object information in the permission review request, the historical resource interaction settlement results executed by the target object and the corresponding historical settlement vouchers for the resource interaction settlement results can be queried in the blockchain network through a data query contract; based on the pledge information in the permission review request, the pledge attribution information corresponding to the pledge information can be queried in the blockchain network through a data query contract; the permission review request is reviewed and processed based on the historical resource interaction settlement request, the historical settlement vouchers, and the pledge attribution information. That is, in combination with the settlement resource amount in the resource interaction settlement request, the resource flow information of the target object is determined, the legality and compliance of the target object in the resource settlement process are determined through the historical settlement vouchers, and the reliability of the pledged content provided by the target object is determined through the pledge attribution information. The three are combined to realize the permission change for the resource lending service of the target object. After the permission is changed, the target object can apply for corresponding resource lending processing to the resource lending service associated with the blockchain network based on the changed permission level. In this embodiment, by reviewing the permissions of the target object, the permission update process of the target object is realized, and the permission change is realized based on the resource interaction settlement result corresponding to the target object, which can effectively ensure the review efficiency and accuracy of the permission change process.
[0105] The present application also provides an application scenario that applies the above-mentioned blockchain-based resource data processing method. Specifically, the application of the blockchain-based resource data processing method in this application scenario is as follows:
[0106] When a user hopes to implement the settlement process of the resource collection service in the cross-border trade process through the blockchain network, a resource interaction settlement request can be submitted to the blockchain node carrying the resource data processing of the present application to start the interactive settlement process of resource collection. The user can initiate a resource interaction settlement request to the blockchain node to request the collection of various resources or perform the exchange process of resource data between overseas and domestic. For example Figure 5As shown, after the user initiates a resource interaction settlement request to the blockchain node, the blockchain node will identify the resource interaction information in the resource interaction settlement request, and then determine the settlement type represented by the resource interaction information, and determine whether it belongs to the resource collection and settlement type or the resource exchange settlement type. When it belongs to the resource collection and settlement type, the blockchain node will first determine the business process information involved in the resource collection in the resource collection information, such as government processes (such as tax / customs / foreign exchange administration processes) and business processes (such as warehouse processes); then, based on the resource interaction information, find the business numbers of each business process in the business process information, and determine the business query ports of each business process; call the resource collection voucher generation contract to access the business query port, and find the business handling information corresponding to the business number in the business query port, and determine the process document information of the resource interaction settlement request in the business handling information. Then, find the document review smart contract of the process document information. When the settlement type is the resource exchange settlement type, it is necessary to determine the resource categories of both parties in the resource exchange in the resource interaction information; call the resource exchange voucher generation contract to query the process document information of the resource category. Based on the process document information, the resource interaction information is subject to compliance review and processing through the document review smart contract to obtain the review result; when the review result indicates that the resource interaction information passes the review, a settlement voucher for the resource interaction settlement request is generated based on the process document information. The settlement voucher and the resource interaction request are uploaded to the resource interaction pool of the blockchain network; when the block generation condition is met, the resource interaction contract is called through the blockchain network to execute the resource interaction request in the resource interaction pool. For the resource collection and settlement type, the overseas resource collection contract is called here, and for the resource exchange settlement type, the resource exchange contract is called here. The resource interaction settlement result can be obtained, and the next block of the blockchain network is generated according to the resource interaction settlement result. In addition, this application also includes the process of implementing permission change processing through the blockchain network, such as Figure 6As shown, the target object can initiate a resource lending request that requires permission authentication to the associated service of the blockchain network, and the associated service party can, according to the request of the target object, initiate a permission review request for the target object to the blockchain node. Thus, relevant data of the target object is shared in the blockchain network. Based on the object information in the permission review request, the historical resource interaction settlement results executed by the target object and the historical settlement vouchers corresponding to the resource interaction settlement results are queried in the blockchain network through a data query contract; based on the pledge information in the permission review request, the pledge attribution information corresponding to the pledge information is queried in the blockchain network through a data query contract; the permission review request is reviewed and processed based on the historical resource interaction settlement request, the historical settlement vouchers, and the pledge attribution information. In the case of passing the review, a permission update request for the target object is generated based on the query record, the query result, and the review result for the permission review request; the permission update request is executed through the blockchain network to generate a record block corresponding to the permission update request. Then, a corresponding review passed message is fed back, and the historical resource interaction settlement request, the historical settlement vouchers, and the pledge attribution information are shared with the service party of the resource lending service to help the service party perform relevant resource processing services. At this time, for the blockchain node, the overall system architecture can refer to Figure 7 As shown, it includes four parties: the target object, the overseas interaction object, the blockchain node, and the node associated service.
[0107] In one embodiment, the complete process of resource data processing based on the blockchain in this application can refer to Figure 8 As shown, it includes:
[0108] Step 801, obtain a resource interaction settlement request. Step 803, perform signature verification processing on the resource interaction settlement request to obtain a signature verification result. Step 805, when the signature verification result indicates that the signature verification is passed, perform identity verification processing on the resource interaction settlement request to obtain an identity verification result. Step 807, when the signature verification result indicates that the signature verification is passed, identify the resource interaction information in the resource interaction settlement request. Step 809, based on the settlement type represented by the resource interaction information, call the voucher generation smart contract to query the process document information of the resource interaction settlement request in the blockchain network. Step 811, search for the document review smart contract of the process document information. Step 813, based on the process document information, perform compliance review processing on the resource interaction information through the document review smart contract to obtain a review result. Step 815, when the review result indicates that the resource interaction information passes the review, generate a settlement voucher for the resource interaction settlement request based on the process document information. Step 817, upload the settlement voucher and the resource interaction request to the resource interaction pool of the blockchain network. Step 819, when the block generation condition is met, call the resource interaction contract through the blockchain network to execute the resource interaction request in the resource interaction pool to obtain a resource interaction settlement result. Step 821, generate the next block of the blockchain network based on the resource interaction settlement result. Step 823, send the next block to each block node of the blockchain network for consensus processing to obtain a consensus result. Step 825, perform consensus verification processing based on the consensus result. Step 827, when the consensus verification processing passes, perform storage processing on the next block.
[0109] It should be understood that although the steps in the flowcharts involved in the above embodiments are sequentially shown according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless there is a clear indication in this article, the execution of these steps has no strict order limit, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above embodiments may include multiple steps or multiple stages. These steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be executed alternately or alternately with at least a part of the steps or stages in other steps or other steps.
[0110] Based on the same inventive concept, an embodiment of this application further provides a blockchain-based resource data processing apparatus for implementing the above-mentioned blockchain-based resource data processing method. The solution provided by this apparatus for solving problems is similar to the solution described in the above method. Therefore, the specific limitations in one or more embodiments of the blockchain-based resource data processing apparatus provided below can refer to the limitations on the blockchain-based resource data processing method in the above text, and will not be repeated here.
[0111] In an exemplary embodiment, as Figure 9 shown, a blockchain-based resource data processing apparatus is provided, including:
[0112] A request acquisition module 902, configured to acquire a resource interaction settlement request and identify resource interaction information in the resource interaction settlement request.
[0113] A data query module 904, configured to query process document information of the resource interaction settlement request in the blockchain network by invoking a voucher generation smart contract based on the settlement type represented by the resource interaction information.
[0114] A voucher generation module 906, configured to generate a settlement voucher for the resource interaction settlement request based on the process document information.
[0115] A request processing module 908, configured to execute the resource interaction settlement request through the blockchain network based on the settlement voucher to obtain a resource interaction settlement result.
[0116] In one embodiment, the settlement type includes a resource collection and settlement type, and the voucher generation smart contract includes a resource collection voucher generation contract. The data query module 904 is specifically configured to: when the settlement type represented by the resource interaction information is the resource collection and settlement type, determine the business process information involved in the resource collection in the resource collection information; based on the business process information, invoke the resource collection voucher generation contract to query the process document information of the resource interaction settlement request.
[0117] In one embodiment, the data query module 904 is further configured to: find the business numbers of each business process in the business process information based on the resource interaction information, and determine the business query ports of each business process; invoke the resource collection voucher generation contract to access the business query ports, and find the business handling information corresponding to the business number at the business query ports, and determine the process document information of the resource interaction settlement request in the business handling information.
[0118] In one embodiment, the settlement type includes a resource exchange settlement type, and the voucher generation smart contract includes a resource exchange voucher generation contract; the data query module 904 is further configured to: when the settlement type represented by the resource interaction information is the resource exchange settlement type, determine the resource categories of both parties in the resource exchange in the resource interaction information; call the resource exchange voucher generation contract to query the process document information of the resource category.
[0119] In one embodiment, the voucher generation module 906 is specifically configured to: find the document review smart contract of the process document information; based on the process document information, perform compliance review processing on the resource interaction information through the document review smart contract to obtain a review result; when the review result indicates that the resource interaction information passes the review, generate a settlement voucher for the resource interaction settlement request based on the process document information.
[0120] In one embodiment, the request acquisition module 902 is specifically configured to: acquire a resource interaction settlement request; perform signature verification processing on the resource interaction settlement request to obtain a signature verification result; when the signature verification result indicates that the signature verification is passed, perform identity verification processing on the resource interaction settlement request to obtain an identity verification result; when the signature verification result indicates that the signature verification is passed, identify the resource interaction information in the resource interaction settlement request.
[0121] In one embodiment, the request processing module 908 is specifically configured to: upload the settlement voucher and the resource interaction request to the resource interaction pool of the blockchain network; when the block generation condition is satisfied, call the resource interaction contract through the blockchain network to execute the resource interaction request in the resource interaction pool to obtain a resource interaction settlement result.
[0122] In one embodiment, it further includes a block generation module, configured to: generate the next block of the blockchain network based on the resource interaction settlement result; send the next block to each block node of the blockchain network for consensus processing to obtain a consensus result; perform consensus verification processing based on the consensus result; when the consensus verification processing is passed, perform storage processing on the next block.
[0123] In one embodiment, it further includes a permission change module, configured to: acquire a permission review request for a target object; query the resource interaction settlement result corresponding to the target object based on the blockchain network and perform review processing on the permission review request; when the review is passed, perform permission update processing on the target object and save the updated permission information of the target object to the blockchain network.
[0124] In one embodiment, the permission change module is further configured to: based on the object information in the permission review request, query, in the blockchain network through the data query contract, the historical resource interaction settlement results executed by the target object and the historical settlement vouchers corresponding to the resource interaction settlement results respectively; based on the pledge information in the permission review request, query, in the blockchain network through the data query contract, the pledge attribution information corresponding to the pledge information; and perform review processing on the permission review request based on the historical resource interaction settlement request, the historical settlement vouchers, and the pledge attribution information.
[0125] In one embodiment, the permission change module is further configured to: generate a permission update request for the target object based on the query record, the query result, and the review result for the permission review request; and execute the permission update request through the blockchain network to generate a record block corresponding to the permission update request.
[0126] Each module in the above blockchain-based resource data processing device can be implemented in whole or in part by software, hardware, and their combination. The above modules can be embedded in the processor in the computer device in the form of hardware or be independent of it, or can be stored in the memory of the computer device in the form of software, so as to facilitate the processor to call and execute the operations corresponding to the above respective modules.
[0127] In an exemplary embodiment, a computer device is provided. The computer device can be a server, and its internal structure diagram can be as Figure 10 shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, abbreviated as I / O), and a communication interface. Among them, the processor, the memory, and the input / output interface are connected through the system bus, and the communication interface is connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data related to resource data processing in the blockchain. The input / output interface of the computer device is used to exchange information between the processor and external devices. The communication interface of the computer device is used to communicate with external terminals through a network connection. When the computer program is executed by the processor, it implements a blockchain-based resource data processing method.
[0128] Those skilled in the art can understand, Figure 10The structure shown is only a block diagram of some structures related to the solution of this application, and does not constitute a limitation on the computer device to which the solution of this application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine some components, or have a different component layout.
[0129] In one embodiment, a computer device is further provided, including a memory and a processor. A computer program is stored in the memory, and when the processor executes the computer program, the steps in the above method embodiments are implemented.
[0130] In one embodiment, a computer-readable storage medium is provided, storing a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.
[0131] In one embodiment, a computer program product or a computer program is provided. The computer program product or the computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the steps in the above method embodiments.
[0132] 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 for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use, and processing of relevant data need to comply with relevant regulations.
[0133] Those of ordinary skill in the art can understand that all or part of the processes in the methods of the above embodiments can be completed by instructing relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above methods. Among them, any reference to a memory, database, or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memories. Non-volatile memories can include read-only memory (ROM), magnetic tapes, floppy disks, flash memories, optical memories, high-density embedded non-volatile memories, resistive random access memories (ReRAM), magnetoresistive random access memories (MRAM), ferroelectric random access memories (FRAM), phase change memories (PCM), graphene memories, etc. Volatile memories can include random access memory (RAM) or external cache memories, etc. By way of illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM), etc. The databases involved in the embodiments provided in the present application can include at least one of relational databases and non-relational databases. Non-relational databases can include distributed databases based on blockchain, etc., without limitation. The processors involved in the embodiments provided in the present application can be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logics, data processing logics based on quantum computing, etc., without limitation.
[0134] The technical features of the above embodiments can be combined arbitrarily. For the sake of brevity of description, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, it should be considered as the scope described in this specification.
[0135] The above-described embodiments merely represent several implementation manners of the present application. The description thereof is relatively specific and detailed, but it should not be construed as a limitation on the patent scope of the present application. It should be noted that for those of ordinary skill in the art, without departing from the concept of the present application, several modifications and improvements can still be made, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the appended claims.
Claims
1. A blockchain-based resource data processing method, characterized in that The method includes: Obtain a resource interaction settlement request and identify the resource interaction information in the resource interaction settlement request; Based on the settlement type represented by the resource interaction information, call a voucher generation smart contract to query the process document information of the resource interaction settlement request in the blockchain network; Generate a settlement voucher for the resource interaction settlement request based on the process document information; Based on the settlement voucher, execute the resource interaction settlement request through the blockchain network to obtain a resource interaction settlement result.
2. The method according to claim 1, wherein The settlement type includes a resource collection and payment settlement type, and the voucher generation smart contract includes a resource collection and payment voucher generation contract; The step of, based on the settlement type represented by the resource interaction information, calling a voucher generation smart contract to query the process document information of the resource interaction settlement request in the blockchain network includes: When the settlement type represented by the resource interaction information is the resource collection and payment settlement type, determine the business process information involved in the resource collection and payment in the resource collection and payment information; Based on the business process information, call the resource collection and payment voucher generation contract to query the process document information of the resource interaction settlement request.
3. The method according to claim 2, wherein The step of, based on the business process information, calling the resource collection and payment voucher generation contract to query the process document information of the resource interaction settlement request includes: Find the business numbers of each business process in the business process information based on the resource interaction information, and determine the business query ports of each business process; Call the resource collection and payment voucher generation contract to access the business query port, and find the business handling information corresponding to the business number at the business query port, and determine the process document information of the resource interaction settlement request in the business handling information.
4. The method according to claim 1, wherein The settlement type includes a resource exchange settlement type, and the voucher generation smart contract includes a resource exchange voucher generation contract; The step of, based on the settlement type represented by the resource interaction information, calling a voucher generation smart contract to query the process document information of the resource interaction settlement request in the blockchain network includes: When the settlement type represented by the resource interaction information is the resource exchange settlement type, determine the resource categories of both parties in the resource exchange in the resource interaction information; Call the resource exchange voucher generation contract to query the process document information of the resource category.
5. The method according to claim 1, wherein The step of generating a settlement voucher for the resource interaction settlement request based on the process document information includes: Find the document review smart contract for the process document information; Based on the process document information, perform a compliance review process on the resource interaction information through the document review smart contract to obtain a review result; When the review result indicates that the resource interaction information passes the review, generate a settlement voucher for the resource interaction settlement request based on the process document information.
6. The method according to claim 1, wherein The step of obtaining a resource interaction settlement request and identifying the resource interaction information in the resource interaction settlement request includes: Obtain a resource interaction settlement request; Perform a signature verification process on the resource interaction settlement request to obtain a signature verification result; When the signature verification result indicates that the signature verification is passed, perform identity verification processing on the resource interaction settlement request to obtain an identity verification result; When the signature verification result indicates that the signature verification is passed, identify the resource interaction information in the resource interaction settlement request.
7. The method according to claim 1, wherein The executing the resource interaction settlement request through the blockchain network based on the settlement voucher to obtain a resource interaction settlement result includes: Upload the settlement voucher and the resource interaction request to the resource interaction pool of the blockchain network; When the block generation condition is satisfied, call a resource interaction contract through the blockchain network to execute the resource interaction request in the resource interaction pool to obtain a resource interaction settlement result.
8. The method according to claim 7, characterized in that, The method further includes: Generate the next block of the blockchain network based on the resource interaction settlement result; Send the next block to each block node of the blockchain network for consensus processing to obtain a consensus result; Perform a consensus verification process based on the consensus result; When the consensus verification process passes, perform a storage process on the next block.
9. The method according to any one of claims 1 to 8, characterized in that, The method further includes: Obtain a permission review request for a target object; Query the resource interaction settlement result corresponding to the target object based on the blockchain network and perform a review process on the permission review request; When the review is passed, perform a permission update process on the target object and save the updated permission information of the target object to the blockchain network.
10. The method according to claim 9, characterized in that The querying the resource interaction settlement result corresponding to the target object based on the blockchain network and performing a review process on the permission review request includes: Based on the object information in the permission review request, query, through a data query contract in the blockchain network, the historical resource interaction settlement results executed by the target object and the historical settlement vouchers corresponding to the resource interaction settlement results respectively; Based on the pledge information in the permission review request, query, through a data query contract in the blockchain network, the pledge attribution information corresponding to the pledge information; Perform a review process on the permission review request based on the historical resource interaction settlement request, the historical settlement voucher, and the pledge attribution information.
11. The method according to claim 9, wherein The performing a permission update process on the target object and saving the updated permission information of the target object to the blockchain network includes: Generate a permission update request for the target object based on the query record, query result, and review result for the permission review request; Execute the permission update request through the blockchain network to generate a record block corresponding to the permission update request.
12. A resource data processing device based on blockchain, characterized in that, The device includes: A request acquisition module, configured to acquire a resource interaction settlement request and identify the resource interaction information in the resource interaction settlement request; A data query module, configured to query, based on the settlement type represented by the resource interaction information, process document information of the resource interaction settlement request in the blockchain network by invoking a voucher generation smart contract; A voucher generation module, configured to generate a settlement voucher for the resource interaction settlement request based on the process document information; A request processing module, configured to execute the resource interaction settlement request through the blockchain network based on the settlement voucher, so as to obtain a resource interaction settlement result.
13. A computer device, comprising a memory and a processor, the memory storing a computer program, characterized in that, When the processor executes the computer program, the steps of the method according to any one of claims 1 to 11 are implemented.
14. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 11 are implemented.
15. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 11 are implemented.