CN112416735A - Application program detection method and device, terminal equipment and storage medium - Google Patents

Application program detection method and device, terminal equipment and storage medium Download PDF

Info

Publication number
CN112416735A
CN112416735A CN201910774377.5A CN201910774377A CN112416735A CN 112416735 A CN112416735 A CN 112416735A CN 201910774377 A CN201910774377 A CN 201910774377A CN 112416735 A CN112416735 A CN 112416735A
Authority
CN
China
Prior art keywords
key node
standard
target application
state information
application program
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910774377.5A
Other languages
Chinese (zh)
Inventor
伍东方
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201910774377.5A priority Critical patent/CN112416735A/en
Publication of CN112416735A publication Critical patent/CN112416735A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/362Software debugging
    • G06F11/366Software debugging using diagnostics

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The embodiment of the invention discloses an application program detection method, an application program detection device, terminal equipment and a storage medium, wherein the method comprises the following steps: after the target application program is operated online, acquiring actual operation state information of each key node when the target application program operates each key node in at least one key node, comparing the actual operation state information of each key node with standard operation state information of each key node included in a standard operation flow to obtain a comparison result, further generating a diagnosis report aiming at the target application program according to the comparison result, and reporting the diagnosis report to a server. By adopting the embodiment of the invention, after the target application program is online, the actual running state information of each key node can be automatically compared with the standard running state information of each key node included in the standard operation process, thereby being beneficial to improving the detection efficiency of the target application program.

Description

