Business data processing method and device, computer equipment and program product

By intercepting business requests and responses at microservice nodes, generating and standardizing log information, the problem of lack of audit record function under the microservice architecture is solved, and the effect of efficiently generating user behavior trajectories is achieved.

CN120179523APending Publication Date: 2025-06-20CHINA SOUTHERN POWER GRID INTERNET SERVICE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510317337.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-18
Publication Date
2025-06-20

AI Technical Summary

Technical Problem

In e-commerce systems, the lack of audit record function under the microservice technology architecture leads to the inability to form a complete user behavior trajectory, it is difficult to locate user operation behavior, and the data is scattered and the format is not unified when recording logs independently, making it difficult to integrate and analyze, resulting in a large overhead of process performance recording of user behavior trajectories.

Method used

Intercept the user's business request at the entrance of each microservice node to generate a tracking identifier; intercept the service response at the exit, record log information, and standardize it in accordance with the preset format to generate the user's behavior trajectory.

Benefits of technology

Through a unified log collection framework, the log information is collected and the user's behavioral trajectory is generated, which avoids the redundancy problem caused by independent log recording of each microservice and improves the efficiency of user behavioral trajectory generation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120179523A_ABST
    Figure CN120179523A_ABST
Patent Text Reader

Abstract

The invention relates to a business data processing method and device, computer equipment, a computer readable storage medium and a computer program product. The method comprises the following steps: intercepting a service request of a user at an entrance of each micro-service node, and generating a tracking identifier for each service request based on a preset naming rule; intercepting a service response corresponding to the service request at an exit of each micro-service node, and recording log information of the service request and the service response; performing standardization processing on the log information according to a preset format to obtain standardized log information; and generating a behavior track of the user based on the tracking identifier and the standardized log information. By adopting the method, the generation efficiency of the behavior track of the user can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of microservice architectures, and particularly to a method, apparatus, computer device, computer-readable storage medium, and computer program product for processing business data. Background Art

[0002] With the continuous development of the e-commerce industry, in an e-commerce system, there are more and more services under the microservice technology architecture, and all interfaces have no audit record function, so it is impossible to form a complete user behavior track and locate the user's operation behavior.

[0003] In related technologies, it is necessary to add audit logs to each interface, which is difficult to implement and error-prone. When logging independently, the log data is scattered and the formats are not unified, making it difficult to integrate and analyze, resulting in a large performance overhead in the process of recording user behavior tracks. Summary of the Invention

[0004] Based on this, it is necessary to provide a method, apparatus, computer device, computer-readable storage medium, and computer program product for processing business data that can reduce the overhead in the process of generating user tracks for the above technical problems.

[0005] In a first aspect, the present application provides a method for processing business data, including:

[0006] Intercept a user's business request at the entrance of each microservice node, and generate a tracking identifier for each business request based on a preset naming rule;

[0007] Intercept the business response corresponding to the business request at the exit of each microservice node, and record the log information of the business request and the business response;

[0008] Standardize the log information according to a preset format to obtain standardized log information; the log information includes the tracking identifier corresponding to the business request, user ID, microservice name, generation time point of the business request, generation time point of the business response, generation time point of the log information, parameters corresponding to the business response, and parameters corresponding to the business request;

[0009] Generate a user's behavior track based on the tracking identifier and the standardized log information; the behavior track includes the user's operation sequence, operation time, and operation result.

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

[0011] Compress the log information to obtain compressed log information;

[0012] Start an independent log writing thread, and store the compressed log information into the database through the log writing thread.

[0013] In one embodiment, the preset format includes the following fields: trace identifier, user ID, microservice name, time point, API path corresponding to the business request, parameters corresponding to the business request, and parameters corresponding to the business response.

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

[0015] In response to the display request of the behavior track, display the behavior track according to a preset dimension; the preset dimension includes user ID, time point, and operation type.

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

[0017] When an abnormal situation is detected, record the abnormal situation and send an abnormal notification through a preset method; the abnormal situation includes security exception, operation exception, performance exception, behavior exception, and system exception.

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

