Log uploading method, terminal equipment and storage medium

By obtaining the fault description information of the target application, determining the fault association module and uploading its log information, the problems of waste of log upload resources and protection of sensitive information are solved, and resource saving and cost reduction are achieved.

CN120104585APending Publication Date: 2025-06-06ZTE CORP
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311665474.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-12-06
Publication Date
2025-06-06

AI Technical Summary

Technical Problem

The prior art wastes a lot of network resources and storage resources when log uploads, increasing server and manpower maintenance costs, while failing to effectively protect user sensitive information.

Method used

By obtaining the fault description information of the target application, determining the fault association module, obtaining and uploading the log information of the module, reducing the amount of uploaded information, saving network and storage resources, and desensitizing sensitive information.

Benefits of technology

It effectively saves network resources and storage resources during log upload, reduces server and manpower maintenance costs, and protects users' sensitive information.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120104585A_ABST
    Figure CN120104585A_ABST
Patent Text Reader

Abstract

The invention provides a log uploading method, terminal equipment and a storage medium. The method comprises the steps of obtaining fault description information of a target application; determining a first fault association module of the target application according to the fault description information; and obtaining log information of the first fault association module, and uploading the log information. According to the method, network resources and storage resources can be saved, and the maintenance cost is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a log uploading method, a terminal device and a storage medium. Background Art

[0002] With the popularity of smart phones, log analysis has become an important part of system development and maintenance. For mobile application development, the more active users are in providing feedback on application failures when using mobile products, the more helpful it is to increase the practical test scenarios of the product, thereby facilitating product performance optimization.

[0003] In the related art, the content in the log information is usually classified, and then the classified log information is uploaded to the server. A large amount of log information will waste a lot of network resources and storage resources, and will also increase the server and manpower maintenance costs. Summary of the invention

[0004] The embodiments of the present application provide a log uploading method, a terminal device and a storage medium, which are at least helpful in saving network resources and storage resources and reducing maintenance costs.

[0005] An embodiment of the present application provides a log uploading method, comprising: obtaining fault description information of a target application; determining a first fault association module of the target application based on the fault description information; obtaining log information of the first fault association module, and uploading the log information.

[0006] An embodiment of the present application provides a terminal device, including: one or more processors; a memory, on which one or more programs are stored. When the one or more programs are executed by one or more processors, the one or more processors implement any one of the log uploading methods in the embodiment of the present application.

[0007] An embodiment of the present application provides a storage medium, which stores a computer program. When the computer program is executed by a processor, any log uploading method in the embodiment of the present application is implemented.

[0008] According to the log uploading method of the embodiment of the present application, when the fault description information of the target application is obtained, the fault association module of the target application can be determined based on the fault description information, and then the log information of the fault association module can be obtained, and the obtained log information of the fault association module can be uploaded; according to this method, the log information of the fault association module associated with the fault of the target application can be used to upload the log, which is beneficial to reduce the amount of information when uploading the log information, thereby helping to save the network resources and storage resources involved in the log uploading, and reducing the server and manpower maintenance costs.

[0009] With regard to the above embodiments and other aspects of the present application and their implementation, further description is provided in the accompanying drawings, detailed description and claims. BRIEF DESCRIPTION OF THE DRAWINGS

[0010] Figure 1 A diagram showing an application scenario of the log uploading method and device according to an embodiment of the present application.

[0011] Figure 2 A flow chart showing a log uploading method according to an embodiment of the present application is shown.

[0012] Figure 3 A flowchart of determining a first fault association module of a target application according to fault description information in an embodiment of the present application is shown.

[0013] Figure 4 A flowchart of obtaining log information of a first fault association module and uploading the log information is shown in an embodiment of the present application.

[0014] Figure 5 A detailed flow chart of a log uploading method according to an exemplary embodiment of the present application is shown.

[0015] Figure 6 A block diagram of a log upload module in an embodiment of the present application is shown.

[0016] Figure 7 It is a structural diagram showing an exemplary hardware architecture of an electronic device capable of implementing the method and apparatus according to an embodiment of the present application. DETAILED DESCRIPTION

[0017] In order to make the purpose, technical solution and advantages of the present application more clear, the embodiments of the present application will be described in detail below with reference to the accompanying drawings. It should be noted that the embodiments and features in the embodiments of the present application can be combined with each other arbitrarily without conflict.

[0018] With the popularization and rapid development of smart terminals, log analysis of terminal device operating systems has become an important part of system development and maintenance. However, the existing log feedback lacks the necessary technical means to optimize log generation, storage and upload, which leads to more and more users being less and less enthusiastic about application failure feedback when using mobile products, which in turn leads to a reduction in practical testing scenarios for related products. In related technologies, all log information needs to be packaged and uploaded to the server, which increases the manpower maintenance cost of the server and R&D personnel and wastes resources. In addition, the log may contain sensitive information, which may be leaked when providing technical support, while the existing user log feedback does not focus on protecting sensitive information from the user side.

