Cache data processing method and device, electronic equipment and storage medium

By using cache annotation parsing and cache manager selection methods in the financial technology system, the problem of low efficiency in cache data processing under high concurrency is solved, and more efficient cache data processing and user experience improvement is achieved.

CN120162279APending Publication Date: 2025-06-17CHINA PING AN PROPERTY INSURANCE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510312139.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-14
Publication Date
2025-06-17

AI Technical Summary

Technical Problem

In the financial technology scenario, when processing cached data, the system faces timeout requests and white screen problems caused by high concurrency user surges, which affects the user experience.

Method used

A cache data processing method is proposed. By calling the target method with cache annotation in response to operation instructions, cache annotation analysis is performed, the appropriate cache manager (secondary cache manager or local cache manager) is selected, and the cache processing method is called through the target cache manager to perform data processing.

Benefits of technology

It improves the processing efficiency of cached data, enhances the system's response ability to cached data, improves user experience, and solves the problems of cache uniformity and data consistency through the cluster local cache synchronization function.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120162279A_ABST
    Figure CN120162279A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a cache data processing method and device, electronic equipment and a storage medium, belongs to the field of data processing, and can be applied to financial science and technology and medical health scenes. The method comprises the steps that a system method is called in response to an operation instruction, a target method is obtained, and the target method is a method with a cache annotation; the target method is subjected to cache annotation analysis processing, an analysis result is obtained, and the analysis result comprises cache data and cache configuration; cache manager selection processing is conducted on the cache data according to the cache configuration, a target cache manager is obtained, and the cache manager comprises a second-level cache manager and a local cache manager; and calling a cache processing method through the target cache manager to carry out data processing on the cache data to obtain a processing result. The embodiment of the invention can be applied to business platforms such as financial science and technology and medical health care, can improve the processing efficiency of cache data, and can be widely applied to the field of data processing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of data processing and the field of fintech, and particularly relates to a method, apparatus, electronic device, and storage medium for processing cached data. Background Art

[0002] With the rapid development of computer technology, the functions of applications or systems are becoming more and more powerful, supporting functions such as shopping, social networking, interactive games, and resource transfer. At the same time, the amount of data that applications or systems need to process is also increasing. In the fintech scenario, it is necessary to cache insurance data so that the system can respond to user operations faster. Currently, when processing cached data, when the system activity encounters a surge in users, it will cause a large number of timeout requests and even a white screen, affecting the user experience. Therefore, how to improve the processing efficiency of cached data has become a technical problem to be solved urgently. Summary of the Invention

[0003] The main purpose of the embodiments of this application is to propose a method, apparatus, electronic device, and storage medium for processing cached data, aiming to improve the processing efficiency of cached data.

[0004] To achieve the above object, on the one hand, the embodiments of this application propose a method for processing cached data, and the method includes:

[0005] Invoking and processing the system method in response to an operation instruction to obtain a target method, where the target method is a method with a cache annotation;

[0006] Performing cache annotation parsing processing on the target method to obtain a parsing result, where the parsing result includes cached data and cache configuration;

[0007] Performing cache manager selection processing on the cached data according to the cache configuration to obtain a target cache manager, and the cache manager includes a secondary cache manager and a local cache manager;

[0008] Invoking a cache processing method through the target cache manager to perform data processing on the cached data to obtain a processing result.

[0009] In some embodiments, the performing cache annotation parsing processing on the target method to obtain a parsing result includes:

[0010] Intercepting and parsing the target method through a cache aspect to obtain a cache annotation;

[0011] Performing execution processing on the target method according to the cache annotation to obtain the cached data;

[0012] Performing configuration data matching processing on the cache annotation to obtain the cache configuration.

[0013] In some embodiments, the cache manager selection process for the cache data according to the cache configuration to obtain a target cache manager includes:

[0014] Determine the cache type of the cache data according to the cache configuration, where the cache type includes a first-level cache and a second-level cache;

[0015] When the cache type is a first-level cache, select the local cache manager as the target cache manager, and the local cache manager is used to access the local cache;

[0016] When the cache type is a second-level cache, select the second-level cache manager as the target cache manager, and the target cache manager is used to access the local cache and the cache database.

[0017] In some embodiments, the data processing of the cache data by invoking a cache processing method through the target cache manager to obtain a processing result includes:

[0018] Perform a method matching process on the target cache manager according to the cache configuration to obtain the cache processing method, where the cache processing method includes a data operation method, a cluster metric viewing method, and a cluster synchronization method;

[0019] Perform data operation processing on the cache data according to the data operation method to obtain the processing result;

[0020] Alternatively, perform metric statistics processing on the cache data according to the cluster metric viewing method to obtain the processing result;

[0021] Alternatively, perform cluster cache synchronization processing on the cache data according to the cluster synchronization method to obtain the processing result.

[0022] In some embodiments, the metric statistics processing of the cache data according to the cluster metric viewing method to obtain the processing result includes:

[0023] Obtain a client instance, and obtain a service instance list according to the client instance;

[0024] Perform metric calculation processing on the local cache according to the cache data to obtain metric data of each storage node;

[0025] Aggregate the metric data of each storage node according to the service instance list to obtain the processing result.

[0026] In some embodiments, the cluster cache synchronization processing of the cache data according to the cluster synchronization method to obtain the processing result includes:

[0027] Obtain a client instance, and obtain a service instance list according to the client instance;

[0028] Traverse and search the service instance list according to the cache data to obtain a target address;

[0029] Synchronize the cache data in the local cache according to the target address to obtain the processing result.

[0030] In some embodiments, after aggregating the metric data of each storage node according to the service instance list to obtain the processing result, it further includes:

[0031] Create a cache access point according to the metric data;

[0032] Perform an interface call on the processing result according to the cache access point to obtain the metric data.

[0033] To achieve the above object, another aspect of the embodiments of the present application proposes a cache data processing device, which is applied to the cache data processing method as described above. The device includes:

[0034] A first module, configured to call and process a system method in response to an operation instruction to obtain a target method, where the target method is a method with a cache annotation;

[0035] A second module, configured to perform cache annotation parsing processing on the target method to obtain a parsing result, where the parsing result includes cache data and cache configuration;

