Resource processing method, device, equipment, medium and product

By storing real resource processing information of user business events in the blockchain and calling smart contracts for processing during data queries, the problem of mismatch between financial data and rules is solved, and accurate and efficient acquisition of financial data is achieved.

CN122019664APending Publication Date: 2026-05-12湖南长银五八消费金融股份有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
湖南长银五八消费金融股份有限公司
Filing Date
2026-01-14
Publication Date
2026-05-12

AI Technical Summary

Technical Problem

Because financial processing rules change frequently, directly uploading processed financial data to the blockchain can lead to a mismatch between the financial data and the processing rules, reducing the accuracy of data acquisition.

Method used

By storing real resource processing information corresponding to user business events in the blockchain, resource processing smart contracts are invoked when responding to data query requests to process the information in the event ledger and dynamically deduce resource calculation results.

Benefits of technology

It ensures the accuracy and reliability of financial data acquisition, supports status tracing at any historical point in time and data reconstruction under rule changes, and improves the efficiency and convenience of resource computing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122019664A_ABST
    Figure CN122019664A_ABST
Patent Text Reader

Abstract

The invention relates to a resource processing method and device, equipment, a medium and a product. The method comprises the steps of obtaining an event account book corresponding to a target service from a block chain in response to a data query request initiated by a data demander for the target service, calling a resource processing smart contract, processing real resource processing information in the event account book to obtain a resource calculation result, and feeding back the resource calculation result to the data demander, wherein the event account book comprises real resource processing information corresponding to at least one user service event for the target service. By adopting the method, the accuracy of financial data acquisition can be ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of blockchain technology, and in particular to a resource processing method, apparatus, device, medium, and product that can be applied to the financial field or other technical fields. Background Technology

[0002] With the continuous development of the financial sector, in order to facilitate the supervision and auditing of financial data on various financial platforms, each financial platform can upload processed financial data to the blockchain, and the auditor can directly obtain the required financial data from the blockchain.

[0003] However, due to the frequent changes in financial processing rules, directly uploading processed financial data to the blockchain can lead to a mismatch between the financial data and the financial processing rules, thereby reducing the accuracy of financial data acquisition. Summary of the Invention

[0004] Therefore, it is necessary to provide a resource processing method, apparatus, equipment, medium, and product that can improve the accuracy of financial data acquisition in response to the above-mentioned technical problems.

[0005] Firstly, this application provides a resource processing method, including:

[0006] In response to a data query request initiated by a data requester for a target business, the event ledger corresponding to the target business is retrieved from the blockchain; wherein, the event ledger contains real resource processing information corresponding to at least one user business event for the target business;

[0007] The resource processing smart contract is invoked to process the actual resource processing information in the event ledger, obtain the resource calculation results, and then feed back the resource calculation results to the data requester.

[0008] In one embodiment, when the event ledger contains at least two pieces of real resource processing information, a resource processing smart contract is invoked to process the real resource processing information in the event ledger to obtain resource calculation results, including:

[0009] Based on the generation timestamp of each real resource processing information, sort the real resource processing information to obtain the sorting result;

[0010] Based on the sorting results, the resource processing smart contract is invoked to process each real resource processing information in turn, thereby obtaining the resource calculation results.

[0011] In one embodiment, based on the sorting result, a resource processing smart contract is invoked to process each real resource processing information sequentially to obtain resource calculation results, including:

[0012] Based on the data query request, determine the parameters to be processed in each real resource processing information;

[0013] Based on the sorting results, the resource processing function in the resource processing smart contract is called to process the parameters to be processed in each real resource processing information in turn, and the resource calculation results are obtained.

[0014] In one embodiment, retrieving the event ledger corresponding to the target business from the blockchain includes:

[0015] Obtain a snapshot of the business status associated with the target business;

[0016] Based on the snapshot generation time of the business status snapshot, the event ledger corresponding to the target business is obtained from the blockchain; wherein, the actual resource processing information contained in the event ledger is the actual resource processing information generated after the snapshot generation time.

[0017] In one embodiment, a resource processing smart contract is invoked to process the actual resource processing information in the event ledger to obtain resource calculation results, including:

[0018] The resource processing smart contract is invoked to process the actual resource processing information in the business state snapshot and event ledger to obtain the resource calculation results.

[0019] In one embodiment, the method further includes:

[0020] In response to an update event for resource processing rules, the resource processing smart contract is updated according to the resource processing logic in the update event.

[0021] Secondly, this application also provides a resource processing apparatus, comprising:

[0022] The acquisition module is used to respond to data query requests initiated by data requesters for target businesses and retrieve the event ledger corresponding to the target business from the blockchain; wherein, the event ledger contains real resource processing information corresponding to at least one user business event for the target business;

[0023] The calculation module is used to call the resource processing smart contract, process the real resource processing information in the event ledger, obtain the resource calculation results, and feed back the resource calculation results to the data requester.

[0024] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to perform the following steps:

[0025] In response to a data query request initiated by a data requester for a target business, the event ledger corresponding to the target business is retrieved from the blockchain; wherein, the event ledger contains real resource processing information corresponding to at least one user business event for the target business;

[0026] The resource processing smart contract is invoked to process the actual resource processing information in the event ledger, obtain the resource calculation results, and then feed back the resource calculation results to the data requester.

[0027] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, performs the following steps:

[0028] In response to a data query request initiated by a data requester for a target business, the event ledger corresponding to the target business is retrieved from the blockchain; wherein, the event ledger contains real resource processing information corresponding to at least one user business event for the target business;

[0029] The resource processing smart contract is invoked to process the actual resource processing information in the event ledger, obtain the resource calculation results, and then feed back the resource calculation results to the data requester.

[0030] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, performs the following steps:

[0031] In response to a data query request initiated by a data requester for a target business, the event ledger corresponding to the target business is retrieved from the blockchain; wherein, the event ledger contains real resource processing information corresponding to at least one user business event for the target business;

[0032] The resource processing smart contract is invoked to process the actual resource processing information in the event ledger, obtain the resource calculation results, and then feed back the resource calculation results to the data requester.

[0033] The aforementioned resource processing methods, apparatus, equipment, media, and products introduce an event ledger containing real resource processing information corresponding to at least one user business event targeting the target business. In response to a data query request initiated by a data requester for the target business, the event ledger corresponding to the target business is retrieved from the blockchain. Then, a resource processing smart contract is invoked to process the real resource processing information in the event ledger, obtaining the resource calculation result, which is then fed back to the data requester. Compared to related technologies that directly upload processed financial data to the blockchain, this method stores the real resource processing information corresponding to user business events in the blockchain. Upon detecting a data query request, the resource processing smart contract is invoked to process the real resource processing information and obtain the resource calculation result. This is equivalent to replaying the event chain of the target business and dynamically deriving the resource calculation result, ensuring the accuracy of financial data acquisition. Attached Figure Description

[0034] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0035] Figure 1 This is a flowchart illustrating a resource processing method in one embodiment;

[0036] Figure 2 This is a schematic diagram of a blockchain structure in one embodiment;

[0037] Figure 3 This is a flowchart illustrating the process of determining resource calculation results in one embodiment;

[0038] Figure 4 This is a schematic diagram of the information acquisition process in one embodiment;

[0039] Figure 5 This is a flowchart illustrating a resource processing method in another embodiment;

[0040] Figure 6 This is a structural block diagram of a resource processing device in one embodiment;

[0041] Figure 7 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation

[0042] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0043] With the continuous development of the financial sector, in order to facilitate the supervision and auditing of financial data on various financial platforms, each financial platform can upload processed financial data to the blockchain, and the auditor can directly obtain the required financial data from the blockchain.

[0044] However, due to the frequent changes in financial processing rules, directly uploading processed financial data to the blockchain can lead to a mismatch between the financial data and the financial processing rules, thereby reducing the reliability of financial data acquisition.

[0045] Based on this, in an exemplary embodiment, a resource processing method is provided. Taking the application of this method to a blockchain node as an example, it can be executed by a data query platform, a blockchain node, where various financial platforms, auditors, and the data query platform can jointly participate in the blockchain. Figure 1 As shown, the specific steps include:

[0046] S101, in response to a data query request initiated by a data requester for a target business, retrieves the event ledger corresponding to the target business from the blockchain.

[0047] In this context, the "data requester" refers to the blockchain node that needs to query resource data, which can be various financial platforms or auditors. The "target business" refers to the financial business that needs to be queried, such as loan repayment or tax calculation. The "data query request" is the request to perform a data query.

[0048] An event ledger is a persistent storage unit that stores an ordered, immutable sequence of events, which can be implemented using blockchain. The event ledger contains real resource processing information corresponding to at least one user business event related to a target business. Furthermore, a user business event is a business action initiated by a user for the target business, such as a loan repayment. Real resource processing information refers to the actual information regarding resource processing involved in the business action; these resources can be financial resources, for example, the actual repayment amount.

[0049] Understandably, to ensure that the data stored in the blockchain can adapt to complex and ever-changing financial processing rules, the data stored in the blockchain can be changed from calculated financial data to unprocessed real resource processing information. For example, for a resource borrowing transaction, after repaying 100 yuan, the remaining repayment amount for the resource borrowing transaction is 1000 yuan. In related technologies, "remaining repayment amount of 1000 yuan" can be stored in the blockchain, while in this embodiment, "repayment of 100 yuan" is stored in the blockchain.

[0050] It's worth noting that, to ensure efficient data storage, the granularity of event uploading can be adaptively adjusted. An event can be generated for each business action, or actions over a period of time can be aggregated into a composite event to optimize performance and storage costs.

[0051] Optionally, when a data requester has a data query requirement for a target business, they can initiate a data query request for the target business through the blockchain node associated with the data requester, based on the business identification information of the target business and the data query requirement.

[0052] Upon detecting a data query request, the business identifier information of the target business can be obtained from the request. Then, based on this business identifier information, the event ledger corresponding to the target business can be retrieved from the blockchain.

[0053] S102 invokes the resource processing smart contract to process the real resource processing information in the event ledger, obtains the resource calculation results, and feeds back the resource calculation results to the data requester.

[0054] In this context, a resource processing smart contract is a smart contract with resource processing capabilities; for example, it may include contract code corresponding to financial processing rules. The resource calculation result is the resource information obtained after calculating the actual resource processing information.

[0055] In one alternative implementation, the calculation rules contained in the resource processing smart contract can be invoked to calculate the actual resource processing information in the event ledger, thereby obtaining the resource calculation result. For example, in cases where the data query requirement is a query request involving only business actions, such as querying the total repayment amount, the calculation formula contained in the resource processing smart contract can be invoked to calculate the actual resource processing information, thereby obtaining the resource calculation result.

[0056] Understandably, to ensure the rationality of resource calculation, the target business will be associated with business description information, such as the resource borrowing amount in a resource borrowing business. Therefore, in another optional implementation, the calculation rules contained in the resource processing smart contract can be invoked based on the business description information of the target business to calculate the actual resource processing information in the event ledger, thereby obtaining the resource calculation result. For example, in cases where the data query requirement is a query for the amount to be repaid, which involves basic business information, the calculation formula contained in the resource processing smart contract can be invoked to calculate the actual resource processing information based on the business description information of the target business, thereby obtaining the resource calculation result.

[0057] Furthermore, after determining the resource calculation results, these results can be fed back to the data requester. For example, the resource calculation results can be displayed on a designated page associated with the data requester, allowing them to access them.

[0058] For example, refer to Figure 2 The diagram illustrates a blockchain structure. When Bank A makes a repayment, its corresponding client A can encapsulate the repayment action into a structured event A'. This event contains factual information such as the resource borrowing business ID, the repayment amount, and a timestamp. This event is an atomic fact record that occurs in the business domain and has business significance; it is immutable.