[0019] Figure 1The application scenario diagram of the log uploading method and device provided in the embodiment of the present application is schematically shown.

[0020] like Figure 1 As shown, the application scenario of the embodiment of the present application may include a terminal device 101, a network 103 and a server 102. The network 103 is used to provide a medium for a communication link between the terminal device 101 and the server 102. The network 103 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.

[0021] The user can use the terminal device 101 to interact with the server 102 through the network 103 to receive or send messages, etc. Various client applications can be installed on the terminal device 101, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc. (only as examples).

[0022] The terminal device 101 can be various electronic devices with a display screen and supporting fault log feedback, including but not limited to smart phones, tablet computers, user equipment (UE), mobile devices, user terminals, terminals, cellular phones, personal digital assistants (PDA), handheld devices, computing devices, vehicle-mounted devices, wearable devices, laptop computers and desktop computers, etc.

[0023] The server 102 may be a server that provides various services, such as a background management server (only an example) supported by the application running on the terminal device 101. The background management server may analyze the received log information and process it, and feed back the processing results (such as the cause of the fault, fault location, etc. generated according to the log information submitted by the terminal device) to the terminal device 101. Exemplarily, the background management server may be an independent physical server, a server cluster consisting of multiple servers, or a cloud server capable of cloud computing.

[0024] In the embodiment of the present application, a plurality means greater than or equal to two.

[0025] It should be noted that the log uploading method and device provided in the embodiment of the present application can be executed by the terminal device 101. Accordingly, the log uploading device provided in the embodiment of the present application can be set in the terminal device 101. The log uploading method provided in the embodiment of the present application can also be executed by a terminal device, server or server cluster that is different from the terminal device 101 and can communicate with the terminal device 101 and / or the server 102. Correspondingly, the log uploading device provided in the embodiment of the present application can also be set in a terminal device, server or server cluster that is different from the terminal device 101 and can communicate with the terminal device 101 and / or the server 102.

[0026] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to the implementation requirements.

[0027] In a first aspect, an embodiment of the present application provides a log uploading method, which can be applied to a terminal device.

[0028] Figure 2 A flow chart of a log uploading method provided in an embodiment of the present application. Figure 2 , the method may include the following steps.

[0029] S210: Obtain fault description information of the target application.

[0030] In this step, the target application can be any application running on the terminal device, and the application software can be, for example, a system application or a third-party application. The fault description information is used to describe the fault of the target application perceived by the user, and can include, but is not limited to, at least one of the following: the version of the application software, the time of the fault, the specific phenomenon of the fault, the frequency of the fault, the severity of the fault, etc. The device can be customized according to the actual situation.

[0031] S220: Determine a first fault associated module of the target application according to the fault description information.

[0032] In this step, the module can be understood as dividing the application into independent parts with specific functions, and the first fault-related module is an application related to the fault of the target application (providing modular functions) or a module included in the application.

[0033] As an example, assuming that the target application is an account application of a terminal device, and the fault description information is that the account application is stuck in use, the first fault association module may include: a data network access module, a performance optimization module, a data network access module, a network access module, etc. In other words, when a fault occurs in the target application, the probability that the fault of the target application is caused by a fault in the first fault association module is high.

[0034] S230, obtaining log information of the first fault association module, and uploading the log information.

[0035] Exemplarily, the log information of the first fault association module may be obtained from the operating system log of a preset terminal device, and the log information may be uploaded.

[0036] In this step, the terminal device will generate usage trace information during the use of the target application, and the operating system log can record this usage trace information. Through these usage trace information, you can understand the usage of each module in the application. The operating system is a set of interrelated system software programs that manage and control the operation of terminal devices, use and run hardware and software resources, and provide public services to organize user interactions. As an example, the operating system on the terminal device may include, but is not limited to, any of the following: Android operating system, HarmonyOS operating system, Apple operating system (IOS system), Microsoft terminal (Windows Phone) operating system, etc.

[0037] According to the log uploading method of the embodiment of the present application, when the fault description information of the target application is obtained, the fault association module of the target application can be determined based on the fault description information, and then the log information of the fault association module can be obtained, and the obtained log information of the fault association module can be uploaded; according to this method, the log information of the fault association module associated with the fault of the target application can be used to upload the log, which is beneficial to reduce the amount of information when uploading the log, thereby helping to save the network resources and storage resources involved in the log upload, and reducing the server and manpower maintenance costs.

