CN114490268A - Full link monitoring method, device, equipment, storage medium and program product - Google Patents

Full link monitoring method, device, equipment, storage medium and program product Download PDF

Info

Publication number
CN114490268A
CN114490268A CN202210123570.4A CN202210123570A CN114490268A CN 114490268 A CN114490268 A CN 114490268A CN 202210123570 A CN202210123570 A CN 202210123570A CN 114490268 A CN114490268 A CN 114490268A
Authority
CN
China
Prior art keywords
link monitoring
monitoring data
data
span
link
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
CN202210123570.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 CN202210123570.4A priority Critical patent/CN114490268A/en
Publication of CN114490268A publication Critical patent/CN114490268A/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/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
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3051Monitoring arrangements for monitoring the configuration of the computing system or of the computing system component, e.g. monitoring the presence of processing resources, peripherals, I/O links, software programs
    • 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/3452Performance evaluation by statistical analysis
    • 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/3466Performance evaluation by tracing or monitoring
    • G06F11/3476Data logging
    • 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/546Message passing systems or structures, e.g. queues
    • 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
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/66Arrangements for connecting between networks having differing types of switching systems, e.g. gateways
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/54Indexing scheme relating to G06F9/54
    • G06F2209/547Messaging middleware

Abstract

The disclosure provides a full link monitoring method which can be applied to the technical field of cloud computing. The method comprises the following steps: generating tracking identification information in response to a service request of a user; generating span identification information at each service call, wherein the span identification information comprises a father node span id, a current node span id and call time information; generating link monitoring data according to the tracking identification information and at least one piece of span identification information; collecting the link monitoring data; and determining a complete link according to the collected link monitoring data. The present disclosure also provides a full link monitoring apparatus, device, storage medium and program product.

Description