[0019] Clean, format, and extract features from the user's historical behavior track to obtain a sample behavior track;

[0020] Based on the sample behavior track, establish a prediction model and train the prediction model to obtain a trained prediction model;

[0021] Input the user's current behavior track into the trained prediction model to obtain the future change trend of the user's behavior track.

[0022] In a second aspect, the present application also provides a business data processing device, including:

[0023] A generation module, configured to intercept a user's business request at the entrance of each microservice node, and generate a trace identifier for each business request based on a preset naming rule;

[0024] A recording module, configured to intercept the business response corresponding to the business request at the exit of each microservice node, and record the log information of the business request and the business response;

[0025] A processing module, configured to standardize the log information according to a preset format to obtain standardized log information; the log information includes a trace identifier corresponding to a service request, a user ID, a microservice name, a generation time point of the service request, a generation time point of the service response, a generation time point of the log information, parameters corresponding to the service response, and parameters corresponding to the service request;

[0026] The generating module is further configured to generate a behavior track of the user based on the trace identifier and the standardized log information; the behavior track includes an operation sequence of the user, an operation time, and an operation result.

[0027] In a third aspect, the present application further provides a computer device, including a memory and a processor, where the memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:

[0028] Intercept a service request of a user at the entrance of each microservice node, and generate a trace identifier for each service request based on a preset naming rule;

[0029] Intercept a service response corresponding to the service request at the exit of each microservice node, and record the log information of the service request and the service response;

[0030] Standardize the log information according to a preset format to obtain standardized log information; the log information includes a trace identifier corresponding to a service request, a user ID, a microservice name, a generation time point of the service request, a generation time point of the service response, a generation time point of the log information, parameters corresponding to the service response, and parameters corresponding to the service request;

[0031] Generate a behavior track of the user based on the trace identifier and the standardized log information; the behavior track includes an operation sequence of the user, an operation time, and an operation result.

[0032] In a fourth aspect, the present application further provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:

[0033] Intercept a service request of a user at the entrance of each microservice node, and generate a trace identifier for each service request based on a preset naming rule;

[0034] Intercept a service response corresponding to the service request at the exit of each microservice node, and record the log information of the service request and the service response;

[0035] Standardize the log information according to a preset format to obtain the standardized log information; the log information includes the trace identifier corresponding to the service request, user ID, microservice name, generation time point of the service request, generation time point of the service response, generation time point of the log information, parameters corresponding to the service response, and parameters corresponding to the service request;

[0036] Generate the user's behavior track based on the trace identifier and the standardized log information; the behavior track includes the user's operation sequence, operation time, and operation result.

[0037] In a fifth aspect, the present application also provides a computer program product, including a computer program, which when executed by a processor implements the following steps:

[0038] Intercept the user's service request at the entrance of each microservice node, and generate a trace identifier for each service request based on a preset naming rule;

[0039] Intercept the service response corresponding to the service request at the exit of each microservice node, and record the log information of the service request and the service response;

[0040] Standardize the log information according to a preset format to obtain the standardized log information; the log information includes the trace identifier corresponding to the service request, user ID, microservice name, generation time point of the service request, generation time point of the service response, generation time point of the log information, parameters corresponding to the service response, and parameters corresponding to the service request;

[0041] Generate the user's behavior track based on the trace identifier and the standardized log information; the behavior track includes the user's operation sequence, operation time, and operation result.

[0042] For the above service data processing method, device, computer device, computer-readable storage medium, and computer program product, first, intercept the user's service request at the entrance of each microservice node, and generate a trace identifier for each service request based on a preset naming rule; intercept the service response corresponding to the service request at the exit of each microservice node, and record the log information of the service request and the service response; standardize the log information according to a preset format to obtain the standardized log information; generate the user's behavior track based on the trace identifier and the standardized log information. In this way, by collecting log information through a unified log collection framework and generating the user's behavior track according to the collected log information, the redundancy problem caused by each microservice independently recording logs is avoided, and the efficiency of generating the user's behavior track is improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] To more clearly illustrate the technical solutions in the embodiments of the present application or related technologies, the following will briefly introduce the accompanying drawings required for the description of the embodiments of the present application or related technologies. Obviously, the accompanying drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other related drawings can also be obtained based on these drawings.