[0038] In some embodiments, step S210 may specifically include: receiving fault description information of the target application input by the terminal device; or, when a fault is detected in the target application, generating fault description information.

[0039] In this embodiment, the fault description information of the target application input by the terminal device can be received through the input interface of the terminal device. Exemplarily, the input interface can be at least one of the following: a text information input interface and an audio information input interface. When the input interface is a text information input interface, the fault description information can be received through the keyboard (or key virtual keyboard) of the terminal device, and when the input interface is an audio information input interface, the fault description information can be received through the microphone array of the terminal device.

[0040] As a specific example, the terminal device includes a help module, and the operation page of the help module includes a first interactive entry element for triggering information feedback (for example, an "information feedback" button). In response to an operation instruction for the first interactive entry element, a user feedback page is opened, and the user feedback page includes a second interactive entry element for receiving fault description information. In response to an operation instruction for the second interactive entry element (for example, a text input box, a voice input button, etc.), the fault description information is received through a text information input interface (corresponding to the text input box) or an audio information input interface (corresponding to the voice input button) of the terminal device.

[0041] Each application of the terminal device may include a help module, or a log analysis upload tool is run on the terminal device, and the log analysis upload tool includes the help module.

[0042] In this embodiment, when an application fails, considering that the user may not be clear about which application has failed (in this case, the log analysis upload tool can be selected to feedback the fault description information), or the cause of the failure of the current application (in this case, at least one of the log analysis upload tool and the help module of the current application can be selected to feedback the fault description information), but only knows the fault phenomenon, at this time, the fault description information input by the user can be received through the input interface of the terminal device, which is conducive to the rapid acquisition of the fault description information.

[0043] In this embodiment, the terminal device can also perform fault self-detection. There are many ways to perform fault self-detection, for example, the terminal device can automatically perform fault self-detection at a fixed time, and generate fault description information when a fault occurs in the target application; or the terminal device includes a terminal display interface, the terminal display interface includes a first interactive element, the first interactive element is used to trigger the fault self-detection, and in response to an operation instruction for the first interactive element, the terminal device starts the fault self-detection, and generates fault description information when a fault occurs in the target application.

[0044] Exemplarily, the first interactive element may be an option or button provided by the terminal interface, and the display information of the first interactive element may include but is not limited to any one of: "Start fault detection", "Fault self-check", etc.; exemplary, the operation instruction for the first interactive element may be an instruction triggered by a click operation, a selection operation, etc.

[0045] In this embodiment, the fault description information of the target application can be obtained in a variety of ways to provide an information basis for subsequently determining the fault association module according to the fault description information.

[0046] Figure 3 A flowchart of determining a first fault association module of a target application according to fault description information in an embodiment of the present application is shown.

[0047] like Figure 3 As shown, in some embodiments, step S220 may specifically include: S11, using a pre-trained fault prediction model to process the fault description information to obtain at least one predicted associated module information; S12, using the fault associated module of the target application corresponding to the associated module information as the first fault associated module.

[0048] In this embodiment, a pre-trained fault prediction model can be used to make predictions based on the fault description information, and the prediction result can be: associated module information of at least one associated module whose fault probability value is greater than a predetermined probability threshold, thereby facilitating the prediction of a module in which a fault occurs in the terminal device based on the fault description information.

[0049] In some embodiments, step S11 may specifically include: using a pre-trained fault prediction model to process the fault description information to obtain at least one prediction label, each prediction label is used to indicate at least one predicted associated module information.

[0050] In this embodiment, the fault description information can be predicted through a pre-trained fault prediction model, and the prediction result can be at least one prediction label. Each prediction label can correspond to one or more predicted associated module information. The module to which the associated module information belongs is the module predicted to be likely to fail, so that the log content corresponding to the prediction label can be subsequently obtained from the operating system log of the terminal device through the prediction label.

[0051] In some embodiments, step S230 may specifically include: S21, obtaining the operating system log of the terminal device to which the target application belongs, the operating system log including multiple module labels; S22, based on each prediction label, determining the similarity value between the corresponding prediction label and each module label; S23, obtaining the module corresponding to the module label whose similarity value is greater than the first threshold as the first fault prediction module of the target application.

[0052] Through the above steps S21-S23, for each prediction label, the module corresponding to the module label whose similarity value with the prediction label is greater than the first threshold can be obtained from the multiple module labels contained in the operating system log of the terminal device as the first fault prediction module, and then the log information of the first fault prediction module can be obtained from the operating system log of the terminal device, and the log information of other modules except the log information of the first fault prediction module can be deleted from the operating system log of the terminal device to filter the operating system log of the terminal device.

[0053] In some embodiments, after the log information of the first fault association module is obtained, the log information of the first fault prediction module may be determined as the fault feedback log of the target application, and the fault feedback log of the target application may be uploaded.