Full link monitoring method, device, equipment, storage medium and program product
Technical Field
The present disclosure relates to the field of cloud computing technologies, and in particular, to the field of distributed tracking technologies, and in particular, to a full-link monitoring method, apparatus, device, storage medium, and program product.
Background
With the maturity of a distributed architecture, a large number of enterprise-level applications adopt distributed and cloud computing technologies, nodes running in enterprise production are often thousands of, calling relations among different types of nodes are complicated and intricate, the nodes are often cross-application, cross-team and cross-park, once a certain link is wrong, problems of development and operation and maintenance personnel are very difficult to locate, and the efficiency is low because massive offline logs are often needed for troubleshooting and analysis. Due to the distributed tracking technology, research and development and operation and maintenance personnel can better master the calling condition among the nodes, the online problems can be more efficiently and conveniently checked, and the possibility is provided for full-link monitoring.
The existing monitoring data acquisition comprises an invasive scheme and a non-invasive scheme, data models of the two schemes are not uniform, and therefore monitoring data acquired by different schemes cannot be uniformly stored, analyzed and processed at a cloud end.
It is to be noted that the information disclosed in the above background section is only for enhancement of understanding of the background of the present disclosure, and thus may include information that does not constitute prior art known to those of ordinary skill in the art.
Disclosure of Invention
In view of the foregoing, the present disclosure provides a full link monitoring method, apparatus, device, storage medium, and program product.
According to a first aspect of the present disclosure, there is provided a full link monitoring method, including: generating tracking identification information in response to a service request of a user;
generating span identification information at each service call, wherein the span identification information comprises a father node span id, a current node span id and call time information;
generating link monitoring data according to the tracking identification information and at least one piece of span identification information;
collecting the link monitoring data; and
determining a complete link according to the collected link monitoring data,
wherein the collecting the link monitoring data comprises:
determining a gateway cluster according to the source of the link monitoring data, wherein the gateway cluster is used for receiving the link monitoring data;
converting the link monitoring data according to a preset data model to generate target data; and
and storing the target data into a database through message middleware.
According to an embodiment of the present disclosure, the preset data model includes link information, timestamp information, application project information, and custom fields.
According to an embodiment of the present disclosure, the converting the link monitoring data according to a preset data model to generate target data includes:
and determining a value corresponding to the field name according to the link monitoring data and the field name in the preset data model.
According to an embodiment of the present disclosure, the determining a gateway cluster according to a source of the link monitoring data includes:
when the source of the link monitoring data is determined to be data acquired by an invasive scheme, determining that the gateway cluster is a first data conversion gateway cluster; and
and when the source of the link monitoring data is determined to be the data acquired by the non-intrusive scheme, determining that the gateway cluster is a second data conversion gateway cluster.
According to an embodiment of the present disclosure, further comprising:
and carrying out expansion and contraction capacity on the gateway cluster according to the size of the link monitoring data volume.
According to an embodiment of the present disclosure, the scaling the gateway cluster according to the size of the link monitoring data volume includes:
if the link monitoring data volume is larger than a first preset threshold value, capacity expansion of a gateway cluster corresponding to the link monitoring data is determined; and
and if the link monitoring data volume is smaller than a second preset threshold value, determining to reduce the capacity of the gateway cluster corresponding to the link monitoring data.
A second aspect of the present disclosure provides a full link monitoring apparatus, including: the first generation module is used for responding to a service request of a user and generating tracking identification information;
the second generation module is used for generating span identification information during each service call, wherein the span identification information comprises a father node span id, a current node span id and timestamp information;
a third generating module, configured to generate link monitoring data according to the tracking identifier information and the at least one span identifier information;
the acquisition module is used for acquiring the link monitoring data; and
a processing module for determining a complete link according to the collected link monitoring data,
wherein the acquisition module comprises:
the determining submodule is used for determining a gateway cluster according to the source of the link monitoring data, and the gateway cluster is used for receiving the link monitoring data;
the conversion submodule is used for converting the link monitoring data according to a preset data model so as to generate target data; and
and the storage submodule is used for storing the target data into a database through message middleware.
A third aspect of the present disclosure provides an electronic device, comprising: one or more processors; a memory for storing one or more programs, wherein the one or more programs, when executed by the one or more processors, cause the one or more processors to perform the above-described full link monitoring method.
The fourth aspect of the present disclosure also provides a computer-readable storage medium having stored thereon executable instructions that, when executed by a processor, cause the processor to perform the above-described full link monitoring method.
A fifth aspect of the present disclosure also provides a computer program product comprising a computer program which, when executed by a processor, implements the above-described full link monitoring method.
According to the full link monitoring method provided by the embodiment of the disclosure, tracking identification information is generated according to a service request of a user and is used for marking each link; generating span identification information during each service call, wherein the span identification information comprises a father node span id, a current node span id and call time information, and determining a service call relation according to the father node span id and the current node span id; when the link monitoring data are collected, the gateway cluster is determined according to the source of the link monitoring data, the link monitoring data are converted according to a preset data model, uniform target data are generated, technical differences of client data collection are shielded, and consumption data can be uniformly consumed at a server side, uniformly stored in a warehouse, uniformly processed, displayed and analyzed; the target data are analyzed, so that the complete link and the response time of each link can be determined, and the monitoring of the full link is realized.
Drawings
The foregoing and other objects, features and advantages of the disclosure will be apparent from the following description of embodiments of the disclosure, which proceeds with reference to the accompanying drawings, in which:
fig. 1 schematically illustrates an application scenario diagram of a full link monitoring method, apparatus, device, storage medium and program product according to an embodiment of the present disclosure;
FIG. 2 schematically illustrates an architecture diagram for full link monitoring in accordance with an embodiment of the disclosure;
FIG. 3 schematically illustrates a flow diagram of a full link monitoring method according to an embodiment of the disclosure;
FIG. 4 schematically illustrates a flow chart of a process of collecting link monitoring data according to an embodiment of the disclosure;
FIG. 5 schematically illustrates a flow diagram of another full link monitoring method according to an embodiment of the disclosure;
fig. 6 schematically shows a flowchart of a method for scaling a gateway cluster according to a link monitoring data volume according to an embodiment of the present disclosure;
fig. 7 schematically shows a block diagram of a full link monitoring apparatus according to an embodiment of the present disclosure; and
fig. 8 schematically illustrates a block diagram of an electronic device adapted to implement a full link monitoring method according to an embodiment of the disclosure.
Detailed Description
Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. It should be understood that the description is illustrative only and is not intended to limit the scope of the present disclosure. In the following detailed description, for purposes of explanation, numerous specific details are set forth in order to provide a thorough understanding of the embodiments of the disclosure. It may be evident, however, that one or more embodiments may be practiced without these specific details. Moreover, in the following description, descriptions of well-known structures and techniques are omitted so as to not unnecessarily obscure the concepts of the present disclosure.
The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. The terms "comprises," "comprising," and the like, as used herein, specify the presence of stated features, steps, operations, and/or components, but do not preclude the presence or addition of one or more other features, steps, operations, or components.
All terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art unless otherwise defined. It is noted that the terms used herein should be interpreted as having a meaning that is consistent with the context of this specification and should not be interpreted in an idealized or overly formal sense.
Where a convention analogous to "at least one of A, B and C, etc." is used, in general such a construction is intended in the sense one having skill in the art would understand the convention (e.g., "a system having at least one of A, B and C" would include but not be limited to systems that have a alone, B alone, C alone, a and B together, a and C together, B and C together, and/or A, B, C together, etc.).
The terms appearing in the present disclosure are explained first:
monitoring the whole link: the industry also refers to APM (Application Performance Management, APM) Application Performance Management or distributed tracking, belongs to the field of IT operation and maintenance Management, and mainly aims at monitoring and optimizing the IT Application Performance and user experience of enterprise key services to improve the reliability and quality of enterprise IT applications. Due to the adoption of the distributed tracking technology, research and development and operation and maintenance personnel can better master the calling condition between the nodes, the problems on the line can be more efficiently and conveniently solved, and the possibility is provided for full-link monitoring. For example, a transaction link passes through 4 nodes deployed in different network spaces: the method comprises the steps of calling b, calling c, calling d, and before the distributed tracking technology appears, the transaction link is combed only by analyzing a log file, and the method is very inefficient. The distributed tracking technology is characterized in that monitoring logic is added in a, b, c and d to intercept a request, a link id number (traceid) is generated after the node a intercepts the request, and the traceid is transmitted downwards along with the request, so that the whole link is connected in series. Thus a, b, c. d, monitoring logic needs to be added to all the four nodes, on one hand, links are connected in series, on the other hand, some key indexes are counted (for example, the monitoring logic of the node b can calculate the stay time of a request on the node b, namely the average response time of the node b, and the average response time is very critical to finding out a performance bottleneck in the link), and the performance bottleneck is reported to a cloud for analysis and display.
Invasive data acquisition: the monitoring data acquisition logic needs to invade codes of monitored objects (application programs), zipkin is adopted in the industry, the application programs need to rely on a related SDK when needing to support APM, when the actual programs run, the data acquisition logic in the SDK acquires link monitoring data, and the application is more convenient to expand in an SDK mode (namely a jar packet), and the application can be expanded and programmed based on a program interface in the SDK, such as the control of monitored objects, ranges, granularities and the like. However, the intrusive method has an obvious disadvantage that each time the SDK is upgraded, the application program needs to be modified and re-deployed, which is high in cost and inflexible for large-scale application.
Non-invasive data acquisition: usually, Java agent technology is adopted, an application program does not need to be modified, but a start parameter is configured, and when the parameter is started, bytecode augmentation technology is used to weave monitoring logic into (attach) target processes, so that the purpose of monitoring is achieved. When the version is upgraded, only the version number corresponding to the Java agent in the startup parameters needs to be modified by the application. However, the byte code enhancement technology has relatively high requirements on the technical level of programmers and is easy to make mistakes. Moreover, the non-invasive method is not as flexible as the SDK method, and the application cannot be extended and programmed.
When an enterprise actually monitors an APM full link, two monitoring data acquisition schemes, namely an invasive data acquisition scheme and a non-invasive data acquisition scheme, may be simultaneously selected according to different applications. Some applications with expansion requirements use an invasive SDK, while applications sensitive to version upgrade tend to use a non-invasive scheme (Java agent) in parallel, which may cause problems, including the concatenation of links and the unification of monitoring data models. The first problem is relatively easy to solve, and it is only necessary to follow the same transmission protocol, for example, the b3 protocol commonly used in the industry, such as http request, the traceid is put in the request header of http in the form of key-value (http header), and the naming of key follows the naming specification of b3 protocol, such as traceid, and is named as: X-B3-TRACEID, so that whether invasive or non-invasive, they generate and retrieve TRACEIDs, just operate X-B3-TRACEID in http header, links can be concatenated. For the second problem, the difficulty is often large because the data standard of full link monitoring (APM) is not unified yet, and the difference between the non-intrusive scheme and the intrusive scheme is large on the data model, for example, the intrusive scheme zipkin has its own set of data model, and the non-intrusive skywalk and pinpoint have their own data models. This results in the monitoring data that different schemes collected, can't unify storage, analysis, processing in the cloud.
Based on the above technical problem, an embodiment of the present disclosure provides a full link monitoring method, including: generating tracking identification information in response to a service request of a user; generating span identification information at each service call, wherein the span identification information comprises a father node span id, a current node span id and call time information; generating link monitoring data according to the tracking identification information and at least one piece of span identification information; collecting the link monitoring data; and determining a complete link according to the collected link monitoring data, wherein the collecting of the link monitoring data comprises: determining a gateway cluster according to the source of the link monitoring data, wherein the gateway cluster is used for receiving the link monitoring data; converting the link monitoring data according to a preset data model to generate target data; and saving the target data to a database through message middleware.
Fig. 1 schematically illustrates an application scenario diagram of a full link monitoring method, apparatus, device, storage medium and program product according to an embodiment of the disclosure. Fig. 2 schematically illustrates an architecture diagram of full link monitoring according to an embodiment of the present disclosure, and it should be noted that the application scenario illustrated in fig. 1 and the architecture diagram illustrated in fig. 2 are only examples of an application scenario and a system architecture that can be used in the embodiment of the present disclosure to help those skilled in the art understand the technical content of the present disclosure, but do not mean that the embodiment of the present disclosure may not be used in other devices, systems, environments or scenarios. It should be noted that the full-link monitoring method and apparatus provided by the embodiment of the present disclosure may be used in the related aspects of the cloud computing technology field and the financial field, and may also be used in any field other than the financial field.
As shown in fig. 1, an application scenario 100 according to this embodiment may include a full link monitoring scenario for an application. The network 104 serves as a medium for providing communication links between the terminal devices 101, 102, 103 and the server 105. Network 104 may include various connection types, such as wired, wireless communication links, or fiber optic cables, to name a few.
The user may use the terminal devices 101, 102, 103 to interact with the server 105 via the network 104 to receive or send messages or the like. The terminal devices 101, 102, 103 may have various client applications installed thereon, such as a shopping-like application, a web browser application, a search-like application, an instant messaging tool, a mailbox client, social platform software, etc. (by way of example only).
The terminal devices 101, 102, 103 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 105 may be a server providing various services, such as a background management server (for example only) providing support for websites browsed by users using the terminal devices 101, 102, 103. The background management server can analyze and process the received data such as the user request and the like, and report the processing result to the cloud for analysis and display (for example, monitoring a call link for the request information of the user, and counting key index parameters).
It should be noted that the full link monitoring method provided by the embodiment of the present disclosure may be generally executed by the server 105. Accordingly, the full link monitoring apparatus provided by the embodiments of the present disclosure may be generally disposed in the server 105. The full link monitoring method provided by the embodiment of the present disclosure may also be performed by a server or a server cluster that is different from the server 105 and is capable of communicating with the terminal devices 101, 102, 103 and/or the server 105. Accordingly, the full link monitoring apparatus provided by the embodiment of the present disclosure may also be disposed in a server or a server cluster different from the server 105 and capable of communicating with the terminal devices 101, 102, 103 and/or the server 105.
It should be understood that the number of terminal devices, networks, and servers in fig. 1 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
As shown in fig. 2, different application nodes adopt different data acquisition schemes (Java agent or SDK), and if the monitoring data are directly sent to the message middleware, due to different formats or data structures of the monitoring data, the subsequent operation and maintenance platform cannot process the data in a unified manner, so in the present disclosure, a layer of data conversion gateway is built at a server side for collecting data, and data of different models are converted and compatible. Specifically, different types of gateways are set according to different initial data models, for example, the gateway cluster 1 receives data acquired through a skywalk non-intrusive scheme, and converts a data model of the non-intrusive scheme into a uniform data model according to a preset data model structure; the gateway cluster 2 receives data collected by the zipkin sdk, and converts a data model of an invasive scheme into a uniform data model according to a preset data model structure. After the architecture is adopted, regardless of an invasive scheme or a non-invasive scheme, and regardless of which open source product is adopted, the collected data are reported to the unified gateway by using an http protocol, and the data are sent to the message middleware after being uniformly processed, wherein the message middleware can be kafka, for example. The data collection cluster consumes data from kafka and warehouses (e.g., an ES database). And the operation and maintenance platform or the monitoring platform in the enterprise can inquire the complete link from the database.
The full link monitoring method of the disclosed embodiment will be described in detail with fig. 3 to 7 based on the scenario described in fig. 1 and the system architecture described in fig. 2.
Fig. 3 schematically illustrates a flow chart of a full link monitoring method according to an embodiment of the disclosure. Fig. 4 schematically shows a flow chart of a process of collecting link monitoring data according to an embodiment of the present disclosure.
As shown in fig. 3, the full link monitoring method of this embodiment includes operations S210 to S250. Wherein, the operations S210 to S230 are a generation process of the link monitoring data.
In operation S210, tracking identification information is generated in response to a service request of a user.
In one example, in a complex microservice architecture, each front-end request forms a complex distributed service invocation link. When a user initiates a service request at a front end, the service request may be, for example, a data access request, and may be a transaction request, and the web server or the gateway generates a tracking identifier, i.e., a traceId, also called a link id, in response to the service request initiated by the user, so as to mark a link, where one request uniquely corresponds to one tracking identifier.
In operation S220, span identification information is generated at each service invocation, wherein the span identification information includes a parent node span id, a current node span id, and invocation time information. In operation S230, link monitoring data is generated according to the trace identification information and at least one of the span identification information.
In one example, at each link call, which may be RPC or DB, a span identification information, i.e. span, is created, and is usually identified by a 64-bit id, the span identification information further includes other data, such as description information, timestamp information for recording the call time, tag information of key-value pair, and parent span id, and the parent span id is used to indicate the source of the span call link, i.e. the caller of the current node. Likewise, the current node may also serve as the parent node for the called node. If a node has no parent, it is called a root span, and all spans are hung on a trace of a feature, sharing a traceId. And transmitting the traceId and the spanId through each request in the whole calling process, taking the traceId and the spanId attached to the request as parentSpanId by each service, and recording the self-generated spanId. According to the parent node span id (parentsspanid) and the current node span id (spanid), the calling relationship of each node can be determined, so that the whole complete calling link is determined, and full link monitoring is realized. And acquiring the link monitoring data after generating the link monitoring data according to the tracking identification information and at least one piece of span identification information.
In operation S240, the link monitoring data is collected. The acquisition process as shown in fig. 4 includes operations S241 to S243.
In operation S241, a gateway cluster is determined according to a source of the link monitoring data, where the gateway cluster is configured to receive the link monitoring data.
In one example, link monitoring data of different data models are acquired by using different acquisition schemes and sent to corresponding gateway clusters, for example, gateway cluster 1 receives data acquired through zipkin sdk, gateway cluster 2 receives data acquired through skywalking non-intrusive scheme, and gateway cluster 3 receives data acquired through pinpoint non-intrusive scheme. The gateway using the packet isolation has the advantage of being capable of flexibly performing scaling according to the data processing pressure monitored by the intrusive and non-intrusive gateway actual links, which can be seen in particular from operation S310 to operation S330 shown in fig. 6.
In operation S242, the link monitoring data is converted according to a preset data model to generate target data.
According to an embodiment of the present disclosure, the preset data model includes link information, timestamp information, application project information, and custom fields.
In one example, the preset data model includes the following fields: link ID, phase ID, parent phase ID, timestamp information, application name, cluster name, phase type, phase name, IP address, port number, container instance ID, error code, error information, and custom field. Wherein, link id (traceid) is used to mark each link, and a request is a link; the stage id (span id) is used to mark the id of a certain stage (or called a certain link) in the link, for example, a calls b, which is a link in the link; parent phase ID, parentSpanId is the spanId of the last phase in the link. Phase type, kind, has four categories: cs (client send), sr (server receive), ss (server send), and cr (client receive). For example, a calls b, a sends a piece of monitoring data after the request is sent, and the data is cs; b, sending a piece of monitoring data when the request is received, wherein the received time is sr; b, immediately performing service logic processing, and returning to the step a after the processing is finished, wherein the step b is ss; a receives the response of b, which is cr. Through these four phases, a call can be clearly described.
The name of the phase, Span name, Span, if http call, http method + http uri (such as get/xxx/user/123), if microservice, service interface name (such as com. xxx. userservice/query); and the IP address represents the address of the client terminal if the IP address is monitoring data sent by the client terminal, and represents the address of the server terminal if the IP address is the monitoring data sent by the server terminal. (the client and server are relative concepts, for example, b calls c, b is the client and c is the server, but b is called a, in the span from a to b, b is the server and a is the client).
Converting the received monitoring data obtained in operation S241 according to the preset data model, processing the converted monitoring data to generate target data in a uniform format, and specifically determining a value corresponding to the field name according to the link monitoring data and the field name in the preset data model. It should be noted that, different data models and data structures in different acquisition schemes are different, corresponding mapping relationships during data conversion are also different, data conversion logics are different, and the data conversion logics are preset according to an initial data model and a target data model.
In operation S243, the target data model is saved in a database through message middleware.
In one example, the target data model generated in operation S242 is sent to message middleware, which may be kafka or other message middleware products, the data collection cluster serves as a consumer, and data of the consumption kafka is stored in a database, which may be an ES database, for example.
In operation S250, a complete link is determined according to the collected link monitoring data.
In one example, the operation and maintenance platform or the monitoring platform may query a complete link based on the ES database, may determine a plurality of query conditions according to a field of a preset data model, for example, may query by application, query by application cluster, query by interface name, query by link ID, and the like, may determine time consumption of each environment (span) according to a recorded timestamp, and may also find more detailed information, such as container ID, error information, ip address, and the like, in each span in a specific query, including a field reported by a user in a customized manner, so as to implement Java program link tracking in parallel with a non-intrusive and an intrusive scheme.
According to the full link monitoring method provided by the embodiment of the disclosure, tracking identification information is generated according to a service request of a user and is used for marking each link; generating span identification information during each service call, wherein the span identification information comprises a father node span id, a current node span id and call time information, and determining a service call relation according to the father node span id and the current node span id; when the link monitoring data are collected, the gateway cluster is determined according to the source of the link monitoring data, the link monitoring data are converted according to a preset data model, uniform target data are generated, technical differences of client data collection are shielded, and consumption data can be uniformly consumed at a server side, uniformly stored in a warehouse, uniformly processed, displayed and analyzed; the target data are analyzed, so that the complete link and the response time of each link can be determined, and the monitoring of the full link is realized.
Fig. 5 schematically illustrates a flow chart of another full link monitoring method according to an embodiment of the disclosure. As shown in fig. 5, operation S241 includes operations S2411 to S2412. It should be noted that the execution sequence of operations S2411 and S2412 is not particularly limited.
In operation S2411, when it is determined that the source of the link monitoring data is data collected by the intrusive scheme, it is determined that the gateway cluster is the first data conversion gateway cluster. In operation S2412, when it is determined that the source of the link monitoring data is data collected by the non-intrusive scheme, it is determined that the gateway cluster is the second data conversion gateway cluster.
In one example, since the structure of the link monitoring data model is related to the data acquisition scheme, different acquisition schemes correspond to link monitoring data of different data models, a corresponding gateway cluster is determined according to the source of the link monitoring data, and when the source of the link monitoring data is determined to be data acquired by the intrusive scheme, the gateway cluster is determined to be a first data conversion gateway cluster, for example, the gateway cluster 1 receives data acquired by the intrusive scheme zipkin sdk; when determining that the source of the link monitoring data is data acquired by the non-intrusive scheme, determining that the gateway cluster is a second data conversion gateway cluster, where it should be noted that different non-intrusive schemes also have different data models, and correspondingly, the second data conversion gateway cluster is different, for example, the gateway cluster 2 receives data acquired by the skywalking non-intrusive scheme, and the gateway cluster 3 receives data acquired by the pinpoint non-intrusive scheme. The gateway cluster is isolated according to the link monitoring data source, on one hand, because of different requirements of data conversion logics, and on the other hand, expansion is facilitated according to actual service conditions.
Preferably, the ip address may be pre-allocated according to the type of the link monitoring data, and the corresponding gateway cluster is reported through an http protocol. The data can be data reported by a Java process or data reported by other languages or technical stacks, and only a gateway for corresponding data conversion needs to be compiled and deployed.
The method can be expanded, and the gateway cluster can be expanded according to the size of the link monitoring data volume. Fig. 6 schematically shows a flowchart of a method for scaling a gateway cluster according to a link monitoring data volume according to an embodiment of the present disclosure. As shown in fig. 6, the method specifically includes operations S310 to S330.
In operation S310, the gateway cluster is scaled according to the size of the link monitoring data volume. In operation S320, if it is determined that the amount of the link monitoring data is greater than the first preset threshold, it is determined to perform capacity expansion on the gateway cluster corresponding to the link monitoring data. In operation S330, if it is determined that the link monitoring data amount is smaller than a second preset threshold, it is determined to perform capacity reduction on the gateway cluster corresponding to the link monitoring data.
In an example, the scale of the gateway cluster may be adjusted according to the size of the link monitoring data volume, when an application transaction volume is large or user request data is large, the corresponding link monitoring data volume is inevitably increased, when the application transaction volume is larger than a first preset threshold, the scale of the gateway cluster needs to be expanded in order to ensure the data processing capability of the gateway, and when the application transaction volume is smaller than a second preset threshold, the scale of the gateway cluster may be reduced in order to save system resources, where the first preset threshold and the second preset threshold may be determined according to an actual pressure test and an actual service requirement, and are not specifically limited herein. The gateway cluster scale is adjusted according to the actual link monitoring data processing pressure of the invasive and non-invasive gateways, and the deployment is more flexible.
The gateway cluster can be deployed in a scalable manner for applications with large transaction volume (the single application usually only selects one scheme from invasive or non-invasive), and the gateway cluster can be deployed by application grouping independently, namely, different applications correspond to different gateway clusters.
Based on the full link monitoring method, the disclosure also provides a full link processing device. The apparatus will be described in detail below with reference to fig. 7.
Fig. 7 schematically shows a block diagram of a full link monitoring apparatus according to an embodiment of the present disclosure.
As shown in fig. 7, the full link monitoring apparatus 600 of this embodiment includes a first generation module 610, a second generation module 620, a third generation module 630, an acquisition module 640, and a processing module 650.
The first generating module 610 is configured to generate tracking identification information in response to a service request of a user. In an embodiment, the first generating module 610 may be configured to perform the operation S210 described above, which is not described herein again.
The second generation module 620 is configured to generate span identification information at each service call, where the span identification information includes a parent node span id, a current node span id, and timestamp information. In an embodiment, the second generating module 620 may be configured to perform the operation S220 described above, which is not described herein again.
The third generating module 630 is configured to generate link monitoring data according to the tracking identification information and at least one of the span identification information. In an embodiment, the third generating module 630 may be configured to perform the operation S230 described above, which is not described herein again.
The collecting module 640 is used for collecting the link monitoring data. In an embodiment, the collecting module 640 may be configured to perform the operation S240 described above, which is not described herein again.
And the processing module 650 is configured to determine a complete link according to the collected link monitoring data. In an embodiment, the processing module 650 may be configured to perform the operation S250 described above, which is not described herein again.
According to the embodiment of the present disclosure, the acquisition module 640 further includes a determination submodule 641, a conversion submodule 642 and a storage submodule 643.
The determining submodule 641 is configured to determine a gateway cluster according to a source of the link monitoring data, where the gateway cluster is configured to receive the link monitoring data. In an embodiment, the determining submodule 641 may be configured to perform the operation S241 described above, and is not described herein again.
The conversion sub-module 642 is configured to convert the link monitoring data according to a preset data model to generate target data. In an embodiment, the converting submodule 642 may be configured to perform the operation S242 described above, and is not described herein again.
The storage sub-module 643 is configured to save the target data to the database through the message middleware. In an embodiment, the storage submodule 643 may be configured to execute the operation S243 described above, and is not described herein again.
According to an embodiment of the present disclosure, any plurality of the first generation module 610, the second generation module 620, the third generation module 630, the acquisition module 640, and the processing module 650 may be combined and implemented in one module, or any one of them may be split into a plurality of modules. Alternatively, at least part of the functionality of one or more of these modules may be combined with at least part of the functionality of the other modules and implemented in one module. According to an embodiment of the present disclosure, at least one of the processing module 610, the converting module 620, the storing module 630 and the querying module 640 may be implemented at least partially as a hardware circuit, such as a Field Programmable Gate Array (FPGA), a Programmable Logic Array (PLA), a system on a chip, a system on a substrate, a system on a package, an Application Specific Integrated Circuit (ASIC), or may be implemented in hardware or firmware in any other reasonable manner of integrating or packaging a circuit, or in any one of or a suitable combination of software, hardware and firmware. Alternatively, at least one of the first generation module 610, the second generation module 620, the third generation module 630, the acquisition module 640 and the processing module 650 may be at least partially implemented as a computer program module, which when executed, may perform a corresponding function.
Fig. 8 schematically illustrates a block diagram of an electronic device adapted to implement a full link monitoring method according to an embodiment of the disclosure.
As shown in fig. 8, an electronic apparatus 900 according to an embodiment of the present disclosure includes a processor 901 which can perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)902 or a program loaded from a storage portion 908 into a Random Access Memory (RAM) 903. Processor 901 may comprise, for example, a general purpose microprocessor (e.g., a CPU), an instruction set processor and/or associated chipset, and/or a special purpose microprocessor (e.g., an Application Specific Integrated Circuit (ASIC)), among others. The processor 901 may also include on-board memory for caching purposes. The processor 901 may comprise a single processing unit or a plurality of processing units for performing the different actions of the method flows according to embodiments of the present disclosure.
In the RAM 903, various programs and data necessary for the operation of the electronic apparatus 900 are stored. The processor 901, the ROM 902, and the RAM 903 are connected to each other through a bus 904. The processor 901 performs various operations of the method flows according to the embodiments of the present disclosure by executing programs in the ROM 902 and/or the RAM 903. Note that the programs may also be stored in one or more memories other than the ROM 902 and the RAM 903. The processor 901 may also perform various operations of the method flows according to embodiments of the present disclosure by executing programs stored in the one or more memories.
Electronic device 900 may also include input/output (I/O) interface 905, input/output (I/O) interface 905 also connected to bus 904, according to an embodiment of the present disclosure. The electronic device 900 may also include one or more of the following components connected to the I/O interface 905: an input portion 906 including a keyboard, a mouse, and the like; an output section 907 including components such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage portion 908 including a hard disk and the like; and a communication section 909 including a network interface card such as a LAN card, a modem, or the like. The communication section 909 performs communication processing via a network such as the internet. The drive 910 is also connected to the I/O interface 905 as necessary. A removable medium 911 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 910 as necessary, so that a computer program read out therefrom is mounted into the storage section 908 as necessary.
The present disclosure also provides a computer-readable storage medium, which may be contained in the apparatus/device/system described in the above embodiments; or may exist separately and not be assembled into the device/apparatus/system. The computer-readable storage medium carries one or more programs which, when executed, implement the method according to an embodiment of the disclosure.
According to embodiments of the present disclosure, the computer-readable storage medium may be a non-volatile computer-readable storage medium, which may include, for example but is not limited to: a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present disclosure, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. For example, according to embodiments of the present disclosure, a computer-readable storage medium may include the ROM 902 and/or the RAM 903 described above and/or one or more memories other than the ROM 902 and the RAM 903.
Embodiments of the present disclosure also include a computer program product comprising a computer program containing program code for performing the method illustrated in the flow chart. When the computer program product runs in a computer system, the program code is used for causing the computer system to realize the full link monitoring method provided by the embodiment of the disclosure.
The computer program performs the above-described functions defined in the system/apparatus of the embodiments of the present disclosure when executed by the processor 901. The above described systems, devices, modules, units, etc. may be implemented by computer program modules according to embodiments of the present disclosure.
In one embodiment, the computer program may be hosted on a tangible storage medium such as an optical storage device, a magnetic storage device, or the like. In another embodiment, the computer program may also be transmitted, distributed in the form of a signal on a network medium, and downloaded and installed through the communication section 909 and/or installed from the removable medium 911. The computer program containing program code may be transmitted using any suitable network medium, including but not limited to: wireless, wired, etc., or any suitable combination of the foregoing.
In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 909, and/or installed from the removable medium 911. The computer program, when executed by the processor 901, performs the above-described functions defined in the system of the embodiment of the present disclosure. The systems, devices, apparatuses, modules, units, etc. described above may be implemented by computer program modules according to embodiments of the present disclosure.
In accordance with embodiments of the present disclosure, program code for executing computer programs provided by embodiments of the present disclosure may be written in any combination of one or more programming languages, and in particular, these computer programs may be implemented using high level procedural and/or object oriented programming languages, and/or assembly/machine languages. The programming language includes, but is not limited to, programming languages such as Java, C + +, python, the "C" language, or the like. The program code may execute entirely on the user computing device, partly on the user device, partly on a remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., through the internet using an internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
Those skilled in the art will appreciate that various combinations and/or combinations of features recited in the various embodiments and/or claims of the present disclosure can be made, even if such combinations or combinations are not expressly recited in the present disclosure. In particular, various combinations and/or combinations of the features recited in the various embodiments and/or claims of the present disclosure may be made without departing from the spirit or teaching of the present disclosure. All such combinations and/or associations are within the scope of the present disclosure.
The embodiments of the present disclosure have been described above. However, these examples are for illustrative purposes only and are not intended to limit the scope of the present disclosure. Although the embodiments are described separately above, this does not mean that the measures in the embodiments cannot be used in advantageous combination. The scope of the disclosure is defined by the appended claims and equivalents thereof. Various alternatives and modifications can be devised by those skilled in the art without departing from the scope of the present disclosure, and such alternatives and modifications are intended to be within the scope of the present disclosure.