[0044] Figure 1 It is an application environment diagram of the business data processing method in an embodiment;

[0045] Figure 2 It is a schematic flowchart of the business data processing method in an embodiment;

[0046] Figure 3 It is a structural block diagram of the business data processing device in an embodiment;

[0047] Figure 4 It is an internal structure diagram of a computer device in an embodiment. Detailed implementation manners

[0048] In order to make the objectives, technical solutions, and advantages of the present application more clear and understandable, the following further details the present application in combination with 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.

[0049] The business data processing method provided by the embodiments of the present application can be applied to an application environment as Figure 1 shown. Among them, the terminal 102 communicates with the server 104 through the network. The data storage system can store the log information data that the server 104 needs to process. The data storage system can be integrated on the server 104, or placed in the cloud or other network servers. Among them, the terminal 102 can be, but is not limited to, various personal computers, laptop computers, smart phones, tablet computers, Internet of Things devices, and portable wearable devices. The Internet of Things devices can be smart speakers, smart TVs, smart air conditioners, smart in-vehicle devices, projection devices, etc. The portable wearable devices can be smart watches, smart bracelets, head-mounted devices, etc. The head-mounted devices can be virtual reality (VR) devices, augmented reality (AR) devices, smart glasses, etc. The server 104 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services.

[0050] In an exemplary embodiment, as Figure 2 shown, a business data processing method is provided, and this method is applied to Figure 1Taking the terminal 102 in [[]] as an example, the following steps 202 to 208 are included. Among them:

[0051] Step 202, intercept the user's service request at the entrance of each microservice node, and generate a tracing identifier for each service request based on a preset naming rule.

[0052] Among them, the microservice node is an instance or deployment unit that runs a single microservice, and each microservice is used to complete a specific business function. The tracing identifier is an identifier used to identify and trace transactions or events in the system.

[0053] Exemplarily, the terminal intercepts the user's service request at the entrance of each microservice node, and generates a tracing identifier for each service request according to the preset naming rule.

[0054] Step 204, intercept the service response corresponding to the service request at the exit of each microservice node, and record the log information of the service request and the service response.

[0055] Among them, the service response is the response made by each microservice node for the corresponding service request.

[0056] Optionally, the terminal intercepts the service response corresponding to the service request at the exit of each microservice node, and records the log information of the service request and the corresponding service response.

[0057] Step 206, standardize the log information according to a preset format to obtain the standardized log information.

[0058] Among them, the log information includes the tracing identifier corresponding to the service request, the user ID, the microservice name, the generation time point of the service request, the generation time point of the service response, the generation time point of the log information, the parameters corresponding to the service response, and the parameters corresponding to the service request.

[0059] Exemplarily, the terminal standardizes the tracing identifier corresponding to the service request, the user ID, the microservice name, the generation time point of the service request, the generation time point of the service response, the generation time point of the log information, the parameters corresponding to the service response, and the parameters corresponding to the service request according to the preset format to obtain the standardized log information.

[0060] For example, the tracing identifier can be a unique tracing ID generated for each user request based on tracing technology, the microservice name can be named according to the function, the time point can be named according to xx year xx month xx day xx hour xx minute xx second, and the parameters corresponding to the service response and the parameters corresponding to the service request can be the product category. The embodiments of the present application do not limit this.

[0061] Step 208: Generate the user's behavior track based on the tracking identifier and the standardized log information.

[0062] Among them, the behavior track includes the user's operation sequence, operation time, and operation result.

[0063] Exemplarily, generate a behavior track including the user's operation sequence, operation time, and operation result based on the tracking identifier and the standardized log information.

[0064] In the above business data processing method, intercept the user's business request at the entrance of each microservice node, and generate a tracking identifier for each business request based on a preset naming rule; intercept the business response corresponding to the business request at the exit of each microservice node, and record the log information of the business request and the business response; standardize the log information according to a preset format to obtain the standardized log information; generate the user's behavior track based on the tracking identifier and the standardized log information. In this way, collect the log information through a unified log collection framework, and generate the user's behavior track according to the collected log information, avoiding the redundancy problem caused by each microservice independently recording logs, and improving the efficiency of generating the user's behavior track.

[0065] In an exemplary embodiment, the business data processing method further includes: compressing the log information to obtain the compressed log information; starting an independent log writing thread, and storing the compressed log information into the database through the log writing thread.

[0066] In actual implementation, compress the log information to obtain the compressed log information; start an independent log writing thread, and store the compressed log information into the database through the log writing thread.

[0067] Among them, the thread is the smallest unit that the operating system can schedule.

[0068] In the above embodiment, after compressing the log information, write the log into the database through an asynchronous thread, reducing the network transmission and storage overhead, and supporting the processing of business data in high-traffic scenarios.

[0069] In an exemplary embodiment, the preset format includes the following fields: tracking identifier, user ID, microservice name, time point, API path corresponding to the business request, parameters corresponding to the business request, and parameters corresponding to the business response.

[0070] In actual implementation, the preset format includes the tracking identifier, user ID, microservice name, time point, API path corresponding to the business request, parameters corresponding to the business request, and parameters corresponding to the business response.

[0071] Among them, the API path refers to the path used to specify a specific resource or operation in the application programming interface.

[0072] In the above embodiments, by storing the log information in a unified format, the display of the log information becomes more intuitive.

[0073] In an exemplary embodiment, the business data processing method further includes: in response to a display request for the behavior track, displaying the behavior track according to a preset dimension;

[0074] Among them, the preset dimension includes user ID, time point, and operation type.

[0075] In actual implementation, in response to a display request for the behavior track, the behavior track is displayed on the visualization interface according to the user ID, time point, and operation type.

[0076] For example, it is displayed on the visualization interface that user A purchased a notebook at 8:34:34 on February 4, 2019.

[0077] In the above embodiments, by displaying the behavior track according to the preset dimension, multi-dimensional analysis of business data can be supported.

[0078] In an exemplary embodiment, the business data processing method further includes: when an abnormal situation is detected, recording the abnormal situation and sending an abnormal notification through a preset method; the abnormal situation includes security exception, operation exception, performance exception, behavior exception, and system exception.

[0079] In actual implementation, when an abnormal situation is detected, the abnormal situation is recorded and an abnormal notification is sent through a preset method. Among them, the preset method can be a text message notification or other notification methods, which are not limited in the embodiments of the present application. The abnormal situation includes security exception, operation exception, performance exception, behavior exception, and system exception.

[0080] For example, the security exception can be frequent login failures, illegal access attempts, etc.; the operation exception can be an abnormal operation frequency, a too high operation failure rate, etc.; the performance exception can be an overly long response time, too high resource occupancy, etc.; the behavior exception can be deviation from normal behavior, etc.; the system exception can be microservice call failure or log information missing, etc.

[0081] In the above embodiments, by detecting the process of business data processing in real time and sending timely notifications when abnormal situations are found, the further serious development of the situation is prevented.

[0082] In an exemplary embodiment, the business data processing method further includes: cleaning, formatting, and feature extracting the historical behavior trajectories of users to obtain sample behavior trajectories; establishing a prediction model based on the sample behavior trajectories and training the prediction model to obtain a trained prediction model; and inputting the current behavior trajectories of users into the trained prediction model to obtain the future change trends of the behavior trajectories of users.

[0083] In actual implementation, clean, format, and feature extract the historical behavior trajectories of users to obtain sample behavior trajectories; establish a prediction model based on the sample behavior trajectories and train the prediction model to obtain a trained prediction model; and input the current behavior trajectories of users into the trained prediction model to obtain the future change trends of the behavior trajectories of users.

[0084] In the above embodiment, by predicting the behavior trajectories of users in advance, personalized recommendations can be made for users.

