Application exception processing method and system, electronic equipment and storage medium
By introducing clients, servers and processors into the mobile application exception handling system, and traversing the clustered exception library using exception identification, the problem of low exception handling efficiency of mobile applications on different terminal devices is solved, and more efficient exception fault handling and improved user experience is achieved.
Patent Information
- Application Number
- CN202411836611.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-13
- Publication Date
- 2025-03-14
AI Technical Summary
In the prior art, the abnormality processing efficiency of mobile applications on different terminal devices is low, resulting in poor user experience and requires manual analysis of massive abnormal information.
By introducing the client, server and processor in the application exception handling system, the client and server calculate the first exception identifier and the second exception identifier respectively and upload it to the processor. The processor traverses the preset clustered exception library based on these identifiers to determine historical exception data and process it.
It improves the efficiency of abnormal fault handling, reduces the need for manual analysis, and improves the user experience.
Smart Images

Figure CN119621406A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to an application exception processing method, system, electronic device and storage medium. Background Art
[0002] As the mobile application architecture for building mobile applications becomes increasingly complex and there are many types of terminal devices, when the same exception occurs in mobile applications in different terminal devices, the collected exception information may be different.
[0003] At present, the abnormal information collected by different terminal devices is often analyzed manually to query the processing process corresponding to each abnormal information from massive data to process the abnormal information, which leads to poor processing efficiency and affects the user experience. Summary of the invention
[0004] In view of this, embodiments of the present invention provide an application exception handling method, system, electronic device and storage medium to solve the problems of poor processing efficiency and affected user experience in the prior art.
[0005] To achieve the above objectives, the embodiments of the present invention provide the following technical solutions:
[0006] A first aspect of an embodiment of the present invention shows an application exception handling method, which is applied to an application exception handling system including a client, a server, and a processor. The method includes:
[0007] If the client detects that an abnormal failure occurs in the application, the client obtains abnormal failure data; processes the abnormal failure data, determines a corresponding first abnormal identification, and uploads the first abnormal identification to execute the processor;
[0008] The server receives the abnormal fault data uploaded by the client, processes the abnormal fault data, determines a corresponding second abnormality identifier, and uploads the second abnormality identifier to execute the processor;
[0009] The processor traverses a preset clustering exception library based on the first exception identifier and the second exception identifier to determine whether there is relevant historical exception data, so as to process the abnormal failure occurring in the application based on the historical exception data.
[0010] Optionally, the client processes the abnormal fault data to determine a corresponding first abnormality identifier, including:
[0011] Convert the abnormal name, abnormal characteristic information and abnormal stack in the abnormal fault data into corresponding codes respectively;
[0012] Processing the combined encoding of the exception name, exception key feature information and exception stack to obtain a fixed-length encoding;
[0013] The fixed-length code is used as a first abnormality identifier.
[0014] Optionally, the server performs processing based on the abnormal fault data to determine a corresponding second abnormality identifier, including:
[0015] Restoring the exception stack in the abnormal fault data to obtain function information;
[0016] Filtering the abnormal characteristic information to obtain abnormal key characteristic information;
[0017] A second exception identifier is constructed based on the exception name, the exception key feature information, and the function information.
[0018] Optionally, the server constructs a second exception identifier based on the exception name, the exception key feature information, and the function information, including:
[0019] Convert the exception name, exception key feature information, and function information into corresponding codes respectively;
[0020] Processing the combined encoding of the exception name, the exception key feature information, and the function information to obtain a fixed-length encoding;
[0021] The fixed-length code is used as a second abnormality identifier.
[0022] Optionally, the processor presets a clustering anomaly library process, including:
[0023] The processor obtains a first historical exception identifier obtained by the client based on each historical exception data;
[0024] The processor obtains a second historical abnormality identifier obtained by the server based on each historical abnormality data;
[0025] The processor performs clustering processing based on each historical abnormal data; and constructs a clustering abnormality library based on each of the clustered historical abnormal data, and its corresponding first historical abnormality identifier and second historical abnormality identifier.
[0026] Optionally, the processor performs clustering processing based on each historical abnormal data, including:
[0027] For each historical abnormal data, construct a corresponding data matrix based on the historical abnormal data;
[0028] Clustering is performed on each of the historical abnormal data based on the data matrix.
[0029] Optionally, also include:
[0030] The processor performs clustering processing on abnormal fault data within a preset time period;
[0031] The same processing operation is performed on the abnormal fault data in the same cluster group according to the first abnormal identification and the second abnormal identification to perform batch processing.
[0032] A second aspect of an embodiment of the present invention shows an application exception handling system, including a client, a server and a processor;
[0033] The client is used to obtain abnormal fault data when an abnormal fault is detected in the application; and to process based on the abnormal fault data, determine the corresponding first abnormal identifier, and upload the first abnormal identifier to execute the processor;
[0034] The server is configured to receive the abnormal fault data uploaded by the client, process the abnormal fault data, determine the corresponding second abnormality identifier, and upload the second abnormality identifier to execute the processor;
[0035] The processor is used to traverse a preset clustering exception library based on the first exception identifier and the second exception identifier to determine whether there is relevant historical exception data, so as to process the abnormal failure occurring in the application based on the historical exception data.
[0036] A third aspect of an embodiment of the present invention shows an electronic device, which is used to run a program, wherein the application exception handling method shown in the first aspect of the embodiment of the present invention is executed when the program is running.
[0037] A fourth aspect of an embodiment of the present invention shows a storage medium, which includes a storage program, wherein when the program is running, the device where the storage medium is located is controlled to execute the application exception handling method shown in the first aspect of the embodiment of the present invention.
[0038] Based on the above-mentioned embodiment of the present invention, an application exception processing method, system, electronic device and storage medium are provided, which are applied to the application exception processing system including a client, a server and a processor. The method includes: if the client detects that an abnormal fault occurs in the application, the abnormal fault data is obtained; and the abnormal fault data is processed based on the abnormal fault data, the corresponding first abnormal identification is determined, and the first abnormal identification is uploaded to the processor for execution; the server receives the abnormal fault data uploaded by the client, processes based on the abnormal fault data, determines the corresponding second abnormal identification, and uploads it to execute the processor; the processor traverses the preset clustering abnormal library based on the first abnormal identification and the second abnormal identification to determine whether there is relevant historical abnormal data, so as to process the abnormal fault of the application based on the historical abnormal data. In the present invention, the clustering abnormal library is traversed based on the first abnormal identification calculated by the client and the second abnormal identification calculated by the server to determine the historical abnormal data in the same cluster group as the abnormal fault information, so as to process the abnormal fault of the application based on the historical abnormal data. Not only can the efficiency of abnormal fault processing be improved, but also the user experience can be improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0039] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.
[0040] Figure 1 A schematic diagram of the architecture of an application exception handling system shown in an embodiment of the present invention;
[0041] Figure 2 A schematic diagram of a flow chart of an application exception handling method according to an embodiment of the present invention;
[0042] Figure 3 A schematic diagram of abnormal fault processing performed by a client according to an embodiment of the present invention;
[0043] Figure 4 A schematic diagram of abnormal fault processing performed by a server in an embodiment of the present invention;
[0044] Figure 5 A flowchart of another method for handling application exceptions according to an embodiment of the present invention is shown;
[0045] Figure 6 This is a schematic diagram of an abnormal fault processing performed by a processor according to an embodiment of the present invention. DETAILED DESCRIPTION
[0046] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0047] The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0048] It should be noted that the descriptions of "first", "second", etc. in the present invention are only used for descriptive purposes and cannot be understood as indicating or implying their relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In addition, the technical solutions between the various embodiments can be combined with each other, but they must be based on the ability of ordinary technicians in the field to implement them. When the combination of technical solutions is contradictory or cannot be implemented, it should be deemed that such a combination of technical solutions does not exist and is not within the scope of protection required by the present invention.
[0049] In this application, the terms "comprises", "comprising" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprising a ..." does not exclude the presence of other identical elements in the process, method, article or device comprising the element.
[0050] See also Figure 1 , is a schematic diagram of the architecture of an application exception handling system shown in an embodiment of the present invention, wherein the application exception handling system includes a client 10, a server 20 and a processor 30.
[0051] The client 10 is connected to the server 20 , and the processor 30 is connected to the client 10 and the server 20 respectively.
[0052] The processor 30 may be deployed inside the server 20 or outside the server 20 .
[0053] The client 10 is the front end of the mobile application, and the server 20 is the back end of the mobile application.
[0054] The process of implementing application exception handling based on the application exception handling system shown above includes:
[0055] If the client 10 detects an abnormal failure in the application, it obtains abnormal failure data; processes the abnormal failure data, determines the corresponding first abnormal identification, and uploads the first abnormal identification to execute the processor 30;
[0056] The client 10 processes the abnormal fault data to determine the corresponding first abnormality identifier, including:
[0057] The exception name, exception feature information and exception stack in the abnormal fault data are converted into corresponding codes respectively; the combined codes of the exception name, exception key feature information and exception stack are processed to obtain a fixed-length code; and the fixed-length code is used as the first exception identifier.
[0058] If the server 20 receives the abnormal fault data uploaded by the client, it processes the abnormal fault data, determines the corresponding second abnormality identifier, and uploads the second abnormality identifier to execute the processor 30;
[0059] The server 20 processes the abnormal fault data to determine the corresponding second abnormal flag, including:
[0060] The exception stack in the abnormal fault data is restored to obtain function information; the abnormal feature information is filtered to obtain abnormal key feature information; and a second abnormal identification is constructed based on the abnormal name, the abnormal key feature information, and the function information.
[0061] It should be noted that the server constructs a second exception identifier based on the exception name, the exception key feature information, and the function information, including:
[0062] The exception name, exception key feature information, and function information are converted into corresponding codes respectively; the combined codes of the exception name, exception key feature information, and function information are processed to obtain a fixed-length code; and the fixed-length code is used as a second exception identifier.
[0063] The processor 30 traverses a preset clustering exception library based on the first exception identifier and the second exception identifier to determine whether there is relevant historical exception data, so as to process the abnormal failure of the application based on the exception processing information.
[0064] The processor 30 presets a clustering abnormality library process, including:
[0065] The processor 30 obtains the first historical exception identifier obtained by the client based on each historical exception data; the processor 30 obtains the second historical exception identifier obtained by the server based on each historical exception data; the processor 30 performs clustering processing based on each historical exception data; and constructs a clustered exception library with each of the clustered historical exception data, and its corresponding first historical exception identifier and second historical exception identifier.
[0066] It should be noted that the processor 30 performs clustering processing based on each historical abnormal data, including:
[0067] For each historical abnormal data, a corresponding data matrix is constructed based on the historical abnormal data; and clustering processing, namely fuzzy clustering processing, is performed on each historical abnormal data based on the data matrix.
[0068] Optionally, the processor 30 further includes:
[0069] Clustering the abnormal fault data within a preset time period;
[0070] The same processing operation is performed on the abnormal fault data in the same cluster group according to the first abnormal identification and the second abnormal identification to perform batch processing.
[0071] In an embodiment of the present invention, first, the client processes the abnormal data of the abnormal failure of the application to calculate the corresponding first abnormal identification; and sends the abnormal data to the server, and sends the first abnormal identification to the processor; then after receiving the abnormal data, the server performs symbol restoration on the abnormal stack in the abnormal data, and filters the abnormal feature information to recalculate the corresponding second abnormal identification, and sends it to the processor; the processor traverses the clustering abnormal library based on the first abnormal identification and the second abnormal identification to determine the historical abnormal data in the same clustering group as the abnormal failure information, so as to process the abnormal failure of the application based on the historical abnormal data. Not only can the efficiency of abnormal failure processing be improved, but also the user experience can be improved.
[0072] Referring to the application exception handling system shown in the above embodiment of the present invention, the present invention also shows an application exception handling method, such as Figure 2 As shown, the method includes:
[0073] Step S201: The client detects whether all its applications have abnormal failures. If so, step S202 is executed; if not, step S201 is continued.
[0074] In the process of implementing step S201, the client detects the performance, health status, application logs, traffic and configuration of each application deployed on itself to monitor whether there are abnormal failures in the application. If so, execute step S202, if not, continue to execute step S201.
[0075] Step S202: The client obtains abnormal fault data.
[0076] In the process of specifically implementing step S202, according to the detected abnormal fault, corresponding data items such as the abnormal name, abnormal feature information and abnormal stack are obtained and used as abnormal fault data.
[0077] It should be noted that the abnormal characteristic information includes information such as the type of abnormality, the location and time of the abnormality.
[0078] Among them, the exception stack is the function stack called by the application when an exception occurs during the application running, that is, the function call sequence. The exception stack can locate the specific module location and cause of the problem.
[0079] Optionally, after obtaining the abnormal fault data, the client sends the abnormal fault data to the server.
[0080] Step S203: the client processes the abnormal fault data, determines a corresponding first abnormal identifier, and uploads the first abnormal identifier to execute the processor;
[0081] It should be noted that the specific process of implementing step S203 includes the following steps:
[0082] Step S11: converting the abnormal name, abnormal characteristic information and abnormal stack in the abnormal fault data into corresponding codes respectively;
[0083] In the specific implementation of step S11, the abnormal name, abnormal characteristic information and abnormal stack in the abnormal fault data are respectively converted into a character string in a preset format, that is, a code.
[0084] It should be noted that the preset format may be a binary format.
[0085] Step S12: Processing the combined code of the exception name, exception key feature information and exception stack to obtain a fixed-length code;
[0086] In the specific implementation of step S12, the codes of the exception name, exception key feature information and exception stack are combined into a string; then, the exception name, exception key feature information and exception stack of a string are converted into a fixed-length code.
[0087] It should be noted that the fixed length is set in advance by the technicians based on the actual situation.
[0088] Optionally, the present application may perform a hash operation on the exception name, exception key feature information and exception stack of a string to obtain a fixed-length code.
[0089] Step S13: Using the fixed-length code as the first abnormality identifier.
[0090] In the specific implementation of step S13, the fixed-length code is used as the classification ID of the abnormal fault data;
[0091] Optionally, after executing step S13, the method further includes:
[0092] Determine whether an abnormal fault identical to the abnormal fault data has occurred within a preset time period. If so, record the number of occurrences, and upload the first abnormal identification and the number of fault occurrences and other information to execute the processor when idle; if not, directly upload the first abnormal identification to execute the processor, such as Figure 3 shown.
[0093] The client of the present invention can not only assist the processor in classification by calculating the classification ID, but also perform statistical processing on similar problems. For example, when the same exception occurs, only the number of occurrences is recorded without uploading, which not only prevents data loss, but also reduces the calculation burden of the client and server.
[0094] Step S204: the server receives the abnormal fault data uploaded by the client, processes the abnormal fault data, determines the corresponding second abnormality identifier, and uploads the second abnormality identifier to execute the processor;
[0095] It should be noted that the server specifically implements a process of processing based on the abnormal fault data to determine the corresponding second abnormal identification, including the following steps:
[0096] Step S21: restore the exception stack in the abnormal fault data to obtain function information;
[0097] In the process of implementing step S21, it is determined whether the symbol table corresponding to the exception stack is stored. If so, the symbol table is used to restore the exception stack, that is, the function address in the exception stack is converted into readable function name information to obtain an exception stack constructed by symbols; then, the function information causing the exception fault is obtained from the restored exception stack. If there is no symbol table of the same type as the exception stack, the exception stack is read to determine the source code where the exception occurs; then, the source code where the exception occurs is converted into information in a readable format, and the function information causing the exception fault is determined from the information in the readable format.
[0098] The function information causing the abnormal fault includes the module information and the cause of the fault.
[0099] It should be noted that the corresponding relationship between the exception stack and the character table is preset.
[0100] Step S22: filtering the abnormal characteristic information to obtain abnormal key characteristic information;
[0101] In the process of implementing step S22, it is determined whether there is an abnormal message filtering rule corresponding to the abnormal type in the abnormal feature information. If so, the abnormal message filtering rule is used to filter the abnormal feature information to obtain abnormal key feature information. If not, the abnormal feature information is directly used as the abnormal key feature information.
[0102] It should be noted that the exception message filtering rules correspond to the exception type. For example, if the exception type is performance exception, the corresponding exception message filtering rules may not include information such as memory usage. The exception message filtering rules corresponding to each exception type are constructed based on the historical exception data related to different exception types.
[0103] Step S23: construct a second exception identifier based on the exception name, the exception key feature information, and the function information.
[0104] Among them, the exception name, exception key feature information, and function information are new features.
[0105] The specific implementation process of step S23 includes the following steps:
[0106] Step S31: convert the exception name, exception key feature information, and reference function information into corresponding codes respectively;
[0107] Step S32: Processing the combined encoding of the exception name, the exception key feature information, and the function information to obtain a fixed-length encoding;
[0108] Step S33: Using the fixed-length code as a second abnormality identifier.
[0109] It should be noted that the specific implementation process of step S31 to step S33 is the same as the specific implementation process of the above-mentioned specific implementation step S11 to step S13, and they can refer to each other.
[0110] Optionally, after the process from step S21 to step S23, the method further includes:
[0111] The second abnormality identification and abnormal fault data are saved in the data warehouse of the server, such as Figure 4 shown.
[0112] In the embodiment of the present invention, after receiving the abnormal data, the server will process the abnormal data, perform symbol restoration on the abnormal stack, etc. The processed abnormal data is more readable than the abnormal information of the client, and the server will calculate the classification ID of the data before storing the data.
[0113] Step S205: The processor traverses the preset clustering exception library based on the first exception identifier and the second exception identifier to determine whether there is relevant historical exception data. If so, step S206 is executed. If not, the processing is performed directly and the processing operation and exception data are written into the clustering exception library to optimize the exception data in the clustering exception library.
[0114] It should be noted that the processor presets the clustering exception library process, including the following steps:
[0115] Step S41: the processor obtains a first historical abnormality identifier obtained by the client through processing based on each historical abnormality data;
[0116] In the specific implementation of step S41 , the processor receives each historical abnormal data uploaded by the client, and the first historical abnormal identification obtained by the client for each historical abnormal data based on the above steps S11 to S13 .
[0117] It should be noted that the historical abnormal data is obtained from the data warehouse and is pre-stored historical abnormal data over a period of time in the past.
[0118] Historical exception data includes the exception stack of historical abnormal faults, exception feature messages, and corresponding exception handling operations.
[0119] Step S42: the processor obtains a second historical abnormality identifier obtained by the server based on each historical abnormality data;
[0120] In the specific implementation of step S42, the processor receives each historical abnormal data uploaded by the server, and the second historical abnormal identification obtained by the server for each historical abnormal data based on the above steps S21 to S23.
[0121] Step S43: the processor performs clustering processing based on each historical abnormal data; and constructs a clustered abnormality library based on each of the clustered historical abnormal data, as well as its first historical abnormality identifier and second historical abnormality identifier.
[0122] The processing operation of each historical abnormal data is recorded when the historical abnormal fault is processed.
[0123] It should be noted that the specific implementation of the processor performing clustering processing based on each historical abnormal data includes the following steps:
[0124] Step S51: for each historical abnormal data, construct a corresponding data matrix based on the historical abnormal data;
[0125] In the specific implementation of step S51, each data item of historical abnormal data is used as a matrix element to construct a corresponding data matrix.
[0126] Step S52: performing clustering processing, namely fuzzy clustering processing, on each of the historical abnormal data based on the data matrix.
[0127] In the specific implementation of step S52, historical abnormal data with fuzzy similarity relationships are determined, and each of the historical abnormal data is clustered using the fuzzy similarity relationships, that is, the historical abnormal data with fuzzy similarity relationships are clustered into a group of data.
[0128] It should be noted that the specific implementation process of step S51 and step S52 only considers the exception stack and exception characteristic message of the historical abnormal fault in the historical abnormal data.
[0129] In the specific implementation of step S43, a correspondence between each group of clustered historical abnormal data and the first historical abnormal identification and the second historical abnormal identification of each clustered historical abnormal data is constructed and written into the clustering abnormality library.
[0130] In the process of implementing step S205, the preset clustering exception library can be quickly queried through the first exception identifier and the second exception identifier to determine whether there is historical exception data similar to the abnormal fault. If so, step S206 is executed. If not, it will be processed directly and the processing operation and exception data will be written into the clustering exception library to optimize the exception data in the clustering exception library.
[0131] Step S206: outputting historical abnormal data similar to the abnormal fault, so as to process the abnormal fault occurring in the application based on the historical abnormal data.
[0132] In the specific implementation of step S206, historical abnormal data similar to the abnormal fault is output, so that the technician can select the corresponding abnormal processing operation from the historical abnormal data to process the abnormal fault occurring in the application.
[0133] It should be noted that the clustering anomaly library can be a data warehouse.
[0134] In an embodiment of the present invention, first, the client processes the abnormal data of the abnormal failure of the application to calculate the corresponding first abnormal identification; and sends the abnormal data to the server, and sends the first abnormal identification to the processor; then after receiving the abnormal data, the server performs symbol restoration on the abnormal stack in the abnormal data, and filters the abnormal feature information to recalculate the corresponding second abnormal identification, and sends it to the processor; the processor traverses the clustering abnormal library based on the first abnormal identification and the second abnormal identification to determine the historical abnormal data in the same clustering group as the abnormal failure information, so as to process the abnormal failure of the application based on the historical abnormal data. Not only can the efficiency of abnormal failure processing be improved, but also the user experience can be improved.
[0135] Optionally, based on the application exception handling method shown in the above embodiment of the present invention, after executing step S206, the method further includes:
[0136] The abnormal fault data is written into a cluster corresponding to the historical abnormal data.
[0137] Specifically, when it is determined that similar historical abnormal data exists, the abnormal fault information can be directly written into the same clustering group, providing developers with a multi-dimensional abnormal query function.
[0138] In an embodiment of the present invention, the processor obtains a clustered exception library based on the first exception identifier and the second exception identifier to determine the historical exception data in the same cluster group as the abnormal fault information, and directly writes the abnormal fault information into the same cluster group, thereby enriching the data in the clustered exception library.
[0139] Based on the application exception handling method shown in the above embodiment of the present invention, the embodiment of the present invention also shows another implementation method of the application exception handling method, such as Figure 5 As shown, the method includes:
[0140] Step S501: The client detects whether all its applications have abnormal failures. If so, step S502 is executed; if not, step S501 is continued.
[0141] Step S502: The client obtains abnormal fault data.
[0142] Step S503: the client performs processing based on the abnormal fault data, determines a corresponding first abnormal identifier, and uploads the first abnormal identifier and the abnormal fault data to execute the processor;
[0143] Step S504: the server receives the abnormal fault data uploaded by the client, processes the abnormal fault data, determines the corresponding second abnormality identifier, and uploads the second abnormality identifier to execute the processor;
[0144] It should be noted that the specific implementation process of step S501 to step S504 is the same as the specific implementation process of the above-mentioned specific implementation steps S201 to step S204, and they can refer to each other.
[0145] Step S505: the processor performs clustering processing on abnormal fault data within a preset time period;
[0146] Specifically, the process of implementing step S505 is to use the data item of each abnormal fault data within the preset time period as a matrix element to construct a corresponding data matrix. The abnormal fault data with fuzzy similarity relationship is determined, and the abnormal fault data with fuzzy similarity relationship is used as the same clustering group to divide the abnormal fault data within the preset time period.
[0147] It should be noted that the preset time period is set according to actual conditions and can generally be set to 6 hours.
[0148] Optionally, after executing step S505, the developer can search for abnormal data, such as Figure 6 shown.
[0149] Step S506: performing the same processing operation on the abnormal fault data in the same cluster group according to the first abnormal identification and the second abnormal identification to perform batch processing.
[0150] In the specific implementation of step S506, batch processing is performed on abnormal fault data in the same cluster group according to the first abnormal identification and the second abnormal identification to execute the same processing operation.
[0151] It should be noted that the processing operation corresponding to the abnormal fault data can be determined through step S205, or can be directly manually input by a technician.
[0152] In an embodiment of the present invention, first, the client processes the abnormal data of the abnormal failure of the application to calculate the corresponding first abnormal identification; and sends the abnormal data to the server, and sends the first abnormal identification to the processor; then after the server receives the abnormal data, it performs symbol restoration on the abnormal stack in the abnormal data, and filters the abnormal feature information to recalculate the corresponding second abnormal identification, and sends it to the processor; the processor clusters the abnormal failure data within a preset time period; according to the first abnormal identification and the second abnormal identification, the abnormal failure data in the same clustering group are subjected to the same processing operation for batch processing. Not only can the efficiency of abnormal failure processing be improved, but also the user experience can be improved.
[0153] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can refer to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system or system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can refer to the partial description of the method embodiment. The method and system embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without creative work.
[0154] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.
[0155] The above description of the disclosed embodiments enables one skilled in the art to implement or use the present invention. Various modifications to these embodiments will be apparent to one skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but rather to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A method for handling application exceptions, characterized in that: The system for handling application exceptions includes a client, a server, and a processor, and the method includes: If the client detects that an abnormal failure occurs in the application, the client obtains abnormal failure data; processes the abnormal failure data, determines a corresponding first abnormal identification, and uploads the first abnormal identification to execute the processor; The server receives the abnormal fault data uploaded by the client, processes the abnormal fault data, determines a corresponding second abnormality identifier, and uploads the second abnormality identifier to execute the processor; The processor traverses a preset clustering exception library based on the first exception identifier and the second exception identifier to determine whether there is relevant historical exception data, so as to process the abnormal failure occurring in the application based on the historical exception data.
2. The method according to claim 1, characterized in that The client processes the abnormal fault data to determine a corresponding first abnormality identifier, including: Convert the abnormal name, abnormal characteristic information and abnormal stack in the abnormal fault data into corresponding codes respectively; Processing the combined encoding of the exception name, exception key feature information and exception stack to obtain a fixed-length encoding; The fixed-length code is used as a first abnormality identifier.
3. The method according to claim 2, characterized in that The server performs processing based on the abnormal fault data to determine a corresponding second abnormality identifier, including: Restoring the exception stack in the abnormal fault data to obtain function information; Filtering the abnormal characteristic information to obtain abnormal key characteristic information; A second exception identifier is constructed based on the exception name, the exception key feature information, and the function information.
4. The method according to claim 3, characterized in that The server constructs a second exception identifier based on the exception name, the exception key feature information, and the function information, including: Convert the exception name, exception key feature information, and function information into corresponding codes respectively; Processing the combined encoding of the exception name, the exception key feature information, and the function information to obtain a fixed-length encoding; The fixed-length code is used as a second abnormality identifier.
5. The method according to claim 1, characterized in that The processor presets the clustering exception library process, including: The processor obtains a first historical exception identifier obtained by the client based on each historical exception data; The processor obtains a second historical abnormality identifier obtained by the server based on each historical abnormality data; The processor performs clustering processing based on each historical abnormal data; and constructs a clustering abnormality library based on each of the clustered historical abnormal data, and its corresponding first historical abnormality identifier and second historical abnormality identifier.
6. The method according to claim 5, characterized in that The processor performs clustering processing based on each historical abnormal data, including: For each historical abnormal data, construct a corresponding data matrix based on the historical abnormal data; Clustering is performed on each of the historical abnormal data based on the data matrix.
7. The method according to claim 1, characterized in that Also includes: The processor performs clustering processing on abnormal fault data within a preset time period; The same processing operation is performed on the abnormal fault data in the same cluster group according to the first abnormal identification and the second abnormal identification to perform batch processing.
8. An application exception handling system, characterized in that: Includes client, server and processor; The client is used to obtain abnormal fault data when an abnormal fault is detected in the application; and to process based on the abnormal fault data, determine the corresponding first abnormal identifier, and upload the first abnormal identifier to execute the processor; The server is configured to receive the abnormal fault data uploaded by the client, process the abnormal fault data, determine the corresponding second abnormality identifier, and upload the second abnormality identifier to execute the processor; The processor is used to traverse a preset clustering exception library based on the first exception identifier and the second exception identifier to determine whether there is relevant historical exception data, so as to process the abnormal failure occurring in the application based on the historical exception data.
9. An electronic device, characterized in that: The electronic device is used to run a program, wherein the application exception handling method according to any one of claims 1 to 7 is executed when the program is running.
10. A storage medium, characterized in that: The storage medium includes a storage program, wherein when the program is running, the device where the storage medium is located is controlled to execute the application exception handling method according to any one of claims 1 to 7.