Claims (10)

1. A full link monitoring method, comprising:
generating tracking identification information in response to a service request of a user;
generating span identification information at each service call, wherein the span identification information comprises a father node span id, a current node span id and call time information;
generating link monitoring data according to the tracking identification information and at least one piece of span identification information;
collecting the link monitoring data; and
determining a complete link according to the collected link monitoring data,
wherein the collecting the link monitoring data comprises:
determining a gateway cluster according to the source of the link monitoring data, wherein the gateway cluster is used for receiving the link monitoring data;
converting the link monitoring data according to a preset data model to generate target data; and
and storing the target data into a database through message middleware.
2. The method of claim 1, wherein the predetermined data model comprises link information, timestamp information, application entry information, and custom fields.
3. The method of claim 2, wherein converting the link monitoring data according to a preset data model to generate target data comprises:
and determining a value corresponding to the field name according to the link monitoring data and the field name in the preset data model.
4. The method of claim 1, wherein determining a gateway cluster from a source of link monitoring data comprises:
when the source of the link monitoring data is determined to be data acquired by an invasive scheme, determining that the gateway cluster is a first data conversion gateway cluster; and
and when the source of the link monitoring data is determined to be the data acquired by the non-intrusive scheme, determining that the gateway cluster is a second data conversion gateway cluster.
5. The method of claim 1, further comprising:
and carrying out expansion and contraction capacity on the gateway cluster according to the size of the link monitoring data volume.
6. The method of claim 5, wherein the scaling the gateway cluster according to the size of the link monitoring data volume comprises:
if the link monitoring data volume is larger than a first preset threshold value, capacity expansion of a gateway cluster corresponding to the link monitoring data is determined; and
and if the link monitoring data volume is smaller than a second preset threshold value, determining to reduce the capacity of the gateway cluster corresponding to the link monitoring data.
7. A full link monitoring apparatus, comprising:
the first generation module is used for responding to a service request of a user and generating tracking identification information;
the second generation module is used for generating span identification information when service is called every time, wherein the span identification information comprises a father node span id, a current node span id and timestamp information;
a third generating module, configured to generate link monitoring data according to the tracking identifier information and the at least one span identifier information;
the acquisition module is used for acquiring the link monitoring data; and
a processing module for determining a complete link according to the collected link monitoring data,
wherein the acquisition module comprises:
the determining submodule is used for determining a gateway cluster according to the source of the link monitoring data, and the gateway cluster is used for receiving the link monitoring data;
the conversion submodule is used for converting the link monitoring data according to a preset data model so as to generate target data; and
and the storage submodule is used for storing the target data into a database through message middleware.
8. An electronic device, comprising:
one or more processors;
a storage device to store one or more programs,
wherein the one or more programs, when executed by the one or more processors, cause the one or more processors to perform the method of any of claims 1-6.
9. A computer readable storage medium having stored thereon executable instructions which, when executed by a processor, cause the processor to perform the method of any one of claims 1 to 6.
10. A computer program product comprising a computer program which, when executed by a processor, implements a method according to any one of claims 1 to 6.
CN202210123570.4A 2022-02-09 2022-02-09 Full link monitoring method, device, equipment, storage medium and program product Pending CN114490268A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210123570.4A CN114490268A (en) 2022-02-09 2022-02-09 Full link monitoring method, device, equipment, storage medium and program product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210123570.4A CN114490268A (en) 2022-02-09 2022-02-09 Full link monitoring method, device, equipment, storage medium and program product

