Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Method and device for determining abnormal thread, computer equipment and storage medium

A thread and exception technology, applied in the field of R&D process optimization, can solve problems such as affecting system stability, unable to automatically and efficiently determine abnormal threads, etc., to relieve thread memory pressure, improve health, and ensure feasibility.

Pending Publication Date: 2022-02-01
PING AN PENSION INSURANCE
View PDF0 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0002] In the process of running the Java application, it is necessary to use the empty thread in the thread pool to create an instantiation thread for the program code in the Java application, so as to execute the program code through the instantiation thread, thereby realizing the function function of the program code; Usually, only one instantiation thread is created for the program code with the same function in the thread pool, but in actual applications, there are multiple instantiation threads for realizing the same function.
Due to the limited number of available threads (that is, empty threads) in the thread pool, if the above phenomenon occurs, it will lead to the problem that there are no available threads in the thread pool during the execution of the subsequent program code, and then the thread cannot be instantiated, resulting in Java applications fail to run, affecting system stability
[0003] In the prior art, when there is no available thread in the thread pool during the running of the Java application, technicians need to manually check to find out the abnormal thread, which is very inefficient; therefore, in the prior art, there is no Automatically and efficiently determine the technical problems of abnormal threads

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and device for determining abnormal thread, computer equipment and storage medium
  • Method and device for determining abnormal thread, computer equipment and storage medium
  • Method and device for determining abnormal thread, computer equipment and storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0047] Embodiments of the present invention provide a method for determining an abnormal thread, such as figure 1 As shown, the method specifically includes the following steps:

[0048] Step S101: Obtain log information generated during running of the target Java application, and determine whether there is thread exhaustion error message in the log information.

[0049] Wherein, the thread exhaustion error message is in the form of: "java.lang.OutOfMemoryError: unable to create new native thread".

[0050]In this embodiment, when a Java application is running in the Java Development Kit JDK, a Java application log will be generated, and it is necessary to actively and regularly obtain the Java application log of the Java application from the JDK according to a set time interval. Judging whether there is a thread exhaustion error message in the form of "java.lang.OutOfMemoryError: unable to create new native thread" in the Java application log, when the thread exhaustion erro...

Embodiment 2

[0109] Based on the method for determining an abnormal thread provided in the first embodiment above, this embodiment provides an apparatus for determining an abnormal thread, specifically, figure 2 An optional structural block diagram of the device for determining an abnormal thread is shown, the device for determining an abnormal thread is divided into one or more program modules, one or more program modules are stored in a storage medium, and are composed of one or more processors to complete the present invention. The program module referred to in the present invention refers to a series of computer program instruction segments capable of completing specific functions, which is more suitable than the program itself to describe the execution process of the device for determining the abnormal thread in the storage medium. The following description will specifically introduce the programs of this embodiment function of the module.

[0110] Such as figure 2 As shown, the d...

Embodiment 3

[0129] This embodiment also provides a computer device, such as a smart phone, a tablet computer, a notebook computer, a desktop computer, a rack server, a blade server, a tower server, or a cabinet server (including an independent server, or A server cluster composed of multiple servers), etc. Such as image 3 As shown, the computer device 30 in this embodiment at least includes but is not limited to: a memory 301 and a processor 302 that can be communicated with each other through a system bus. It should be pointed out that, image 3 Only computer device 30 is shown having components 301-302, but it should be understood that implementing all of the illustrated components is not a requirement and that more or fewer components may instead be implemented.

[0130] In this embodiment, the memory 301 (that is, a readable storage medium) includes a flash memory, a hard disk, a multimedia card, a card-type memory (for example, SD or DX memory, etc.), random access memory (RAM), s...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a method and device for determining an abnormal thread, computer equipment and a storage medium, and the method comprises the steps: obtaining log information generated in a running process of a target Java application, and judging whether thread depletion error reporting information exists in the log information or not; under the condition that the thread depletion error reporting information exists, obtaining a thread file generated in the running process of the target Java application, wherein the thread file comprises a thread name of an instantiated thread; forming a thread pair by any two thread names in the thread file, and calculating a similarity value of the two thread names in each thread pair; determining two target instantiated threads corresponding to two thread names in the thread pair with the maximum similarity value as an abnormal thread pair, and sending alarm information added with the abnormal thread pair to a specified terminal; according to the method and the device, the abnormal thread can be automatically, efficiently and accurately determined.

Description

technical field [0001] The invention relates to the technical field of research and development process optimization, in particular to a method, device, computer equipment and storage medium for determining abnormal threads. Background technique [0002] In the process of running the Java application, it is necessary to use the empty thread in the thread pool to create an instantiation thread for the program code in the Java application, so as to execute the program code through the instantiation thread, thereby realizing the function function of the program code; Usually, only one instantiation thread is created for program codes with the same function in the thread pool, but in actual applications, multiple instantiation threads for realizing the same function may be created. Due to the limited number of available threads (that is, empty threads) in the thread pool, if the above phenomenon occurs, it will lead to the problem that there are no available threads in the threa...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
IPC IPC(8): G06F9/50
CPCG06F9/5016G06F9/5022G06F9/5033G06F9/5038G06F2209/5011
Inventor 蒋树新
Owner PING AN PENSION INSURANCE
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products