Application program detection method and device, terminal equipment and storage medium
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method and an apparatus for detecting an application program, a terminal device, and a storage medium.
Background
At present, after an application program is online, if an existing network user has a problem of occurrence, a developer can only drag for a log of the existing network user through a background server after the existing network user is online. Further, developers need to manually analyze the log to detect the rare problem. It can be seen that the detection efficiency is low by adopting the detection mode.
Disclosure of Invention
The embodiment of the invention provides an application program detection method, an application program detection device, terminal equipment and a storage medium, which can automatically detect a target application program after the target application program is on line, generate and report a diagnosis report, and are beneficial to improving the detection efficiency of the target application program.
In one aspect, an embodiment of the present invention provides an application detection method, where the method is applied to a terminal device, where the terminal device runs a target application, where the target application includes at least one key node, and the method includes:
after the target application program is operated online, acquiring actual operation state information of each key node when the target application program operates each key node in the at least one key node;
comparing the actual running state information of each key node with the standard running state information of each key node included in a standard operation flow to obtain a comparison result, wherein the standard running state information of each key node refers to the running state information of each key node obtained under the condition that the target application program runs normally;
and generating a diagnosis report aiming at the target application program according to the comparison result, and reporting the diagnosis report to a server.
In another aspect, an embodiment of the present invention provides an apparatus for detecting an application, where the apparatus is configured in a terminal device, the terminal device runs a target application, and the target application includes at least one key node, and the apparatus includes:
the processing module is used for acquiring the actual running state information of each key node when the target application program runs each key node in the at least one key node after the target application program runs on line;
the processing module is further configured to compare the actual running state information of each key node with standard running state information of each key node included in a standard operation flow to obtain a comparison result, where the standard running state information of each key node is the running state information of each key node obtained when the target application program runs normally;
the processing module is further used for generating a diagnosis report aiming at the target application program according to the comparison result;
and the communication module is used for reporting the diagnosis report to a server.
Correspondingly, an embodiment of the present invention further provides a terminal device, including: a processor and a storage device; the storage device is used for storing program instructions; the processor calls the program instructions to perform: after the target application program is operated online, acquiring actual operation state information of each key node when the target application program operates each key node in the at least one key node; comparing the actual running state information of each key node with the standard running state information of each key node included in a standard operation flow to obtain a comparison result, wherein the standard running state information of each key node refers to the running state information of each key node obtained under the condition that the target application program runs normally; and generating a diagnosis report aiming at the target application program according to the comparison result, and reporting the diagnosis report to a server.
Accordingly, the embodiment of the present invention further provides a computer storage medium, in which program instructions are stored, and when the program instructions are executed, the computer storage medium is used for implementing the above methods.
In the embodiment of the invention, after the target application program is operated online, the actual operation state information of each key node when the target application program operates each key node in at least one key node can be obtained, the actual operation state information of each key node is compared with the standard operation state information of each key node included in the standard operation flow to obtain the comparison result, and then a diagnosis report aiming at the target application program is generated according to the comparison result and reported to the server. By adopting the embodiment of the invention, the automatic detection of the target application program can be realized after the target application program is online, and the detection efficiency of the target application program is favorably improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a diagram illustrating standard operating state information of a key node according to an embodiment of the present invention;
FIG. 2 is a flowchart illustrating the generation of a standard workflow document according to an embodiment of the present invention;
FIGS. 3 a-3 b are schematic diagrams of a test interface of a diagnostic device according to an embodiment of the present invention;
FIG. 4 is a schematic diagram illustrating a derivation flow of an application detection method according to an embodiment of the present invention;
FIG. 5 is a schematic diagram of a critical node operation exception according to an embodiment of the present invention;
FIG. 6 is a flowchart illustrating an application detection method according to an embodiment of the present invention;
FIG. 7 is a flowchart illustrating another application detection method according to an embodiment of the present invention;
FIG. 8 is a schematic illustration of a diagnostic report according to an embodiment of the present invention;
FIG. 9 is a schematic illustration of another diagnostic report according to an embodiment of the present invention;
FIG. 10 is a flowchart illustrating a further method for detecting an application according to an embodiment of the present invention;
FIG. 11 is a schematic structural diagram of an application detection apparatus according to an embodiment of the present invention;
fig. 12 is a schematic structural diagram of a terminal device according to an embodiment of the present invention.
Detailed Description
At present, after an application program is online, in order to solve the problem of the occurrence of the user on the current network, the user on the current network is required to be on line to drag for logs, a large amount of logs are required to be analyzed manually, and for personnel who are not familiar with relevant codes, the logs are difficult to read and analyze, and the problems cannot be found quickly and effectively.
In order to solve the above problems, the present invention provides an application detection method, which can obtain actual operation state information of each key node when a target application program operates each key node in at least one key node after the target application program is online operated, compare the actual operation state information of each key node with standard operation state information of each key node included in a standard operation flow to obtain a comparison result, further generate a diagnosis report for the target application program according to the comparison result, and report the diagnosis report to a server. By adopting the mode, after the target application program is online, the actual running state information of each key node can be automatically compared with the standard running state information of each key node included in the standard operation process, so that the automatic detection of the target application program and the generation of a diagnosis report are realized, the log is fished out without depending on the online of the current network user, and the log is not required to be analyzed manually, and the detection efficiency of the target application program is favorably improved.
The key node may be a code block or a function in the target application program, and the selection of the key node is related to the service type of the target application program. For example, the service type corresponding to the target application is an opening type, and in a process of implementing the opening, a camera needs to be opened first, camera data needs to be acquired after the camera is opened, and further, after the camera data is acquired, the camera data needs to be uploaded to a server.
The standard running state information of each key node is the running state information of each key node acquired under the condition that the target application program runs normally. In an embodiment, the terminal device may record the running state information of each key node in the at least one key node under the condition that the target application program runs normally, and use the recorded running state information of each key node as the standard running state information of each key node, and further generate a standard job flow file of the target application program by using the standard running state information of each key node according to the running timing condition in the recorded running state information of each key node, where the standard job flow file includes the standard running state information of each key node in the target application program. The standard operation state information of each key node may include one or more of a standard operation parameter condition, a standard operation timing condition, and a standard operation frequency condition.
Illustratively, fig. 1 illustrates standard operation state information of an encoding node Encoder, which includes a node name, a standard operation parameter condition, a standard operation timing condition, and a standard operation number condition. It can be seen that the standard operation parameter condition indicates that the standard operation frequency of the coding node Encoder is 1, the standard operation parameter condition indicates that the standard operation parameter mRunStep of the coding node Encoder is 4, and the standard operation timing condition indicates that the coding node Encoder depends on the execution of the gain compensation node AGC in timing sequence.
Further, after the standard running state information of all the key nodes in the target application program is recorded, the standard running state information of each key node may be concatenated according to the running time sequence condition of each key node to generate a standard workflow file in a preset file format (e.g., json).
Illustratively, the flow of generating the standard workflow file described above may be as shown in fig. 2. Firstly, at least one key node can be selected from the target application program, the key node in the at least one key node is operated, the operation state of each key node is recorded, and the operation state is converted into a standard operation parameter condition when each key node is operated. Further, when the operation of the target application program is finished, the operation states of the key nodes can be summarized and sorted, the standard operation time sequence condition and the standard operation frequency condition are automatically generated, and then the standard operation state information of the key nodes including the standard operation parameter condition, the standard operation time sequence condition and the standard operation frequency condition is generated. Further, the standard operation state information of each key node may be concatenated to generate a standard workflow file in a preset file format (e.g., json) according to the standard operation timing condition of each key node.
In one embodiment, a pre-developed diagnostic device is further run in the terminal device, and after the standard workflow file is generated, the standard workflow file may be imported into the diagnostic device, and the diagnostic device may parse the standard workflow file, and restore standard operation state information of each key node in the target application from the standard workflow file under the above various conditions (e.g., standard operation parameter conditions, standard operation timing conditions, and standard operation frequency conditions). Further, the terminal device may test the diagnoser based on the standard operating state information of each key node, and after the diagnoser is tested, may add a Software Development Kit (SDK) corresponding to the diagnoser to the target application.
Further, after the target application program is operated online, in the operation process of the target application program, the terminal device may transmit actual operation state information of each key node to the diagnotor, and the diagnotor may compare the actual operation state information of each key node with standard operation state information of each key node included in the standard operation flow to obtain a comparison result, and then generate a diagnostic report for the target application program according to the comparison result, and report the diagnostic report to the server.
Exemplarily, the testing interface of the diagnostic apparatus is as shown in fig. 3a, and it is assumed that the standard workflow of the standard workflow file imported into the diagnostic apparatus corresponding to 5 key nodes is: recording nodes Record-noise suppression nodes ANS-gain compensation nodes AGC-coding nodes Encoder-synthesis nodes Muxer, and key node items corresponding to the 5 key nodes are displayed in the test interface diagram. For such a situation, the user may randomly click on each key node item, and input a click operation for the "diagnose" button, thereby triggering the test.
For example, if the user randomly clicks the above 5 key node items in the test process, the sequence is as follows: and (3) the diagnostic device can simulate and run 5 key nodes according to the random click sequence, and since the click sequence of the 5 key node items is consistent with the standard work flow, the terminal equipment can output a diagnostic report as shown in fig. 3 b. Further, the developer may determine the accuracy of the output of the diagnostician based on the diagnostic report.
The derivation process of the application detection method provided by the present invention can be shown in fig. 4. Firstly, in the embodiment of the invention, a set of referential standard operation flow is needed for detecting whether each key node in a target application program is abnormal; secondly, when the target application program runs normally, the referential standard operation flow records the running state of each key node in the target application program, and abstracts the running state into a language which can be recognized by a machine, namely, the running state is abstracted into a judgable condition (such as the standard running parameter condition, the standard running time sequence condition and the standard running frequency condition), and then the referential standard operation flow is generated based on the judgable condition.
The judgment of the abnormality of the key node can include several conditions:
firstly, asynchronization does not have a callback, for the situation, the number of times of the key node is operated can be judged, and if the number of times of the key node is 0, the key node asynchronization is determined not to have the callback.
Secondly, the compatibility problem, for this situation, needs to judge the parameter value when the key node operates. For example, an application corresponding to a target application program is a video application, a parameter corresponding to a certain key node in the target application program is resolution, the parameter value of the certain key node is 1080P, and a display screen of the current terminal device only supports resolutions of 720P and below, so that the compatibility problem of the certain key node exists.
Thirdly, the timing problem, in view of this situation, needs to judge the dependency relationship of each key node when operating.
Fourth, the call causes a status problem. Time sequence dependence, multiple calls and call parameters need to be judged in a combined mode.
Illustratively, assuming that the target application includes A, B, C, D, E key nodes, the corresponding standard workflow is: a- > B- > C- > D- > E, for the abnormal situation of A, B, C, D, E, see a schematic diagram of a key node operation abnormality as shown in FIG. 5. It can be seen that, firstly, since B runs depending on A, in the actual running process, A directly calls execution C after running is finished, and since B calls depending on A, B does not call execution and B has running exception; secondly, the parameter transmitted to D by C is wrong, so that D is not successfully called, and D is abnormal in operation; further, C asynchronously calls D, but D has no callback, that is, E is not notified, and D has an abnormal condition of asynchronization without callback.
In an embodiment, a flowchart of an application detection method proposed by an embodiment of the present invention may be as shown in fig. 6. First, the terminal device may load a standard work flow file, and restore the program state by class name reflection, to generate standard running state information of each key node in the target application program, where the standard running state information includes a standard running parameter condition, a standard running timing condition, and a standard running frequency condition. Further, after the target application program is operated online, in the operation process, when the actual operation state information of the first key node in each key node is obtained, on one hand, the actual operation parameters in the actual operation state information can be compared with the standard operation parameter conditions, whether the actual operation parameters are consistent with the standard parameters indicated by the standard operation parameter conditions or not is judged, and if so, the comparison result indicates that the first key node is operated normally; and if the actual operation parameters of the first key node are inconsistent with the standard parameters, the comparison result indicates that the actual operation parameters of the first key node are inconsistent with the standard parameters. On the other hand, the actual running time sequence in the actual running state information can be compared with the standard running time sequence condition, whether the actual running time sequence is consistent with the standard time sequence indicated by the standard running time sequence condition or not is judged, and if the actual running time sequence is consistent with the standard time sequence indicated by the standard running time sequence condition, the comparison result indicates that the first key node runs normally; and if the actual operation time sequence of the first key node is inconsistent with the standard operation time sequence, the comparison result indicates that the actual operation time sequence of the first key node is inconsistent with the standard operation time sequence. Wherein the first key node is any one of the key nodes in the target application program
Further, operation status summarization is performed after the whole process is finished, and the operation status summarization includes summarizing comparison results for operation parameters and operation time sequences generated after comparison of all key nodes is finished, and actual operation times of each key node. Further, the actual operation times of each key node can be compared with the standard operation time condition, whether the actual operation times of each key node are consistent with the standard operation times indicated by the standard operation time condition or not is judged, and if the actual operation times of any key node are detected to be consistent with the standard operation times, the comparison result indicates that any key node normally operates; and if the actual running times of the key nodes are inconsistent with the standard running times, the comparison result indicates that the actual running times of the key nodes are inconsistent with the standard running times.
Referring to fig. 7 again, which is a schematic flowchart of an application detection method according to an embodiment of the present invention, the method according to the embodiment of the present invention may be executed by a terminal device, where the terminal device runs a target application, and the target application includes at least one key node. The method of an embodiment of the present invention includes the following steps.
S701: and after the target application program is operated on line, acquiring the actual operation state information of each key node when the target application program operates each key node in at least one key node. The target application program may refer to any program corresponding to an application, such as a video application, a social application, a shopping platform, and the like, which is not specifically limited in this embodiment of the present invention.
S702: and comparing the actual running state information of each key node with the standard running state information of each key node included in the standard operation flow to obtain a comparison result. The standard running state information of each key node refers to the running state information of each key node acquired under the condition that the target application program runs normally.
The standard operation state information comprises one or more of standard operation parameter conditions, standard operation time sequence conditions and standard operation frequency conditions. The actual operation state information includes one or more of actual operation parameters, actual operation time sequences, and actual operation times.
In an embodiment, the standard running state information includes a standard running parameter condition and a standard running timing condition, and the terminal device may compare, when acquiring actual running state information of a first key node in the at least one key node during running of the target application program, the actual running state information of the first key node with the standard running parameter condition and the standard running timing condition of the first key node included in the standard workflow, where the first key node is any one of the at least one key node. And further, generating a comparison result aiming at the operation parameters and the operation time sequence after comparison aiming at all the key nodes in the at least one key node is finished.
Exemplarily, referring to fig. 1, it is assumed that the first key node is a coding node Encoder, actual operation state information of the coding node Encoder includes an actual operation parameter and an actual operation timing sequence, and a standard parameter condition and a standard operation timing sequence condition included by the coding node Encoder corresponding to the standard operation state information are as shown in fig. 1, and it can be seen that the standard operation parameter condition indicates a standard operation parameter mRunStep ═ 4 of the coding node Encoder, and the standard operation timing sequence condition indicates that the coding node Encoder depends on the execution of the gain compensation node AGC in timing sequence. For the situation, when the terminal device obtains the actual running state information of the Encoder in the running process of the target application program, on one hand, the actual running parameters in the actual running state information can be compared with the standard parameter conditions of the Encoder, and if the actual running parameters of the Encoder obtained by comparison are consistent with the standard running parameters mRunStep (4) indicated by the standard parameter conditions of the Encoder, the terminal device indicates that the Encoder runs normally according to the comparison result of the running parameters; if the actual operation parameters are inconsistent with the standard operation parameters mRunStep, the comparison result aiming at the operation parameters indicates that the actual operation parameters of the Encoder are inconsistent with the standard operation parameters mRunStep-4.
On the other hand, the actual operation parameters in the actual operation state information can be compared with the standard parameter conditions of the Encoder, if the actual operation time sequence of the Encoder is obtained by comparison and is consistent with the time sequence indicated by the standard operation time sequence conditions of the Encoder, namely the actual operation time sequence of the Encoder represents that the Encoder is executed in AGC (automatic gain control) in the actual operation process, the Encoder is indicated to normally operate according to the comparison result of the operation time sequence; if the difference is not consistent, for example, the Encoder is executed before the AGC in the actual operation process, the comparison result aiming at the operation time sequence indicates that the Encoder is executed before the AGG. Further, the comparison result of the Encoder for the operation parameter and the comparison result for the operation timing sequence are combined into the comparison result for the operation parameter and the operation timing sequence.
Further, in an embodiment, the standard running state information further includes a standard running frequency condition, and the actual running state information of each key node includes the actual running frequency of each key node recorded after the target application program is run. For such a situation, after the target application program is run, the terminal device may compare the actual running state information of each key node with the standard running frequency condition of each key node included in the standard operation flow, so as to obtain a comparison result for the running frequency.
Illustratively, referring to fig. 1, it is assumed that the first key node is a coding node Encoder, and the actual operation state information of the coding node Encoder includes a node name, a standard operation parameter condition, a standard operation timing condition, and a standard operation frequency condition. It can be seen that the standard operation parameter condition indicates that the standard operation frequency of the coding node Encoder is 1, the standard operation parameter condition indicates that the standard operation parameter mRunStep of the coding node Encoder is 4, and the standard operation timing condition indicates that the coding node Encoder depends on the execution of the gain compensation node AGC in timing sequence. For the situation, after the terminal device obtains the comparison result of the Encoder for the operation parameters and the operation time sequence, when the end of the operation of the target application program is detected, the actual operation times of the Encoder recorded after the end of the operation of the target application program in the actual operation state information of the Encoder can be compared with the standard operation times condition of the Encoder, and if the actual operation times of the Encoder is obtained by comparison and is consistent with the standard operation times '1' indicated by the standard operation times condition of the Encoder, the Encoder is indicated to operate normally according to the comparison result of the operation times; and if the running times are inconsistent, indicating that the actual running times of the Encoder are inconsistent with the standard running times of 1 according to the comparison result of the running times.
By analogy, by adopting a comparison mode similar to the Encoder, comparison results aiming at the operation parameters and the operation time sequence of all key nodes in the target application program and comparison results aiming at the operation times of all key nodes can be obtained, the comparison results aiming at the operation parameters and the operation time sequence of all key nodes and the comparison results aiming at the operation times of all key nodes are combined into a final comparison result of all key nodes, and a diagnosis report aiming at the target application program is generated based on the final comparison result.
S703: and generating a diagnosis report aiming at the target application program according to the comparison result, and reporting the diagnosis report to a server.
Exemplarily, it is assumed that the standard operation state information includes a standard operation timing sequence condition of each key node, the target application includes 5 key nodes, which are respectively a recording node Record, an impartial node ANS, a gain compensation node AGC, a coding node Encoder, and a synthesis node Muxer, and the timing sequence relationships of the 5 key nodes characterized by the standard operation timing sequence condition in the standard workflow are as follows: record- > ANS- > AGC- > Encoder- > Muxer. For such a situation, the terminal device compares the actual running time sequence of each key node with the standard running time sequence conditions of each key node included in the standard operation flow, and the obtained comparison result for the running time sequence represents the time sequence relationship of each key node in the actual running process: record- > ANS- > AGC- > Encoder- > Muxer, a diagnosis report as shown in FIG. 8 can be generated based on the comparison result for the operation timing sequence, and the diagnosis report shows that each key node operates normally and the operation sequence of each key node in the actual operation process.
Or, for the case in the above example, the terminal device compares the actual running time sequence of each key node with the standard running time sequence condition of each key node included in the standard workflow, and the obtained comparison result for the running time sequence represents the time sequence relationship of each key node in actual running, and is also: record- > ANS- > Encode > AGC- > Muxer, Encode performed prior to AGC, a diagnostic report as shown in FIG. 9 may be generated based on the comparison for the run timing, the diagnostic report showing Encode performed prior to AGC. It can be seen that the developer can quickly locate the problem in the running process of the target program according to the diagnosis report without manually analyzing a large amount of logs.
In one embodiment, the content of the diagnosis report for the target application may be presented in text form, in addition to the presentation form of the code form shown in fig. 8 or fig. 9, for example, the diagnosis report shown in fig. 9 may be adjusted to a text message "Encoder is performed before AGC". By adopting the mode, non-developers can intuitively position the running problem of the target application program.
In the embodiment of the invention, after the target application program is operated online, the actual operation state information of each key node when the target application program operates each key node in at least one key node can be obtained, the actual operation state information of each key node is compared with the standard operation state information of each key node included in the standard operation flow to obtain the comparison result, and then a diagnosis report aiming at the target application program is generated according to the comparison result and reported to the server. By adopting the embodiment of the invention, the automatic detection of the target application program and the generation and report of the diagnosis report can be realized after the target application program is online, the log is fished out without depending on the online of the current network user, and the log is not required to be analyzed manually, thereby being beneficial to improving the detection efficiency of the target application program.
Referring to fig. 10, a schematic flowchart of another application detection method according to an embodiment of the present invention is shown, where the method according to the embodiment of the present invention may be executed by a terminal device. The method of an embodiment of the present invention includes the following steps.
S101: and loading the standard work flow file of the target application program. The standard work flow of the target application program can be imported by a developer, and after the terminal device detects that the standard work flow is imported, the standard work flow file of the target application program is automatically loaded.
S102: and performing class name reflection on the standard running state file to generate a standard operation flow corresponding to the target application program. The class name may be a class name of each standard operation state condition included in the standard workflow file, such as a standard operation parameter condition, a standard operation timing condition, a standard operation frequency condition, and the like.
In an embodiment, the terminal device may record the running state information of each key node in the at least one key node under the condition that the target application program runs normally, and use the recorded running state information of each key node as the standard running state information of each key node, and further generate the standard job flow file of the target application program by using the standard running state information of each key node according to the running time sequence in the recorded running state information of each key node. For a specific implementation of how to generate the standard job flow file of the target application program, reference may be made to the related description of fig. 2 in the foregoing embodiment, and details are not described here again.
Further, after the standard workflow file of the target application program is loaded, each standard operation state condition included in the standard workflow file can be restored through class name reflection, and then the standard workflow corresponding to the target application program is generated based on each standard operation state condition.
S103: and after the target application program is operated on line, acquiring the actual operation state information of each key node when the target application program operates each key node in at least one key node.
S104: and comparing the actual running state information of each key node with the standard running state information of each key node included in the standard operation flow to obtain a comparison result, wherein the standard running state information of each key node refers to the running state information of each key node acquired under the condition that the target application program runs normally.
S105: and generating a diagnosis report aiming at the target application program according to the comparison result, and reporting the diagnosis report to a server. For specific implementation of steps S103 to S105, refer to the above embodiments and the related description of steps S701 to S703, which are not described herein again.
And selecting the key node in the target application program to be associated with the service type corresponding to the target application program. In one embodiment, the terminal device may obtain a service type of the target application program, and determine at least one key node from nodes included in the target application program according to the service type of the target application program.
In an embodiment, a template list selected by a key node may be established for each service type, and each template list includes identification information (e.g., a node name) of each preset key node under the corresponding service type. For example, a certain service type is live broadcasting, and the names of the nodes in the live broadcasting are sequentially: downloading, decoding and playing, wherein the template list corresponding to the watching live broadcast comprises node names of downloading, decoding and playing. For such a situation, after acquiring the service type of the target application program, the terminal device may acquire the identification information of the preset key node from the target template list corresponding to the service type, and further determine, as the key node, a node that matches the identification information of the preset key node from among nodes included in the target application program.
In the embodiment of the invention, the terminal equipment can load the standard operation flow file of the target application program and perform class name reflection on the standard operation state file so as to generate the standard operation flow corresponding to the target application program. Further, after the target application program is operated online, the actual operation state information of each key node when the target application program operates each key node in the at least one key node can be acquired, the actual operation state information of each key node is compared with the standard operation state information of each key node included in the standard operation flow, a comparison result is obtained, a diagnosis report for the target application program is generated according to the comparison result, and the diagnosis report is reported to the server. By adopting the embodiment of the invention, the automatic detection of the target application program and the generation and report of the diagnosis report can be realized after the target application program is online, the log is fished out without depending on the online of the current network user, and the log is not required to be analyzed manually, thereby being beneficial to improving the detection efficiency of the target application program.
Embodiments of the present invention further provide a computer storage medium, in which program instructions are stored, and when the program instructions are executed, the computer storage medium is configured to implement the corresponding method described in the above embodiments.
Referring to fig. 11, a schematic structural diagram of an application detection apparatus according to an embodiment of the present invention is shown, where the application detection apparatus according to the embodiment of the present invention may be disposed in a terminal device, and the terminal device runs a target application, where the target application includes at least one key node.
In one implementation of the apparatus of the embodiment of the present invention, the apparatus includes the following structure.
A processing module 201, configured to obtain actual operation state information of each key node when the target application runs each key node of the at least one key node after the target application runs online;
the processing module 201 is further configured to compare the actual running state information of each key node with the standard running state information of each key node included in the standard operation flow to obtain a comparison result, where the standard running state information of each key node is the running state information of each key node obtained when the target application program runs normally;
the processing module 201 is further configured to generate a diagnosis report for the target application according to the comparison result;
a communication module 202, configured to report the diagnosis report to a server.
In one embodiment, the standard operating state information includes one or more of standard operating parameter conditions, standard operating timing conditions, and standard number of operations conditions.
In an embodiment, the standard running state information includes the standard running parameter condition and the standard running timing condition, and the processing module 201 is specifically configured to, in the running process of the target application program, compare, when obtaining actual running state information of a first key node in the at least one key node, the actual running state information of the first key node with the standard running parameter condition and the standard running timing condition of the first key node included in a standard workflow, where the first key node is any one of the at least one key node; and generating a comparison result aiming at the operation parameter and the operation time sequence after comparison aiming at all the key nodes in the at least one key node is finished.
In an embodiment, the standard running state information includes the standard running time condition, the actual running state information of each key node includes the actual running time of each key node recorded after the target application program is run, and the processing module 201 is further configured to compare the actual running state information of each key node with the standard running time condition of each key node included in a standard job flow after the target application program is run, so as to obtain a comparison result for the running times.
In one embodiment, the processing module 201 is further configured to load a standard workflow file of the target application program; and performing class name reflection on the standard running state file to generate a standard operation flow corresponding to the target application program.
In an embodiment, the processing module 201 is further configured to record, under the condition that the target application program runs normally, running state information of each key node in the at least one key node; taking the recorded running state information of each key node as the standard running state information of each key node; and generating a standard operation flow file of the target application program by using the standard operation state information of each key node according to the recorded operation time sequence in the operation state information of each key node.
In an embodiment, the processing module 201 is further configured to obtain a service type of the target application; and determining at least one key node from the nodes included in the target application program according to the service type of the target application program.
In the embodiment of the present invention, reference may be made to the description of relevant contents in the embodiments corresponding to the foregoing drawings for specific implementations of the above modules.
In the embodiment of the present invention, after the target application program is online operated, the processing module 201 obtains the actual operation state information of each key node when the target application program operates each key node of the at least one key node. Further, the actual running state information of each key node is compared with the standard running state information of each key node included in the standard operation flow through the processing module 201 to obtain a comparison result, a diagnosis report for the target application program is generated according to the comparison result, and the diagnosis report is reported to the server through the communication module 202. By adopting the embodiment of the invention, after the target application program is online, the actual running state information of each key node can be automatically compared with the standard running state information of each key node included in the standard operation process, thereby being beneficial to improving the detection efficiency of the target application program.
Referring to fig. 12 again, the schematic structural diagram of a terminal device according to an embodiment of the present invention is shown, where the terminal device runs a target application, and the target application includes at least one key node, and the terminal device according to an embodiment of the present invention includes structures such as a power supply module, and includes a processor 301, a storage device 302, and a transceiver 303. The processor 301, the storage device 302 and the transceiver 303 can exchange data, and the processor 301 implements a corresponding application program detection function.
The storage device 302 may include a volatile memory (volatile memory), such as a random-access memory (RAM); the storage device 302 may also include a non-volatile memory (non-volatile memory), such as a flash memory (flash memory), a solid-state drive (SSD), etc.; the storage means 302 may also comprise a combination of memories of the kind described above.
The processor 301 may be a Central Processing Unit (CPU) 301. In one embodiment, the processor 301 may also be a Graphics Processing Unit (GPU) 301. The processor 301 may also be a combination of a CPU and a GPU. In the terminal device, a plurality of CPUs and GPUs may be included as necessary to perform corresponding application detection. In one embodiment, the storage device 302 is used to store program instructions. The processor 301 may invoke the program instructions to implement the various methods as described above in embodiments of the invention.
In a first possible implementation manner, the processor 301 of the terminal device calls a program instruction stored in the storage device 302, so as to obtain actual operation state information of each key node when the target application runs each key node of the at least one key node after the target application runs online; comparing the actual running state information of each key node with the standard running state information of each key node included in a standard operation flow to obtain a comparison result, wherein the standard running state information of each key node refers to the running state information of each key node obtained under the condition that the target application program runs normally; and generating a diagnosis report aiming at the target application program according to the comparison result, and reporting the diagnosis report to a server through a transceiver 303.
In one embodiment, the standard operating state information includes one or more of standard operating parameter conditions, standard operating timing conditions, and standard number of operations conditions.
In an embodiment, the standard running state information includes the standard running parameter condition and the standard running timing condition, and the processor 301 is specifically configured to, in the running process of the target application program, compare, when obtaining actual running state information of a first key node in the at least one key node, the actual running state information of the first key node with the standard running parameter condition and the standard running timing condition of the first key node included in a standard workflow, where the first key node is any one of the at least one key node; and generating a comparison result aiming at the operation parameter and the operation time sequence after comparison aiming at all the key nodes in the at least one key node is finished.
In an embodiment, the standard running state information includes the standard running time condition, the actual running state information of each key node includes the actual running time of each key node recorded after the target application program is run, and the processor 301 is further configured to compare the actual running state information of each key node with the standard running time condition of each key node included in a standard job flow after the target application program is run, so as to obtain a comparison result for the running times.
In one embodiment, the processor 301 is further configured to load a standard workflow file of the target application; and performing class name reflection on the standard running state file to generate a standard operation flow corresponding to the target application program.
In one embodiment, the processor 301 is further configured to record running state information of each key node in the at least one key node when the target application runs normally; taking the recorded running state information of each key node as the standard running state information of each key node; and generating a standard operation flow file of the target application program by using the standard operation state information of each key node according to the recorded operation time sequence in the operation state information of each key node.
In one embodiment, the processor 301 is further configured to obtain a service type of the target application; and determining at least one key node from the nodes included in the target application program according to the service type of the target application program.
In the embodiment of the present invention, the specific implementation of the processor 301 may refer to the description of relevant contents in the embodiments corresponding to the foregoing drawings.
In the embodiment of the present invention, after the target application program is online operated, the processor 301 obtains the actual operation state information of each key node when the target application program operates each key node of the at least one key node. Further, the actual running state information of each key node is compared with the standard running state information of each key node included in the standard operation flow through the processor 301 to obtain a comparison result, a diagnosis report for the target application program is generated according to the comparison result, and the diagnosis report is reported to the server through the transceiver 303. By adopting the embodiment of the invention, after the target application program is online, the actual running state information of each key node can be automatically compared with the standard running state information of each key node included in the standard operation process, thereby being beneficial to improving the detection efficiency of the target application program.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), or the like.
While the invention has been described with reference to a number of embodiments, it will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the invention as defined by the appended claims.