Publications (1)

Publication Number Publication Date
CN114490268A true CN114490268A (en) 2022-05-13

Family

ID=81478848

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210123570.4A Pending CN114490268A (en) 2022-02-09 2022-02-09 Full link monitoring method, device, equipment, storage medium and program product

Country Status (1)

Country Link
CN (1) CN114490268A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115334153A (en) * 2022-08-12 2022-11-11 北京百度网讯科技有限公司 Data processing method and device for service grid
CN116232963A (en) * 2023-02-20 2023-06-06 中银消费金融有限公司 Link tracking method and system
WO2024002232A1 (en) * 2022-07-01 2024-01-04 中兴通讯股份有限公司 Data processing method, apparatus and system, edge server, electronic device, and storage medium

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024002232A1 (en) * 2022-07-01 2024-01-04 中兴通讯股份有限公司 Data processing method, apparatus and system, edge server, electronic device, and storage medium
CN115334153A (en) * 2022-08-12 2022-11-11 北京百度网讯科技有限公司 Data processing method and device for service grid
CN115334153B (en) * 2022-08-12 2023-10-27 北京百度网讯科技有限公司 Data processing method and device for service grid
CN116232963A (en) * 2023-02-20 2023-06-06 中银消费金融有限公司 Link tracking method and system
CN116232963B (en) * 2023-02-20 2024-02-09 中银消费金融有限公司 Link tracking method and system