[0036] A third module, configured to select a cache manager for the cache data according to the cache configuration to obtain a target cache manager, where the cache manager includes a secondary cache manager and a local cache manager;

[0037] A fourth module, configured to call a cache processing method through the target cache manager to process the cache data to obtain a processing result.

[0038] In some embodiments, the second module, configured to perform cache annotation parsing processing on the target method to obtain a parsing result, includes the following units:

[0039] A first unit, configured to intercept and parse the target method through a cache aspect to obtain a cache annotation;

[0040] A second unit, configured to execute the target method according to the cache annotation to obtain the cache data;

[0041] The third unit is used to perform configuration data matching processing on the cache annotation to obtain the cache configuration.

[0042] In some embodiments, the third module is used to perform cache manager selection processing on the cache data according to the cache configuration to obtain a target cache manager, including the following units:

[0043] The fourth unit is used to determine the cache type of the cache data according to the cache configuration, and the cache type includes a first-level cache and a second-level cache;

[0044] The fifth unit is used to select the local cache manager as the target cache manager when the cache type is the first-level cache, and the local cache manager is used to access the local cache;

[0045] The sixth unit is used to select the second-level cache manager as the target cache manager when the cache type is the second-level cache, and the target cache manager is used to access the local cache and the cache database.

[0046] In some embodiments, the fourth module is used to call a cache processing method through the target cache manager to perform data processing on the cache data to obtain a processing result, including:

[0047] The seventh unit is used to perform method matching processing on the target cache manager according to the cache configuration to obtain the cache processing method, and the cache processing method includes a data operation method, a cluster metric viewing method, and a cluster synchronization method;

[0048] The eighth unit is used to perform data operation processing on the cache data according to the data operation method to obtain the processing result;

[0049] The ninth unit is used to perform metric statistical processing on the cache data according to the cluster metric viewing method to obtain the processing result;

[0050] The tenth unit is used to perform cluster cache synchronization processing on the cache data according to the cluster synchronization method to obtain the processing result.

[0051] In some embodiments, the ninth unit is used to perform metric statistical processing on the cache data according to the cluster metric viewing method to obtain the processing result, including:

[0052] The first subunit is used to obtain a client instance and obtain a service instance list according to the client instance;

[0053] The second subunit is used to perform metric calculation processing on the local cache according to the cache data to obtain metric data of each storage node;

[0054] A third sub - unit, configured to aggregate the metric data of each storage node according to the service instance list to obtain the processing result.

[0055] In some embodiments, the tenth unit, configured to perform cluster cache synchronization processing on the cache data according to the cluster synchronization method to obtain the processing result, includes:

[0056] A fourth sub - unit, configured to obtain a client instance and obtain a service instance list according to the client instance;

[0057] A fifth sub - unit, configured to perform a traversal search process on the service instance list according to the cache data to obtain a target address;

[0058] A sixth sub - unit, configured to perform a synchronization operation process on the cache data in the local cache according to the target address to obtain the processing result.

[0059] In some embodiments, after the ninth unit, an eleventh unit may further be included, configured to:

[0060] Create a cache access point according to the metric data;

[0061] Perform an interface call process on the processing result according to the cache access point to obtain the metric data.

[0062] On the other hand, to achieve the above object, an embodiment of the present application provides an electronic device, where the electronic device includes a memory and a processor, the memory stores a computer program, and when the processor executes the computer program, the cache data processing method as described above is implemented.

[0063] On yet another hand, to achieve the above object, an embodiment of the present application provides a computer - readable storage medium, where the computer - readable storage medium stores a computer program, and when the computer program is executed by a processor, the cache data processing method as described above is implemented.

[0064] A method, apparatus, electronic device, and storage medium for processing cached data proposed in this application call and process system methods in response to operation instructions to obtain target methods, and can annotate methods through cache annotations, enabling quick identification of methods that need to process cached data and improving the system's response efficiency to cached data. In addition, this solution performs cache annotation parsing processing on the target method to obtain a parsing result, and performs cache manager selection processing on the cached data according to the cache configuration to obtain a target cache manager, which can solve the problem of cache singularity by adding a secondary cache function. Moreover, this solution calls a cache processing method through the target cache manager to process the cached data, and can increase the cluster local cache synchronization function through the cache processing method to synchronize the local cache within the cluster, improving the processing efficiency of cached data and enhancing the user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0065] To more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for the description of the embodiments of the present invention. Obviously, the following drawings are only some embodiments of the present invention, and those of ordinary skill in the art can obtain other drawings without creative efforts based on these drawings.

[0066] Figure 1 is a schematic diagram of the application environment of a method for processing cached data provided by an embodiment of this application;

[0067] Figure 2 is a flowchart of a method for processing cached data provided by an embodiment of this application;

[0068] Figure 3 is Figure 2 a flowchart of step S202 in

[0069] Figure 4 is Figure 2 a flowchart of step S203 in

[0070] Figure 5 is Figure 2 a flowchart of step S204 in

[0071] Figure 6 is Figure 5 a flowchart of step S503 in

[0072] Figure 7 is Figure 5 a flowchart of step S504 in

[0073] Figure 8 is a schematic structural diagram of a device for processing cached data provided by an embodiment of this application;

[0074] Figure 9 It is a schematic diagram of the hardware structure of the electronic device provided by the embodiments of the present application. Detailed implementation manners

[0075] In order to make the objectives, technical solutions and advantages of the present application clearer, 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.

[0076] It should be noted that although the functional modules are divided in the device schematic diagram and the logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different module division in the device or a different order in the flowchart. Terms such as "first" and "second" in the description, claims and the above-mentioned drawings are used to distinguish similar objects and do not necessarily need to describe a specific order or sequence.

[0077] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the technical field to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.

[0078] First, several nouns involved in the present application are analyzed:

[0079] Local cache is a technology used to improve the data access speed. It stores a part of the data in the physical memory of the client locally for quick access when needed. Local cache is usually used to buffer the data written back from the client to the server to reduce the read / write pressure on the server and the network load.