Claims (10)

1. An application detection method is applied to a terminal device, the terminal device runs a target application, the target application comprises at least one key node, and the method comprises the following steps:
after the target application program is operated online, acquiring actual operation state information of each key node when the target application program operates each key node in the at least one key node;
comparing the actual running state information of each key node with the standard running state information of each key node included in a standard operation flow to obtain a comparison result, wherein the standard running state information of each key node refers to the running state information of each key node obtained under the condition that the target application program runs normally;
and generating a diagnosis report aiming at the target application program according to the comparison result, and reporting the diagnosis report to a server.
2. The method of claim 1, wherein the standard operating state information comprises one or more of standard operating parameter conditions, standard operating timing conditions, and standard number of operations conditions.
3. The method according to claim 1 or 2, wherein the standard operating status information includes the standard operating parameter condition and the standard operating timing condition, and the comparing the actual operating status information of each key node with the standard operating status information of each key node included in a standard workflow obtains a comparison result, including:
in the running process of the target application program, when actual running state information of a first key node in the at least one key node is acquired, comparing the actual running state information of the first key node with the standard running parameter condition and the standard running time sequence condition of the first key node included in a standard operation process, wherein the first key node is any one of the at least one key node;
and generating a comparison result aiming at the operation parameter and the operation time sequence after comparison aiming at all the key nodes in the at least one key node is finished.
4. The method according to claim 3, wherein the standard running state information includes the standard running time condition, and the actual running state information of each key node includes the actual running time of each key node recorded after the target application program is run, and the method further includes:
and after the target application program is operated, comparing the actual operation state information of each key node with the standard operation frequency condition of each key node included in a standard operation flow to obtain a comparison result aiming at the operation frequency.
5. The method according to claim 1, wherein before comparing the actual operating status information of each key node with the standard operating status information of each key node included in a standard workflow, the method further comprises:
loading a standard operation flow file of the target application program;
and performing class name reflection on the standard running state file to generate a standard operation flow corresponding to the target application program.
6. The method of claim 5, wherein prior to said loading the standard workflow file for the target application, the method further comprises:
recording the running state information of each key node in the at least one key node under the condition that the target application program runs normally;
taking the recorded running state information of each key node as the standard running state information of each key node;
and generating a standard operation flow file of the target application program by using the standard operation state information of each key node according to the recorded operation time sequence in the operation state information of each key node.
7. The method according to claim 1, wherein before obtaining actual operating state information of each key node when the target application runs each of the at least one key node after the target application runs online, the method further comprises:
acquiring the service type of the target application program;
and determining at least one key node from the nodes included in the target application program according to the service type of the target application program.
8. An apparatus for detecting an application, the apparatus being configured to a terminal device, the terminal device running a target application, the target application including at least one key node, the apparatus comprising:
the processing module is used for acquiring the actual running state information of each key node when the target application program runs each key node in the at least one key node after the target application program runs on line;
the processing module is further configured to compare the actual running state information of each key node with standard running state information of each key node included in a standard operation flow to obtain a comparison result, where the standard running state information of each key node is the running state information of each key node obtained when the target application program runs normally;
the processing module is further used for generating a diagnosis report aiming at the target application program according to the comparison result;
and the communication module is used for reporting the diagnosis report to a server.
9. A terminal device, characterized in that it comprises a processor and a storage means, said processor and storage means being interconnected, wherein said storage means is adapted to store a computer program comprising program instructions, said processor being configured to invoke said program instructions to perform the method according to any one of claims 1-7.
10. A computer storage medium having stored thereon program instructions for implementing a method according to any one of claims 1 to 7 when executed.
CN201910774377.5A 2019-08-21 2019-08-21 Application program detection method and device, terminal equipment and storage medium Pending CN112416735A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910774377.5A CN112416735A (en) 2019-08-21 2019-08-21 Application program detection method and device, terminal equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910774377.5A CN112416735A (en) 2019-08-21 2019-08-21 Application program detection method and device, terminal equipment and storage medium

