CN112596938A - Abnormity monitoring method and device - Google Patents
Abnormity monitoring method and device Download PDFInfo
- Publication number
- CN112596938A CN112596938A CN202011569158.2A CN202011569158A CN112596938A CN 112596938 A CN112596938 A CN 112596938A CN 202011569158 A CN202011569158 A CN 202011569158A CN 112596938 A CN112596938 A CN 112596938A
- Authority
- CN
- China
- Prior art keywords
- function
- time
- thread
- target
- determining
- 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
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/0703—Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
- G06F11/0751—Error or fault detection not based on redundancy
- G06F11/0754—Error or fault detection not based on redundancy by exceeding limits
- G06F11/0757—Error or fault detection not based on redundancy by exceeding limits by exceeding a time limit, i.e. time-out, e.g. watchdogs
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/0703—Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
- G06F11/0706—Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment
- G06F11/0709—Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment in a distributed system consisting of a plurality of standalone computer nodes, e.g. clusters, client-server systems
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/0703—Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
- G06F11/079—Root cause analysis, i.e. error or fault diagnosis
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Health & Medical Sciences (AREA)
- Biomedical Technology (AREA)
- Computer Hardware Design (AREA)
- Debugging And Monitoring (AREA)
Abstract
The embodiment of the application provides an abnormity monitoring method. When monitoring a process such as a network system or an application program, a target thread may be obtained first, where the target thread includes at least one function for a thread whose execution time is longer than a first time threshold among one or more threads of the process. After determining the target thread with a long execution view, the target function of the target thread can be determined, and the target function is the function called by the target thread. After the target function is determined, the function call time of the target thread may be obtained, where the function call time is the time when the target thread calls the target function. Next, it may be determined whether the function call time of the target thread is greater than a second time threshold. And if so, determining the target function as an abnormal function. Therefore, the method can quickly locate and can accurately reach specific functions in the program under the conditions of slow program execution or unstable response time and the like, and the efficiency of abnormity monitoring is improved.
Description
Technical Field
The present application relates to the field of computer technologies, and in particular, to an anomaly monitoring method and apparatus.
Background
In order to monitor the working condition of the network system, a method for monitoring the server logs may be adopted at present, for example, the number of the server logs may be analyzed, or the value of a specific field of the server logs with an abnormality may be analyzed. If the network system has faults, the monitoring system can determine the faults according to the server logs and inform corresponding technicians, so that the technicians can timely remove the faults.
However, the conventional monitoring method can only locate a failed link to a server or a module, that is, only which server or module in the network system fails can be determined, and a specific program or function that has a problem cannot be determined. The technician also checks the error log of the system or checks the situation by personally going to the position of the server with the fault, so that the problem can be solved. Therefore, a large amount of time is consumed in fault location, the fault removal time is increased, a time course required by the system from fault occurrence to normal operation recovery is caused, and the normal operation of the system is influenced.
Disclosure of Invention
In view of this, embodiments of the present application provide an exception monitoring method and apparatus, which aim to find a function with an exception in a program according to the running time of each thread in a process.
In a first aspect, an embodiment of the present application provides an anomaly monitoring method, where the method includes:
acquiring a target thread, wherein the target thread is a thread with the execution time longer than a first time threshold and comprises at least one function;
determining a target function of the target thread, wherein the target function is a function called by the target thread;
acquiring function calling time of the target thread, wherein the function calling time comprises the time for calling the target function by the target thread;
and judging whether the function calling time is greater than a second time threshold value, if so, determining that the target function is an abnormal function.
Optionally, the determining an objective function of the target thread includes:
acquiring a method stack of the target thread, wherein the method stack comprises at least one piece of function information, and the function information is related information of a function to be called of the target thread;
and determining a function corresponding to the function information at the top of the stack of the method as a target function.
Optionally, the obtaining the function call time of the target thread includes:
and determining the time for which the function information at the top of the stack of the method is kept unchanged as the function calling time.
Optionally, the determining, as the function call time, the time for keeping the function information at the top of the method stack unchanged includes:
periodically scanning function information at the top of the stack of the method;
determining the interval time between the first time and the second time as the function calling time in response to the change of the function information at the top of the method stack;
the first time is the time when the function information of the method stack top is changed into the function information of the target function, and the second information is the time when the function information of the method stack top is changed into the function information of the non-target function.
Optionally, the obtaining the target thread includes:
acquiring a thread list, wherein the thread list comprises at least one executing thread;
and in response to the execution time of any one thread in the at least one executing thread being greater than a first threshold value, determining the thread with the execution time greater than the first threshold value as a target thread.
Optionally, the determining that the objective function is an abnormal function includes:
acquiring a corresponding relation between a function and a code identifier, wherein the code identifier is an identifier of the number of lines where the code is located;
and acquiring the code identification corresponding to the target function according to the corresponding relation between the code identification and the function.
In a second aspect, an embodiment of the present application provides an abnormality monitoring apparatus, where the apparatus includes: the thread acquisition module is used for acquiring a target thread, wherein the target thread is a thread with the execution time longer than a first time threshold value, and comprises at least one function; a determining module, configured to determine a target function of the target thread, where the target function is a function being called by the target thread; the time acquisition module is used for acquiring function calling time of the target thread, wherein the function calling time comprises the time for calling the target function by the target thread; and the judging module is used for judging whether the function calling time is greater than a second time threshold, and if so, determining that the target function is an abnormal function.
Optionally, the determining module is configured to obtain a method stack of the target thread, where the method stack includes at least one piece of function information, and the function information is related to a function to be called by the target thread; and determining a function corresponding to the function information at the top of the stack of the method as a target function.
Optionally, when the determining module determines the target function by using the method stack of the target thread, the determining module is configured to determine, as the function call time, a time when the function information at the top of the method stack remains unchanged.
Optionally, the determining module is configured to periodically scan function information of a stack top of the method stack; determining the interval time between the first time and the second time as the function calling time in response to the change of the function information at the top of the method stack; the first time is the time when the function information of the method stack top is changed into the function information of the target function, and the second information is the time when the function information of the method stack top is changed into the function information of the non-target function.
Optionally, the thread obtaining module is configured to obtain a thread list, where the thread list includes at least one executing thread; and in response to the execution time of any one thread in the at least one executing thread being greater than a first threshold value, determining the thread with the execution time greater than the first threshold value as a target thread.
Optionally, the determining module is configured to obtain a correspondence between a function and a code identifier, where the code identifier is an identifier of a line number where the code is located; and acquiring the code identification corresponding to the target function according to the corresponding relation between the code identification and the function.
In a third aspect, an embodiment of the present application provides a computer-readable storage medium, which is used for storing a computer program, and can enable the computer to execute the method for monitoring an anomaly according to the foregoing first aspect.
The embodiment of the application provides an abnormity monitoring method and device. When monitoring a process such as a network system or an application program, a target thread may be obtained first, where the target thread includes at least one function for a thread whose execution time is longer than a first time threshold among one or more threads of the process. After determining the target thread with a long execution view, the target function of the target thread can be determined, and the target function is the function called by the target thread. After the target function is determined, the function call time of the target thread may be obtained, where the function call time is the time when the target thread calls the target function. Next, it may be determined whether the function call time of the target thread is greater than a second time threshold. If the function calling time is larger than the second time threshold, the target function is called by the target thread for a longer time, and the target function may have a problem. Therefore, the objective function can be determined as an abnormal function. Therefore, the time for calling each function by the target thread with longer execution time in the process is compared. The long calling time usually indicates that the function is abnormal, so that the function with long calling time is determined as an abnormal function, and the abnormal function can be directly positioned. Therefore, the program can be quickly positioned and can be accurately positioned to specific functions in the program under the conditions of slow execution of the program or unstable response time and the like, the efficiency of abnormal monitoring is improved, and the working pressure of technicians is reduced.
Drawings
To illustrate the technical solutions in the present embodiment or the prior art more clearly, the drawings needed to be used in the description of the embodiment or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a flowchart of a method of an anomaly monitoring method according to an embodiment of the present application;
fig. 2 is a schematic structural diagram of an abnormality monitoring apparatus according to an embodiment of the present application.
Detailed Description
Currently, when monitoring a network system running on a plurality of servers, each server may be monitored. For example, a conventional monitoring system may obtain the number of server logs generated by a plurality of servers in real time. And scanning the database of the server when the number of the server logs of any one of the servers exceeds a threshold value, so as to find abnormal logs generated in the running process of the server and further determine the abnormality generated in the running process of the server. Thus, even if the network system is composed of a plurality of servers, a technician can quickly find a failed server from among the plurality of servers when the system fails.
Conventional monitoring systems can only determine a failed server or a failed software module, and cannot determine that a particular portion of the program has failed. In order to determine the specific location of the fault, monitoring can be performed by using a buried point method. A buried point refers to inserting an output statement in an application. When the program runs to the output statement, the preset character can be output. If the preset character is detected, the program before the output statement is not problematic. In this way, the location of the fault in the program can be determined.
However, this solution of buried points only allows to determine whether a program between two buried points has failed. In order to determine the operation of each function in the program, a buried point is needed between any two functions. Then, when the network system is large in size, the number of the required buried points is greatly increased, and the modification amount of the code is large, which also brings extra burden to the server.
In order to provide a method capable of automatically determining a fault function, the embodiment of the application provides an anomaly monitoring method and device. The following describes an anomaly monitoring method provided by an embodiment of the present application from the perspective of an anomaly monitoring system with reference to the drawings of the specification. The anomaly monitoring system provided by the embodiment of the application can run on an independent server or a server cluster and is used for monitoring the anomaly of a program designed based on an Object Oriented design method. It should be apparent that the described embodiments are only some of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
Before describing specific technical solutions, some terms of art related to the embodiments of the present application are described first.
And (4) process: a Process (Process) is a running activity of a program in a computer on a data set, and is a basic unit for resource allocation and scheduling by a system. In a computer structure designed for a process, the process is a basic execution entity of a program; in a computer architecture designed to be thread-oriented (i.e., object-oriented), a process is a container of threads, and a process may include multiple threads.
Thread: a Thread (Thread) is the smallest unit that the operating system can perform arithmetic scheduling. It is included in the process and is the actual unit of operation in the process. One or more functions may be called during the course of a thread's execution. By calling the function, the thread can realize the function of operation scheduling.
Function: in object-oriented design computer programs, also called methods, a piece of program or code is referred to directly by another piece of program or code.
Stack: a stack, also known as a stack, is an arithmetic limited data structure, such as a linked list. One section of the stack can insert and delete data, and the other end cannot be modified. One end into which data can be inserted is called the top of the stack and the other end is called the bottom of the stack. The process of data entering the stack from the top of the stack is called pushing (or pushing, pushing). The process of data leaving the stack from the top of the stack is called outbound (or push). When new data is pushed onto the stack, the element originally at the top of the stack is moved backwards.
Referring to fig. 1, fig. 1 is a flowchart of a method of an anomaly monitoring method according to an embodiment of the present application, including:
s101: and acquiring a target thread.
For software or system designed based on the object-oriented design method, one or more processes can be run, and each process can realize the function of the process through one or more threads in the running process. In the running process of any one thread, any one function in the application program can be called to realize the function of the thread.
When monitoring software or a system designed based on an object-oriented design method, a monitoring server may first obtain a target thread, which may be a thread with an execution time longer than a first time threshold. Wherein the first time threshold may be a time threshold preset by a technician. If the time of the thread execution exceeds the first time threshold, the thread is possible to be in failure.
In some possible implementations, the monitoring server may further obtain a thread list, which may include at least one executing thread, for example, a thread list that a server is running. The monitoring server may obtain an execution time of each thread in the thread list, and when the execution time of any one thread in the thread list is greater than a first threshold, determine the thread with the execution time greater than the first threshold as a target thread. For example, when a process invokes a new thread, the monitoring server may record the identification of the new thread and the time the new thread executes. The monitoring server may determine the new thread as the target thread if the execution time of the new thread exceeds a first time threshold.
S102: and determining an objective function of the target thread.
After obtaining the target thread, the monitoring server may determine an objective function being executed by the target thread. Optionally, for software or system designed based on the object-oriented design method, when a function is called, the thread may add the relevant information of the function to be called to the method stack first, and after the calling of the function is finished, the thread may pop the relevant information of the function. That is, the function information at the top of the method stack is the related information of the function currently called by the thread. Then, the monitoring server may determine a function corresponding to the function information at the top of the method stack as the target function.
S103: and acquiring the function calling time of the target thread.
After determining the target function of the target thread, the monitoring server may obtain function call time of the target thread, where the function call time is time for the target thread to call the target function. Optionally, if the monitoring server determines the target function through the method stack of the target thread, the monitoring server may determine, as the function call time, a time when the function information at the top of the method stack remains unchanged.
Optionally, the monitoring server may periodically scan function information at the top of the method stack of the target thread. And if the function information at the top of the method stack of the target thread is changed into the related information of the target function at the first time, the function information is changed into the related information of other functions at the second time. The monitoring server may determine an interval time between the first time and the second time as the function call time. For example, the monitoring server may determine function information at the top of the method stack by using a thread snapshot, and the thread snapshot may obtain relevant information of the target thread. Specifically, the monitoring server may periodically perform a thread snapshot on the target thread. If the function information at the top of the stack of the target thread method is changed into the related information of the target function in the Xth thread snapshot and is changed into other function information in the X + N thread snapshots, the monitoring server can determine the total time of the N thread snapshots as the function call time of the target thread. Wherein X, N is a positive integer greater than 1. Therefore, through the thread snapshot, the running progress of the monitored software or system can be determined without modifying the monitored software or system.
S104: and judging whether the function calling time is greater than a second time threshold value, if so, determining that the target function is an abnormal function.
After determining the function call time, the monitoring server may determine whether the function call time is greater than a second time threshold, and if the function call time is greater than the second time threshold, it indicates that the time for the target thread to call the target function is too long, that is, the execution of the target function needs to consume more time, and the target function may have a problem. Then the monitoring server may determine the objective function as an abnormal function, thereby alerting the technician.
Optionally, in order to further determine the location of the fault, the monitoring server may further obtain a correspondence between the function and the code identifier. The code identifier is an identifier of a line number where the code is located, that is, a line number identifier corresponding to each code in the program. Then, according to the correspondence between the code identifier and the function, the monitoring server may obtain the code identifier corresponding to the target function. Therefore, when the software or the system has faults, the codes of the positions where the faults possibly occur can be directly positioned, and the efficiency of monitoring the abnormity is further improved.
The embodiment of the application provides an abnormity monitoring method. When monitoring a process such as a network system or an application program, a target thread may be obtained first, where the target thread includes at least one function for a thread whose execution time is longer than a first time threshold among one or more threads of the process. After determining the target thread with a long execution view, the target function of the target thread can be determined, and the target function is the function called by the target thread. After the target function is determined, the function call time of the target thread may be obtained, where the function call time is the time when the target thread calls the target function. Next, it may be determined whether the function call time of the target thread is greater than a second time threshold. If the function calling time is larger than the second time threshold, the target function is called by the target thread for a longer time, and the target function may have a problem. Therefore, the objective function can be determined as an abnormal function. Therefore, the time for calling each function by the target thread with longer execution time in the process is compared. The long calling time usually indicates that the function is abnormal, so that the function with long calling time is determined as an abnormal function, and the abnormal function can be directly positioned. Therefore, the program can be quickly positioned and can be accurately positioned to specific functions in the program under the conditions of slow execution of the program or unstable response time and the like, the efficiency of abnormal monitoring is improved, and the working pressure of technicians is reduced.
The foregoing provides some specific implementation manners of the anomaly monitoring method for the embodiment of the present application, and based on this, the present application also provides a corresponding apparatus. The above-mentioned device provided by the embodiments of the present application will be described in terms of functional modularity.
Referring to the schematic structural diagram of the abnormality monitoring apparatus shown in fig. 2, the apparatus 200 includes:
a thread obtaining module 210, configured to obtain a target thread, where the target thread is a thread whose execution time is longer than a first time threshold, and the target thread includes at least one function;
a determining module 220, configured to determine a target function of the target thread, where the target function is a function being called by the target thread;
a time obtaining module 230, configured to obtain function call time of the target thread, where the function call time includes time for the target thread to call the target function;
the determining module 240 is configured to determine whether the function call time is greater than a second time threshold, and if so, determine that the target function is an abnormal function.
The embodiment of the application provides an abnormity monitoring device. When monitoring a process such as a network system or an application program, a target thread may be obtained first, where the target thread includes at least one function for a thread whose execution time is longer than a first time threshold among one or more threads of the process. After determining the target thread with a long execution view, the target function of the target thread can be determined, and the target function is the function called by the target thread. After the target function is determined, the function call time of the target thread may be obtained, where the function call time is the time when the target thread calls the target function. Next, it may be determined whether the function call time of the target thread is greater than a second time threshold. If the function calling time is larger than the second time threshold, the target function is called by the target thread for a longer time, and the target function may have a problem. Therefore, the objective function can be determined as an abnormal function. Therefore, the time for calling each function by the target thread with longer execution time in the process is compared. The long calling time usually indicates that the function is abnormal, so that the function with long calling time is determined as an abnormal function, and the abnormal function can be directly positioned. Therefore, the program can be quickly positioned and can be accurately positioned to specific functions in the program under the conditions of slow execution of the program or unstable response time and the like, the efficiency of abnormal monitoring is improved, and the working pressure of technicians is reduced.
Optionally, in some possible implementations, the determining module 220 is configured to obtain a method stack of the target thread, where the method stack includes at least one piece of function information, and the function information is related to a function to be called by the target thread; and determining a function corresponding to the function information at the top of the stack of the method as a target function.
Optionally, in some possible implementations, when the determining module determines the target function by using the method stack of the target thread, the determining module 230 is configured to determine, as the function call time, a time when the function information at the top of the method stack is kept unchanged.
Optionally, in some possible implementations, the determining module 230 is configured to periodically scan function information at the top of the method stack; determining the interval time between the first time and the second time as the function calling time in response to the change of the function information at the top of the method stack; the first time is the time when the function information of the method stack top is changed into the function information of the target function, and the second information is the time when the function information of the method stack top is changed into the function information of the non-target function.
Optionally, in some possible implementations, the thread obtaining module 210 is configured to obtain a thread list, where the thread list includes at least one executing thread; and in response to the execution time of any one thread in the at least one executing thread being greater than a first threshold value, determining the thread with the execution time greater than the first threshold value as a target thread.
Optionally, in some possible implementation manners, the determining module 240 is configured to obtain a corresponding relationship between a function and a code identifier, where the code identifier is an identifier of a line number where the code is located; and acquiring the code identification corresponding to the target function according to the corresponding relation between the code identification and the function.
Therefore, the program can be quickly positioned and can be accurately positioned to specific functions in the program under the conditions of slow execution of the program or unstable response time and the like, the efficiency of abnormal monitoring is improved, and the working pressure of technicians is reduced.
In the embodiments of the present application, the names "first" and "second" in the names "first time threshold", "second time threshold", and the like are used only for name identification, and do not represent the first and second in sequence.
As can be seen from the above description of the embodiments, those skilled in the art can clearly understand that all or part of the steps in the above embodiment methods can be implemented by software plus a general hardware platform. Based on such understanding, the technical solution of the present application may be embodied in the form of a software product, which may be stored in a storage medium, such as a read-only memory (ROM)/RAM, a magnetic disk, an optical disk, or the like, and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network communication device such as a router) to execute the method according to the embodiments or some parts of the embodiments of the present application.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the apparatus embodiment, since it is substantially similar to the method embodiment, it is relatively simple to describe, and reference may be made to some descriptions of the method embodiment for relevant points. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
The above description is only an exemplary embodiment of the present application, and is not intended to limit the scope of the present application.
Claims (10)
1. An anomaly monitoring method, comprising:
acquiring a target thread, wherein the target thread is a thread with the execution time longer than a first time threshold and comprises at least one function;
determining a target function of the target thread, wherein the target function is a function called by the target thread;
acquiring function calling time of the target thread, wherein the function calling time comprises the time for calling the target function by the target thread;
and judging whether the function calling time is greater than a second time threshold value, if so, determining that the target function is an abnormal function.
2. The method of claim 1, wherein determining the objective function of the target thread comprises:
acquiring a method stack of the target thread, wherein the method stack comprises at least one piece of function information, and the function information is related information of a function to be called of the target thread;
and determining a function corresponding to the function information at the top of the stack of the method as a target function.
3. The method of claim 2, wherein obtaining the function call time of the target thread comprises:
and determining the time for which the function information at the top of the stack of the method is kept unchanged as the function calling time.
4. The method of claim 3, wherein determining the time for which the function information at the top of the method stack remains unchanged as the function call time comprises:
periodically scanning function information at the top of the stack of the method;
determining the interval time between the first time and the second time as the function calling time in response to the change of the function information at the top of the method stack;
the first time is the time when the function information of the method stack top is changed into the function information of the target function, and the second information is the time when the function information of the method stack top is changed into the function information of the non-target function.
5. The method of claim 1, wherein obtaining the target thread comprises:
acquiring a thread list, wherein the thread list comprises at least one executing thread;
and in response to the execution time of any one thread in the at least one executing thread being greater than a first threshold value, determining the thread with the execution time greater than the first threshold value as a target thread.
6. The method of claim 1, wherein the determining that the objective function is an abnormal function comprises:
acquiring a corresponding relation between a function and a code identifier, wherein the code identifier is an identifier of the number of lines where the code is located;
and acquiring the code identification corresponding to the target function according to the corresponding relation between the code identification and the function.
7. An anomaly monitoring device, said device comprising:
the thread acquisition module is used for acquiring a target thread, wherein the target thread is a thread with the execution time longer than a first time threshold value, and comprises at least one function;
a determining module, configured to determine a target function of the target thread, where the target function is a function being called by the target thread;
the time acquisition module is used for acquiring function calling time of the target thread, wherein the function calling time comprises the time for calling the target function by the target thread;
and the judging module is used for judging whether the function calling time is greater than a second time threshold, and if so, determining that the target function is an abnormal function.
8. The apparatus of claim 7,
the determining module is configured to obtain a method stack of the target thread, where the method stack includes at least one piece of function information, and the function information is related to a function to be called by the target thread; and determining a function corresponding to the function information at the top of the stack of the method as a target function.
9. The apparatus of claim 8,
the determining module is used for periodically scanning function information at the top of the stack of the method; determining the interval time between the first time and the second time as the function calling time in response to the change of the function information at the top of the method stack;
the first time is the time when the function information of the method stack top is changed into the function information of the target function, and the second information is the time when the function information of the method stack top is changed into the function information of the non-target function.
10. The apparatus of claim 7,
the thread obtaining module is used for obtaining a thread list, and the thread list comprises at least one executing thread; and in response to the execution time of any one thread in the at least one executing thread being greater than a first threshold value, determining the thread with the execution time greater than the first threshold value as a target thread.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011569158.2A CN112596938A (en) | 2020-12-26 | 2020-12-26 | Abnormity monitoring method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011569158.2A CN112596938A (en) | 2020-12-26 | 2020-12-26 | Abnormity monitoring method and device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN112596938A true CN112596938A (en) | 2021-04-02 |
Family
ID=75202369
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011569158.2A Pending CN112596938A (en) | 2020-12-26 | 2020-12-26 | Abnormity monitoring method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112596938A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113608982A (en) * | 2021-07-27 | 2021-11-05 | 远景智能国际私人投资有限公司 | Function execution performance monitoring method and device, computer equipment and storage medium |
CN115858399A (en) * | 2023-02-09 | 2023-03-28 | 创智和宇信息技术股份有限公司 | Method and system for performing code-level performance analysis by using thread stack snapshot |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106980555A (en) * | 2017-03-24 | 2017-07-25 | 山东浪潮商用系统有限公司 | A kind of overtime thread processing method and device |
CN108021496A (en) * | 2016-10-28 | 2018-05-11 | 腾讯科技(深圳)有限公司 | Thread-data processing method and processing device |
CN109840177A (en) * | 2017-11-24 | 2019-06-04 | 腾讯科技(深圳)有限公司 | A kind of processing method and relevant device of Caton |
CN110134385A (en) * | 2019-05-17 | 2019-08-16 | 中国农业银行股份有限公司 | Record the method and C language general journal frame of C language function call chain |
CN110941553A (en) * | 2019-11-22 | 2020-03-31 | 山东英信计算机技术有限公司 | Code detection method, device, equipment and readable storage medium |
CN111382026A (en) * | 2018-12-28 | 2020-07-07 | 广州市百果园信息技术有限公司 | Caton monitoring method, device, system, storage medium and computer equipment |
CN111552613A (en) * | 2020-04-26 | 2020-08-18 | 北京字节跳动网络技术有限公司 | Thread timeout processing method and device and electronic equipment |
-
2020
- 2020-12-26 CN CN202011569158.2A patent/CN112596938A/en active Pending
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108021496A (en) * | 2016-10-28 | 2018-05-11 | 腾讯科技(深圳)有限公司 | Thread-data processing method and processing device |
CN106980555A (en) * | 2017-03-24 | 2017-07-25 | 山东浪潮商用系统有限公司 | A kind of overtime thread processing method and device |
CN109840177A (en) * | 2017-11-24 | 2019-06-04 | 腾讯科技(深圳)有限公司 | A kind of processing method and relevant device of Caton |
CN111382026A (en) * | 2018-12-28 | 2020-07-07 | 广州市百果园信息技术有限公司 | Caton monitoring method, device, system, storage medium and computer equipment |
CN110134385A (en) * | 2019-05-17 | 2019-08-16 | 中国农业银行股份有限公司 | Record the method and C language general journal frame of C language function call chain |
CN110941553A (en) * | 2019-11-22 | 2020-03-31 | 山东英信计算机技术有限公司 | Code detection method, device, equipment and readable storage medium |
CN111552613A (en) * | 2020-04-26 | 2020-08-18 | 北京字节跳动网络技术有限公司 | Thread timeout processing method and device and electronic equipment |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113608982A (en) * | 2021-07-27 | 2021-11-05 | 远景智能国际私人投资有限公司 | Function execution performance monitoring method and device, computer equipment and storage medium |
CN115858399A (en) * | 2023-02-09 | 2023-03-28 | 创智和宇信息技术股份有限公司 | Method and system for performing code-level performance analysis by using thread stack snapshot |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US6763369B1 (en) | Hierarchical process management in an intelligent call processing system | |
CN112596938A (en) | Abnormity monitoring method and device | |
US20160352573A1 (en) | Method and System for Detecting Network Upgrades | |
CN110618864A (en) | Interrupt task recovery method and device | |
CN112527484A (en) | Workflow breakpoint continuous running method and device, computer equipment and readable storage medium | |
CN112527619A (en) | Analysis link calling method and system based on directed acyclic graph structure | |
CN113900952A (en) | Test case execution method and device, terminal equipment and readable storage medium | |
CN111181777B (en) | Service degradation method, device, computer equipment and storage medium | |
CN113094243B (en) | Node performance detection method and device | |
CN112000442A (en) | Method and device for automatically acquiring cluster state based on kubernets platform | |
CN104158843A (en) | Storage unit invalidation detecting method and device for distributed file storage system | |
CN115757138A (en) | Method and device for determining script abnormal reason, storage medium and electronic equipment | |
CN114706733B (en) | Section program abnormity monitoring method and device | |
CN113886122B (en) | System operation exception handling method, device, equipment and storage medium | |
CN109672573B (en) | Configuration file deployment method, configuration file determination method, server and storage medium | |
CN116028251A (en) | Method, device and equipment for reporting error log and readable storage medium | |
KR102519132B1 (en) | System and method for operating self-growing software based on microservice | |
CN108958827B (en) | Method and system for processing program upgrading fault | |
CN107861842B (en) | Metadata damage detection method, system, equipment and storage medium | |
CN110597668A (en) | Resident job processing method and system | |
CN111090586B (en) | Method and device for reporting code coverage rate data file and computer equipment | |
CN110569120B (en) | Processing method and device for timing task | |
CN109542344B (en) | Method and device for cleaning disk space, storage medium and terminal | |
CN113687929B (en) | Exception handling method and related device | |
CN116048656A (en) | Method, device and medium for deploying system components |
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 |