[0054] In this embodiment, the model can be used to predict modules based on the user's fault description, and the corresponding trust boundary can be set (the modules corresponding to labels other than the predicted label are regarded as modules predicted to be unrelated to the target application's fault and are trusted modules), and the log information not involving the fault-related modules is filtered out. Only the log information of the fault-related modules is uploaded, rather than the entire content of the operating system log, to achieve log upload based on the principle of minimum data upload.

[0055] Figure 4 A flowchart of obtaining log information of a first fault association module and uploading the log information is shown in an embodiment of the present application.

[0056] like Figure 4 As shown, in some embodiments, step S230 may specifically include: S31, determining target information containing sensitive information from the log information of the first fault association module; S32, desensitizing the target information to obtain desensitized log information; S33, uploading the desensitized log information.

[0057] In this embodiment, the sensitive information contained in the log information of the first fault association module to be uploaded may be filtered first, and then the desensitized log information may be uploaded to achieve desensitization of the sensitive information.

[0058] In some embodiments, after step S32, the desensitized log information may be encrypted to obtain encrypted log information, and step S33 may specifically include: uploading the encrypted log information. In the case of desensitizing sensitive information, the transmission security of the log information is further achieved.

[0059] In some embodiments, step S31 specifically includes: S41, obtaining a preset information filtering strategy, the information filtering strategy including at least one regular expression of a sensitive information type; S42, obtaining log information matching the regular expression from the log information of the first fault association module as target information; step S32 specifically may include: S43, determining the sensitive information type corresponding to the regular expression matched by the target information; S44, performing corresponding desensitizing processing on the target information based on the sensitive information type to obtain the desensitized log information.

[0060] Exemplarily, the information filtering strategy may specifically include regular expressions for different sensitive information types. The regular expressions are used to define the grammatical rules of sensitive information, so that character strings that conform to the grammatical rules are identified as sensitive information. When the sensitive information includes multiple information types, an information filtering strategy can be formed by combining multiple regular expressions.

[0061] Exemplarily, sensitive information such as name, password, email address, telephone number, address, etc. in the log information of the first fault association module may be desensitized to protect user information security from the source.

[0062] In this embodiment, based on whether the log information of the first fault association module matches the regular expression, it can be determined whether the log information of the first fault association module includes sensitive information; further, it can be determined which regular expression the log information of the first fault association module matches, so that the specific information type of the sensitive information can be determined in the log information of the first fault association module, so that corresponding desensitization processing can be performed accordingly based on different information types.

[0063] In some embodiments, after step S33, the method further includes: S51, generating a confirmation prompt message, the confirmation prompt message is used to indicate fault information and reminder information; wherein the fault information is used to identify the first fault association module, and the reminder information is used to indicate that the log information of the first fault association module has been desensitized; S52, in response to a confirmation instruction for the confirmation prompt message, uploading the log information of the first fault association module to a predetermined server.

[0064] As an example, the predetermined server may be a research and development backend server or a server corresponding to a fault analysis platform, and the fault analysis platform is used to perform problem analysis and problem location according to log information of the first fault association module uploaded by the terminal device.

[0065] In this embodiment, after the corresponding risk notification prompt is made, the abnormal logs can be packaged and uploaded to the server according to the instructions for confirming submission.

[0066] According to the log uploading method of the embodiment of the present disclosure, when obtaining the log information of the first fault association module of the target application and uploading the log information, sensitive information in the log information can be protected to a certain extent, and the log information not involving the fault association module can be filtered out, thereby saving network resources and storage resources and reducing the manpower maintenance costs of servers and R&D personnel.

[0067] Figure 5 Detailed flow chart showing a log uploading method according to some exemplary embodiments of the present application. Figure 5As shown, the log uploading method includes: mobile phone processing process, module prediction and log uploading process, and data encryption and desensitization process.

[0068] like Figure 5 As shown, the module pre-judgment and minimum upload process may include the following steps.

[0069] S501, data preparation.

[0070] In this step, data preparation may include the following sub-steps: collecting historical fault data, for example, collecting user-submitted fault descriptions and corresponding module information from a database or log file; performing data cleaning on the historical fault data, for example, removing duplicates, null values, or irrelevant information; and labeling the cleaned historical fault data, for example, associating each fault description with one or more module labels.

[0071] Exemplarily, if the user's description of the fault is "XX account application is stuck in use", the module label can be at least one of the following: "XX account", "Performance optimization", "Data network access", "WiFi network access", indicating that the fault-related module is at least one of the following: "XX account" module, "Performance optimization" module, "Data network access" module or "WiFi network access" module.

[0072] S502, feature extraction.