[0085] To illustrate the business data processing method in the present application in detail, an embodiment is used for illustration below. Exemplarily, the present application illustrates the business data processing method in a specific scenario.

[0086] First, intercept the business requests of users at the entrance of each microservice node, and generate a tracking identifier for each business request according to the preset naming rules.

[0087] Intercept the business responses corresponding to the business requests at the exit of each microservice node, and record the log information of the business requests and the corresponding business responses. Standardize the tracking identifier corresponding to the business request, user ID, microservice name, generation time point of the business request, generation time point of the business response, generation time point of the log information, parameters corresponding to the business response, and parameters corresponding to the business request according to the preset format to obtain the standardized log information.

[0088] Compress the log information to obtain compressed log information; start an independent log writing thread, and store the compressed log information into the database through the log writing thread.

[0089] Generate behavior trajectories including the operation sequences, operation times, and operation results of users according to the tracking identifier and the standardized log information. In response to the display request of the behavior trajectories, display the behavior trajectories on the visualization interface according to the user ID, time point, and operation type.

[0090] When it is detected that an abnormal situation occurs, record the abnormal situation and send an abnormal notification through a preset method. The abnormal situations include security exceptions, operation exceptions, performance exceptions, behavior exceptions, and system exceptions.

[0091] Clean, format, and extract features from the user's historical behavior trajectory to obtain a sample behavior trajectory; based on the sample behavior trajectory, establish a prediction model and train the prediction model to obtain a trained prediction model; input the user's current behavior trajectory into the trained prediction model to obtain the future change trend of the user's behavior trajectory.

[0092] This application realizes the automatic collection of logs through a unified log collection framework, which speeds up the rate of business data processing. By associating log data with a tracking identifier and a user ID, a complete user behavior trajectory is formed, facilitating quick problem location when problems occur.

[0093] This application adopts an asynchronous writing mechanism, which reduces the impact on system performance and supports high-concurrency scenarios.

[0094] This application supports multi-dimensional business data analysis through a standardized log format and a visualization analysis platform.

[0095] It should be understood that although the steps in the flowcharts involved in the above-described embodiments are shown in sequence according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless there is a clear indication in this article, the execution of these steps has no strict order limit, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-described embodiments may include multiple steps or multiple stages. These steps or stages are not necessarily executed at the same moment, but can be executed at different moments. The execution order of these steps or stages is not necessarily sequential, but can be executed alternately or alternately with at least a part of other steps or steps in other steps.

[0096] Based on the same inventive concept, the embodiments of this application also provide a business data processing device for implementing the business data processing method described above. The implementation solutions provided by this device to solve problems are similar to those described in the above method. Therefore, the specific limitations in one or more embodiments of the business data processing device provided below can refer to the limitations on the business data processing method in the above text, and will not be repeated here.

[0097] In an exemplary embodiment, as Figure 3 shown, a business data processing device is provided, including: a generation module 301, a recording module 302, and a processing module 303, where:

[0098] The generation module is used to intercept the user's business requests at the entrance of each microservice node and generate a tracking identifier for each business request based on a preset naming rule.

[0099] A recording module, configured to intercept the service response corresponding to the service request at the exit of each microservice node, and record the log information of the service request and the service response.

[0100] A processing module, configured to standardize the log information according to a preset format to obtain standardized log information; the log information includes a trace identifier corresponding to the service request, a user ID, a microservice name, a generation time point of the service request, a generation time point of the service response, a generation time point of the log information, parameters corresponding to the service response, and parameters corresponding to the service request.

[0101] The generation module is further configured to generate a user behavior track based on the trace identifier and the standardized log information; the behavior track includes a user's operation sequence, operation time, and operation result.

[0102] In some embodiments, the apparatus further includes a storage module, configured to compress the log information to obtain compressed log information;

[0103] Start an independent log writing thread, and store the compressed log information into a database through the log writing thread.

[0104] In some embodiments, the preset format includes the following fields: trace identifier, user ID, microservice name, time point, API path corresponding to the service request, parameters corresponding to the service request, and parameters corresponding to the service response.