Publications (1)

Publication Number Publication Date
CN112416735A true CN112416735A (en) 2021-02-26

Family

ID=74779768

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910774377.5A Pending CN112416735A (en) 2019-08-21 2019-08-21 Application program detection method and device, terminal equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112416735A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114185324A (en) * 2021-10-25 2022-03-15 华能澜沧江水电股份有限公司 Abnormal point detection method and device of automatic power generation control program and computer equipment

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104572318A (en) * 2013-10-24 2015-04-29 腾讯科技(深圳)有限公司 Report information obtaining method, device, equipment and system
CN106371958A (en) * 2016-08-31 2017-02-01 浪潮电子信息产业股份有限公司 Server fault diagnosis system and method
US20170123875A1 (en) * 2015-11-04 2017-05-04 International Business Machines Corporation Detecting anomalies in program execution
CN107239702A (en) * 2016-03-29 2017-10-10 腾讯科技(深圳)有限公司 The method and device of a kind of security breaches detection
CN108228442A (en) * 2016-12-14 2018-06-29 华为技术有限公司 A kind of detection method and device of abnormal nodes
CN109101397A (en) * 2018-08-01 2018-12-28 武汉索雅信息技术有限公司 High-Performance Computing Cluster monitoring method, unit and storage medium
CN109542744A (en) * 2018-11-19 2019-03-29 Oppo广东移动通信有限公司 Detect method, apparatus, storage medium and the terminal of terminal booting abnormal problem
CN109862379A (en) * 2018-12-29 2019-06-07 北京奇艺世纪科技有限公司 A kind of log processing method, device, mobile terminal and storage medium

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104572318A (en) * 2013-10-24 2015-04-29 腾讯科技(深圳)有限公司 Report information obtaining method, device, equipment and system
US20170123875A1 (en) * 2015-11-04 2017-05-04 International Business Machines Corporation Detecting anomalies in program execution
CN107239702A (en) * 2016-03-29 2017-10-10 腾讯科技(深圳)有限公司 The method and device of a kind of security breaches detection
CN106371958A (en) * 2016-08-31 2017-02-01 浪潮电子信息产业股份有限公司 Server fault diagnosis system and method
CN108228442A (en) * 2016-12-14 2018-06-29 华为技术有限公司 A kind of detection method and device of abnormal nodes
CN109101397A (en) * 2018-08-01 2018-12-28 武汉索雅信息技术有限公司 High-Performance Computing Cluster monitoring method, unit and storage medium
CN109542744A (en) * 2018-11-19 2019-03-29 Oppo广东移动通信有限公司 Detect method, apparatus, storage medium and the terminal of terminal booting abnormal problem
CN109862379A (en) * 2018-12-29 2019-06-07 北京奇艺世纪科技有限公司 A kind of log processing method, device, mobile terminal and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114185324A (en) * 2021-10-25 2022-03-15 华能澜沧江水电股份有限公司 Abnormal point detection method and device of automatic power generation control program and computer equipment
CN114185324B (en) * 2021-10-25 2024-04-02 华能澜沧江水电股份有限公司 Abnormal point detection method and device for automatic power generation control program and computer equipment