[0073] In this step, each fault description may be preprocessed first, for example, word segmentation, stop word removal, stem extraction, etc. may be performed on the fault description; then feature extraction may be performed, for example, term frequency-inverse document frequency (TF-IDF) technology, word embedding (such as Word2Vec, a tool for generating word vectors, or GloVe, a word vector neural network model), etc. may be used to convert the text of the extracted stem into a numerical vector of the corresponding stem.

[0074] S503, model training.

[0075] In this step, first, an algorithm for model training is selected. Considering that a fault description may correspond to multiple fault-related modules, a multi-label classification algorithm can be selected, such as a random forest algorithm, a K-nearest neighbor algorithm (K-NN), or a neural network algorithm; secondly, model training is performed. Specifically, the model is trained using the features of the extracted stems and the module labels to obtain a trained model; then, model validation is performed. Specifically, cross-validation or an independent validation set can be used to evaluate the model performance. When the model performance reaches a predetermined performance indicator, the model training is stopped.

[0076] S504, model deployment.

[0077] In this step, the model is first exported. Specifically, the trained model can be saved in a deployable format, such as the Predictive Model Markup Language (PMML) format, the Open Neural Network Exchange (ONNX) or a format supported by a specific platform. For example, the model is published to the streaming platform kafka in a data-like manner, and the application side calls and predicts the model in the manner of consuming the model. It should be understood that the format of model deployment can be customized according to actual conditions, and the embodiments of the present disclosure do not make specific limitations; secondly, the model is serviced. Specifically, the model can be deployed as a model service with an application programming interface (API), and the trained model can be accessed by calling the API interface, or the model can be integrated into the existing user fault submission system of the terminal device, and the integrated model can be directly called in the user fault submission system to predict the fault description information.

[0078] S505, online application.

[0079] In this step, first, the terminal device receives the fault description information or performs a fault self-check to obtain the fault description information. Taking the reception of the fault description information as an example, when the user submits the fault description information through the input interface of the terminal device, the fault description information is sent to the model service interface of the fault prediction model; secondly, data preprocessing, specifically, data cleaning of the fault description information; then model prediction, specifically, feature extraction of the cleaned fault description information, and prediction of the extracted features using the fault prediction model to obtain a prediction label for indicating at least one predicted associated module information, that is, one or more module categories that may fail.

[0080] S506, log filtering.

[0081] In this step, the logs of modules not related to the fault can be filtered from the operating system log of the terminal device according to the prediction results. For example, if the fault description information entered by the user is "XX account application usage is slow", after filtering, the fault log records to be uploaded to the server include at least one of the following: log information corresponding to the module label "XX account", log information corresponding to the module label "performance optimization", log information corresponding to the module label "data network access", and log information corresponding to the module label "WiFi network access".

[0082] S507: Encrypt and desensitize sensitive information.

[0083] In this step, filtering sensitive information in the operating system log is an important security measure to protect user privacy. The following describes the specific process of identifying and filtering sensitive information such as user identification (ID), password, contact information, etc. contained in the log through a specific example.

[0084] Reference Figure 5 In the "Data Encryption and Desensitization" process, step S507 may specifically include the following steps:

[0085] S5071, define a rule policy. Specifically, a rule policy needs to be defined to define the category of sensitive information, that is, which information is considered sensitive information and needs to be filtered or replaced. Sensitive information may include at least one of the following: user name and password, email address, phone number, address, etc.

[0086] S5072, identifying sensitive information. Specifically, the regular expressions included in the rule policy may be used to identify the sensitive information.

[0087] For example: usernames and passwords are usually alphanumeric, email addresses have a specific format, and phone numbers have a specific format. Here are some example regular expressions for emails and phone numbers:

[0088] EMAIL_REGEX=r'\b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[AZ|az]{2,7}\b'

[0089] PHONE_REGEX=r'\b\d{3}[-.\s]? \d{3}[-.\s]? \d{4}\b'

[0090] EMAIL_REGEX is the regular expression for the email address format, and PHONE_REGEX is the regular expression for the phone number.

[0091] S5073, filter or replace sensitive information. Specifically, the operating system log can be received by the written function, each information entry in the operating system log can be used as input, and a regular expression can be used to find and replace sensitive information. For example, in the following code "

[0092] Python

[0093] Copy code

[0094] import re

[0095] def filter_privacy_info(log_entry):

[0096] log_entry=re.sub(EMAIL_REGEX,'[EMAIL]',log_entry)

[0097] log_entry=re.sub(PHONE_REGEX,'[PHONE]',log_entry)