[0080] The Spring framework is a Java development platform that provides a comprehensive programming and configuration model, supporting multiple functions and integrations, including inversion of control (IoC), aspect-oriented programming (AOP), data access abstraction, transaction management, etc., aiming to simplify the development, deployment and management of enterprise-level applications.

[0081] As described in the background art section, in the related art, when data processing is performed through the system local cache framework, in fintech or medical service scenarios, such as limited-time coupon grabbing in the coupon center and registration in the medical center, access to cached data is required. When the system activities encounter a surge in users, a large number of timeout requests or even blank screens will occur, affecting the user experience. Exemplarily, in the insurance application page, after the operation updates the insurance label configuration, users still see the old labels for a period of time because the local cache is distributed on different machines and the local cache within the cluster is not synchronized, resulting in inconsistent cache obtained by accessing different machines. Additionally, when viewing the local cache occupancy and hit rate of insurance information, each machine needs to be checked one by one, which is inefficient, and the information such as the local cache usage and cache hit rate in the cluster environment is not intuitive. Moreover, the insurance list only supports first-level cache, with cache singularity, and does not support second-level cache. If the local cache fails collectively, it is easy to cause cache penetration, leading to the risk of database downtime.

[0082] Based on this, the embodiments of the present application provide a method, device, electronic device, and storage medium for caching data processing, aiming to improve the processing efficiency of cached data.

[0083] The method, device, electronic device, and storage medium for caching data processing provided by the embodiments of the present application are specifically described through the following embodiments. First, the data processing method in the embodiments of the present application is described.

[0084] The method for caching data processing provided by the embodiments of the present application can be applied in an application environment such as Figure 1 where the client 101 communicates with the server 102 through the network. The server can receive the user's operation instructions through the client, call and process the system method in response to the operation instructions to obtain the target method, where the target method is a method with a cache annotation; perform cache annotation parsing processing on the target method to obtain the parsing result, where the parsing result includes cached data and cache configuration; perform cache manager selection processing on the cached data according to the cache configuration to obtain the target cache manager, where the cache manager includes a second-level cache manager and a local cache manager; call the cache processing method through the target cache manager to perform data processing on the cached data to obtain the processing result, and return the processing result to the client. By calling the cache processing method through the target cache manager to perform data processing on the cached data, the embodiments of the present application can synchronize the local cache within the cluster by adding the cluster local cache synchronization function through the cache processing method, improve the processing efficiency of the cached data, and enhance the user experience.

[0085] A cache data processing method provided by an embodiment of the present application relates to the technical field of data processing, can be applied to the fintech scenario, and can also be applied to the medical service scenario, and can improve the data processing efficiency of the system in the scenario. The cache data processing method provided by the embodiment of the present application can be applied to a terminal, or to a server side, or can also be software running on the terminal or the server side. In some embodiments, the terminal can be a smart phone, a tablet computer, a laptop computer, a desktop computer, etc.; the server side can be configured as an independent physical server, or can be configured as a server cluster or a distributed system composed of multiple physical servers, or can also be configured as a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms; the software can be an application that implements a cache data processing method, etc., but is not limited to the above forms.

[0086] The present application can be used in many general or specific computer system environments or configurations. For example: personal computers, server computers, handheld or portable devices, tablet devices, multi-processor systems, microprocessor-based systems, set-top boxes, programmable consumer electronic devices, network PCs, minicomputers, mainframe computers, distributed computing environments including any of the above systems or devices, and so on. The present application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform specific tasks or implement specific abstract data types. The present application can also be practiced in a distributed computing environment, where tasks are performed by remote processing devices connected through a communication network. In a distributed computing environment, program modules can be located in local and remote computer storage media including storage devices.

[0087] It should be noted that in each specific embodiment of the present application, when it comes to relevant processing that needs to be carried out based on data related to the user's identity or characteristics such as user information, user behavior data, user historical data, and user location information, the user's permission or consent will be obtained first. Moreover, the collection, use, and processing of these data, etc., will comply with relevant laws, regulations, and standards. In addition, when the embodiment of the present application needs to obtain the user's sensitive personal information, the user's separate permission or separate consent will be obtained through methods such as pop-up windows or jumping to a confirmation page. After clearly obtaining the user's separate permission or separate consent, the necessary user-related data for the normal operation of the embodiment of the present application will be obtained.

[0088] Please refer to Figure 2 , Figure 2It is an alternative flowchart of a cache data processing method provided by an embodiment of the present application. Figure 2 The method in

[0089] Step S201: In response to an operation instruction, call and process a system method to obtain a target method, where the target method is a method with a cache annotation.

[0090] Step S202: Perform cache annotation parsing processing on the target method to obtain a parsing result, where the parsing result includes cache data and cache configuration.

[0091] Step S203: Perform cache manager selection processing on the cache data according to the cache configuration to obtain a target cache manager. The cache manager includes a secondary cache manager and a local cache manager.

[0092] Step S204: Call a cache processing method through the target cache manager to perform data processing on the cache data to obtain a processing result.

[0093] Steps S201 to S204 as shown in the embodiment of the present application can be applied to the field of data processing technology and are applicable to data processing scenarios such as financial scenarios and medical scenarios. The system processes cache data. In a possible implementation, the cache data is medical data, such as personal health records, prescriptions, inspection reports, etc. For example, in the field of insurance applications, users often perform business handling operations such as coupon redemption by logging in to the system. Cache data will be generated during the login process or other business handling processes. Processing the cache data can improve the efficiency of insurance business handling and the user experience.

[0094] The embodiment of the present application first obtains an operation instruction to call and process a system method to obtain a target method. The operation instruction includes the user's interaction operation with the client. The operation instruction can include operations that need to process cache data, such as query operations, delete operations, etc. The interaction operation is obtained by the user's click, input, etc. on the interaction interface of the client, and can also include operations such as the system's analysis and processing of the data input by the user. The input data can include voice data, image data, etc.

