CN116302830A - Micro-service inspection method and device for application program and computer equipment - Google Patents

Micro-service inspection method and device for application program and computer equipment Download PDF

Info

Publication number
CN116302830A
CN116302830A CN202310298633.4A CN202310298633A CN116302830A CN 116302830 A CN116302830 A CN 116302830A CN 202310298633 A CN202310298633 A CN 202310298633A CN 116302830 A CN116302830 A CN 116302830A
Authority
CN
China
Prior art keywords
inspection
data
micro
target
service
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
CN202310298633.4A
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.)
Industrial and Commercial Bank of China Ltd ICBC
Original Assignee
Industrial and Commercial Bank of China Ltd ICBC
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 Industrial and Commercial Bank of China Ltd ICBC filed Critical Industrial and Commercial Bank of China Ltd ICBC
Priority to CN202310298633.4A priority Critical patent/CN116302830A/en
Publication of CN116302830A publication Critical patent/CN116302830A/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/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/3006Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system is distributed, e.g. networked systems, clusters, multiprocessor systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/547Remote procedure calls [RPC]; Web services
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

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

Abstract

The application relates to a micro-service inspection method, a micro-service inspection device, computer equipment, a storage medium and a computer program product of an application program. The method comprises the following steps: determining at least one patrol item for the target application in response to the patrol item configuration instruction for the target application; acquiring original monitoring data of a target client, and performing inspection operation on the original monitoring data according to data inspection conditions corresponding to inspection items to obtain micro-service inspection data corresponding to the inspection items; returning the micro-service inspection data corresponding to each inspection item to the target client; the micro-service inspection data are used for converting the micro-service inspection data into the inspection data in a target format according to a preset data interaction federation protocol; the target format inspection data is used for the central server to generate an inspection data aggregation report. The method can improve the micro-service inspection efficiency.

Description

Micro-service inspection method and device for application program and computer equipment
Technical Field
The present invention relates to the field of computer technology and the field of financial technology, and in particular, to a method, an apparatus, a computer device, a storage medium, and a computer program product for micro-service inspection of an application program.
Background
With the development of computer technology, a micro-service inspection technology appears.
At present, when micro-service inspection is performed on an application program, only fixed type inspection data can be obtained, and the running state of micro-service in the application program can not be clearly reflected due to different data formats of the inspection data, so that the micro-service inspection efficiency for the application program is lower.
Therefore, the conventional technology has the problem that the micro-service inspection efficiency of the application program is not high.
Disclosure of Invention
In view of the foregoing, it is desirable to provide a micro-service inspection method, apparatus, computer device, computer-readable storage medium, and computer program product for an application program capable of improving the efficiency of micro-service inspection.
The method for inspecting the micro-service of the application program is characterized by comprising the following steps:
determining at least one patrol item for the target application in response to the patrol item configuration instruction for the target application;
acquiring original monitoring data of a target client, and performing inspection operation on the original monitoring data according to data inspection conditions corresponding to inspection items to obtain micro-service inspection data corresponding to the inspection items; the target client is a client running a target micro service; the target micro-service is at least one micro-service in the target application program;
Returning the micro-service inspection data corresponding to each inspection item to the target client; the micro-service inspection data are used for being converted into target format inspection data according to a preset data interaction federation protocol; and the target format inspection data is used for the central server to generate an inspection data aggregation report.
In one embodiment, according to a data inspection condition corresponding to an inspection item, performing an inspection operation on original monitoring data to obtain micro-service inspection data corresponding to the inspection item, including:
acquiring a data screening threshold corresponding to the data inspection condition;
performing inspection operation on the original monitoring data according to the data screening threshold value to obtain a data inspection result; the data inspection result comprises the inspected data after the screening, which is matched with the data screening threshold;
and determining the screened inspection data as micro-service inspection data corresponding to the inspection items.
In one embodiment, determining at least one patrol item for a target application in response to patrol item configuration instructions for the target application comprises:
responding to a patrol item configuration instruction aiming at a target application program, and acquiring a micro-service patrol request transmitted by the patrol item configuration instruction;
analyzing the micro-service inspection request to obtain a request analysis result;
Identifying at least one inspection item aiming at a target application program according to a request analysis result; each inspection item has corresponding data inspection conditions.
In one embodiment, identifying at least one patrol item for the target application according to the request parsing result includes:
determining at least one patrol item identifier in an activated state according to a request analysis result;
and taking the inspection items corresponding to the inspection item identifiers as at least one inspection item aiming at the target application program.
The method for inspecting the micro-service of the application program is characterized by comprising the following steps:
sending a patrol data calling request to a target client; the patrol data call request is used for indicating the target client to return the patrol data in the target format; the target format inspection data is obtained by performing format conversion operation on the micro-service inspection data by a target client according to a preset data interaction federation protocol; the micro-service inspection data are determined by adopting the micro-service inspection of the application program;
and generating an inspection data aggregation report according to the target format inspection data.
In one embodiment, generating an inspection data aggregation report according to the target format inspection data includes:
Acquiring a data aggregation mode aiming at target format inspection data;
and according to the data aggregation mode, carrying out aggregation operation on the target format inspection data to obtain an inspection data aggregation report.
In one embodiment, the method for acquiring the data aggregation of the inspection data aiming at the target format includes:
determining a data aggregation identifier corresponding to the target format inspection data; the data aggregation identifier comprises at least one of a patrol item aggregation identifier or an application name aggregation identifier;
and determining a data aggregation mode characterized by the data aggregation identifier as a data aggregation mode aiming at the target format inspection data.
A micro-service inspection device for an application program, the device comprising:
the determining module is used for responding to the inspection item configuration instruction aiming at the target application program and determining at least one inspection item aiming at the target application program;
the inspection module is used for acquiring the original monitoring data of the target client, and performing inspection operation on the original monitoring data according to the data inspection conditions corresponding to the inspection items to obtain micro-service inspection data corresponding to the inspection items; the target client is a client running a target micro service; the target micro-service is at least one micro-service in the target application program;
The return module is used for returning the micro-service inspection data corresponding to each inspection item to the target client, wherein the micro-service inspection data is used for being converted into the inspection data in the target format according to a preset data interaction federation protocol; and the target format inspection data is used for the central server to generate an inspection data aggregation report.
A micro-service inspection device for an application program, the device comprising:
the sending module is used for sending a patrol data calling request to the target client; the patrol data call request is used for indicating the target client to return the patrol data in the target format; the target format inspection data is obtained by performing format conversion operation on the micro-service inspection data by a target client according to a preset data interaction federation protocol; the micro-service inspection data are determined by adopting the micro-service inspection method of the application program;
and the generating module is used for generating an inspection data aggregation report according to the inspection data in the target format.
A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method described above when executing the computer program.
A computer readable storage medium having stored thereon a computer program, characterized in that the computer program when executed by a processor realizes the steps of the above-mentioned method.
A computer program product comprising a computer program, characterized in that the computer program, when being executed by a processor, implements the steps of the method described above.
The method, the device, the computer equipment, the storage medium and the computer program product for micro-service inspection of the application program determine at least one inspection item for a target application program by responding to an inspection item configuration instruction for the target application program; acquiring original monitoring data of a target client, and performing inspection operation on the original monitoring data according to data inspection conditions corresponding to inspection items to obtain micro-service inspection data corresponding to the inspection items; the target client is a client running a target micro service; the target micro-service is at least one micro-service in the target application program; returning the micro-service inspection data corresponding to each inspection item to the target client; the micro-service inspection data are used for being converted into target format inspection data according to a preset data interaction federation protocol; the target format inspection data is used for a central server to generate an inspection data aggregation report; therefore, different inspection items can be set for different types of application programs, micro-service inspection data matched with the service scene can be flexibly obtained according to the service scene corresponding to the application program, and the micro-service inspection data of different data format types are converted into the target format inspection data according to the unified data interaction federal protocol, so that the node data of different clients are protected, the micro-service operation data analysis is facilitated, and the micro-service inspection efficiency of the application program is improved.
Drawings
FIG. 1 is an application environment diagram of a method for micro-service inspection of an application in one embodiment;
FIG. 2 is a flow chart of a method for micro-service inspection of an application program according to one embodiment;
FIG. 3 is a flow chart of a method for implementing microservice inspection according to one embodiment;
FIG. 4 is a flowchart of a method for micro-service inspection of an application in another embodiment;
FIG. 5 is a flow chart of a method for micro-service inspection of an application in one embodiment;
FIG. 6 is a diagram of a server architecture in one embodiment;
FIG. 7 is a block diagram of a micro-service inspection device of an application in one embodiment;
FIG. 8 is a block diagram of a micro-service inspection device for an application in one embodiment;
fig. 9 is an internal structural diagram of a computer device in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present application.
It should be noted that the application discloses a method, a device, a computer readable storage medium and a computer program product for micro-service inspection of an application program, which can be applied to the technical field of financial science and technology.
It should be noted that the terms "first," "second," and the like in the description and claims of the present disclosure and in the foregoing figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the disclosure described herein may be capable of operation in sequences other than those illustrated or described herein. The implementations described in the following exemplary examples are not representative of all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure.
The micro-service inspection method of the application program provided by the embodiment of the application program can be applied to an application environment shown in fig. 1. Wherein the computer device 102 determines at least one patrol item for the target application in response to the patrol item configuration instruction for the target application; the computer equipment 102 acquires the original monitoring data of the target client, and performs the inspection operation on the original monitoring data according to the data inspection conditions corresponding to the inspection items to obtain micro-service inspection data corresponding to the inspection items; the target client is a client running a target micro service; the target micro-service is at least one micro-service in the target application program; the computer equipment 102 returns the micro-service inspection data corresponding to each inspection item to the target client; the micro-service inspection data are used for converting the micro-service inspection data into the inspection data in a target format according to a preset data interaction federation protocol; the target format inspection data is used for the central server to generate an inspection data aggregation report. The computer equipment can be various personal computers, notebook computers, smart phones, tablet computers and Internet of things equipment.
In one embodiment, as shown in fig. 2, a method for inspecting a micro service of an application program is provided, and the method is applied to the computer device 102 in fig. 1 for illustration, and includes the following steps:
step S202, at least one patrol item for a target application is determined in response to a patrol item configuration instruction for the target application.
The target application program may refer to an application program that needs to perform micro-service inspection.
The inspection item may refer to an inspection task for determining whether a micro-service with abnormal operation exists in the target application program. For example, a patrol term may refer to a patrol task for screening out micro-services with a maximum number of concurrency in a target application greater than a threshold value 50.
The patrol item configuration instruction may be an instruction for configuring a patrol task for the target application program.
In specific implementation, the computer device determines the patrol item corresponding to the target application program in response to the patrol item configuration instruction of the target application program.
Step S204, original monitoring data of a target client is obtained, and the original monitoring data is subjected to inspection operation according to data inspection conditions corresponding to inspection items, so that micro-service inspection data corresponding to the inspection items are obtained; the target client is a client running a target micro service; the target micro-service is at least one micro-service in the target application.
The target client may refer to a client where the target application program is located.
The original monitoring data may refer to data for monitoring the running state of the micro service of each application program in each client.
The data inspection condition may be a data screening condition for screening out micro services with abnormal running states. For example, the data patrol condition may refer to a condition that the maximum number of concurrency is greater than the patrol threshold 50.
Wherein a micro-service may refer to a service running in an application.
The micro-service inspection data may refer to data corresponding to an operation state of the micro-service.
In the specific implementation, the computer equipment acquires the micro-service running state data of the target application program in the target client, and for any inspection item, the computer equipment determines the micro-service inspection running data matched with the data inspection condition according to the data inspection condition corresponding to the inspection item, and the computer equipment takes the data item corresponding to the micro-service inspection data matched with the data inspection condition as the micro-service inspection data of the inspection item.
Step S206, returning the micro-service inspection data corresponding to each inspection item to the target client; the micro-service inspection data are used for converting the micro-service inspection data into the inspection data in a target format according to a preset data interaction federation protocol; the target format inspection data is used for the central server to generate an inspection data aggregation report.
The data interaction federation protocol may refer to a specific federation communication protocol, where the specific federation communication protocol may be used to agree on a data exchange sequence of each data participant in the federation process, and encryption and decryption methods adopted before and after data exchange.
Wherein the central server may be a server for managing a plurality of clients.
The target format inspection data may refer to inspection data having a specific format.
The inspection data aggregation report may be a data report obtained by aggregating the micro-service inspection data of each client according to a certain data aggregation rule.
In specific implementation, the computer equipment returns the micro-service inspection data corresponding to each inspection item to the target client.
In practical application, the micro-service inspection method of the application program can be realized by a server platform (a micro architecture is provided by no server operation). Fig. 3 exemplarily provides a flowchart of a method for implementing micro-service inspection on a Severless platform based on a preset personalized service inspection framework.
The Severless platform can determine clients corresponding to the http application access requests based on a preset personalized service inspection frame, and monitor application program micro-service operation data of the clients. The method comprises the steps of obtaining the personalized configuration analysis result of an http access request by obtaining the data of the http access request, determining the routing inspection item corresponding to the http access request, and further screening out the routing inspection item with problems. And finally, assembling a return value according to the federal protocol, and switching to the next section of link for inspection after the completion. After all the links are inspected, returning the return values of all the links to the central server.
The method, the device, the computer equipment, the storage medium and the computer program product for micro-service inspection of the application program determine at least one inspection item for a target application program by responding to an inspection item configuration instruction for the target application program; acquiring original monitoring data of a target client, and performing inspection operation on the original monitoring data according to data inspection conditions corresponding to inspection items to obtain micro-service inspection data corresponding to the inspection items; the target client is a client running a target micro service; the target micro-service is at least one micro-service in the target application program; returning the micro-service inspection data corresponding to each inspection item to the target client; the micro-service inspection data are used for converting the micro-service inspection data into the inspection data in a target format according to a preset data interaction federation protocol; the target format inspection data is used for the central server to generate an inspection data aggregation report; therefore, different inspection items can be set for different types of application programs, micro-service inspection data matched with the service scene can be flexibly obtained according to the service scene corresponding to the application program, and the micro-service inspection data of different data format types are converted into the target format inspection data according to the unified data interaction federal protocol, so that the node data of different clients are protected, the micro-service operation data analysis is facilitated, and the micro-service inspection efficiency of the application program is improved.
In another embodiment, according to a data inspection condition corresponding to an inspection item, performing an inspection operation on original monitoring data to obtain micro-service inspection data corresponding to the inspection item, including: acquiring a data screening threshold corresponding to the data inspection condition; performing inspection operation on the original monitoring data according to the data screening threshold value to obtain a data inspection result; the data inspection result comprises the inspected data after the screening, which is matched with the data screening threshold; and determining the screened inspection data as micro-service inspection data corresponding to the inspection items.
The data filtering threshold may be a value used to filter the inspection data, for example, in the inspection item of "maximum concurrency number", the data filtering threshold may be set to 50, and in practical application, the server may use the micro service with the maximum concurrency number greater than 50 as the micro service with abnormal running state.
The post-screening inspection data may refer to an inspection data item corresponding to a micro service with an abnormal running state.
In specific implementation, for any inspection item, the computer equipment acquires an inspection threshold corresponding to a data inspection condition of the inspection item, when the computer equipment executes the inspection task of the inspection item aiming at a target application program, the computer equipment uses a micro service with the inspection item value larger than the inspection threshold in the micro service operation data as an abnormal operation micro service, and the computer equipment uses inspection data items corresponding to the abnormal operation micro services as micro service inspection data corresponding to the inspection item.
For example, for the inspection item "maximum concurrency number", the data filtering threshold of the maximum concurrency number may be set to 50, and for the application program a, when the inspection item "maximum concurrency number" is executed by the computer device, the original data source corresponding to the inspection item in the application program a includes { micro service name: a microservice 1; the method comprises the following steps: calling; maximum number of concurrency: 90; time: 2023-03-05 20:55:34}, { micro-service name: a micro service 2; the method comprises the following steps: calling; maximum number of concurrency: 20, a step of; time: 2023-03-05 20:50:31}, { micro-service name: a micro service 3; the method comprises the following steps: calling; maximum number of concurrency: 30; time: 2023-03-0520:45:20}, { micro-service name: a micro service 4; the method comprises the following steps: calling; maximum number of concurrency: 60; time: 2023-03-05 20:38:34}, the computer device screens out the microservice data items with the maximum concurrency number greater than 50, and obtains a data inspection result as { microservice name: a microservice 1; the method comprises the following steps: calling; maximum number of concurrency: 90; time: 2023-03-05 20:55:34} and { micro-service name: a micro service 4; the method comprises the following steps: calling; maximum number of concurrency: 60; time: 2023-03-05 20:38:34}. Each microservice data item corresponds to a json (a lightweight data exchange format) record, and the data inspection result is a new json array formed by a plurality of json records.
To facilitate understanding by those skilled in the art, a configuration format for setting data patrol conditions for an application is provided below: { application name: an application program A; patrol item that needs to be activated: the maximum concurrency number, the thread pool full number; configuration rules: { maximum concurrency count inspection threshold: 50, thread pool full number inspection threshold: 1, provider current limit number inspection threshold: 1, provider current limit number inspection threshold: 1, no provider number inspection threshold: 1, rpc total failure count inspection threshold: 1000, rpc failure rate threshold patrol threshold: 0.01, rpc service maximum time-consuming patrol threshold: 1000, rpc service average time consuming patrol threshold: 1000}}.
The configuration format code indicates that the maximum concurrency number of the patrol item is greater than 50 and the thread pool full number of the patrol item is greater than 1 for the application program 1.
According to the technical scheme, the data screening threshold corresponding to the data inspection condition is obtained; performing inspection operation on the original monitoring data according to the data screening threshold value to obtain a data inspection result; the data inspection result comprises the inspected data after the screening, which is matched with the data screening threshold; determining the screened inspection data as micro-service inspection data corresponding to the inspection items; therefore, different data screening thresholds can be set according to different business scenes, so that different data inspection conditions are set, more effective micro-service inspection data can be obtained, and the micro-service inspection efficiency of an application program is improved.
In another embodiment, determining at least one patrol item for a target application in response to patrol item configuration instructions for the target application comprises: responding to a patrol item configuration instruction aiming at a target application program, and acquiring a micro-service patrol request transmitted by the patrol item configuration instruction; analyzing the micro-service inspection request to obtain a request analysis result; identifying at least one inspection item aiming at a target application program according to a request analysis result; each inspection item has corresponding data inspection conditions.
The micro-service inspection request may be an inspection request for micro-service operation data of the application program. In practical applications, the microservice routing inspection request may be a request for a pointer to initiate a target routing inspection item for a certain application.
The request analysis result may be a patrol item analysis result of the target application program by the pointer. For example, the request analysis result may refer to various types of inspection items corresponding to the target application program.
In specific implementation, a computer device responds to a routing inspection configuration instruction for a target application program, determines an http access request parameter corresponding to the input target application program and routing inspection items set for the http access request parameter, and analyzes the http access request parameter to obtain various routing inspection items for the target application program.
According to the technical scheme, a micro-service inspection request transmitted by an inspection item configuration instruction is acquired by responding to the inspection item configuration instruction aiming at a target application program; analyzing the micro-service inspection request to obtain a request analysis result; identifying at least one inspection item aiming at a target application program according to a request analysis result; therefore, the acquired micro-service inspection request can be analyzed, inspection items corresponding to different micro-service inspection requests are obtained, different inspection methods are conveniently adopted for different application programs, accurate micro-service inspection data are obtained, and therefore micro-service inspection efficiency of the application programs is improved.
In another embodiment, identifying at least one patrol item for the target application according to the request parsing result includes: determining at least one patrol item identifier in an activated state according to a request analysis result; and taking the inspection items corresponding to the inspection item identifiers as at least one inspection item aiming at the target application program.
The activation state may refer to a work start state of the inspection item.
In the specific implementation, the computer equipment determines the inspection item identifier in the activated state according to the analysis result of the http access request parameter of the target application program, and the computer equipment determines the inspection item corresponding to the inspection item identifier in the activated state as the inspection item corresponding to the target application program.
According to the technical scheme of the embodiment, at least one patrol item identifier in an activated state is determined according to a request analysis result; taking the inspection items corresponding to the inspection item identifiers as at least one inspection item aiming at the target application program; therefore, different inspection items can be set according to different application programs, so that micro-service inspection data corresponding to different application programs are obtained, and the micro-service inspection efficiency of the application programs is improved.
In another embodiment, as shown in fig. 4, a method for inspecting a micro service of an application program is provided, and the method is applied to the computer device 102 in fig. 1 for illustration, and includes the following steps:
step S402, in response to the inspection item configuration instruction for the target application, determines at least one inspection item for the target application.
Step S404, original monitoring data of a target client is obtained, and a data screening threshold corresponding to a data inspection condition is obtained; the target client is a client running a target micro service; the target micro-service is at least one micro-service in the target application.
Step S406, carrying out inspection operation on the original monitoring data according to the data screening threshold value to obtain a data inspection result; the data inspection result comprises the inspected data after the screening, which is matched with the data screening threshold value.
Step S408, determining that the screened inspection data is micro-service inspection data corresponding to the inspection items.
Step S410, returning the micro-service inspection data corresponding to each inspection item to the target client; the micro-service inspection data are used for converting the micro-service inspection data into the inspection data in a target format according to a preset data interaction federation protocol; the target format inspection data is used for the central server to generate an inspection data aggregation report. It should be noted that, the specific limitation of the above steps may be referred to the specific limitation of the micro service inspection method of an application program, which is not described herein.
In one embodiment, as shown in fig. 5, a method for inspecting a micro service of an application program is provided, and the method is applied to a server for illustration, and includes the following steps:
step S502, sending a patrol data calling request to a target client; the patrol data call request is used for indicating the target client to return the patrol data in the target format; the target format inspection data is obtained by performing format conversion operation on the micro-service inspection data by a target client according to a preset data interaction federation protocol; the microservice inspection data is determined using the methods of the embodiments described above.
The routing inspection data call request may refer to a request for calling the routing inspection data of the client.
In a specific implementation, a central server sends a patrol data call request to each target client.
Step S504, generating an inspection data aggregation report according to the inspection data in the target format.
In the specific implementation, after each target client returns the target format inspection data to the central server, the central server aggregates the target format inspection data returned by each client to obtain an inspection data aggregation report.
For ease of understanding by those skilled in the art, the following exemplary set rules for the data interaction federal protocol are provided: { data type: html data format/json data format, aggregation type: patrol item aggregation/application name aggregation, next link address: address 1/address 2/address 3, resulting in status: success/failure }.
The setting rule indicates that the target client returns the micro-service inspection data according to the html data format (or json data format), and indicates that the central server aggregates the micro-service inspection data according to the inspection item (or application name), and after the micro-service inspection data of the current link is aggregated, the micro-service inspection data of the next address 1 (or address 2 or address 3) link is aggregated, and the processing result of the micro-service inspection data of the current link is displayed as success (or failure).
In practical applications, the method for micro-service inspection of application program can be applied to the server architecture shown in fig. 6. The central server sends a patrol data calling request to the client 1 and the client 4, and the client 1 and the client 4 respond to the patrol data calling request to return patrol data to the central server. Since the routing inspection data call request to the client 1 triggers the routing inspection data call request to the upstream clients 2 and 3 of the link of the client 1, in the actual routing inspection process, the client 3 returns the corresponding routing inspection data to the downstream client 2, the client 2 returns the routing inspection data corresponding to the client 2 and the client 3 to the downstream client 1, and finally the client returns the routing inspection data of the link of the client 1, the client 2 and the client 3 to the central server. The central server aggregates according to the patrol items and sends patrol data aggregation reports to the client 1 and the client 4 according to the patrol item aggregation mode.
According to the technical scheme, a patrol data aggregation report is generated by sending a patrol data calling request to a target client and then carrying out patrol data in a target format returned by the target client; therefore, the routing inspection data information corresponding to each client can be obtained on the basis of protecting the private node data of each client, and the micro-service routing inspection efficiency of the application program is improved.
In another embodiment, generating an inspection data aggregation report from the target format inspection data includes: acquiring a data aggregation mode aiming at target format inspection data; and according to the data aggregation mode, carrying out aggregation operation on the target format inspection data to obtain an inspection data aggregation report.
In the specific implementation, a central server determines a data aggregation mode corresponding to each target format inspection data, and the central server aggregates each target format inspection data according to the data aggregation mode and generates an inspection data aggregation report.
According to the technical scheme, a data aggregation mode aiming at target format inspection data is obtained; according to the data aggregation mode, carrying out aggregation operation on the target format inspection data to obtain an inspection data aggregation report; therefore, different inspection data aggregation reports can be generated according to different data aggregation modes, so that the processing speed of micro-service inspection data is improved, and the micro-service inspection efficiency is improved.
In another embodiment, the method for acquiring the data aggregation of the inspection data aiming at the target format includes: determining a data aggregation identifier corresponding to the target format inspection data; the data aggregation identifier comprises at least one of a patrol item aggregation identifier or an application name aggregation identifier; and determining a data aggregation mode characterized by the data aggregation identifier as a data aggregation mode aiming at the target format inspection data.
The data aggregation mode may be to aggregate the inspection data according to inspection items or according to application names.
In the specific implementation, the central server determines a data aggregation identifier corresponding to the target format inspection data, namely, the central server determines that the data aggregation identifier is an inspection item aggregation identifier or an application name aggregation identifier, when the central server determines that the data aggregation identifier is an inspection item aggregation identifier, the central server aggregates the target format inspection data according to the inspection item, and when the central server determines that the data aggregation identifier is an application name aggregation identifier, the central server aggregates the target format inspection data according to the application name.
According to the technical scheme, a data aggregation mode represented by the data aggregation identifier is determined by determining the data aggregation identifier corresponding to the target format inspection data and is used as the data aggregation mode aiming at the target format inspection data; therefore, the data aggregation mode required to be followed by the inspection data aggregation report can be determined, so that different types of inspection data aggregation reports can be generated according to actual needs, and the micro-service inspection efficiency can be improved.
It should be understood that, although the steps in the flowcharts related to the embodiments described above are sequentially shown as indicated by arrows, these steps are not necessarily sequentially performed in the order indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least some of the steps in the flowcharts described in the above embodiments may include a plurality of steps or a plurality of stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of the steps or stages is not necessarily performed sequentially, but may be performed alternately or alternately with at least some of the other steps or stages.
Based on the same inventive concept, the embodiment of the application also provides a micro-service inspection device for the application program for realizing the micro-service inspection method of the application program. The implementation scheme of the solution provided by the device is similar to the implementation scheme described in the above method, so the specific limitation in the embodiments of the micro-service inspection device for one or more application programs provided below can be referred to the limitation of the micro-service inspection method for the application program hereinabove, and will not be repeated here.
In one embodiment, as shown in fig. 7, there is provided a micro service inspection apparatus for an application program, including:
a determining module 702, configured to determine at least one patrol item for a target application in response to a patrol item configuration instruction for the target application;
the inspection module 704 is configured to obtain original monitoring data of the target client, and perform an inspection operation on the original monitoring data according to a data inspection condition corresponding to an inspection item, so as to obtain micro-service inspection data corresponding to the inspection item; the target client is a client running a target micro service; the target micro-service is at least one micro-service in the target application program;
A returning module 706, configured to return the microservice inspection data corresponding to each inspection item to the target client; the micro-service inspection data are used for converting the micro-service inspection data into the inspection data in a target format according to a preset data interaction federation protocol; the target format inspection data is used for the central server to generate an inspection data aggregation report.
In another embodiment, the inspection module 704 is specifically configured to obtain a data screening threshold corresponding to the data inspection condition; performing inspection operation on the original monitoring data according to the data screening threshold value to obtain a data inspection result; the data inspection result comprises the inspected data after the screening, which is matched with the data screening threshold; and determining the screened inspection data as micro-service inspection data corresponding to the inspection items.
In another embodiment, the determining module 702 is specifically configured to obtain, in response to a patrol item configuration instruction for a target application, a microservice patrol request incoming to the patrol item configuration instruction; analyzing the micro-service inspection request to obtain a request analysis result; identifying at least one inspection item aiming at a target application program according to a request analysis result; each inspection item has corresponding data inspection conditions.
In another embodiment, the determining module 702 is specifically configured to determine, according to the analysis result of the request, at least one patrol item identifier in an active state; and taking the inspection items corresponding to the inspection item identifiers as at least one inspection item aiming at the target application program.
In one embodiment, as shown in fig. 8, there is provided a micro service inspection apparatus for an application program, including:
a sending module 802, configured to send a patrol data call request to a target client; the patrol data call request is used for indicating the target client to return the patrol data in the target format; the target format inspection data is obtained by performing format conversion operation on the micro-service inspection data by a target client according to a preset data interaction federation protocol; the micro-service inspection data are determined by adopting the micro-service inspection method of the application program;
the generating module 804 is configured to generate an aggregation report of the inspection data according to the inspection data in the target format.
In another embodiment, the generating module 804 is specifically configured to obtain a data aggregation manner for the target format inspection data; and according to the data aggregation mode, carrying out aggregation operation on the target format inspection data to obtain an inspection data aggregation report.
In another embodiment, the generating module 804 is specifically configured to determine a data aggregation identifier corresponding to the target format inspection data; the data aggregation identifier comprises at least one of a patrol item aggregation identifier or an application name aggregation identifier; and determining a data aggregation mode characterized by the data aggregation identifier as a data aggregation mode aiming at the target format inspection data.
The modules in the micro-service inspection device of the application program can be all or partially implemented by software, hardware and a combination thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one embodiment, a computer device is provided, which may be a server, and the internal structure of which may be as shown in fig. 9. The computer device includes a processor, a memory, and a network interface connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The database of the computer device is used for storing micro-service inspection data of the application program. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program, when executed by a processor, implements a micro-service inspection method for an application program.
It will be appreciated by those skilled in the art that the structure shown in fig. 9 is merely a block diagram of a portion of the structure associated with the present application and is not limiting of the computer device to which the present application applies, and that a particular computer device may include more or fewer components than shown, or may combine some of the components, or have a different arrangement of components.
In one embodiment, a computer device is provided comprising a memory and a processor, the memory having stored therein a computer program, the processor when executing the computer program performing the steps of:
determining at least one patrol item for the target application in response to the patrol item configuration instruction for the target application;
acquiring original monitoring data of a target client, and performing inspection operation on the original monitoring data according to data inspection conditions corresponding to inspection items to obtain micro-service inspection data corresponding to the inspection items; the target client is a client running a target micro service; the target micro-service is at least one micro-service in the target application program;
returning the micro-service inspection data corresponding to each inspection item to the target client; the micro-service inspection data are used for converting the micro-service inspection data into the inspection data in a target format according to a preset data interaction federation protocol; the target format inspection data is used for the central server to generate an inspection data aggregation report.
In one embodiment, the processor, when executing the computer program, performs the steps of:
acquiring a data screening threshold corresponding to the data inspection condition;
performing inspection operation on the original monitoring data according to the data screening threshold value to obtain a data inspection result; the data inspection result comprises the inspected data after the screening, which is matched with the data screening threshold;
and determining the screened inspection data as micro-service inspection data corresponding to the inspection items.
In one embodiment, the processor, when executing the computer program, performs the steps of:
responding to a patrol item configuration instruction aiming at a target application program, and acquiring a micro-service patrol request transmitted by the patrol item configuration instruction;
analyzing the micro-service inspection request to obtain a request analysis result;
identifying at least one inspection item aiming at a target application program according to a request analysis result; each inspection item has corresponding data inspection conditions.
In one embodiment, the processor, when executing the computer program, performs the steps of:
determining at least one patrol item identifier in an activated state according to a request analysis result;
and taking the inspection items corresponding to the inspection item identifiers as at least one inspection item aiming at the target application program.
In one embodiment, a computer readable storage medium is provided, storing a computer program, which when executed by a processor, causes the processor to perform the steps of a micro-service inspection method of an application program described above. The steps of a method for inspecting a micro service of an application may be the steps of a method for inspecting a micro service of an application in the above embodiments.
In one embodiment, a computer program product is provided, comprising a computer program which, when executed by a processor, causes the processor to perform the steps of a microservice inspection method of an application as described above. The steps of a method for inspecting a micro service of an application may be the steps of a method for inspecting a micro service of an application in the above embodiments.
It should be noted that, user information (including but not limited to user equipment information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, presented data, etc.) referred to in the present application are information and data authorized by the user or sufficiently authorized by each party.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, database, or other medium used in the various embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, high density embedded nonvolatile Memory, resistive random access Memory (ReRAM), magnetic random access Memory (Magnetoresistive Random Access Memory, MRAM), ferroelectric Memory (Ferroelectric Random Access Memory, FRAM), phase change Memory (Phase Change Memory, PCM), graphene Memory, and the like. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory, and the like. By way of illustration, and not limitation, RAM can be in the form of a variety of forms, such as static random access memory (Static Random Access Memory, SRAM) or dynamic random access memory (Dynamic Random Access Memory, DRAM), and the like. The databases referred to in the various embodiments provided herein may include at least one of relational databases and non-relational databases. The non-relational database may include, but is not limited to, a blockchain-based distributed database, and the like. The processors referred to in the embodiments provided herein may be general purpose processors, central processing units, graphics processors, digital signal processors, programmable logic units, quantum computing-based data processing logic units, etc., without being limited thereto.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The above examples only represent a few embodiments of the present application, which are described in more detail and are not to be construed as limiting the scope of the present application. It should be noted that it would be apparent to those skilled in the art that various modifications and improvements could be made without departing from the spirit of the present application, which would be within the scope of the present application. Accordingly, the scope of protection of the present application shall be subject to the appended claims.

Claims (12)

1. A method for micro-service inspection of an application program, the method comprising:
determining at least one patrol item for a target application in response to a patrol item configuration instruction for the target application;
acquiring original monitoring data of a target client, and performing inspection operation on the original monitoring data according to data inspection conditions corresponding to the inspection items to obtain micro-service inspection data corresponding to the inspection items; the target client is a client running a target micro service; the target micro-service is at least one micro-service in the target application program;
Returning the micro-service inspection data corresponding to each inspection item to the target client; the micro-service inspection data are used for being converted into target format inspection data according to a preset data interaction federation protocol; and the target format inspection data is used for the central server to generate an inspection data aggregation report.
2. The method of claim 1, wherein the performing a patrol operation on the original monitoring data according to the data patrol condition corresponding to the patrol item to obtain micro-service patrol data corresponding to the patrol item comprises:
acquiring a data screening threshold corresponding to the data inspection condition;
performing inspection operation on the original monitoring data according to the data screening threshold value to obtain a data inspection result; the data inspection result comprises the inspected data after the screening, which is matched with the data screening threshold;
and determining the screened inspection data as micro-service inspection data corresponding to the inspection items.
3. The method of claim 1, wherein the determining at least one patrol item for a target application in response to a patrol item configuration instruction for the target application comprises:
Responding to a patrol item configuration instruction aiming at a target application program, and acquiring a micro-service patrol request transmitted by the patrol item configuration instruction;
analyzing the micro-service inspection request to obtain a request analysis result;
identifying at least one inspection item aiming at the target application program according to the request analysis result; each inspection item has a corresponding data inspection condition.
4. A method according to claim 3, wherein said identifying at least one patrol item for said target application based on said request parsing result comprises:
determining at least one patrol item identifier in an activated state according to the request analysis result;
and taking the inspection item corresponding to each inspection item identifier as at least one inspection item aiming at the target application program.
5. A method for micro-service inspection of an application program, the method comprising:
sending a patrol data calling request to a target client; the patrol data call request is used for indicating the target client to return the patrol data in the target format; the target format inspection data are obtained by performing format conversion operation on the micro-service inspection data by the target client according to a preset data interaction federation protocol; the microservice routing data determined using the method of any one of claims 1 to 4;
And generating an inspection data aggregation report according to the target format inspection data.
6. The method of claim 5, wherein generating an aggregate report of inspection data from the inspection data in the target format comprises:
acquiring a data aggregation mode aiming at the target format inspection data;
and according to the data aggregation mode, carrying out aggregation operation on the target format inspection data to obtain the inspection data aggregation report.
7. The method of claim 6, wherein the obtaining the data aggregation for the target format inspection data comprises:
determining a data aggregation identifier corresponding to the target format inspection data; the data aggregation identifier comprises at least one of a patrol item aggregation identifier or an application name aggregation identifier;
and determining a data aggregation mode of the data aggregation identifier characterization as a data aggregation mode aiming at the target format inspection data.
8. A micro-service inspection device for an application program, the device comprising:
a determining module for determining at least one patrol item for a target application in response to a patrol item configuration instruction for the target application;
The inspection module is used for acquiring original monitoring data of the target client, and performing inspection operation on the original monitoring data according to the data inspection conditions corresponding to the inspection items to obtain micro-service inspection data corresponding to the inspection items; the target client is a client running a target micro service; the target micro-service is at least one micro-service in the target application program;
the return module is used for returning the microservice inspection data corresponding to each inspection item to the target client; the micro-service inspection data are used for being converted into target format inspection data according to a preset data interaction federation protocol; and the target format inspection data is used for the central server to generate an inspection data aggregation report.
9. A micro-service inspection device for an application program, the device comprising:
the sending module is used for sending a patrol data calling request to the target client; the patrol data call request is used for indicating the target client to return the patrol data in the target format; the target format inspection data are obtained by performing format conversion operation on the micro-service inspection data by the target client according to a preset data interaction federation protocol; the microservice routing data determined using the method of any one of claims 1 to 4;
And the generating module is used for generating an inspection data aggregation report according to the target format inspection data.
10. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the steps of the method of any of claims 1 to 7 when the computer program is executed.
11. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 7.
12. A computer program product comprising a computer program, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 7.
CN202310298633.4A 2023-03-24 2023-03-24 Micro-service inspection method and device for application program and computer equipment Pending CN116302830A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310298633.4A CN116302830A (en) 2023-03-24 2023-03-24 Micro-service inspection method and device for application program and computer equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310298633.4A CN116302830A (en) 2023-03-24 2023-03-24 Micro-service inspection method and device for application program and computer equipment