[0059] Furthermore, client A signs event A' using its bank private key and broadcasts it to the consortium blockchain network. At this point, the ledger nodes in the blockchain use the consensus mechanism in the consensus layer to sort event A' among other events and package it into blocks, forming an immutable and ordered event ledger. Depending on the trade-off between performance and decentralization, consensus mechanisms can be implemented using algorithms such as Proof of Authority (PoA), Raft Consensus Algorithm (RAFT), or Istanbul Byzantine Fault Tolerance (IBFT).

[0060] Auditor C can initiate a data query request for business D through the Auditor C node in the blockchain. Subsequently, the nodes in the blockchain can call the resource processing smart contract to calculate the actual resource processing information corresponding to business D in the event ledger, obtain the resource calculation result, and feed the resource calculation result back to Auditor C. At this point, the auditor can independently verify the entire resource calculation process, upgrading the audit from "result verification" to "process reproduction," thereby ensuring the reliability of the audit results.

[0061] It is worth noting that since the blockchain no longer stores the results of financial resources, when querying data, it is necessary to replay the event chain through smart contracts to dynamically deduce the resource calculation results. Therefore, the method in this embodiment supports state tracing at any historical point in time and data reconstruction under rule changes, thereby ensuring the reliability of resource calculation.

[0062] Furthermore, since both the resource processing smart contract and the event ledger are public, any blockchain node can repeat this process to verify the authenticity of the results without the need for a third party, thus ensuring the convenience of resource computation.

[0063] The aforementioned resource processing method introduces an event ledger containing real resource processing information corresponding to at least one user business event targeting the target business. In response to a data query request initiated by a data requester for the target business, the event ledger corresponding to the target business is retrieved from the blockchain. Then, a resource processing smart contract is invoked to process the real resource processing information in the event ledger, obtaining the resource calculation result, which is then fed back to the data requester. Compared to related technologies that directly upload processed financial data to the blockchain, this method stores the real resource processing information corresponding to user business events in the blockchain. Upon detecting a data query request, the resource processing smart contract is invoked to process the real resource processing information and obtain the resource calculation result. This is equivalent to replaying the event chain of the target business and dynamically deriving the resource calculation result, ensuring the reliability of financial data acquisition.

[0064] Based on the above embodiments, in this application embodiment, when the event ledger contains at least two pieces of real resource processing information, an optional method for determining the resource calculation result is provided, such as... Figure 3 As shown, the specific steps include:

[0065] S301, Sort each piece of real resource processing information according to its generation timestamp to obtain the sorting result.

[0066] The so-called generation timestamp is used to characterize the generation time of the actual resource processing information. The so-called sorting result contains the actual resource processing information of each time series.

[0067] Optionally, the real resource processing information can be sorted according to the generation timestamps of each real resource processing information, in chronological order, to obtain the sorting result.

[0068] S302, based on the sorting results, invoke the resource processing smart contract to process each real resource processing information in sequence and obtain the resource calculation results.

[0069] Optionally, the calculation rules contained in the resource processing smart contract can be invoked to calculate each real resource processing information in the sorted result sequentially, thereby obtaining the resource calculation result. Alternatively, the calculation rules contained in the resource processing smart contract can be invoked based on the business description information of the target business to calculate each real resource processing information in the sorted result sequentially, thereby obtaining the resource calculation result.

[0070] In this embodiment of the application, by sorting the real resource processing information according to the generated timestamp, the rationality of target service retransmission during resource calculation can be guaranteed, thereby ensuring the accuracy of resource calculation results.

[0071] Based on the above embodiments, the method for determining the resource calculation result is further refined in this embodiment. Specifically, based on the data query request, the parameters to be processed in each real resource processing information are determined; based on the sorting result, the resource processing function in the resource processing smart contract is called to process the parameters to be processed in each real resource processing information in turn to obtain the resource calculation result.

[0072] The so-called parameters to be processed are the actual resource parameters that need to be involved in resource calculation. For example, this could be the actual repayment amount. The so-called resource processing function is the function used for resource processing; for example, it could be the calculation function corresponding to the calculation logic in the tax calculation rules.

[0073] Understandably, since real resource processing information contains various types of data, such as resource parameters, generation timestamps, and business action identifiers, in order to save computing resources, the parameters to be processed in each piece of real resource processing information can be determined based on the corresponding resource parameter identifier in the data query request before calculation.

