CN113760658A - Monitoring method, device and equipment - Google Patents

Monitoring method, device and equipment Download PDF

Info

Publication number
CN113760658A
CN113760658A CN202111027223.3A CN202111027223A CN113760658A CN 113760658 A CN113760658 A CN 113760658A CN 202111027223 A CN202111027223 A CN 202111027223A CN 113760658 A CN113760658 A CN 113760658A
Authority
CN
China
Prior art keywords
log file
request information
request
information
abnormal
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
CN202111027223.3A
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.)
Shandong Paimeng Network Technology Co ltd
Original Assignee
Shandong Paimeng Network Technology 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 Shandong Paimeng Network Technology Co ltd filed Critical Shandong Paimeng Network Technology Co ltd
Priority to CN202111027223.3A priority Critical patent/CN113760658A/en
Publication of CN113760658A publication Critical patent/CN113760658A/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/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/3024Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is a central processing unit [CPU]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/3037Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is a memory, e.g. virtual memory, cache
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3055Monitoring arrangements for monitoring the status of the computing system or of the computing system component, e.g. monitoring if the computing system is on, off, available, not available
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3065Monitoring arrangements determined by the means or processing involved in reporting the monitored data
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3089Monitoring arrangements determined by the means or processing involved in sensing the monitored data, e.g. interfaces, connectors, sensors, probes, agents
    • G06F11/3093Configuration details thereof, e.g. installation, enabling, spatial arrangement of the probes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2201/00Indexing scheme relating to error detection, to error correction, and to monitoring
    • G06F2201/80Database-specific techniques

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • Quality & Reliability (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Mathematical Physics (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The embodiment of the specification discloses a monitoring method, a monitoring device and monitoring equipment. The method comprises the following steps: acquiring request information of a client, wherein the request information is an http request; obtaining a log file based on the request information, the log file comprising: the request of the request information is time-consuming, and/or the use condition of a CPU, and/or abnormal information when the request information is executed; analyzing the log file, and storing the analyzed log file into a database; and accessing the database through a service interface to obtain performance monitoring data. By adopting the monitoring method provided by the embodiment of the specification, the comprehensive monitoring of the server can be realized, the problem of the server can be quickly positioned, and the efficiency of solving the service problem is improved.

Description

Monitoring method, device and equipment
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a monitoring method, a monitoring device, and a monitoring apparatus
Background
Js is a JavaScript running environment based on Chrome V8 engine. Js uses an event-driven, non-blocking I/O model, making it lightweight and efficient. With the high-speed development of the internet, the transmission speed is faster and faster, the response speed of the interface is more and more important, and the back-end personnel pay more and more attention to the performance problem of the service.
At present, the monitoring of a node.js server often uses pm2(Process Manager 2) or egg and other services and frames with daemon processes, and can only monitor the subprocesses, but cannot combine and submit the memory occupation information of all the subprocesses. Moreover, the problem of the server cannot be locally reproduced in many cases, and cannot monitor the processing speed of the program and the problem of memory leakage caused by the program, so that the node.
Based on this, a new monitoring method is needed, which can realize the comprehensive monitoring of the node.
Disclosure of Invention
The embodiment of the specification provides a monitoring method, a monitoring device and monitoring equipment, which are used for solving the following technical problems: the existing node.js monitoring method can only monitor the subprocess and can not combine the memory occupation information of all the subprocesses and submit the information. Moreover, the problem of the server cannot be locally reproduced in many cases, and cannot monitor the processing speed of the program and the problem of memory leakage caused by the program, so that the node.
In order to solve the above technical problem, the embodiments of the present specification are implemented as follows:
the monitoring method provided by the embodiment of the specification is applied to a server side, and the method comprises the following steps:
acquiring request information of a client, wherein the request information is an http request;
obtaining a log file based on the request information, the log file comprising: the request of the request information is time-consuming, and/or the use condition of a CPU, and/or abnormal information when the request information is executed;
analyzing the log file, and storing the analyzed log file into a database;
and accessing the database through a service interface to obtain performance monitoring data.
Further, the obtaining a log file based on the request information specifically includes:
and calculating the time consumption of the request information based on the monitoring middleware to obtain the log file.
Further, the obtaining a log file based on the request information specifically includes:
and acquiring the service condition of the CPU when the request information is executed by adopting a point burying mode to obtain a log file.
Further, the acquiring, in a point-embedded manner, a usage of the CPU when executing the request information, and acquiring the log file specifically includes:
and acquiring the utilization rate of the CUP and the utilization rate of the memory when the request information is executed by adopting a point burying mode, and acquiring a log file.
Further, the obtaining a log file based on the request information specifically includes:
acquiring abnormal information when the request information is executed based on a predefined global abnormal monitoring middleware;
and storing the abnormal information into a log file.
Further, the content of the exception information includes: request address, request parameters, execution stack, exception type.
Further, the analyzing the log file and storing the analyzed log file into a database specifically includes:
and analyzing the log file at regular time, and storing the analyzed log file into a MySQL database.
Further, the method further comprises:
when the global abnormal monitoring middleware monitors abnormal information, abnormal information pushing is triggered;
the abnormal information pushing middleware pushes the abnormal information to a preset telephone number or an electronic mailbox in millisecond level by adopting a preset format in a message or mail mode.
The monitoring device provided by the embodiment of the present specification is applied to a server, and the device includes:
the request acquisition module is used for acquiring request information of a client, wherein the request information is an http request;
a log file obtaining module, configured to obtain a log file based on the request information, where the log file includes: the request of the request information is time-consuming, and/or the use condition of a CPU, and/or abnormal information when the request information is executed;
the analysis module is used for analyzing the log file and storing the analyzed log file into a database;
and the monitoring module accesses the database through a service interface to obtain performance monitoring data.
Further, the obtaining a log file based on the request information specifically includes:
and calculating the time consumption of the request information based on the monitoring middleware to obtain the log file.
Further, the obtaining a log file based on the request information specifically includes:
and acquiring the service condition of the CPU when the request information is executed by adopting a point burying mode, and acquiring a log file.
Further, the acquiring, in a point-embedded manner, a usage of the CPU when executing the request information, and acquiring the log file specifically includes:
and acquiring the utilization rate of the CUP and the utilization rate of the memory when the request information is executed by adopting a point burying mode, and acquiring a log file.
Further, the obtaining a log file based on the request information specifically includes:
acquiring abnormal information when the request information is executed based on a predefined global abnormal monitoring middleware;
and storing the abnormal information into a log file.
Further, the content of the exception information includes: request address, request parameters, execution stack, exception type.
Further, the analyzing the log file and storing the analyzed log file into a database specifically includes:
and analyzing the log file at regular time, and storing the analyzed log file into a MySQL database.
Further, the apparatus further comprises:
when the global abnormal monitoring middleware monitors abnormal information, abnormal information pushing is triggered;
the abnormal information pushing middleware pushes the abnormal information to a preset telephone number or an electronic mailbox in millisecond level by adopting a preset format in a message or mail mode.
An embodiment of the present specification further provides an electronic device, which is applied to a server and includes:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to:
acquiring request information of a client, wherein the request information is an http request;
obtaining a log file based on the request information, the log file comprising: the request of the request information is time-consuming, and/or the use condition of a CPU, and/or abnormal information when the request information is executed;
analyzing the log file, and storing the analyzed log file into a database;
and accessing the database through a service interface to obtain performance monitoring data.
Further, the obtaining a log file based on the request information specifically includes:
and calculating the time consumption of the request information based on the monitoring middleware to obtain the log file.
Further, the obtaining a log file based on the request information specifically includes:
and acquiring the service condition of the CPU when the request information is executed by adopting a point burying mode to obtain a log file.
Further, the acquiring, in a point-embedded manner, a usage of the CPU when executing the request information, and acquiring the log file specifically includes:
and acquiring the utilization rate of the CUP and the utilization rate of the memory when the request information is executed by adopting a point burying mode, and acquiring a log file.
Further, the obtaining a log file based on the request information specifically includes:
acquiring abnormal information when the request information is executed based on a predefined global abnormal monitoring middleware;
and storing the abnormal information into a log file.
Further, the content of the exception information includes: request address, request parameters, execution stack, exception type.
Further, the analyzing the log file and storing the analyzed log file into a database specifically includes:
and analyzing the log file at regular time, and storing the analyzed log file into a MySQL database.
Further, the method further comprises:
when the global abnormal monitoring middleware monitors abnormal information, abnormal information pushing is triggered;
the abnormal information pushing middleware pushes the abnormal information to a preset telephone number or an electronic mailbox in millisecond level by adopting a preset format in a message or mail mode.
The embodiment of the specification adopts at least one technical scheme which can achieve the following beneficial effects: the system can realize comprehensive monitoring of the server, realize quick positioning of the server problem and improve the efficiency of solving the service problem.
Drawings
In order to more clearly illustrate the embodiments of the present specification or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, it is obvious that the drawings in the following description are only some embodiments described in the present specification, and for those skilled in the art, other drawings can be obtained according to the drawings without any creative effort.
Fig. 1 is a schematic diagram of a monitoring method provided in an embodiment of the present disclosure;
fig. 2 is a schematic diagram of a monitoring device provided in an embodiment of the present disclosure.
Detailed Description
In order to make those skilled in the art better understand the technical solutions in the present specification, the technical solutions in the embodiments of the present specification will be clearly and completely described below with reference to the drawings in the embodiments of the present specification, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be obtained by a person skilled in the art without making any inventive step based on the embodiments of the present disclosure, shall fall within the scope of protection of the present application.
Fig. 1 is a schematic view of a monitoring method provided in an embodiment of the present specification, and as shown in fig. 1, the monitoring method provided in the embodiment of the present specification is applied to a server, and the method includes:
step S101: and acquiring request information of a client, wherein the request information is an http request.
In this embodiment of the present specification, the request information of the client is an http request, that is, a request message from the client to the server. Specifically, the request message includes, in the message head line, a request method for the resource, an identifier of the resource, and a protocol used.
It should be noted that the server in this specification is node.
Step S103: obtaining a log file based on the request information, the log file comprising: the request of the request information is time-consuming, and/or the use condition of a CPU, and/or abnormal information when the request information is executed.
In an embodiment of the present specification, the obtaining a log file based on the request information specifically includes:
and calculating the time consumption of the request information based on the monitoring middleware to obtain the log file.
Specifically, calculating the time consumption of the http request information by adopting a monitoring middleware; the obtained request is time consuming as a log file.
In a specific embodiment, the request elapsed time may be used as an index for performance monitoring, and if the request elapsed time exceeds a preset time, the request is considered to be abnormal.
In an embodiment of the present specification, the obtaining a log file based on the request information specifically includes:
and acquiring the service condition of the CPU when the request information is executed by adopting a point burying mode to obtain a log file.
In the embodiments of the present specification, the manner of embedding the point may be code embedding, or visualizing embedding, and the specific manner of embedding the point does not constitute a limitation of the present application.
In an embodiment of this specification, the obtaining, in a point-embedded manner, a log file according to a usage of the CPU when the request information is executed includes:
and acquiring the utilization rate of the CUP and the utilization rate of the memory when the request information is executed by adopting a point burying mode, and acquiring a log file.
Adopting a point burying mode to acquire the service condition of the CPU when the request information is executed, and performing data statistics to obtain statistical data after statistics; then, classifying the statistical data to obtain classified data; and storing the classification data into a log library as a log file for storage.
In an embodiment of this specification, the obtaining a log file based on the request information specifically includes:
acquiring abnormal information when the request information is executed based on a predefined global abnormal monitoring middleware;
and storing the abnormal information into a log file.
In a specific embodiment, the monitoring of the anomaly information includes: the number of rejected clients, the number of failed key lookups, and the time for a link between master stations to be broken. The rejected client number refers to the number of the clients rejected after the maximum connection number is exceeded; the number of failed key lookups refers to the number of failures in performing a query operation; the time when the link between the master stations is broken refers to the time when reconnection occurs. When the rejected client number exists, a warning reminder is sent out. When there is a failed key lookup, a warning alert is also issued. When the time of the link disconnection between the main stations exceeds 60s, an alarm prompt is sent out.
In an embodiment of the present specification, the content of the exception information includes: request address, request parameters, execution stack, exception type.
By adopting the pre-defined global anomaly monitoring middleware, the anomaly information can be found in time and positioned.
In an embodiment of the present specification, the method further comprises:
when the global abnormal monitoring middleware monitors abnormal information, abnormal information pushing is triggered;
the abnormal information pushing middleware pushes the abnormal information to a preset telephone number or an electronic mailbox in millisecond level by adopting a preset format in a message or mail mode.
In the embodiments of the present specification, the preset format includes the content, time, and the like of the exception information, and the content of the preset format does not constitute a limitation to the present application.
Step S105: and analyzing the log file, and storing the analyzed log file into a database.
In an embodiment of this specification, the parsing the log file, and storing the parsed log file in a database specifically includes:
and analyzing the log file at regular time, and storing the analyzed log file into a MySQL database.
Step S107: and accessing the database through a service interface to obtain performance monitoring data.
In the embodiment of the present specification, the database is accessed by accessing a service interface of the node.
By adopting the monitoring method provided by the embodiment of the specification, the comprehensive monitoring of the server can be realized, the problem of the server can be quickly positioned, and the efficiency of solving the service problem is improved.
The above details a monitoring method, and accordingly, the present specification also provides a monitoring device, as shown in fig. 2. Fig. 2 is a schematic diagram of a monitoring device provided in an embodiment of the present specification, where the monitoring device provided in the embodiment of the present specification is applied to a server, and the monitoring device includes:
a request obtaining module 201, configured to obtain request information of a client, where the request information is an http request;
a log file obtaining module 203, configured to obtain a log file based on the request information, where the log file includes: the request of the request information is time-consuming, and/or the use condition of a CPU, and/or abnormal information when the request information is executed;
the analysis module 205 is used for analyzing the log file, and storing the analyzed log file into a database;
and the monitoring module 207 accesses the database through a service interface to obtain performance monitoring data.
Further, the obtaining a log file based on the request information specifically includes:
and calculating the time consumption of the request information based on the monitoring middleware to obtain the log file.
Further, the obtaining a log file based on the request information specifically includes:
and acquiring the service condition of the CPU when the request information is executed by adopting a point burying mode to obtain a log file.
Further, the acquiring, in a point-embedded manner, a usage of the CPU when executing the request information, and acquiring the log file specifically includes:
and acquiring the utilization rate of the CUP and the utilization rate of the memory when the request information is executed by adopting a point burying mode, and acquiring a log file.
Further, the obtaining a log file based on the request information specifically includes:
acquiring abnormal information when the request information is executed based on a predefined global abnormal monitoring middleware;
and storing the abnormal information into a log file.
Further, the content of the exception information includes: request address, request parameters, execution stack, exception type.
Further, the analyzing the log file and storing the analyzed log file into a database specifically includes:
and analyzing the log file at regular time, and storing the analyzed log file into a MySQL database.
Further, the apparatus further comprises:
when the global abnormal monitoring middleware monitors abnormal information, abnormal information pushing is triggered;
the abnormal information pushing middleware pushes the abnormal information to a preset telephone number or an electronic mailbox in millisecond level by adopting a preset format in a message or mail mode.
An embodiment of the present specification further provides an electronic device, which is applied to a server and includes:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to:
acquiring request information of a client, wherein the request information is an http request;
obtaining a log file based on the request information, the log file comprising: the request of the request information is time-consuming, and/or the use condition of a CPU, and/or abnormal information when the request information is executed;
analyzing the log file, and storing the analyzed log file into a database;
and accessing the database through a service interface to obtain performance monitoring data.
Further, the obtaining a log file based on the request information specifically includes:
and calculating the time consumption of the request information based on the monitoring middleware to obtain the log file.
Further, the obtaining a log file based on the request information specifically includes:
and acquiring the service condition of the CPU when the request information is executed by adopting a point burying mode, and acquiring a log file.
Further, the acquiring, in a point-embedded manner, a usage of the CPU when executing the request information, and acquiring the log file specifically includes:
and acquiring the utilization rate of the CUP and the utilization rate of the memory when the request information is executed by adopting a point burying mode, and acquiring a log file.
Further, the obtaining a log file based on the request information specifically includes:
acquiring abnormal information when the request information is executed based on a predefined global abnormal monitoring middleware;
and storing the abnormal information into a log file.
Further, the content of the exception information includes: request address, request parameters, execution stack, exception type.
Further, the analyzing the log file and storing the analyzed log file into a database specifically includes:
and analyzing the log file at regular time, and storing the analyzed log file into a MySQL database.
Further, the method further comprises:
when the global abnormal monitoring middleware monitors abnormal information, abnormal information pushing is triggered;
the abnormal information pushing middleware pushes the abnormal information to a preset telephone number or an electronic mailbox in millisecond level by adopting a preset format in a message or mail mode.
The foregoing description has been directed to specific embodiments of this disclosure. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
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 embodiments of the apparatus, the electronic device, and the nonvolatile computer storage medium, since they are substantially similar to the embodiments of the method, the description is simple, and the relevant points can be referred to the partial description of the embodiments of the method.
The apparatus, the electronic device, the nonvolatile computer storage medium and the method provided in the embodiments of the present description correspond to each other, and therefore, the apparatus, the electronic device, and the nonvolatile computer storage medium also have similar advantageous technical effects to the corresponding method.
In the 90 s of the 20 th century, improvements in a technology could clearly distinguish between improvements in hardware (e.g., improvements in circuit structures such as diodes, transistors, switches, etc.) and improvements in software (improvements in process flow). However, as technology advances, many of today's process flow improvements have been seen as direct improvements in hardware circuit architecture. Designers almost always obtain the corresponding hardware circuit structure by programming an improved method flow into the hardware circuit. Thus, it cannot be said that an improvement in the process flow cannot be realized by hardware physical modules. For example, a Programmable Logic Device (PLD), such as a Field Programmable Gate Array (FPGA), is an integrated circuit whose Logic functions are determined by programming the Device by a user. A digital system is "integrated" on a PLD by the designer's own programming without requiring the chip manufacturer to design and fabricate application-specific integrated circuit chips. Furthermore, nowadays, instead of manually making an Integrated Circuit chip, such Programming is often implemented by "logic compiler" software, which is similar to a software compiler used in program development and writing, but the original code before compiling is also written by a specific Programming Language, which is called Hardware Description Language (HDL), and HDL is not only one but many, such as abel (advanced Boolean Expression Language), ahdl (alternate Hardware Description Language), traffic, pl (core universal Programming Language), HDCal (jhdware Description Language), lang, Lola, HDL, laspam, hardward Description Language (vhr Description Language), vhal (Hardware Description Language), and vhigh-Language, which are currently used in most common. It will also be apparent to those skilled in the art that hardware circuitry that implements the logical method flows can be readily obtained by merely slightly programming the method flows into an integrated circuit using the hardware description languages described above.
The controller may be implemented in any suitable manner, for example, the controller may take the form of, for example, a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro) processor, logic gates, switches, an Application Specific Integrated Circuit (ASIC), a programmable logic controller, and an embedded microcontroller, examples of which include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320, the memory controller may also be implemented as part of the control logic for the memory. Those skilled in the art will also appreciate that, in addition to implementing the controller as pure computer readable program code, the same functionality can be implemented by logically programming method steps such that the controller is in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers and the like. Such a controller may thus be considered a hardware component, and the means included therein for performing the various functions may also be considered as a structure within the hardware component. Or even means for performing the functions may be regarded as being both a software module for performing the method and a structure within a hardware component.
The systems, devices, modules or units illustrated in the above embodiments may be implemented by a computer chip or an entity, or by a product with certain functions. One typical implementation device is a computer. In particular, the computer may be, for example, a personal computer, a laptop computer, a cellular telephone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
For convenience of description, the above devices are described as being divided into various units by function, and are described separately. Of course, the functionality of the various elements may be implemented in the same one or more software and/or hardware implementations in implementing one or more embodiments of the present description.
As will be appreciated by one skilled in the art, the present specification embodiments may be provided as a method, system, or computer program product. Accordingly, embodiments of the present description may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, embodiments of the present description may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and so forth) having computer-usable program code embodied therein.
The description has been presented with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the description. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data optimization apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data optimization apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data optimization apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data optimization apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
This description may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. The specification may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
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 system embodiment, since it is substantially similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
The above description is only an example of the present specification, and is not intended to limit the present application. Various modifications and changes may occur to those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.

Claims (10)

1. A monitoring method is applied to a server side, and is characterized in that the method comprises the following steps:
acquiring request information of a client, wherein the request information is an http request;
obtaining a log file based on the request information, the log file comprising: the request of the request information is time-consuming, and/or the use condition of a CPU, and/or abnormal information when the request information is executed;
analyzing the log file, and storing the analyzed log file into a database;
and accessing the database through a service interface to obtain performance monitoring data.
2. The method of claim 1, wherein obtaining the log file based on the request information specifically comprises:
and calculating the time consumption of the request information based on the monitoring middleware to obtain the log file.
3. The method of claim 1, wherein obtaining the log file based on the request information specifically comprises:
and acquiring the service condition of the CPU when the request information is executed by adopting a point burying mode to obtain a log file.
4. The method according to claim 3, wherein the obtaining, in a point-embedded manner, a log file based on the usage of the CPU when the request information is executed includes:
and acquiring the utilization rate of the CUP and the utilization rate of the memory when the request information is executed by adopting a point burying mode, and acquiring a log file.
5. The method of claim 1, wherein obtaining the log file based on the request information specifically comprises:
acquiring abnormal information when the request information is executed based on a predefined global abnormal monitoring middleware;
and storing the abnormal information into a log file.
6. The method of claim 5, wherein the content of the exception information comprises: request address, request parameters, execution stack, exception type.
7. The method of claim 1, wherein parsing the log file and storing the parsed log file in a database comprises:
and analyzing the log file at regular time, and storing the analyzed log file into a MySQL database.
8. The method of claim 5, wherein the method further comprises:
when the global abnormal monitoring middleware monitors abnormal information, abnormal information pushing is triggered;
the abnormal information pushing middleware pushes the abnormal information to a preset telephone number or an electronic mailbox in millisecond level by adopting a preset format in a message or mail mode.
9. A monitoring device applied to a server side is characterized by comprising:
the request acquisition module is used for acquiring request information of a client, wherein the request information is an http request;
a log file obtaining module, configured to obtain a log file based on the request information, where the log file includes: the request of the request information is time-consuming, and/or the use condition of a CPU, and/or abnormal information when the request information is executed;
the analysis module is used for analyzing the log file and storing the analyzed log file into a database;
and the monitoring module accesses the database through a service interface to obtain performance monitoring data.
10. An electronic device applied to a server comprises:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to:
acquiring request information of a client, wherein the request information is an http request;
obtaining a log file based on the request information, the log file comprising: the request of the request information is time-consuming, and/or the use condition of a CPU, and/or abnormal information when the request information is executed;
analyzing the log file, and storing the analyzed log file into a database;
and accessing the database through a service interface to obtain performance monitoring data.
CN202111027223.3A 2021-09-02 2021-09-02 Monitoring method, device and equipment Pending CN113760658A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111027223.3A CN113760658A (en) 2021-09-02 2021-09-02 Monitoring method, device and equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111027223.3A CN113760658A (en) 2021-09-02 2021-09-02 Monitoring method, device and equipment

Publications (1)

Publication Number Publication Date
CN113760658A true CN113760658A (en) 2021-12-07

Family

ID=78792694

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111027223.3A Pending CN113760658A (en) 2021-09-02 2021-09-02 Monitoring method, device and equipment

Country Status (1)

Country Link
CN (1) CN113760658A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116582406A (en) * 2023-07-13 2023-08-11 支付宝(杭州)信息技术有限公司 Method and device for uploading monitoring data
CN117591381A (en) * 2024-01-18 2024-02-23 南京研利科技有限公司 Data reporting method and device

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107423194A (en) * 2017-06-30 2017-12-01 阿里巴巴集团控股有限公司 Front end abnormality alarming processing method, apparatus and system
CN109960621A (en) * 2017-12-22 2019-07-02 南京欣网互联网络科技有限公司 A kind of data pick-up method based on big data visual control platform
CN110377588A (en) * 2019-07-23 2019-10-25 中国工商银行股份有限公司 A kind of database object access monitoring method, server and terminal
CN110795322A (en) * 2019-10-28 2020-02-14 深圳前海环融联易信息科技服务有限公司 Service monitoring method and device, computer equipment and storage medium
CN111143828A (en) * 2019-12-11 2020-05-12 中盈优创资讯科技有限公司 Safety control method and device for Web page and service

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107423194A (en) * 2017-06-30 2017-12-01 阿里巴巴集团控股有限公司 Front end abnormality alarming processing method, apparatus and system
CN109960621A (en) * 2017-12-22 2019-07-02 南京欣网互联网络科技有限公司 A kind of data pick-up method based on big data visual control platform
CN110377588A (en) * 2019-07-23 2019-10-25 中国工商银行股份有限公司 A kind of database object access monitoring method, server and terminal
CN110795322A (en) * 2019-10-28 2020-02-14 深圳前海环融联易信息科技服务有限公司 Service monitoring method and device, computer equipment and storage medium
CN111143828A (en) * 2019-12-11 2020-05-12 中盈优创资讯科技有限公司 Safety control method and device for Web page and service

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
维克托•法西克: "《互联网信息监测***研究》", pages: 345 - 348 *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116582406A (en) * 2023-07-13 2023-08-11 支付宝(杭州)信息技术有限公司 Method and device for uploading monitoring data
CN116582406B (en) * 2023-07-13 2023-09-26 支付宝(杭州)信息技术有限公司 Method and device for uploading monitoring data
CN117591381A (en) * 2024-01-18 2024-02-23 南京研利科技有限公司 Data reporting method and device
CN117591381B (en) * 2024-01-18 2024-04-09 南京研利科技有限公司 Data reporting method and device

Similar Documents

Publication Publication Date Title
CN107066519B (en) Task detection method and device
CN108243032B (en) Method, device and equipment for acquiring service level information
CN107491371B (en) Deployment monitoring method and device
CN113760658A (en) Monitoring method, device and equipment
CN111090502B (en) Stream data task scheduling method and device
CN110635962A (en) Abnormity analysis method and device for distributed system
CN113596078A (en) Service problem positioning method and device
CN111639011A (en) Data monitoring method, device and equipment
CN111753328B (en) Private data leakage risk detection method and system
CN113590285A (en) Method, system and equipment for dynamically setting thread pool parameters
CN112559565A (en) Abnormity detection method, system and device
CN110825943B (en) Method, system and equipment for generating user access path tree data
CN112416974A (en) Data processing method, device and equipment and readable storage medium
CN113742036A (en) Index processing method and device and electronic equipment
CN110968483A (en) Service data acquisition method and device and electronic equipment
CN111078435A (en) Service processing method and device and electronic equipment
CN109039695B (en) Service fault processing method, device and equipment
CN113672660B (en) Data query method, device and equipment
US10496467B1 (en) Monitoring software computations of arbitrary length and duration
CN111967769B (en) Risk identification method, apparatus, device and medium
CN110245136B (en) Data retrieval method, device, equipment and storage equipment
CN111967767A (en) Business risk identification method, device, equipment and medium
CN111796864A (en) Data verification method and device
CN107341084B (en) Data processing method and device
CN110908792A (en) Data processing method and device

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