Publications (1)

Publication Number Publication Date
CN116302830A true CN116302830A (en) 2023-06-23

Family

ID=86814828

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310298633.4A Pending CN116302830A (en) 2023-03-24 2023-03-24 Micro-service inspection method and device for application program and computer equipment

Country Status (1)

Country Link
CN (1) CN116302830A (en)

Similar Documents

Publication Publication Date Title
US11876809B2 (en) Identifying a cyber-attack impacting a particular asset
US11736378B1 (en) Collaborative incident management for networked computing systems
US11144608B2 (en) Triggering generation of an accelerated data model summary for a data model
US20200167395A1 (en) Data fabric service system
US10860618B2 (en) Low-latency streaming analytics
CN112910945B (en) Request link tracking method and service request processing method
US11829330B2 (en) Log data extraction from data chunks of an isolated execution environment
US11615082B1 (en) Using a data store and message queue to ingest data for a data intake and query system
US11966797B2 (en) Indexing data at a data intake and query system based on a node capacity threshold
US12019634B1 (en) Reassigning a processing node from downloading to searching a data group
CN110932933A (en) Network condition monitoring method, computing device and computer storage medium
CN112866319B (en) Log data processing method, system and storage medium
CN116302830A (en) Micro-service inspection method and device for application program and computer equipment
CN116389502B (en) Cross-cluster scheduling system, method, device, computer equipment and storage medium
CN117435367B (en) User behavior processing method, device, equipment, storage medium and program product
US20240119385A1 (en) Methods and systems for discovery and monitoring of business flows
CN116627681B (en) Service request processing method, device, computer equipment, medium and program product
CN115866029B (en) Method, device, computer equipment and storage medium for processing microservice offline
CN117097643A (en) Peripheral connection state processing method and device and computer equipment
CN117978539A (en) Network intrusion detection system, method, apparatus, computer device and medium
CN118260075A (en) Data processing method, apparatus, computer device, readable storage medium, and product
CN118152459A (en) Data online reporting method, device, computer equipment, medium and program product
US20110219387A1 (en) Interactive Remote Troubleshooting of a Running Process
CN116909785A (en) Processing method, device, equipment, storage medium and program product for abnormal event
CN116860480A (en) Call request processing method, device, computer equipment and storage medium

Legal Events

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