Fault anomaly classification method, device and readable storage medium
By performing multi-level classification and updating the field lookup table for fault and anomaly data, the problem of inaccurate classification in existing technologies is solved, enabling rapid filtering and refined fault and anomaly localization, and dynamically updating the field lookup table to adapt to various anomaly types.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-16
- Publication Date
- 2026-04-14
AI Technical Summary
Existing fault and anomaly classification methods are too granular, resulting in inaccurate classification and an inability to accurately locate the main fault points of the application.
The abnormal data is first categorized to find and sort those containing specific fields. Then, a second categorization and field lookup table conversion are performed. Fields not entered are translated using a third-party translation interface, and the field lookup table is updated. Finally, the results are displayed in an intuitive table or bar chart.
It enables rapid filtering and fine-grained classification of faults and anomalies, ensuring that developers can accurately locate faults and anomalies, and dynamically update the field lookup table to accommodate various anomaly types.
Smart Images

Figure CN114398195B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of computers, and more specifically to a fault and anomaly classification method, apparatus, and readable storage medium. Background Technology
[0002] Typically, after an application is released, various factors such as hardware environment, software environment, and human operation may cause abnormal situations to occur in the application. These abnormalities are generally referred to as crashes. When a crash occurs, the application logs are retrieved to collect fault and abnormal information, which is then reported. The cause of the crash is determined based on the reported fault and abnormal information.
[0003] When performing fault and anomaly analysis on data, it is often necessary to sort the reported problems one by one, and usually, the sorting criteria may be different crash functions.
[0004] In existing technologies, the classification of faults and anomalies is too granular, which is not conducive to the unified classification of faults and anomalies. As a result, the classification will not reflect the main fault points of the application due to inaccurate classification. Summary of the Invention
[0005] The purpose of this invention is to at least solve one of the technical problems existing in the prior art, and to provide a fault and anomaly classification method, device and readable storage medium, which can quickly filter faults and anomalies, enabling developers to more accurately locate faults and anomalies.
[0006] A fault anomaly classification method according to a first aspect of the present invention includes: acquiring anomaly data in response to a fault anomaly classification request; performing a first classification process on the anomaly data to obtain a first classification result; and performing a second classification process on the first classification result to obtain a second classification result.
[0007] The fault and anomaly classification method according to the first aspect of the present invention has at least the following beneficial effects: it can quickly filter faults and anomalies, enabling developers to more accurately locate faults and anomalies.
[0008] According to a first aspect of the present invention, a fault anomaly classification method is provided, wherein performing a first classification process on the anomaly data to obtain a first classification result includes: checking whether the anomaly data includes a first field; and sorting the anomaly data including the first field by at least one of anomaly quantity, anomaly percentage, anomaly device quantity, and / or anomaly function.
[0009] The fault anomaly classification method according to the first aspect of the present invention has at least the following beneficial effects: it achieves refined classification of the abnormal data in the first aspect.
[0010] According to a first aspect of the present invention, a fault anomaly classification method is provided, wherein a first field is obtained by performing a first parsing on the anomaly function, and the presence of an EXCEPTION field and / or an ERROR field in the anomaly function string is taken as the first classification result.
[0011] The fault and anomaly classification method according to the first aspect of the present invention has at least the following beneficial effects: it enables rapid filtering of faults and anomalies.
[0012] According to a first aspect of the present invention, a fault anomaly classification method, wherein performing a second classification process on the first classification result to obtain a second classification result includes: performing a second parsing on the first classification result, classifying the presence of a second field in the anomaly function string, and obtaining the second classification result.
[0013] According to a first aspect of the present invention, a fault anomaly classification method, wherein filtering by a second field includes: filtering the anomaly function string by the value of the second field.
[0014] According to a first aspect of the present invention, the fault anomaly classification method further includes filtering by a second field by: searching for the second field from a field lookup table and filtering the anomaly function string that includes the second field.
[0015] According to a first aspect of the present invention, the fault anomaly classification method includes converting the second classification result into anomaly categories to obtain a conversion result, which includes: looking up a field lookup table through the second field to obtain a conversion field for the second field; and classifying the second classification result including the second field through the conversion field to obtain the conversion result.
[0016] The fault anomaly classification method according to the first aspect of the present invention has at least the following beneficial effects: after conversion through a specific field lookup table, more intuitive fault information can be displayed.
[0017] According to a first aspect of the present invention, the fault anomaly classification method further includes: if the second field does not find a corresponding conversion field in the field lookup table, then obtaining the abnormal function string in the second category, calling a third-party translation interface to translate the abnormal function string word by word to obtain a translation field, and classifying the result according to the translation field.
[0018] The fault anomaly classification method according to the first aspect of the present invention has at least the following beneficial effects: it performs fault translation on other fields that have not been classified, ensuring the classification and intuitive display of fields not entered into the field lookup table.
[0019] The fault anomaly classification method according to a first aspect of the present invention further includes: performing statistics on identical translation fields; if the number of translation fields exceeds a preset number, creating a new third category; and updating the field lookup table with the translation fields.
[0020] The fault and anomaly classification method according to the first aspect of the present invention has at least the following beneficial effects: by dynamically updating a large number of non-entry field lookup tables, the classification of faults and anomalies is dynamically classified.
[0021] According to the fault anomaly classification method of the first aspect of the present invention, the third category is displayed according to preset display rules. It is displayed intuitively through customized tables or bar charts.
[0022] According to a second aspect of the present invention, a fault anomaly classification apparatus includes: an anomaly data acquisition module for acquiring a fault anomaly classification request and acquiring anomaly data; a first classification module for performing a first classification process on the anomaly data to obtain a first classification result; and a second classification module for performing a second classification process on the first classification result to obtain a second classification result.
[0023] The fault and anomaly classification method according to the first aspect of the present invention has at least the following beneficial effects: it can quickly filter faults and anomalies, enabling developers to more accurately locate faults and anomalies.
[0024] A computer-readable storage medium according to a third aspect of the present invention stores computer-executable instructions, wherein the computer-executable instructions are used to perform the fault anomaly classification method described in the first aspect.
[0025] Additional aspects and advantages of the invention will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. Attached Figure Description
[0026] The present invention will be further described below with reference to the accompanying drawings and embodiments;
[0027] Figure 1 This is a flowchart of a fault anomaly classification method provided in one embodiment of this application;
[0028] Figure 2 This is a flowchart of a fault anomaly classification method provided in another embodiment of this application;
[0029] Figure 3 This is a flowchart of a fault anomaly classification method provided in another embodiment of this application;
[0030] Figure 4This is a flowchart of a fault anomaly classification method provided in another embodiment of this application;
[0031] Figure 5 This is a flowchart of a fault anomaly classification method provided in another embodiment of this application;
[0032] Figure 6 This is a flowchart of a fault anomaly classification method provided in another embodiment of this application;
[0033] Figure 7 This is a flowchart of a fault anomaly classification method provided in another embodiment of this application;
[0034] Figure 8 This is a block diagram of a fault anomaly classification device provided in another embodiment of this application. Detailed Implementation
[0035] This section will describe in detail specific embodiments of the present invention. Preferred embodiments of the present invention are shown in the accompanying drawings. The purpose of the drawings is to supplement the textual description with graphics, so that people can intuitively and vividly understand each technical feature and overall technical solution of the present invention, but they should not be construed as limiting the scope of protection of the present invention.
[0036] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0037] It should be noted that although functional modules are divided in the device schematic diagram and a logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart. The terms "first," "second," and "third," etc., in the specification, claims, and the aforementioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence.
[0038] The client and server can communicate directly, such as via WiFi or Bluetooth; or they can communicate through a third-party network, such as via mobile internet (2G / 3G / 4G / 5G, etc.).
[0039] In the description of this invention, unless otherwise explicitly defined, terms such as "setup" should be interpreted broadly, and those skilled in the art can reasonably determine the specific meaning of the above terms in this invention in conjunction with the specific content of the technical solution.
[0040] Reference Figure 1 , Figure 1 The example fault and anomaly classification method includes the following steps:
[0041] S1110, in response to the fault / anomaly classification request, obtain anomaly data;
[0042] S1120, Perform the first classification process on the abnormal data to obtain the first classification result;
[0043] S1130, Perform second classification processing on the first classification result to obtain the second classification result.
[0044] In some embodiments, abnormal data is obtained by obtaining log data generated when the application fails or encounters an exception. By obtaining the log data, the abnormal data of the application during runtime can be obtained.
[0045] In some embodiments, abnormal data also needs to be processed, and abnormal data can be filtered and selected by setting fields;
[0046] In some embodiments, the abnormal data obtained initially is usually inconvenient to view and the data format is relatively complex. Therefore, it is necessary to perform secondary classification, that is, to filter by setting some keywords to obtain the fault and abnormal data that the developers want.
[0047] In some embodiments, it is also necessary to perform field conversion on the fault and exception data that developers want, such as converting it into Chinese fault information or fault information corresponding to numbers, so as to facilitate developers to perform statistics and look up information.
[0048] According to the solution provided in the embodiments of this application, faults and anomalies are quickly filtered, enabling developers to more accurately locate faults and anomalies.
[0049] Reference Figure 2 , Figure 2 The example fault and anomaly classification method includes the following steps:
[0050] S1210, Check if abnormal data includes data passed through the first field;
[0051] S1220, sort the abnormal data including the first field by at least one of the following: number of abnormalities, percentage of abnormalities, number of abnormal devices, and / or abnormal function.
[0052] In some embodiments, in order to distinguish faults in log information, ERROR and EXCEPTION are commonly used fields in commonly used fault information, and the filtering method of ERROR and EXCEPTION fields can be customized to meet the needs of different project faults and anomalies.
[0053] According to the solution provided in the embodiments of this application, the refined classification of abnormal data in the first aspect is achieved.
[0054] Reference Figure 3 , Figure 3 The example fault and anomaly classification method includes the following steps:
[0055] S1310, Perform second parsing on the first classification result, classify the exception function string that contains a second field, and obtain the second classification result.
[0056] In some embodiments, when developers want to focus on device-related anomalies, they can filter the fault and anomaly data by using "device" to obtain only the fault and anomaly data that includes device anomalies.
[0057] In some implementations, the settings of the second field can often be customized according to the requirements of project development.
[0058] According to the solution provided in the embodiments of this application, rapid filtering of faults and anomalies is achieved, and fault information that developers want to focus on is obtained.
[0059] Reference Figure 4 , Figure 4 The example fault and anomaly classification method includes the following steps:
[0060] S1410, Look up the field lookup table through the second field to obtain the transformed field of the second field;
[0061] S1420, the second classification result, including the second field, is classified by the transformation field to obtain the transformation result.
[0062] In some embodiments, the exception fields DeviceRemoved and DeviceReset both represent device-related exceptions, while RaiseBadAllocException and OutOfMemory both represent memory-related exceptions. In order to make the faults more intuitive, the above DeviceRemoved, DeviceReset, RaiseBadAllocException and OutOfMemory are converted through a field lookup table to obtain the corresponding classification results: device exceptions and memory exceptions.
[0063] In some embodiments, the second field is a preset field, that is, the abnormal function string is filtered by the abnormal value of the second field.
[0064] In some embodiments, the exception function string that includes the second field is filtered from the preset field corresponding to the field lookup table.
[0065] According to the solution provided in the embodiments of this application, after conversion through a specific field lookup table, more intuitive fault information can be displayed.
[0066] refer to Figure 5, Second aspect, another fault and exception classification method implemented by the present invention, including the steps:
[0067] S1510, if the corresponding conversion field cannot be found in the field look-up table for the second field, obtain the exception function string in the second classification, call the third-party translation interface to translate each word of the exception function string to obtain the translation field, and classify according to the translation field to obtain the conversion result.
[0068] In some embodiments, for example, the exception NullPointException (null pointer exception) is not shown in the field look-up table. In this embodiment, by decomposing NullPointException, Null, Point, and Exception are obtained, and their corresponding Chinese translations, namely null, pointer, and exception, are obtained and combined.
[0069] According to the fault and exception classification method of the first aspect embodiment of the present invention, it has at least the following beneficial effects: fault translation is performed on other fields that have not been classified, ensuring the classification and intuitive display of fields that have not been entered into the field look-up table.
[0070] Reference Figure 6 , another fault and exception classification method implemented by the present invention, including the steps:
[0071] S1610, count the same translation fields; and update the field look-up table with the translation fields;
[0072] S1620, if the number of translation fields exceeds the preset number, create a new third classification;
[0073] S1630, perform exception category conversion on the second classification result to obtain the conversion result.
[0074] In some embodiments, when there are multiple keywords (in English) that are the same and not included in the field look-up table, the technical solution of the present invention can be used to translate the keywords (in English), and the translated fault and exception information is entered into the field look-up table for updating.
[0075] In some embodiments, when the data of the same keyword (in English) exceeds the set number, the update of the field look-up table can be triggered.
[0076] According to the fault and exception classification method of the first aspect embodiment of the present invention, it has at least the following beneficial effects: by dynamically updating the non-entered field look-up table with a large number, ensuring the dynamic classification of faults and exceptions.
[0077] Reference Figure 7 , another fault and exception classification method implemented by the present invention, including the steps:
[0078] S1710, the conversion results are displayed according to preset display rules.
[0079] In one embodiment, the conversion results are displayed using preset rules for generating tables, bar charts, and heatmaps.
[0080] The fault anomaly classification method according to the first aspect of the present invention has at least the following beneficial effects: it can display more intuitive fault anomaly information.
[0081] refer to Figure 8 Secondly, another fault anomaly classification device according to the present invention includes:
[0082] The abnormal data acquisition module is used to obtain fault abnormality classification requests and acquire abnormal data; the first classification module is used to perform first classification processing on the abnormal data and obtain the first classification result; the second classification module is used to perform second classification processing on the first classification result and obtain the second classification result.
[0083] The fault and anomaly classification method according to the first aspect of the present invention has at least the following beneficial effects: it can quickly filter faults and anomalies, enabling developers to more accurately locate faults and anomalies.
[0084] Additionally, embodiments of this application provide a computer-readable storage medium storing computer-executable instructions for performing actions such as... Figures 1-7 A fault / anomaly classification method for any example.
[0085] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.
[0086] It will be understood by those skilled in the art that all or some of the steps and systems in the methods disclosed above can be implemented as software, firmware, hardware, and suitable combinations thereof. Some or all of the physical components can be implemented as software executed by a processor, such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit. Such software can be distributed on a computer-readable medium, which can include computer storage media (or non-transitory media) and communication media (or transient media). As is known to those skilled in the art, the term computer storage media 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 includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technologies, CD-ROM, digital versatile disc (DVD) or other optical disc storage, magnetic cartridges, magnetic tape, disk storage or other magnetic storage devices, or any other medium that can be used to store desired information and is accessible to a computer. Furthermore, as is known to those skilled in the art, communication media typically contain computer-readable instructions, data structures, program modules, or other data in modulated data signals such as carrier waves or other transmission mechanisms, and may include any information delivery medium.
[0087] The above is a detailed description of the preferred embodiments of this application. However, this application is not limited to the above embodiments. Those skilled in the art can make various equivalent modifications or substitutions without departing from the spirit of this application. All such equivalent modifications or substitutions are included within the scope defined by the claims of this application.
Claims
1. A fault anomaly classification method, characterized in that, The method includes: In response to a fault / anomaly classification request, retrieve anomaly data; Perform a first classification process on the abnormal data to obtain a first classification result; Perform a second classification process on the first classification result to obtain a second classification result; specifically, this includes: performing a second parsing on the first classification result, filtering the abnormal function string through a second field to obtain the second classification result, wherein the second field is obtained by custom modification; The second classification result is converted into an anomaly category to obtain a conversion result; the conversion result is obtained by looking up the field lookup table for the second field to obtain the conversion field for the second field; the second classification result including the second field is classified according to the conversion field to obtain the conversion result; if the second field does not find a corresponding conversion field in the field lookup table, the abnormal function string in the second category is obtained, a third-party translation interface is called to translate the abnormal function string word by word to obtain the translation field, the conversion result is obtained by classifying according to the translation field, and the conversion result is displayed according to the preset display image generation rules; If multiple keywords with the same meaning exist but are not included in the field lookup table, the keywords are translated. If the number of keywords exceeds a preset number, the translated fields are entered into the field lookup table for updating. If the number of translated fields exceeds a preset number, a new third category is created.
2. The fault anomaly classification method according to claim 1, characterized in that, The first classification process performed on the abnormal data to obtain the first classification result includes: Check whether the abnormal data includes the first field; The abnormal data including the first field are sorted by at least one of the following: number of abnormalities, percentage of abnormalities, number of abnormal devices, and / or abnormal function.
3. The fault anomaly classification method according to claim 2, characterized in that, The first parsing is performed on the abnormal function using the first field, and the presence of the EXCEPTION field and / or ERROR field in the abnormal function string is taken as the first classification result.
4. The fault anomaly classification method according to claim 1, characterized in that, The filtering via the second field includes: The exception function string is filtered based on the value of the second field.
5. The fault anomaly classification method according to claim 1, characterized in that, The filtering via the second field also includes: The second field is searched from the field lookup table, and the abnormal function strings that include the second field are filtered.
6. The fault anomaly classification method according to any one of claims 1-5, characterized in that, The third category is displayed according to preset display rules.
7. A fault / abnormality classification device, characterized in that, The device includes: an abnormal data acquisition module for acquiring a fault anomaly classification request and acquiring abnormal data; a first classification module for performing a first classification process on the abnormal data to obtain a first classification result; and a second classification module for performing a second classification process on the first classification result to obtain a second classification result. Specifically, it includes performing a second parsing on the first classification result, filtering the abnormal function string through a second field to obtain the second classification result, wherein the second field is obtained through custom modification. The second classification result is converted into an anomaly category to obtain a conversion result; the conversion result is obtained by looking up the field lookup table for the second field to obtain the conversion field for the second field; the second classification result including the second field is classified according to the conversion field to obtain the conversion result; if the second field does not find a corresponding conversion field in the field lookup table, the abnormal function string in the second category is obtained, a third-party translation interface is called to translate the abnormal function string word by word to obtain the translation field, the conversion result is obtained by classifying according to the translation field, and the conversion result is displayed according to the preset display image generation rules; If multiple keywords with the same meaning exist but are not included in the field lookup table, the keywords are translated. If the number of keywords exceeds a preset number, the translated fields are entered into the field lookup table for updating. If the number of translated fields exceeds a preset number, a new third category is created.
8. A computer-readable storage medium storing computer-executable instructions for performing the fault anomaly classification method according to any one of claims 1 to 6.
Citation Information
Patent Citations
Big data log monitoring method and device, storage medium and computer equipment
CN110309110A
Abnormal log processing method and device
CN111651595A