[0074] For example, if the resource parameter is identified as a repayment resource identifier, the repayment resource identifier can be used as an index to query the actual resource processing information, obtain the repayment parameter in the actual resource processing information, and use the repayment parameter as a parameter to be processed.

[0075] Furthermore, after determining the parameters to be processed in each real resource processing information, the resource processing function in the resource processing smart contract can be called to calculate the parameters to be processed in each real resource processing information in the sorting result in turn, thereby obtaining the resource calculation result.

[0076] In this embodiment of the application, by first determining the parameters to be processed in the real resource processing information, and then calling the resource processing function to process the parameters to be processed in sequence, the resource calculation result can be obtained, which can reduce the computing power consumption in the calculation process and improve the efficiency of resource calculation.

[0077] Based on the above embodiments, this application provides an optional method for information acquisition, such as... Figure 4 As shown, the specific steps include:

[0078] S401, obtain a snapshot of the business status associated with the target business.

[0079] A business status snapshot is a snapshot that represents the resource processing status of a target business at a specific moment. To ensure computational efficiency, a business status snapshot can be saved at the corresponding moment in a preset snapshot generation cycle and stored in a preset snapshot cache. For example, the business status snapshot can be saved daily at 1 AM, then hashed, and the hash result stored on the blockchain.

[0080] Optionally, the latest business status snapshot associated with the target business can be obtained from the snapshot cache based on the business identifier in the data query request.

[0081] S402: Based on the snapshot generation time of the business status snapshot, retrieve the event ledger corresponding to the target business from the blockchain.

[0082] The snapshot generation time refers to the moment when a snapshot of the business state is generated. The actual resource processing information contained in the event ledger is the actual resource processing information generated after the snapshot generation time.

[0083] It is understandable that since the business status snapshot already contains the business status at a certain moment, there is no need to repeatedly obtain the actual resource processing information before the snapshot generation time. Instead, only the actual resource processing information after the snapshot generation time needs to be obtained.

[0084] Optionally, an event ledger containing real resource processing information generated by the target business after the snapshot generation time can be obtained from the blockchain based on the snapshot generation time of the business status snapshot.

[0085] In this embodiment of the application, a business status snapshot is introduced. By using the business status snapshot as a calculation benchmark, computing resources can be effectively saved and resource computing efficiency can be improved.

[0086] Based on the above embodiments, this application provides another optional method for determining resource calculation results. Specifically, it involves calling a resource processing smart contract to process the real resource processing information in the business state snapshot and event ledger to obtain the resource calculation results.

[0087] Optionally, before performing calculations, the parameters to be processed in each real resource processing information can be determined based on the resource parameter identifier corresponding to the data query request. Then, the resource processing function in the resource processing smart contract can be called to calculate the parameters to be processed in the real resource processing information sequentially based on the business state snapshot, thus obtaining the resource calculation result.

[0088] In this embodiment of the application, by processing the business status snapshot and the actual resource processing information generated after the business status snapshot is generated, the resource calculation result is obtained, which can improve the efficiency of resource calculation while ensuring the accuracy of the resource calculation result.

[0089] Based on the above embodiments, this application provides an optional method for updating smart contracts, specifically, in response to an update event for resource processing rules, updating the resource processing smart contract according to the resource processing logic in the update event.

[0090] Among them, the so-called resource processing rules are the calculation rules for resource processing, and the so-called resource processing logic is the calculation logic for resource processing.

[0091] Optionally, when there is a need to change resource processing rules, the rule management terminal corresponding to the resource processing rules can initiate an update event for the resource processing rules based on the updated resource processing logic corresponding to the resource processing rules.

[0092] Upon detecting an update event, the original resource processing logic in the resource processing smart contract can be updated based on the resource processing logic within the update event, resulting in an updated resource processing smart contract. At this point, the updated resource processing smart contract can be directly invoked to reprocess the actual resource processing information and obtain the resource calculation result. It is worth noting that no data migration or other operations are required during this process; simply recalculating the resources based on the updated resource processing smart contract is sufficient to obtain the resource calculation result.