[0095] For example, the embodiments of the present application are applied to the process of handling loan services in a bank. A user interacts with the bank system by inputting an operation instruction. The server can call a system method in the server according to the operation instruction returned by the client to obtain a target method, which is a method with a cache annotation and is used to access or process cache data. For example, when a user needs to view the loan amount and inputs the corresponding operation instruction to the server, the server will call the data processing method for viewing the loan amount. At this time, the loan amount can be used as cache data, and this method will be pre - annotated with a cache annotation. By parsing the cache annotation of the target method, a corresponding parsing result can be obtained according to the cache annotation parsing. The parsing result includes cache data and cache configuration. The cache data is the data that the target method needs to access or process, that is, the loan amount that the user needs to query. The cache configuration is the configuration data corresponding to the cache data, which may include the life cycle of the cache data, cache policies, etc. Then, according to the cache configuration, cache manager selection processing is performed on the cache data. A target cache manager can be selected from a secondary cache manager and a local cache manager, and the corresponding cache processing method is called through the target cache manager to process the cache data to obtain a processing result. Moreover, in the embodiments of the present application, a corresponding cache processing method is added to the corresponding target cache manager. By adding a cluster local cache synchronization function, the problem of out - of - sync local caches within the cluster can be solved. Additionally, a cluster metric statistics function can be added to solve the problem of non - intuitive local cache metrics within the cluster, thereby improving the processing efficiency of cache data.

[0096] As can be seen from the above solution, in the embodiments of the present application, the cache processing method can, by parsing the cache annotation of the target method, select a corresponding target cache manager according to the parsing result, and thus call the corresponding processing method through the target cache manager to process the cache data, improving the processing efficiency of the cache data. Moreover, by pre - annotating the target method with a cache annotation in the embodiments of the present application, the cache data that needs to be processed can be quickly found, improving the user experience.

[0097] In step S201 of some embodiments, in response to an operation instruction, a system method is called and processed to obtain a target method, where the target method is a method with a cache annotation;

[0098] In the embodiments of the present application, an operation instruction is an instruction for accessing or processing cached data. For example, in the business scenario of registering at a medical center, registration is completed by performing corresponding interactive operations on the registration page of the client. During this process, relevant information needs to be filled in. At this time, cached data can be used to improve the data filling efficiency. For example, during the registration and login processes of the client, the user has filled in relevant user information, and these user information can be stored as cached data in the local cache. The local cache can be the physical memory or other storage media of the client. When filling in relevant data on the registration page, cached data can be obtained for automatic filling, thereby improving the response efficiency of the system. And obtaining cached data requires calling a system method through the server. The system method is used to process the data in the system. In this feasible embodiment, it is necessary to obtain cached data. The cached data can be medical electronic records, electronic personal health records, including a series of electronic records such as medical records, electrocardiograms, and medical images that have the value of being saved for future reference. The target method is called to obtain the cached data, and the target method has corresponding cache annotations. The embodiments of the present application can quickly find the target method for processing relevant cached data through cache annotations, which can accelerate the response speed of the system and improve the processing efficiency of cached data.

[0099] Please refer to Figure 3 , in step S202 of some embodiments, the cache annotation parsing process for the target method to obtain a parsing result includes:

[0100] Step S301, intercept and parse the target method through a cache aspect to obtain a cache annotation;

[0101] Step S302, perform an execution process on the target method according to the cache annotation to obtain the cached data;

[0102] Step S303, perform a configuration data matching process on the cache annotation to obtain the cache configuration.

[0103] In the embodiments of the present application, by performing a cache annotation parsing process on the target method, a parsing result is obtained. The parsing result includes cached data and a cache configuration. Among them, the target method is used to perform corresponding processing on the cached data, such as querying, modifying, adding, deleting, etc. The embodiments of the present application can add corresponding cache annotations to the target method in advance. The cache annotation can be added to the corresponding code of each target method and does not affect the running process of the code. The cache annotation is used to mark the processing of cached data and the corresponding cached data and cache configuration data, etc., which can be written according to the actual situation. The writing rules are not limited here. By parsing the cache annotation, the cached data to be processed and the cache configuration corresponding to the cached data can be obtained.

[0104] In step S301 of some embodiments, the target method is intercepted and parsed through a cache aspect to obtain cache annotations.

[0105] In the embodiments of the present application, Spring AOP (Aspect-Oriented Programming) can be used to create a cache aspect. This cache aspect will intercept all methods annotated with cache annotations, that is, the target method is intercepted through the cache aspect, and then the code of the target method is parsed to obtain cache annotations. Exemplarily, through the configuration class or the automatic configuration mechanism of the framework, reflection technology can be used to traverse the specified package or class path to find all classes and methods annotated with cache annotations (such as @Cacheable), and these annotations are parsed to identify which method results need to be cached.

[0106] For example, in the loan business of a banking system, a user needs to query the loan amount and perform a repayment operation. At this time, querying and modifying the loan amount are required. By caching the loan amount data, the cached data can be temporarily stored in memory or other high-speed storage media for quick access and reading of data. The server can determine the target methods to be called through the corresponding interaction operations with the user, such as data query methods and amount repayment methods. These methods will access the cached data, that is, the loan amount. By pre-annotating with cache annotations and creating a cache aspect on the server side, data query methods and amount repayment methods annotated with cache annotations can be intercepted. By parsing the cache annotations of the target methods, the cached data to be processed can be identified, and the processing results can be cached, etc.

[0107] In step S302 of some embodiments, the target method is executed according to the cache annotations to obtain the cached data.

[0108] In the embodiments of the present application, the parameters required by the target method can be obtained according to the cache annotations, and then the target method is executed according to the input parameters. The target method directly obtains data from the cache. If the cache hits, the value in the cache is directly returned to obtain the cached data; if the cache misses, the target method is executed, and the result is stored in the cache, and the result is used as the cached data.

[0109] For example, in the process of handling the business of querying the loan amount, the target method is a data query method used to obtain the loan amount and display it to the user. At this time, the parameters required by the data query method may include data such as the loan contract number, repayment card number, and loan product type. The loan amount is queried based on these parameters. At this time, the corresponding value will be first searched in the cache. The cache can be local memory or other storage media. If a hit occurs in the cache, the value in the cache is directly returned to obtain the cache data. If the cache is not hit, the target method is executed to query the value of the loan amount, and the value of the loan amount is stored in the cache, and the loan amount is used as the cache data.