[0098] return log_entry", a filter() function is defined to filter out log information in the operating system log that does not conform to the regular expression and return the log information that conforms to the regular expression; re.sub() is used to implement regular replacement, specifically, to replace the log information in the operating system log that conforms to the regular expression (EMAIL_REGEX) of email with a predetermined log item (log_entry), such as the predetermined first replacement information (non-sensitive information) or a null value; to replace the log information in the operating system log that conforms to the regular expression (PHONE_REGEX) of mobile phone numbers with a predetermined log item (log_entry), such as the predetermined second replacement information (non-sensitive information) or a null value. The first replacement information and the second replacement information may be the same or different, as long as they are non-sensitive information, and the embodiments of the present application do not make specific limitations.

[0099] S5074, encryption processing. Specifically, the log information after filtering or replacing the sensitive information can be encrypted to obtain encrypted and desensitized log information.

[0100] S508, package and upload and display prompt information.

[0101] In this step, the encrypted and desensitized log information is packaged, and before being uploaded to the server, a prompt message is generated and displayed to remind the user that the fault module and log information involved in the log have been desensitized. After receiving the user's confirmed upload instruction, the log information is uploaded to the predetermined server.

[0102] Continue to refer to Figure 5 For a terminal device such as a mobile phone, the log uploading method includes the following steps.

[0103] S50A: Receive fault description information.

[0104] In this step, the fault description information is description information of the perceived application fault input by the user through the input interface of the terminal when the user perceives the application fault.

[0105] S50B, generate a system log.

[0106] In this step, the terminal device can obtain the current operating system log of the terminal device.

[0107] S50C, fault module prediction and minimum upload.

[0108] In this step, the above steps S505-S507 can be called to determine the association module related to the fault of the target application, that is, the first fault association module of the target application, based on the fault description information, and obtain the log information of the first fault association module from the operating system log of the preset terminal device; desensitize and encrypt the log information of the fault association module, and use the encrypted and desensitized log information as the log information to be uploaded.

[0109] refer to Figure 5 After step S50C, the above step S508 can be called to upload the log information.

[0110] Through the log uploading method of the embodiment of the present invention, the fault module prediction and the minimum upload principle can set the trust boundary based on the user's fault description using the model prediction, filter out the corresponding module logs that are not related to the fault, and then provide the user with the corresponding risk notification prompts, and then the abnormal logs can be packaged and uploaded to the R&D background server.

[0111] According to the log uploading method of the embodiment of the present application, fault description information can be received on the user feedback page of the user help module of the terminal device. In the case that the terminal device currently has a user feedback page of the user help module, the log uploading method of the present application will not cause new changes in the user interface in terms of information reception. The interface changes in that: when the user feedbacks the application fault through the user feedback page, a pop-up box is displayed when the log upload is submitted, and the content displayed in the pop-up box includes: the predicted associated module information and the prompt information that the log information to be uploaded has been desensitized, and the user interaction elements included in the pop-up box (such as the "Confirm to submit the log" button) respond to the operation instructions of the user interaction elements to upload the encrypted and packaged log to the server.

[0112] Compared with the related technologies such as using the log history data of the terminal device to determine the priority of the information to be uploaded, or classifying the log into abnormal types based on the predetermined abnormal log keywords, the log upload method of the embodiment of the present application can save resources. Specifically, from the perspective of network resources, especially in a mobile network environment, uploading only logs related to the fault will save a lot of network bandwidth resources; from the perspective of storage resources, only uploading logs involving faults can reduce the storage space consumption of the server to a certain extent; from the perspective of computing and processing resources, analyzing all logs requires more computing power, which will increase the server and labor costs, while according to the method of the present application, only the log information of the fault-related fault-related module needs to be analyzed, which can save server and labor costs; from the perspective of battery life, on a mobile device, only uploading logs involving faults can reduce the power consumption to a certain extent. In general, this method greatly reduces the use of network bandwidth and reduces user-perceivable pain points by uploading only log information related to the fault; and only storing logs related to the fault on the server will also reduce storage space consumption to a certain extent; and, only analyzing logs of applications related to the fault will reduce the computing and analysis burden on the server and manpower, thereby locating problems more quickly and improving the efficiency of fault repair.

[0113] It can be understood that the above-mentioned various method embodiments mentioned in this application can be combined with each other to form a combined embodiment without violating the principle logic. Due to space limitations, this application will not go into details. Those skilled in the art can understand that in the above-mentioned method of the specific implementation method, the specific execution order of each step should be determined by its function and possible internal logic.

[0114] In addition, the present application also provides a log uploading device, a terminal device, and a computer-readable storage medium, all of which can be used to implement any log uploading method provided by the present application. The corresponding technical solutions and descriptions are referred to in the corresponding records of the method part and will not be repeated here.

[0115] In a second aspect, an embodiment of the present application provides a log uploading device.