[0093] Alternatively, based on the logical differences between the original resource processing logic in the resource processing smart contract and the resource processing logic in the update event, a target processing logic can be determined that can directly convert the resource calculation result based on the original resource processing logic into the resource calculation result based on the updated resource processing logic. Then, the target processing logic can be used as the resource calculation logic in the resource processing smart contract. At this point, the original resource calculation result can be directly updated using the target processing logic in the resource processing smart contract, resulting in a resource calculation result adapted to the changed resource processing rules.

[0094] In this embodiment of the application, by updating the resource processing smart contract, the real resource processing information stored in the blockchain can be recalculated using the updated resource processing smart contract to obtain resource calculation results that are compatible with the changed resource processing rules, thereby avoiding data migration and improving the efficiency of resource calculation.

[0095] Figure 5 This is a flowchart illustrating a resource processing method in another embodiment. Based on the above embodiments, this embodiment provides an optional example of a resource processing method. (In conjunction with...) Figure 5 The specific implementation process is as follows:

[0096] S501 responds to a data query request initiated by a data requester for a target business and retrieves the event ledger corresponding to the target business from the blockchain.

[0097] The event ledger contains real resource processing information corresponding to at least one user business event for the target business.

[0098] S502, based on the generation timestamp of each real resource processing information in the event ledger, sort the real resource processing information to obtain the sorting result.

[0099] S503, based on the data query request, determine the parameters to be processed in each real resource processing information.

[0100] S504: Based on the sorting results, the resource processing function in the resource processing smart contract is called to process the parameters to be processed in each real resource processing information in turn, and the resource calculation results are obtained.

[0101] Optionally, a snapshot of the business status associated with the target business can also be obtained; based on the snapshot generation time of the business status snapshot, the event ledger corresponding to the target business can be obtained from the blockchain; wherein, the actual resource processing information contained in the event ledger is the actual resource processing information generated after the snapshot generation time.

[0102] Furthermore, the resource processing smart contract is invoked to process the actual resource processing information in the business state snapshot and event ledger to obtain the resource calculation results.

[0103] Optionally, in response to an update event for resource processing rules, the resource processing smart contract is updated according to the resource processing logic in the update event.

[0104] The specific processes of S501-S504 described above can be found in the description of the above method embodiments. Their implementation principles and technical effects are similar, and will not be repeated here.

[0105] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed 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 performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0106] Based on the same inventive concept, this application also provides a resource processing apparatus for implementing the resource processing method described above. The solution provided by this apparatus is similar to the implementation scheme described in the above method; therefore, the specific limitations in one or more resource processing apparatus embodiments provided below can be found in the limitations of the resource processing method described above, and will not be repeated here.

[0107] In one exemplary embodiment, such as Figure 6 As shown, a resource processing device 1 is provided, including: an acquisition module 10 and a calculation module 20, wherein:

[0108] The acquisition module 10 is used to respond to a data query request initiated by a data requester for a target business and obtain the event ledger corresponding to the target business from the blockchain; wherein, the event ledger contains real resource processing information corresponding to at least one user business event for the target business;

[0109] The calculation module 20 is used to call the resource processing smart contract, process the real resource processing information in the event ledger, obtain the resource calculation results, and feed back the resource calculation results to the data requester.

[0110] In an exemplary embodiment, when the event ledger contains at least two pieces of real resource processing information, the calculation module 20 is specifically used for:

[0111] Based on the generation timestamps of each real resource processing information, the information is sorted to obtain a sorting result. Based on the sorting result, the resource processing smart contract is invoked to process each piece of real resource processing information in turn to obtain the resource calculation result.

[0112] In one exemplary embodiment, the computing module 20 is further configured to:

[0113] Based on the data query request, determine the parameters to be processed in each real resource processing information; based on the sorting results, call the resource processing function in the resource processing smart contract to process the parameters to be processed in each real resource processing information in turn, and obtain the resource calculation results.

[0114] In an exemplary embodiment, the acquisition module 10 is specifically used for:

[0115] Obtain a snapshot of the business status associated with the target business; based on the snapshot generation time of the business status snapshot, obtain the event ledger corresponding to the target business from the blockchain; wherein, the actual resource processing information contained in the event ledger is the actual resource processing information generated after the snapshot generation time.

[0116] In one exemplary embodiment, the computing module 20 is further configured to:

[0117] The resource processing smart contract is invoked to process the actual resource processing information in the business state snapshot and event ledger to obtain the resource calculation results.

[0118] In an exemplary embodiment, the resource processing apparatus 1 further includes an update module, wherein the update module is used to:

[0119] In response to an update event for resource processing rules, the resource processing smart contract is updated according to the resource processing logic in the update event.

[0120] Each module in the aforementioned resource processing device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the memory of a computer device as software, so that the processor can call and execute the operations corresponding to each module.

[0121] In one exemplary embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 7As shown, this computer device includes a processor, memory, input / output interfaces (I / O), and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The database stores actual resource processing data. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communicating with external terminals via a network connection. When the computer program is executed by the processor, it implements a resource processing method.

[0122] Those skilled in the art will understand that Figure 7 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0123] In one embodiment, a computer device is also provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in the above method embodiments.

[0124] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon that, when executed by a processor, implements the steps in the above method embodiments.

[0125] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in the above method embodiments.

[0126] It should be noted that the data involved in this application (including but not limited to real resource processing data) are all data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.

[0127] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.

[0128] The technical features of the above embodiments can be combined in any way. For the sake of brevity, 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, they should be considered to be within the scope of this application.

[0129] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A resource processing method, characterized in that, The method includes: In response to a data query request initiated by a data requester for a target business, the event ledger corresponding to the target business is obtained from the blockchain; wherein, the event ledger contains real resource processing information corresponding to at least one user business event for the target business; The resource processing smart contract is invoked to process the actual resource processing information in the event ledger, obtain the resource calculation result, and then feed back the resource calculation result to the data requester.

2. The method according to claim 1, characterized in that, When the event ledger contains at least two pieces of real resource processing information, the invocation of the resource processing smart contract processes the real resource processing information in the event ledger to obtain resource calculation results, including: Based on the generation timestamp of each real resource processing information, sort the real resource processing information to obtain the sorting result; Based on the sorting results, the resource processing smart contract is invoked to process each real resource processing information in turn, thereby obtaining the resource calculation results.

3. The method according to claim 2, characterized in that, The step involves invoking a resource processing smart contract based on the sorting result to process each real resource processing information sequentially, thereby obtaining resource calculation results, including: Based on the data query request, determine the parameters to be processed in each real resource processing information; Based on the sorting results, the resource processing function in the resource processing smart contract is called to process the parameters to be processed in each real resource processing information in turn, and the resource calculation results are obtained.

4. The method according to claim 1, characterized in that, The step of obtaining the event ledger corresponding to the target business from the blockchain includes: Obtain a snapshot of the business status associated with the target business; Based on the snapshot generation time of the business status snapshot, the event ledger corresponding to the target business is obtained from the blockchain; wherein, the actual resource processing information contained in the event ledger is the actual resource processing information generated after the snapshot generation time.

5. The method according to claim 4, characterized in that, The resource processing smart contract is invoked to process the actual resource processing information in the event ledger to obtain resource calculation results, including: The resource processing smart contract is invoked to process the business state snapshot and the actual resource processing information in the event ledger to obtain the resource calculation result.

6. The method according to any one of claims 1-5, characterized in that, The method further includes: In response to an update event for resource processing rules, the resource processing smart contract is updated according to the resource processing logic in the update event.

7. A resource processing device, characterized in that, The device includes: The acquisition module is used to respond to a data query request initiated by a data requester for a target business and to obtain the event ledger corresponding to the target business from the blockchain; wherein, the event ledger contains real resource processing information corresponding to at least one user business event for the target business; The calculation module is used to invoke the resource processing smart contract to process the real resource processing information in the event ledger, obtain the resource calculation result, and feed back the resource calculation result to the data requester.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.