[0110] In step S303 of some embodiments, the cache annotation is processed for configuration data matching to obtain the cache configuration.

[0111] In the embodiments of the present application, the configuration data can be directly read from the annotation information by matching through the cache annotation. The cache configuration usually includes the name of the cache, the key generation strategy of the cache, the expiration time of the cache, etc. It is also possible to match the corresponding configuration information from the configuration file according to the information in the annotation, so as to use the matched configuration information as the cache configuration. For example, the relevant position of the configuration information is marked in the cache annotation, and the corresponding cache configuration can be matched from the configuration file according to the location of the configuration information. It is also possible to pre-mark the configuration data in the configuration file and match the corresponding cache configuration according to the marking symbol in the cache annotation.

[0112] One of the technical solutions in the above technical solutions has the following advantages or beneficial effects: In the embodiments of the present application, the cache aspect intercepts and parses the target method to obtain the cache annotation, and the cache data and cache configuration can be quickly obtained through the cache annotation, improving the processing efficiency of the cache data.

[0113] Please refer to Figure 4 , in step S203 of some embodiments, the cache data is processed by the cache manager selection according to the cache configuration to obtain the target cache manager, including:

[0114] Step S401, determining the cache type of the cache data according to the cache configuration, where the cache type includes a first-level cache and a second-level cache;

[0115] Step S402, when the cache type is a first-level cache, select the local cache manager as the target cache manager, and the local cache manager is used to access the local cache;

[0116] Step S403, when the cache type is the secondary cache, select the secondary cache manager as the target cache manager, and the target cache manager is used to access the local cache and the cache database.

[0117] In the embodiments of the present application, the cache configuration is the relevant configuration information of the cached data, including the cache data name, cache data type, cache policy, etc. The cache type of the cached data can be obtained by parsing the cache configuration. Among them, the cache type is used to select the target cache manager. In the embodiments of the present application, the cache managers include the local cache manager and the secondary cache manager. Different cache managers can be selected according to different cache types, and different processing methods can be called according to the target cache manager to process the cached data.

[0118] In step S401 of some embodiments, the cache type can indicate the cache location of the cached data, and is used to select the target cache manager from the cache managers. In the embodiments of the present application, the cache managers include the local cache manager and the secondary cache manager, and different cache managers are selected as the target cache manager according to different cache types. For example, the primary cache is used to match the local cache manager, and the secondary cache is used to match the secondary cache manager.

[0119] In step S402 of some embodiments, when the cache type is the primary cache, select the local cache manager as the target cache manager. Through the local cache manager, the local cache can be accessed. The local cache is used to temporarily store frequently accessed data in the memory within the application process. By placing the data frequently queried by users in the local cache (memory), users do not need to query the data from the disk, but directly query the corresponding data from the cache, thereby improving the query efficiency and solving the performance problem of the high-concurrency system.

[0120] In step S403 of some embodiments, when the cache type is the secondary cache, select the secondary cache manager as the target cache manager. Through the secondary cache manager, the local cache and the cache database can be accessed. For example, when a user needs to obtain a certain data, first obtain it from the local cache through the secondary cache manager. If the data does not exist in the local cache, obtain it from the cache database. Among them, the cache database can adopt the Redis database. By using the Redis database, the read and write speed can be improved, which is especially suitable for high-frequency access scenarios, and supports a distributed architecture. Horizontal expansion can be achieved through master-slave replication, sharding technology, etc., and it can easily handle scenarios where the data volume surges, such as e-commerce promotion scenarios, etc.

[0121] One of the technical solutions in the above technical solutions has the following advantages or beneficial effects: In the embodiment of the present application, different target cache managers can be selected according to the cache type, and different processing methods can be called according to the target cache manager to process the cache data, improving the processing efficiency of the cache data. And by using the cache database as the secondary cache, the problem of cache singularity is solved.

[0122] Please refer to Figure 5 , in step S204 of some embodiments, the data processing of the cache data by calling the cache processing method through the target cache manager to obtain a processing result includes:

[0123] Step S501, perform method matching processing on the target cache manager according to the cache configuration to obtain the cache processing method, where the cache processing method includes a data operation method, a cluster metric viewing method, and a cluster synchronization method;

[0124] Step S502, perform data operation processing on the cache data according to the data operation method to obtain the processing result;

[0125] Step S503, or perform metric statistical processing on the cache data according to the cluster metric viewing method to obtain the processing result;

[0126] Step S504, or perform cluster cache synchronization processing on the cache data according to the cluster synchronization method to obtain the processing result.

[0127] In the embodiment of the present application, the target cache manager is one of the local cache manager and the secondary cache manager. The cache processing method is used to process the cache data, including processing methods such as obtaining the cache data, deleting the cache data, and setting the cache data. By calling the corresponding cache processing method through the target cache manager to process the cache data, the final processing result is obtained, such as obtaining the cache data.

[0128] In step S501 of some embodiments, the corresponding cache processing method can be matched through the cache configuration. For example, if the cache configuration includes the name of the cache processing method to be called, the corresponding cache processing method can be matched according to this name, so as to perform corresponding data processing on the cache data according to the cache processing method. In the embodiment of the present application, the cache processing method includes a data operation method, a cluster metric viewing method, and a cluster synchronization method. The data operation method is used to perform processing such as adding, deleting, modifying, and querying on the cache data. The cluster metric viewing method is used to obtain the local memory usage metrics for storing the cache data in all machines in the cluster. The cluster synchronization method is used to synchronize the cache data in the cluster, such as deleting the local cache data in the cluster.

[0129] In step S502 of some embodiments, the data operation method may include methods such as obtaining cache (get), deleting cache (evict), setting cache (put), etc. These methods may be defined or rewritten in the cache processing class, and different cache strategies and implementations may be satisfied by rewriting these methods. For example, double-check locking may be used to ensure that only one thread loads cache data in a high-concurrency environment, while other threads wait for the result, or a built-in automatic data loading mechanism, exception handling, or fallback mechanism may be used.

[0130] In step S503 of some embodiments, the cluster indicator viewing method is used to obtain local memory usage indicators for storing cache data in all machines in the cluster. These indicators may include hit rate, miss rate, number of cache items, memory usage, expiration policy execution status, and other indicators.

[0131] In step S504 of some embodiments, a cluster synchronization method is used to synchronize cached data within a cluster, such as deleting or updating a local cache within a cluster. In a distributed system, it is easy for cached data within a cluster to be out of sync, which can be manifested as node B still holding the old version of data after business node A updates the local cache. For example, in an e-commerce flash sale scenario, after node A deducts inventory, node B may continue to sell sold-out goods. Therefore, an embodiment of the present application deletes or updates the local cache through a cluster synchronization method to synchronize the local cache within the cluster.

[0132] One of the above technical solutions has the following advantages or beneficial effects: the embodiment of the present application calls the cache processing method through the target cache manager to process the cache data, wherein the cache processing method includes a data operation method, a cluster indicator viewing method and a cluster synchronization method. The data operation method can quickly process the cache data, the cluster indicator viewing method can intuitively query the local cache indicators in the cluster, and the cluster synchronization method can synchronize the cache data in the cluster, thereby improving the efficiency of data processing.

[0133] See also Figure 6 In step S503 of some embodiments, the step of performing indicator statistics processing on the cache data according to the cluster indicator viewing method to obtain the processing result includes:

[0134] Step S601, obtaining a client instance, and obtaining a service instance list according to the client instance;

[0135] Step S602, performing index calculation processing on the local cache according to the cache data to obtain index data of each storage node;

[0136] Step S603: Aggregate the metric data of each storage node according to the service instance list to obtain the processing result.

[0137] In the embodiment of the present application, the cluster metric viewing method is used to perform metric statistics on cached data. By obtaining the client instance, the service implementation list can be obtained, and metric calculation is performed according to the cached data. Thus, the metric data is aggregated according to the service implementation table to obtain the final processing result. The processing result is the cluster metric data after statistics, including statistical data of metrics such as hit rate, miss rate, number of cache items, memory usage, and expiration policy execution.

[0138] In step S601 of some embodiments, the client instance refers to a microservice instance registered with the server. Each client instance periodically sends a heartbeat packet to maintain the registration status, and the client instance can be discovered and called by other clients. The service instance list is used to record each client instance, and the service instance list containing the client instance can be found through the client instance.

[0139] In step S602 of some embodiments, the corresponding storage location can be found according to the cached data. For example, the cached data can be stored in local memory or other storage media. Monitoring agents can be deployed in advance at the storage location to collect data regularly and summarize and calculate. Memory check commands can also be executed in batches through the configuration management tool to check the storage location, so as to obtain the metric data of each storage node.

[0140] In step S603 of some embodiments, all storage nodes in the cluster can be found according to the service instance. By aggregating the metric data of all storage nodes, where data aggregation refers to the process of summarizing a large amount of data into smaller and more meaningful data sets, and by extracting key information from the original data, it is easier to perform analysis and visualization. Specifically, the aggregation methods can include operations such as summation, average value, counting, maximum value, minimum value, grouping, etc. In the embodiment of the present application, the final processing result is obtained by aggregating the metric data of all storage nodes, and the processing result can be displayed in a visual form on the terminal or display device.

[0141] One of the technical solutions in the above technical solutions has the following advantages or beneficial effects: The embodiment of the present application performs statistics on the metric data in the cluster through the cluster metric viewing method, which can intuitively display the local cache metrics in the cluster, more intuitively and quickly view the local memory usage in the cluster. For example, it can quickly locate the hit rate of the insurance configuration cache, thereby quickly locating the performance of the insurance page interface and improving the data analysis efficiency.

[0142] Please refer to Figure 7, in step S504 of some embodiments, the cluster cache synchronization processing of the cache data according to the cluster synchronization method to obtain the processing result includes:

[0143] Step S701, obtain a client instance, and obtain a service instance list according to the client instance;

[0144] Step S702, perform a traversal search process on the service instance list according to the cache data to obtain a target address;

[0145] Step S703, perform a synchronization operation process on the cache data in the local cache according to the target address to obtain the processing result.

[0146] In the embodiments of the present application, the cluster synchronization method is used to synchronize the cache data in the local cache within the cluster, enhancing the data consistency of the local cache in the cluster. Among them, the cluster synchronization method includes synchronizing the local cache of each storage node within the cluster, that is, performing synchronization update or deletion processing on the cache data.

[0147] In step S701 of some embodiments, the client instance refers to a microservice instance registered to the server. Each client instance will periodically send a heartbeat packet to maintain the registration status, and the client instance can be discovered and called by other clients. The service instance list is used to record each client instance, and the service instance list containing the client instance can be obtained through the client instance.

[0148] In step S702 of some embodiments, the storage node that needs to update the cache data can be queried according to the service instance list. The target address is obtained by traversing the service instance list, and the target address is the storage address where the cache data is stored. Among them, the traversal search can adopt a depth-first search algorithm and a breadth-first search algorithm. Depth-first search means traversing along the depth of the tree until reaching the leaf node, and then backtracking to the nearest parent node to continue the search. Breadth-first search means starting from the root node and expanding the search layer by layer outward.

[0149] In step S703 of some embodiments, when synchronizing the cache data in the target address, the local cache within the cluster can be deleted, or the local cache within the cluster can be updated. For example, in an insurance system, when an operator modifies insurance configuration data at the backend, at this time the insurance configuration data is cache data. By obtaining the address and port list of all nodes in the cluster when the cache data changes, and calling the cache update interface to update the local cache, so that users can see the latest insurance information.

[0150] One of the above technical solutions has the following advantages or beneficial effects: In the embodiment of the present application, the cache data is processed by the cluster synchronization method for cluster cache synchronization, which enhances the data consistency of the local cache in the cluster and can quickly respond to real-time business scenarios.

[0151] In some embodiments, after aggregating the metric data of each storage node according to the service instance list to obtain the processing result, it further includes:

[0152] Creating a cache access point according to the metric data;

[0153] Performing interface call processing on the processing result according to the cache access point to obtain the metric data.

[0154] In the embodiment of the present application, a cache access point can be created on each storage node according to the metric data. The cache access point is used to provide the application cache status for the outside. Thus, the processing result can be viewed by making an interface call to the cache access point. The processing result is the metric data obtained by statistically analyzing the metric data in the cluster, including cluster statistical data such as hit rate, miss rate, number of cache items, memory usage, and expiration policy execution status. For example, in an insurance system, the backend monitoring module can call the cache access point to obtain the metric data, so as to more intuitively and quickly view the local memory usage in the cluster. For example, the hit rate of the insurance configuration cache can be quickly located, and thus the performance bottleneck of the insurance page interface can be quickly located.

[0155] One of the above technical solutions has the following advantages or beneficial effects: In the embodiment of the present application, the cache access point can provide an interface for obtaining metric data, which is convenient for obtaining metric data for subsequent monitoring and other processing, and improves the data processing efficiency.

[0156] Next, in combination with specific application examples, the solution of the embodiment of the present application will be introduced and described in detail:

[0157] Embodiments of the present application can be applied to the field of data processing technology, and are applicable to fintech and healthcare scenarios. Specifically, they are applied to scenarios for processing cached data, such as querying, adding, deleting, and modifying cached data. By processing the cached data, the system can perform risk assessment on financial data. The system can be used for applying for loans, credit cards, or purchasing insurance, wealth management products, etc. The system can also be an insurance system, a bank system, a trading system, or an order system. Embodiments of the present application can quickly locate cached data by adding cache annotations to the target method and parsing the cache annotations. By selecting different cache managers, it can support secondary caching, effectively prevent cache penetration, reduce database queries, improve system robustness, and effectively avoid the white screen problem caused by system crashes. At the same time, by calling the cache processing method in the cache manager, the local cache can be synchronized in the cluster, enhancing data consistency of the local cache in the cluster. For example, when the operation updates the insurance configuration, users can see the latest insurance information, and the modified inventory of time-limited coupon grabbing can also take effect immediately, which can adapt to business scenarios with strong real-time requirements. And by performing cluster statistics on the local cache metric data, it is possible to more intuitively and quickly view the local memory usage in the cluster, such as quickly locating the hit rate of the insurance configuration cache. In the Good Life application system applied to the insurance field, in order to save development manpower, embodiments of the present application can integrate components into the software development scaffolding. By introducing the scaffolding component dependency, extended annotations can be used without repeated development. Each access is equivalent to saving nearly a thousand lines of code. After using the extended cache component in multiple scenarios of the Good Life system, the average response speed of the page interface can be increased by more than 50%. For example, the average response time of the insurance shelf list interface in the system is shortened from 783ms to 350ms. And by performing cluster statistics on the local cache metrics, it is possible to more intuitively and quickly view the local memory usage in the cluster.

[0158] Please refer to Figure 8 , embodiments of the present application also provide a cached data processing device that can implement the above-mentioned cached data processing method. The device includes:

[0159] The first module 801 is configured to call and process the system method in response to an operation instruction to obtain a target method, where the target method is a method with a cache annotation;

[0160] The second module 802 is configured to perform cache annotation parsing processing on the target method to obtain a parsing result, where the parsing result includes cached data and cache configuration;

[0161] The third module 803 is configured to perform cache manager selection processing on the cached data according to the cache configuration to obtain a target cache manager. The cache manager includes a secondary cache manager and a local cache manager;

[0162] The fourth module 804 is configured to call a cache processing method through the target cache manager to process the cache data and obtain a processing result.

[0163] It can be understood that the content in the above method embodiments is applicable to the device embodiments of the present application. The functions specifically implemented by the device embodiments of the present application are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those of the above method embodiments.

[0164] An embodiment of the present application further provides an electronic device, which includes a memory and a processor. The memory stores a computer program, and when the processor executes the computer program, the above data processing method is implemented. The electronic device can be any intelligent terminal including a tablet computer, an in-vehicle computer, etc.

[0165] Please refer to Figure 9 , Figure 9 which shows the hardware structure of an electronic device according to another embodiment. The electronic device includes:

[0166] A processor 901, which can be implemented by using a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, etc., and is configured to execute relevant programs to implement the technical solutions provided by the embodiments of the present application;

[0167] A memory 902, which can be implemented in the form of a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM), etc. The memory 902 can store an operating system and other application programs. When implementing the technical solutions provided by the embodiments of this specification through software or firmware, the relevant program codes are stored in the memory 902, and are called by the processor 901 to execute a cache data processing method according to an embodiment of the present application;

[0168] An input / output interface 903, which is configured to implement information input and output;

[0169] A communication interface 904, which is configured to implement communication interaction between this device and other devices, and can implement communication through a wired method (such as USB, network cable, etc.) or through a wireless method (such as a mobile network, WIFI, Bluetooth, etc.);

[0170] The bus 905 transmits information among various components of the device (such as the processor 901, the memory 902, the input / output interface 903, and the communication interface 904);

[0171] Among them, the processor 901, the memory 902, the input / output interface 903, and the communication interface 904 are communicatively connected to each other inside the device through the bus 905.

[0172] The embodiment of the present application also provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the above-mentioned method for processing cached data is implemented.

[0173] As a non-transitory computer-readable storage medium, the memory can be used to store non-transitory software programs and non-transitory computer-executable programs. In addition, the memory may include high-speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, a flash memory device, or other non-transitory solid-state storage devices. In some embodiments, the memory may optionally include a memory remotely provided relative to the processor, and these remote memories can be connected to the processor through a network. Examples of the above network include but are not limited to the Internet, an enterprise intranet, a local area network, a mobile communication network, and combinations thereof.

[0174] A method, device, electronic device, and storage medium for processing cached data provided by the embodiment of the present application can call and process a system method in response to an operation instruction to obtain a target method, and can annotate the method through cache annotation, so that a method that needs to process cached data can be quickly identified, improving the response efficiency of the system to cached data. In addition, the solution performs cache annotation parsing processing on the target method to obtain a parsing result, and performs cache manager selection processing on the cached data according to the cache configuration to obtain a target cache manager, which can solve the problem of cache singularity by adding a secondary cache function. Moreover, the solution calls a cache processing method through the target cache manager to process the cached data, and can synchronize the local cache within the cluster by adding a cluster local cache synchronization function to the cache processing method, improving the processing efficiency of the cached data and enhancing the user experience.