Similar Documents

Publication Publication Date Title
US8312322B2 (en) System for automated generation of computer test procedures
CN112241360B (en) Test case generation method, device, equipment and storage medium
CN109815119B (en) APP link channel testing method and device
CN111198797B (en) Operation monitoring method and device and operation analysis method and device
CN111290951B (en) Test method, terminal, server, system and storage medium
CN111190827A (en) Interface automation test method and device, storage medium and electronic equipment
CN111522749B (en) Page testing method and device, readable storage medium and electronic equipment
CN114996103A (en) Page abnormity detection method and device, electronic equipment and storage medium
CN110795353B (en) Quick application debugging method, device, equipment and storage medium
CN114546881A (en) Application software testing method, electronic device and computer readable storage medium
CN110543429A (en) Test case debugging method and device and storage medium
CN106294109B (en) Method and device for acquiring defect code
CN112540808A (en) Method for recording program behavior level calling relation and related equipment
CN107451056B (en) Method and device for monitoring interface test result
CN112416735A (en) Application program detection method and device, terminal equipment and storage medium
JP5006824B2 (en) Test program management system
CN110888804B (en) Interface test method and interface test platform
CN112100035A (en) Page abnormity detection method, system and related device
CN112148599A (en) Performance pressure measurement method, device and equipment
CN116738091A (en) Page monitoring method and device, electronic equipment and storage medium
CN111666200A (en) Testing method and terminal for time consumption of cold start of PC software
CN110362464B (en) Software analysis method and equipment
KR20130067959A (en) Method and appratus for processing error of application
US20160275002A1 (en) Image capture in application lifecycle management for documentation and support
CN111522737B (en) Automatic test verification method and device for front-end interface and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination