CN113672470A - Interface monitoring method, device, equipment and medium - Google Patents

Interface monitoring method, device, equipment and medium Download PDF

Info

Publication number
CN113672470A
CN113672470A CN202110990680.6A CN202110990680A CN113672470A CN 113672470 A CN113672470 A CN 113672470A CN 202110990680 A CN202110990680 A CN 202110990680A CN 113672470 A CN113672470 A CN 113672470A
Authority
CN
China
Prior art keywords
interface
monitoring component
data
interface monitoring
component
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
CN202110990680.6A
Other languages
Chinese (zh)
Inventor
黄冲
王波
蒋品
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Cloud Computing Beijing Co Ltd
Original Assignee
Beijing Guangqiyuan Digital 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 Beijing Guangqiyuan Digital Technology Co ltd filed Critical Beijing Guangqiyuan Digital Technology Co ltd
Priority to CN202110990680.6A priority Critical patent/CN113672470A/en
Publication of CN113672470A publication Critical patent/CN113672470A/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/302Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is a software system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • G06F11/3409Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment for performance assessment
    • G06F11/3433Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment for performance assessment for load management

Abstract

The embodiment of the specification discloses an interface monitoring method, an interface monitoring device, equipment and a medium, wherein the interface monitoring method comprises the following steps: acquiring an interface monitoring component, and uploading the interface monitoring component to a server; after the interface monitoring component is downloaded from the server and accessed by the interface, the accessed interface monitoring component is embedded in a closure function of the interface so as to monitor the operation data of the interface; and generating an interface operation report according to the operation data.

Description

Interface monitoring method, device, equipment and medium
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method, an apparatus, a device, and a medium for monitoring an interface.
Background
In the prior art, various operation data of the interface during operation need to be monitored, for example, the size of the memory occupied by the interface and the number of the allocated threads, and data of Meters, gates, Counters, Histograms, Timers and the like of the interface. Currently, in order to monitor the above operation data, a large amount of Meters codes need to be written in front of the business logic codes of each interface, and the Meters codes are combined in a Controller of each service. The interface monitoring scheme has high coupling degree (of the code and the interface) on the architecture, the code amount needing to be written is large, and the code positioning is difficult. When the interface parameters change, the code for monitoring of each interface needs to be modified or maintained independently, so that the code modification or maintenance difficulty is improved.
In view of the above, a more efficient interface monitoring scheme is needed.
Disclosure of Invention
Embodiments of the present specification provide an interface monitoring method, apparatus, device, and medium, so as to solve a technical problem of how to perform interface monitoring more efficiently.
In order to solve the above technical problem, the embodiments of the present specification provide the following technical solutions:
an embodiment of the present specification provides an interface monitoring method, including:
acquiring an interface monitoring component, and uploading the interface monitoring component to a server;
after the interface monitoring component is downloaded from the server and accessed by the interface, the accessed interface monitoring component is embedded in a closure function of the interface so as to monitor the operation data of the interface;
and generating an interface operation report according to the operation data.
Optionally, the interface monitoring component is packaged with Metrics class.
Optionally, the interface accessing the interface monitoring component includes:
and configuring a downloading address in a maven setting file of the interface so that the interface can access the downloaded interface monitoring component after downloading the interface monitoring component through the downloading address.
Optionally, the interface monitoring component has a component template; the interface monitoring component embedded point accessed comprises the following steps in the closure function of the interface:
and using the component template in the service layer of the interface, and transmitting the name and/or URL address and/or key value of the interface into a closure function of the component template.
Optionally, monitoring the operation data of the interface includes:
the operational data of the interface is monitored by Metrics.
Optionally, the operation data includes one or more of occupied memory data, thread allocation data, Meters data, Gauges data, Counters data, Histograms data, and Timers data.
Optionally, after generating an interface operation report according to the operation data, the method further includes:
and transmitting the running report to an Influxdb system and a Grafana system for displaying.
An embodiment of the present specification provides an interface monitoring apparatus, including:
the building module is used for acquiring the interface monitoring component and uploading the interface monitoring component to the server;
the monitoring module is used for embedding the accessed interface monitoring component in a closure function of the interface to monitor the operation data of the interface after the interface monitoring component is downloaded from the server and accessed by the interface;
and the report module is used for generating an interface operation report according to the operation data.
An embodiment of the present specification provides an interface monitoring device, including:
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 perform the interface monitoring method described above.
The present specification provides a computer-readable storage medium, which stores computer-executable instructions, and when the computer-executable instructions are executed by a processor, the method for monitoring an interface is implemented.
The embodiment of the specification adopts at least one technical scheme which can achieve the following beneficial effects:
the method comprises the steps that a public and sharable interface monitoring component is built, each interface can realize the monitoring of interface operation data by referring to the interface monitoring component, monitoring codes do not need to be independently written for each interface, therefore, the code realization difficulty of interface monitoring is reduced, and the interface monitoring efficiency is improved.
Drawings
In order to more clearly illustrate the embodiments of the present specification or the technical solutions in the prior art, the drawings used in the description of the embodiments of the present specification or the prior art will be briefly described below. It should be apparent that the drawings described below are only some of the drawings to which the embodiments described in the present specification may relate, and that other drawings may be derived from those drawings by those of ordinary skill in the art without inventive effort.
Fig. 1 is a schematic diagram of an execution main body of an interface monitoring method in a first embodiment of this specification.
Fig. 2 is a schematic flow chart of an interface monitoring method in the first embodiment of the present specification.
Fig. 3 is a schematic structural diagram of an interface monitoring device in a second 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 of the embodiments of the present specification. It is to be understood that the embodiments described herein are only some embodiments of the application and not all 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.
In the prior art, various operation data of the interface during operation need to be monitored, for example, the size of the memory occupied by the interface and the number of the allocated threads, and data of Meters, gates, Counters, Histograms, Timers and the like of the interface. At present, for any interface, in order to monitor the above-mentioned operation data of the interface, a large number of Meters codes need to be written before the business logic code of the interface, and the Meters codes are combined in the Controller of the service corresponding to the interface. The interface monitoring scheme has high coupling degree (of the code and the interface) on the architecture, the code amount needing to be written is large, and the code positioning is difficult. When the interface parameters change, the code for monitoring of each interface needs to be modified or maintained independently, so that the code modification or maintenance difficulty is improved. In summary, the monitoring efficiency of the current interface monitoring scheme is low.
A first embodiment (hereinafter referred to as "embodiment one") of this specification provides an interface monitoring method, and an execution main body of the embodiment one may be a terminal (including but not limited to a mobile phone, a computer, a pad, a television), or a server, or an operating system, or an application program, or an interface monitoring platform, or an interface monitoring system, and the like, that is, the execution main body may be various and may be set, used, or changed as needed. In addition, a third party application may assist the execution principal in executing embodiment one. For example, as shown in fig. 1, the interface monitoring method in the first embodiment may be performed by a server, and an application program (corresponding to the server) may be installed on a terminal (held by a user), and data transmission may be performed between the terminal or the application program and the server, and data collection or input or output or page or information processing may be performed by the terminal or the application program, so as to assist the server in performing the interface monitoring method in the first embodiment.
As shown in fig. 2, an interface monitoring method according to an embodiment includes:
s101: an execution main body acquires an interface monitoring component and uploads the interface monitoring component to a server;
the execution subject of embodiment one may obtain the interface monitoring component. The interface monitoring component may be constructed by the execution subject of the first embodiment, so that the execution subject of the first embodiment may obtain the interface monitoring component; alternatively, the interface monitoring component may be constructed by using another subject other than the execution subject of embodiment one, and the execution subject of embodiment one may obtain the interface monitoring component from the other subject.
In the first embodiment, the interface monitoring component may be constructed by newly building a module project by Idea and compiling a jar package. Specifically, constructing the interface monitoring component may include: encapsulation classes, such as tomcat Metrics, JVMMetrics, Metrics, etc., can be encapsulated, that is, the interface monitoring component is encapsulated with Metrics classes (or Metrics frames); defining a MetricsReporter which is an interface and annotated by an SPI (Serial peripheral interface); and then packaging the data into jar packets which can be accessed by the back-end engineering integration, wherein the jar packets are the interface monitoring components.
After the execution main body obtains the interface monitoring component, the interface monitoring component can be uploaded to a server, so that all parties can conveniently and directly download the interface monitoring component from the server, and the transmission efficiency of the interface monitoring component is improved. Specifically, the jar package (i.e., the interface monitoring component) may be uploaded to a nexus maven repository, so that a project (i.e., a project to be accessed by the interface monitoring component, the project including an interface, the interface being accessed after the project is deployed) may be configured in a pom file, so as to share and reference the jar package (i.e., the interface monitoring component) in the nexus maven repository.
S103: when the interface monitoring component is downloaded from the server and accessed by an interface, the accessed interface monitoring component is embedded in a closure function of the interface so as to monitor the operation data of the interface;
in one embodiment, the interface monitoring component may be downloaded and accessed by an interface (typically a backend interface). Wherein, the interface accessing the interface monitoring component may include:
1.1, configuring a download address (of the interface monitoring component) in a maven setting file of an interface (specifically, the download address of the image of the interface monitoring component of the nexus maven warehouse may be configured in the maven setting file of the interface), so that the interface downloads the interface monitoring component through the download address (from a server).
1.2, after the interface downloads the interface monitoring component (determined by the execution main body of the first embodiment), the interface is accessed to the downloaded interface monitoring component (determined by the execution main body of the first embodiment), and the interface and the downloaded interface monitoring component are packaged in a unified manner.
In particular, the interface monitoring component to be accessed (i.e., the downloaded interface monitoring component) is embedded in the closure function of the interface (the execution agent of embodiment one).
In an embodiment, after the interface monitoring component is constructed by Java closure encapsulation, the interface monitoring component has a component template, that is, the interface monitoring component provides a component template (template). The interface accessing the interface monitoring component may further include: and using the component template (of the downloaded interface monitoring component) at the service layer of the interface, so as to transmit the name and/or URL address and/or key value of the interface into a 'closure function of the component template used by the service layer of the interface', so that the interface and the downloaded interface monitoring component are uniformly packaged, and the interface references the interface monitoring component.
Additionally, the interface may be accessed to the interface monitoring component prior to the interface accessing an infrastructure library of various types of services or applications (infrastructure libraries including, but not limited to, database clusters, message middleware clusters, Redis cache clusters, etc.).
S105: and generating an interface operation report according to the operation data by the (execution main body).
Through the above content, the interface is accessed to the interface monitoring component, the interface and the downloaded interface monitoring component are packaged in a unified way, and the accessed interface monitoring component is embedded in a closure function of the interface, so that the interface monitoring can monitor the operation data of the interface.
Since the interface monitoring component is packaged with Metrics, after the interface and the downloaded interface monitoring component are packaged in a unified manner, the interface monitoring component can monitor the operation data of the interface through Metrics technology. The operation data includes, but is not limited to, one or more of (interface) occupied memory data, (interface) thread allocation data, (interface) Meters data, (interface) gates data, (interface) Counters data, (interface) Histograms data, and (interface) Timers data.
For example, the interface monitoring component may monitor the memory size or how many threads are allocated by an interface (e.g., Java API) running on the Tomcat container and Java virtual machine Jvm, as well as monitor Meters data, Gauges data, Counters data, Histograms data, or Timers data of the interface via Metrics technology. The Meters data, the Gauges data, the Counters data, the histories data, or the Timers data are all existing concepts.
The execution subject of the first embodiment may generate an interface operation report according to the operation data of the interface monitored by the interface monitoring component. Specifically, a spi folder may be defined in a META-INF folder in the resources directory of the project, an interface implementation class to be loaded is defined under the spi folder, and then various operation reports, such as http scheduled metrocs report, adaptive report, and the like, are generated by an spi mechanism.
The execution subject of the first embodiment may display the interface running report, and may also transmit (through the interface monitoring component) the running report to the infilxdb and Grafana systems (infilxdb + Grafana systems) for display.
In the first embodiment, a common and sharable interface monitoring component is constructed, each interface can download the interface monitoring component through a server, and each interface can quote or access the interface monitoring component, so that for any interface, the operation monitoring of the interface can be realized by accessing the interface monitoring component, and monitoring codes do not need to be written separately for each interface or service system. When the interface parameters change or the interface monitoring mode needs to be changed, only the interface monitoring component needs to be modified, and each interface is accessed to the modified interface monitoring component. By the first embodiment, the code implementation difficulty (including code writing and maintenance difficulty) of the interface monitoring can be reduced, the coupling degree of the interface monitoring and the interface on the architecture is reduced, and the interface monitoring efficiency is improved.
As shown in fig. 3, a second embodiment of the present disclosure provides an interface monitoring apparatus corresponding to the method of the first embodiment, including:
a construction module 202, configured to obtain an interface monitoring component, and upload the interface monitoring component to a server;
a monitoring module 204, configured to, after the interface monitoring component is downloaded from the server and accessed by an interface, embed the accessed interface monitoring component in a closure function of the interface, so as to monitor operation data of the interface;
and a report module 206, configured to generate an interface operation report according to the operation data.
Optionally, the interface monitoring component is packaged with Metrics class.
Optionally, the apparatus further comprises:
and the access module is used for enabling the interface to be accessed into the interface monitoring component.
Optionally, the interface accessing the interface monitoring component includes:
and configuring a downloading address in a maven setting file of the interface so that the interface can access the downloaded interface monitoring component after downloading the interface monitoring component through the downloading address.
Optionally, the interface monitoring component has a component template; the interface monitoring component embedded point accessed comprises the following steps in the closure function of the interface:
and using the component template in the service layer of the interface, and transmitting the name and/or URL address and/or key value of the interface into a closure function of the component template.
Optionally, monitoring the operation data of the interface includes:
the operational data of the interface is monitored by Metrics.
Optionally, the operation data includes one or more of occupied memory data, thread allocation data, Meters data, Gauges data, Counters data, Histograms data, and Timers data.
Optionally, the report module 206 is further configured to transmit the running report to infiluxdb and Grafana systems for display.
A third embodiment of the present specification provides an interface monitoring apparatus, including:
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, the instructions being executable by the at least one processor to enable the at least one processor to perform the interface monitoring method of embodiment one.
A fourth embodiment of the present specification provides a computer-readable storage medium storing computer-executable instructions that, when executed by a processor, implement the interface monitoring method of the first embodiment.
The above embodiments may be used in combination, and the modules having the same name between different embodiments or within the same embodiment may be the same or different modules.
While certain embodiments of the present disclosure have been described above, 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 have to be in the particular order shown or in 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 apparatus, device, and non-volatile computer-readable storage medium embodiments, since they are substantially similar to the method embodiments, the description is relatively simple, and in relation to the description, reference may be made to some portions of the description of the method embodiments.
The apparatus, the device, the nonvolatile computer readable storage medium, and the method provided in the embodiments of the present specification correspond to each other, and therefore, the apparatus, the 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 functions of the various elements may be implemented in the same one or more software and/or hardware implementations 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 processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing 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 processing 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 processing 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 disk storage or other magnetic storage devices, or any other non-transmission medium which 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. An interface monitoring method, comprising:
acquiring an interface monitoring component, and uploading the interface monitoring component to a server;
after the interface monitoring component is downloaded from the server and accessed by the interface, the accessed interface monitoring component is embedded in a closure function of the interface so as to monitor the operation data of the interface;
and generating an interface operation report according to the operation data.
2. The method of claim 1, the interface monitoring component is encapsulated with Metrics classes.
3. The method of claim 2, interfacing to the interface monitoring component comprising:
and configuring a downloading address in a maven setting file of the interface so that the interface can access the downloaded interface monitoring component after downloading the interface monitoring component through the downloading address.
4. The method of claim 1, the interface monitoring component having a component template; the interface monitoring component embedded point accessed comprises the following steps in the closure function of the interface:
and using the component template in the service layer of the interface, and transmitting the name and/or URL address and/or key value of the interface into a closure function of the component template.
5. The method of claim 1, monitoring operational data of the interface comprising:
the operational data of the interface is monitored by Metrics.
6. The method of claim 1, wherein the operational data comprises one or more of occupied memory data, thread allocation data, Meters data, Gauges data, Counters data, Histograms data, and Timers data.
7. The method of claim 1, after generating an interface operational report from the operational data, the method further comprising:
and transmitting the running report to an Influxdb system and a Grafana system for displaying.
8. An interface monitoring device, comprising:
the building module is used for acquiring the interface monitoring component and uploading the interface monitoring component to the server;
the monitoring module is used for embedding the accessed interface monitoring component in a closure function of the interface to monitor the operation data of the interface after the interface monitoring component is downloaded from the server and accessed by the interface;
and the report module is used for generating an interface operation report according to the operation data.
9. An interface monitoring device, comprising:
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 perform the interface monitoring method of any one of claims 1 to 7.
10. A computer-readable storage medium storing computer-executable instructions that, when executed by a processor, implement the interface monitoring method of any one of claims 1 to 7.
CN202110990680.6A 2021-08-26 2021-08-26 Interface monitoring method, device, equipment and medium Pending CN113672470A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110990680.6A CN113672470A (en) 2021-08-26 2021-08-26 Interface monitoring method, device, equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110990680.6A CN113672470A (en) 2021-08-26 2021-08-26 Interface monitoring method, device, equipment and medium

Publications (1)

Publication Number Publication Date
CN113672470A true CN113672470A (en) 2021-11-19

Family

ID=78546857

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110990680.6A Pending CN113672470A (en) 2021-08-26 2021-08-26 Interface monitoring method, device, equipment and medium

Country Status (1)

Country Link
CN (1) CN113672470A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114553740A (en) * 2022-03-11 2022-05-27 以萨技术股份有限公司 Method, system, readable storage medium and device for cross-network monitoring

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114553740A (en) * 2022-03-11 2022-05-27 以萨技术股份有限公司 Method, system, readable storage medium and device for cross-network monitoring
CN114553740B (en) * 2022-03-11 2023-11-10 以萨技术股份有限公司 Method, system, readable storage medium and device for cross-network monitoring

Similar Documents

Publication Publication Date Title
CN108712454B (en) File processing method, device and equipment
CN107045438B (en) Application top view processing method, device and component
CN109947643B (en) A/B test-based experimental scheme configuration method, device and equipment
CN107092475B (en) Calling method and device of interactive control
CN108628688B (en) Message processing method, device and equipment
CN108549562A (en) A kind of method and device of image load
CN111885082B (en) Web application package processing method, device and equipment
CN110989939A (en) Data cache processing method, device and equipment and cache component
CN107479868B (en) Interface loading method, device and equipment
CN114547024A (en) SQL statement risk detection method, device, equipment and medium
CN113672470A (en) Interface monitoring method, device, equipment and medium
CN111338655B (en) Installation package distribution method and system
CN110941443B (en) Method and device for modifying file name in SDK (software development kit) and electronic equipment
CN111273965B (en) Container application starting method, system and device and electronic equipment
CN111459573A (en) Method and device for starting intelligent contract execution environment
CN111190692A (en) Monitoring method and system based on Roc processor and readable medium
CN108769152B (en) Service refresh policy registration method, service refresh request method, device and equipment
CN111796864A (en) Data verification method and device
CN111427584A (en) Method, device and equipment for generating executable file
CN112925527B (en) Calling method, calling device, storage medium and electronic equipment
CN111090425B (en) Program packaging method and device and electronic equipment
CN114594978A (en) Updating method, device and equipment of packaging library
CN113076102A (en) Page display method, device, equipment and medium
CN114356448A (en) Object control method, device, equipment and medium
CN117591107A (en) Method, equipment and medium for fast rendering front-end interface

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
TA01 Transfer of patent application right

Effective date of registration: 20220801

Address after: 100190 Beijing Haidian District Zhichun Road 49 No. 3 West 309

Applicant after: TENCENT CLOUD COMPUTING (BEIJING) Co.,Ltd.

Address before: 100102 Room 203, 14 and 19, floor 2, building 19, Wangjing Dongyuan seventh district, Chaoyang District, Beijing

Applicant before: Beijing Guangqiyuan Digital Technology Co.,Ltd.

TA01 Transfer of patent application right