[0175] The embodiments described in the embodiments of the present application are for more clearly illustrating the technical solutions of the embodiments of the present application, and do not constitute a limitation on the technical solutions provided by the embodiments of the present application. Those skilled in the art can know that with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by the embodiments of the present application are equally applicable to similar technical problems.

[0176] Those skilled in the art can understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of the present application, and may include more or fewer steps than those shown in the figures, or combine some steps, or different steps.

[0177] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated, that is, they may be located in one place, or may be distributed to multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0178] Those of ordinary skill in the art can understand that all or some of the steps in the methods disclosed above, and the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, and their appropriate combinations.

[0179] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of the present application and the above-mentioned drawings are used to distinguish similar objects, and do not necessarily describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances, so that the embodiments of the present application described here can be implemented in an order other than those illustrated or described here. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units does not necessarily limit to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products, or devices.

[0180] It should be understood that in the present application, "at least one (item)" means one or more, and "multiple" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" may mean: only A exists, only B exists, and both A and B exist at the same time. Among them, A and B can be singular or plural. The character " / " generally means that the associated objects before and after are in an "or" relationship. "At least one (one) of the following" or a similar expression means any combination of these items, including any combination of single item (one) or plural items (ones). For example, at least one (one) of a, b, or c may mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.

[0181] In several embodiments provided by this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the above-mentioned units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed couplings or direct couplings or communication connections to each other can be through some interfaces. The indirect couplings or communication connections of devices or units can be in electrical, mechanical or other forms.

[0182] The units described above as separate components may or may not be physically separated. The components displayed as units may or may not be physical units, that is, they may be located in one place or distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0183] In addition, in each embodiment of this application, the functional units can be integrated in a processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.

[0184] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of this technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes multiple instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods in each embodiment of this application. The foregoing storage medium includes: various media that can store programs such as USB flash drives, mobile hard disks, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical discs.

[0185] The preferred embodiments of the embodiments of this application have been described above with reference to the drawings, but this does not limit the scope of rights of the embodiments of this application. Any modifications, equivalent replacements, and improvements made by those skilled in the art without departing from the scope and essence of the embodiments of this application shall be within the scope of rights of the embodiments of this application.

Claims

1. A cache data processing method, characterized in that: The method comprises: In response to the operation instruction, the system method is called and processed to obtain a target method, wherein the target method is a method with a cache annotation; Perform cache annotation parsing on the target method to obtain a parsing result, wherein the parsing result includes cache data and cache configuration; Performing cache manager selection processing on the cache data according to the cache configuration to obtain a target cache manager, the cache manager including a secondary cache manager and a local cache manager; The target cache manager calls a cache processing method to process the cache data to obtain a processing result.

2. The method according to claim 1, characterized in that The cache annotation parsing process is performed on the target method to obtain a parsing result, including: The target method is intercepted and parsed through the cache aspect to obtain a cache annotation; Execute the target method according to the cache annotation to obtain the cache data; The cache annotation is processed for configuration data matching to obtain the cache configuration.

3. The method according to claim 1, characterized in that: The step of performing a cache manager selection process on the cache data according to the cache configuration to obtain a target cache manager includes: Determine a cache type of the cache data according to the cache configuration, the cache type including a first-level cache and a second-level cache; When the cache type is a first-level cache, selecting the local cache manager as the target cache manager, the local cache manager being used to access the local cache; When the cache type is a level 2 cache, the level 2 cache manager is selected as the target cache manager, and the target cache manager is used to access the local cache and the cache database.

4. The method according to claim 1, characterized in that The step of processing the cache data by invoking a cache processing method through the target cache manager to obtain a processing result includes: Perform method matching processing on the target cache manager according to the cache configuration to obtain the cache processing method, which includes a data operation method, a cluster indicator viewing method and a cluster synchronization method; Performing data operation processing on the cache data according to the data operation method to obtain the processing result; Alternatively, performing indicator statistical processing on the cache data according to the cluster indicator viewing method to obtain the processing result; Alternatively, cluster cache synchronization processing is performed on the cache data according to the cluster synchronization method to obtain the processing result.

5. The method according to claim 4, characterized in that The performing indicator statistics processing on the cache data according to the cluster indicator viewing method to obtain the processing result includes: Obtain a client instance, and obtain a service instance list according to the client instance; Performing index calculation processing on the local cache according to the cache data to obtain index data of each storage node; The indicator data of each storage node is aggregated according to the service instance list to obtain the processing result.

6. The method according to claim 4, characterized in that The performing cluster cache synchronization processing on the cache data according to the cluster synchronization method to obtain the processing result includes: Obtain a client instance, and obtain a service instance list according to the client instance; Performing a traversal search process on the service instance list according to the cache data to obtain a target address; A synchronization operation is performed on the cache data in the local cache according to the target address to obtain the processing result.

7. The method according to claim 5, characterized in that After performing indicator statistics processing on the cache data according to the cluster indicator viewing method to obtain the processing result, the method further includes: Create a cache access point according to the indicator data; The processing result is processed by performing an interface call according to the cache access point to obtain the indicator data.

8. A cache data processing device, characterized in that: The device comprises: The first module is used to call the system method in response to the operation instruction to obtain the target method, where the target method is a method with a cache annotation; The second module is used to perform cache annotation parsing on the target method to obtain a parsing result, which includes cache data and cache configuration; A third module is used to perform a cache manager selection process on the cache data according to the cache configuration to obtain a target cache manager, where the cache manager includes a secondary cache manager and a local cache manager; The fourth module is used to call the cache processing method through the target cache manager to process the cache data and obtain a processing result.

9. An electronic device, characterized in that: The electronic device comprises a memory and a processor, the memory stores a computer program, and the processor implements the cache data processing method according to any one of claims 1 to 7 when executing the computer program.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the cache data processing method according to any one of claims 1 to 7 is implemented.