[0105] In some embodiments, the apparatus further includes a display module, configured to display the behavior track according to a preset dimension in response to a display request for the behavior track; the preset dimension includes user ID, time point, and operation type.

[0106] In some embodiments, the apparatus further includes a detection module, configured to record an abnormal situation and send an abnormal notification in a preset manner when an abnormal situation is detected; the abnormal situation includes security exception, operation exception, performance exception, behavior exception, and system exception.

[0107] In some embodiments, the apparatus further includes a prediction module, configured to clean, format, and extract features from a user's historical behavior track to obtain a sample behavior track;

[0108] Based on the sample behavior track, establish a prediction model and train the prediction model to obtain a trained prediction model;

[0109] Input the user's current behavior track into the trained prediction model to obtain a future change trend of the user's behavior track.

[0110] Each module in the above-mentioned service data processing device can be implemented in whole or in part by software, hardware, or a combination thereof. Each of the above modules can be embedded in the processor of the computer device in hardware form or independent of it, or stored in the memory of the computer device in software form, so that the processor can call and execute the operations corresponding to each of the above modules.

[0111] In an exemplary embodiment, a computer device is provided. The computer device can be a server, and its internal structure diagram can be as Figure 4 shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, abbreviated as I / O), a communication interface, a display unit, and an input device. Among them, the processor, the memory, and the input / output interface are connected through a system bus, and the communication interface, the display unit, and the input device are connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store log information data. The input / output interface of the computer device is used to exchange information between the processor and external devices. The communication interface of the computer device is used to communicate with external terminals through a network connection. When the computer program is executed by the processor, it implements a service data processing method.

[0112] The display unit of the computer device is used to form a visually visible picture, which can be a display screen, a projection device, or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen. The input device of the computer device can be a touch layer covering the display screen, or a button, a trackball, or a touchpad provided on the housing of the computer device, or an external keyboard, touchpad, or mouse, etc.

[0113] Those skilled in the art can understand that Figure 4 the structure shown in

[0114] is only a block diagram of some structures related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine some components, or have a different component layout.

[0115] Intercept the user's business request at the entrance of each microservice node, and generate a tracking identifier for each business request based on a preset naming rule;

[0116] Intercept the business response corresponding to the business request at the exit of each microservice node, and record the log information of the business request and the business response;

[0117] Standardize the log information according to a preset format to obtain standardized log information; the log information includes the tracking identifier corresponding to the business request, user ID, microservice name, generation time point of the business request, generation time point of the business response, generation time point of the log information, parameters corresponding to the business response, and parameters corresponding to the business request;

[0118] Generate the user's behavior trajectory based on the tracking identifier and the standardized log information; the behavior trajectory includes the user's operation sequence, operation time, and operation result.

[0119] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the following steps are implemented:

[0120] Intercept the user's business request at the entrance of each microservice node, and generate a tracking identifier for each business request based on a preset naming rule;

[0121] Intercept the business response corresponding to the business request at the exit of each microservice node, and record the log information of the business request and the business response;

[0122] Standardize the log information according to a preset format to obtain standardized log information; the log information includes the tracking identifier corresponding to the business request, user ID, microservice name, generation time point of the business request, generation time point of the business response, generation time point of the log information, parameters corresponding to the business response, and parameters corresponding to the business request;

[0123] Generate the user's behavior trajectory based on the tracking identifier and the standardized log information; the behavior trajectory includes the user's operation sequence, operation time, and operation result.

[0124] In one embodiment, a computer program product is provided, including a computer program. When the computer program is executed by a processor, the following steps are implemented:

[0125] Intercept the user's business request at the entrance of each microservice node, and generate a tracking identifier for each business request based on a preset naming rule;

[0126] Intercept the service response corresponding to the service request at the exit of each microservice node, and record the log information of the service request and the service response;

[0127] Standardize the log information according to a preset format to obtain the standardized log information; the log information includes the trace identifier corresponding to the service request, user ID, microservice name, generation time point of the service request, generation time point of the service response, generation time point of the log information, parameters corresponding to the service response, and parameters corresponding to the service request;