[0116] Figure 6 A block diagram of a log upload device provided in an embodiment of the present application. Figure 6 , an embodiment of the present application provides a log uploading device, and the log uploading device 600 may include the following modules.

[0117] The acquisition module 610 is used to obtain the fault description information of the target application; the determination module 620 is used to determine the first fault association module of the target application according to the fault description information; the acquisition module 610 is also used to obtain the log information of the first fault association module; the upload module 630 is used to upload the log information.

[0118] In some embodiments, when the acquisition module 610 is used to acquire the fault description information of the target application, it is specifically used to: receive the fault description information of the target application input by the terminal device; or generate the fault description information when a fault is detected in the target application.

[0119] In some embodiments, the determination module 620 is specifically used to: process the fault description information using a pre-trained fault prediction model to obtain at least one predicted associated module information; and use the fault associated module of the target application corresponding to the associated module information as the first fault associated module.

[0120] In some embodiments, when the determination module 620 is used to process the fault description information using a pre-trained fault prediction model to obtain at least one predicted associated module information, it is specifically used to: process the fault description information using a pre-trained fault prediction model to obtain at least one prediction label, each prediction label is used to indicate at least one predicted associated module information.

[0121] In some embodiments, the determination module 620, when used to determine the first fault-associated module of the target application based on the fault description information, is specifically used to: obtain an operating system log of a terminal device to which the target application belongs, the operating system log including a plurality of module labels; based on each prediction label, determine a similarity value between the corresponding prediction label and each module label; obtain a module corresponding to a module label having a similarity value greater than a first threshold value as the first fault prediction module of the target application.

[0122] The acquisition module 610, when used to obtain the log information of the first fault association module, is specifically used to: determine the target information containing sensitive information from the log information of the first fault association module; desensitize the target information to obtain the desensitized log information; the upload module 630 is specifically used to upload the desensitized log information.

[0123] In some embodiments, the acquisition module 610, when used to determine target information containing sensitive information from the log information of the first fault association module, is specifically used to: obtain a preset information filtering strategy, the information filtering strategy includes at least one regular expression of a sensitive information type; obtain log information that matches the regular expression from the log information of the first fault association module as target information; and, when used to desensitize the target information to obtain desensitized log information, is specifically used to: determine the sensitive information type corresponding to the regular expression matched by the target information; and perform corresponding desensitization on the target information based on the sensitive information type to obtain desensitized log information.

[0124] In some embodiments, the upload module 630 is specifically used to: generate a confirmation prompt message, the confirmation prompt message is used to indicate fault information and reminder information; wherein the fault information is used to identify the first fault association module, and the reminder information is used to indicate that the log information of the first fault association module has been desensitized; in response to a confirmation instruction for the confirmation prompt message, upload the log information of the first fault association module to a predetermined server.

[0125] According to the log upload module of the embodiment of the present application, when the fault description information of the target application is obtained, the fault association module of the target application can be determined based on the fault description information, and then the log information of the fault association module can be obtained, and the acquired log information of the fault association module can be uploaded; according to this method, the log information of the fault association module associated with the fault of the target application can be used to upload the log, which is beneficial to reduce the amount of log information uploaded by the terminal device, thereby helping to save the network resources and storage resources involved in log uploading, and reducing server and manpower maintenance costs.

[0126] It should be clear that the present invention is not limited to the specific configurations and processes described in the above embodiments and shown in the figures. For the convenience and brevity of description, a detailed description of the known methods is omitted here, and the specific working processes of the systems, modules and units described above can refer to the corresponding processes in the aforementioned method embodiments, which will not be repeated here.

[0127] Each module in the above log upload device can be implemented in whole or in part by software, hardware, or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute operations corresponding to each module.

[0128] In a third aspect, the embodiments of the present application further provide an electronic device. In some embodiments, the electronic device can be implemented as the terminal device in the above embodiments.

[0129] Figure 7 A structural diagram showing an exemplary hardware architecture of an electronic device capable of implementing the method and apparatus according to an embodiment of the present invention. Figure 7 The electronic device includes: at least one processor 701; at least one memory 702, and one or more I / O interfaces 703; wherein the memory 702 stores one or more computer programs that can be executed by at least one processor 701, and the one or more computer programs are executed by at least one processor 701 so that the at least one processor 701 can execute the above-mentioned log uploading method.

[0130] Among them, the processor is a device with data processing capabilities, including but not limited to the central processing unit (CPU); the memory is a device with data storage capabilities, including but not limited to random access memory (RAM, more specifically SDRAM, DDR, etc.), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory (FLASH); the I / O interface (read-write interface) is connected between the processor and the memory, and can realize information exchange between the memory and the processor, including but not limited to the data bus (Bus), etc.