Similar Documents

Publication Publication Date Title
CN111083225B (en) Data processing method and device in Internet of things platform and Internet of things platform
US10394693B2 (en) Quantization of data streams of instrumented software
CN114490268A (en) Full link monitoring method, device, equipment, storage medium and program product
US8046195B2 (en) Performance testing of enterprise service bus
CN113987074A (en) Distributed service full-link monitoring method and device, electronic equipment and storage medium
US11294740B2 (en) Event to serverless function workflow instance mapping mechanism
US10225375B2 (en) Networked device management data collection
CN109783562B (en) Service processing method and device
CN114090366A (en) Method, device and system for monitoring data
US20220138074A1 (en) Method, electronic device and computer program product for processing data
CN113596078A (en) Service problem positioning method and device
CN115357761A (en) Link tracking method and device, electronic equipment and storage medium
Bielefeld Online performance anomaly detection for large-scale software systems
CN113806169A (en) Method and device for processing business exception
CN113760562A (en) Link tracking method, device, system, server and storage medium
US20230118838A1 (en) Advanced agent instrumentation for opentelemetry implementations
CN112491943A (en) Data request method, device, storage medium and electronic equipment
CN113515271B (en) Service code generation method and device, electronic equipment and readable storage medium
Liu et al. A middleware-based implementation for data integration of remote devices
CN115237399A (en) Method for collecting data, storage medium, processor and engineering vehicle
CN115202973A (en) Application running state determining method and device, electronic equipment and medium
CN114756301A (en) Log processing method, device and system
CN114840718A (en) Link data processing method, device, equipment, storage medium and program product
CN114880321A (en) Service early warning method and device
CN113595795A (en) Network communication method, device, system, equipment and 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