[0128] Generate the behavior track of the user based on the trace identifier and the standardized log information; the behavior track includes the operation sequence, operation time, and operation result of the user.

[0129] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use, and processing of relevant data need to comply with relevant regulations.

[0130] Those of ordinary skill in the art can understand that all or part of the processes in the methods of the above embodiments can be completed by instructing relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above methods. Among them, any reference to a memory, database, or other medium used in the embodiments provided in 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), magnetoresistive 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 be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM), etc. The databases involved in the embodiments provided in this application can include at least one of relational databases and non-relational databases. Non-relational databases can include distributed databases based on blockchain, etc., without limitation. The processors involved in the embodiments provided in this application can be general-purpose processors, central processors, graphics processors, digital signal processors, programmable logic devices, data processing logics based on quantum computing, artificial intelligence (AI) processors, etc., without limitation.

[0131] The technical features of the above embodiments can be combined arbitrarily. For the sake of brevity of description, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, it should be considered to be within the scope recorded in this application.

[0132] The above-described embodiments merely represent several implementation manners of the present application. The description thereof is relatively specific and detailed, but it should not be construed as a limitation on the patent scope of the present application. It should be noted that for those of ordinary skill in the art, without departing from the concept of the present application, several modifications and improvements can still be made, and these all fall within the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the appended claims.

Claims

1. A business data processing method, characterized in that: The method comprises: Intercept the user's business request at the entrance of each microservice node, and generate a tracking identifier for each business request based on the preset naming rules; Intercept the business response corresponding to the business request at the exit of each microservice node, and record log information of the business request and the business response; The log information is standardized according to a preset format to obtain standardized log information; the log information includes a tracking identifier corresponding to the business request, a user ID, a microservice name, a time point when the business request is generated, a time point when the business response is generated, a time point when the log information is generated, parameters corresponding to the business response, and parameters corresponding to the business request; A user behavior track is generated based on the tracking identifier and the standardized log information; the behavior track includes the user's operation sequence, operation time and operation result.

2. The method according to claim 1, characterized in that The method further comprises: Compressing the log information to obtain compressed log information; An independent log writing thread is started, and the compressed log information is stored in a database through the log writing thread.

3. The method according to claim 1, characterized in that The preset format includes the following fields: tracking identifier, user ID, microservice name, time point, API path corresponding to the business request, parameters corresponding to the business request, and parameters corresponding to the business response.

4. The method according to claim 1, characterized in that: The method further comprises: In response to a request to display the behavior track, the behavior track is displayed according to preset dimensions; the preset dimensions include user ID, time point, and operation type.

5. The method according to claim 1, characterized in that The method further comprises: When an abnormal situation is detected, the abnormal situation is recorded and an abnormal notification is sent in a preset manner; the abnormal situation includes security abnormalities, operation abnormalities, performance abnormalities, behavior abnormalities and system abnormalities.

6. The method according to claim 1, characterized in that The method further comprises: Clean, format and extract features of the user's historical behavior trajectory to obtain a sample behavior trajectory; Based on the sample behavior trajectory, a prediction model is established, and the prediction model is trained to obtain a trained prediction model; The current behavior trajectory of the user is input into the trained prediction model to obtain the future change trend of the user's behavior trajectory.

7. A business data processing device, characterized in that: The device comprises: The generation module is used to intercept the user's business request at the entrance of each microservice node and generate a tracking identifier for each business request based on the preset naming rules; A recording module, used to intercept the business response corresponding to the business request at the exit of each microservice node, and record the log information of the business request and the business response; A processing module is used to standardize the log information according to a preset format to obtain standardized log information; the log information includes a tracking identifier corresponding to the business request, a user ID, a microservice name, a time point when the business request is generated, a time point when the business response is generated, a time point when the log information is generated, parameters corresponding to the business response, and parameters corresponding to the business request; The generating module is further used to generate a user's behavior track based on the tracking identifier and the standardized log information; the behavior track includes the user's operation sequence, operation time and operation result.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.

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

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