[0131] The embodiment of the present application also provides a computer-readable storage medium on which a computer program is stored, wherein the computer program implements the above-mentioned log uploading method when executed by the processor / processing core. The computer-readable storage medium can be a volatile or non-volatile computer-readable storage medium.

[0132] Those skilled in the art will appreciate that all or some of the steps, systems, and functional modules / units in the apparatus disclosed above may be implemented as software, firmware, hardware, or a suitable combination thereof.

[0133] In hardware implementations, the division between functional modules / units mentioned in the above description does not necessarily correspond to the division of physical components; for example, one physical component may have multiple functions, or one function or step may be performed by several physical components in cooperation.

[0134] Some physical components or all physical components may be implemented as software executed by a processor, such as a central processing unit (CPU), a digital signal processor or a microprocessor, or implemented as hardware, or implemented as an integrated circuit, such as an application-specific integrated circuit. Such software may be distributed on a computer-readable medium, which may include a computer storage medium (or non-temporary medium) and a communication medium (or temporary medium). As known to those of ordinary skill in the art, the term computer storage medium includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules or other data). Computer storage media include, but are not limited to, random access memory (RAM, more specifically SDRAM, DDR, etc.), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory (FLASH) or other disk storage; read-only compact disk (CD-ROM), digital versatile disk (DVD) or other optical disk storage; magnetic cassettes, magnetic tapes, disk storage or other magnetic storage; any other medium that can be used to store desired information and can be accessed by a computer. Furthermore, it is well known to those skilled in the art that communication media typically embodies computer readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media.

[0135] The present application has disclosed example embodiments, and although specific terms are used, they are only used and should only be interpreted as general illustrative meanings, and not for limiting purposes. In some instances, it will be apparent to those skilled in the art that, unless otherwise expressly indicated, features, characteristics, and / or elements described in conjunction with a particular embodiment may be used alone, or in combination with features, characteristics, and / or elements described in conjunction with other embodiments. Therefore, it will be understood by those skilled in the art that various changes in form and detail may be made without departing from the scope of the present application as set forth in the appended claims.

Claims

1. A log upload method, in, The method comprises: Get the fault description information of the target application; Determining a first fault association module of the target application according to the fault description information; Obtain log information of the first fault association module, and upload the log information.

2. The method according to claim 1, in, The obtaining of the fault description information of the target application includes: Receiving fault description information of the target application input by a terminal device; Alternatively, when a failure of the target application is detected, the failure description information is generated.

3. The method according to claim 1, in, The determining, according to the fault description information, a first fault association module of the target application includes: Processing the fault description information using a pre-trained fault prediction model to obtain at least one predicted associated module information; The fault association module of the target application corresponding to the association module information is used as the first fault association module.

4. The method according to claim 3, in, The method of processing the fault description information by using the pre-trained fault prediction model to obtain at least one predicted associated module information includes: The fault description information is processed using a pre-trained fault prediction model to obtain at least one prediction label, each of which is used to indicate at least one predicted associated module information.

5. The method according to claim 4, in, The determining, according to the fault description information, a first fault association module of the target application includes: Obtaining an operating system log of a terminal device to which the target application belongs, wherein the operating system log includes a plurality of module tags; Based on each of the predicted labels, determining a similarity value between the corresponding predicted label and each of the module labels; A module corresponding to a module label having a similarity value greater than a first threshold is obtained as a first fault prediction module of the target application.

6. The method according to claim 1, in, The obtaining log information of the first fault association module and uploading the log information includes: Determining target information containing sensitive information from the log information of the first fault association module; Performing desensitization processing on the target information to obtain desensitized log information; Upload the desensitized log information.

7. The method according to claim 6, in, The step of determining target information containing sensitive information from the log information of the first fault association module includes: Obtaining a preset information filtering strategy, wherein the information filtering strategy includes at least one regular expression of a sensitive information type; Acquire, from the log information of the first fault association module, log information matching the regular expression as the target information; The desensitizing the target information to obtain the desensitized log information includes: Determine the sensitive information type corresponding to the regular expression matched by the target information; The target information is desensitized based on the sensitive information type to obtain desensitized log information.

8. The method according to claim 6, in, The uploading of the log information includes: Generate confirmation prompt information, the confirmation prompt information is used to indicate fault information and reminder information; wherein the fault information is used to identify the first fault association module, and the reminder information is used to indicate that the log information of the first fault association module has been desensitized; In response to a confirmation instruction for the confirmation prompt information, the log information of the first fault association module is uploaded to a predetermined server.

9. A terminal device, include: at least one processor; A memory having at least one program stored thereon, wherein when the at least one program is executed by the at least one processor, the at least one processor implements the method according to any one of claims 1 to 8.

10. A storage medium, in, The storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 8 is implemented.