Micro-service dependency relationship processing method and device, equipment and storage medium

By obtaining the link tracking data of the microservice architecture, determining key call information, and generating a topology diagram, the problem of complex microservice dependencies and high storage costs is solved, and the effects of clearly displaying dependencies and reducing storage costs are achieved.

CN118733407APending Publication Date: 2024-10-01MASHANG CONSUMER FINANCE CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202310322952.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-03-29
Publication Date
2024-10-01

AI Technical Summary

Technical Problem

In IT service systems, the dependencies between microservices are complex and difficult to clearly display. As the business scale expands, the number of microservices increases, and the data collected and stored by performance management tools is large, resulting in high storage costs.

Method used

By obtaining link tracking data in the microservice architecture, key call information is determined, a topology diagram is generated, and the dependency relationship between microservices and call interfaces is displayed, thereby reducing the amount of data that needs to be processed and saving storage space.

Benefits of technology

Clearly display the dependencies between microservices, reduce storage costs, control data storage costs, reduce the risk of data loss, and assist in the transformation and upgrade of microservice architecture.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118733407A_ABST
    Figure CN118733407A_ABST
Patent Text Reader

Abstract

The invention provides a micro-service dependency relationship processing method and device, equipment and a storage medium, and the method comprises the steps: obtaining link tracking data between micro-services in a micro-service architecture, the link tracking data comprising a plurality of historical call records of each micro-service, each historical calling record comprises a first micro-service, a second micro-service and first calling interface information, the first micro-service and the second micro-service have a dependency relationship, and the dependency relationship is used for indicating the first micro-service to call the second micro-service through a first calling interface; determining key calling information of each calling interface in the micro-service architecture according to the link tracking data, wherein the key calling information is used for indicating at least one group of micro-services for realizing a dependency relationship through the corresponding calling interface; and according to the key calling information of each calling interface, generating a topological structure chart comprising each micro-service and each calling interface, and displaying the topological structure chart. According to the embodiment of the invention, the dependency relationship between the micro-services can be conveniently displayed, and the storage cost of the micro-service related data is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data processing technology, and in particular to a microservice dependency processing method, apparatus, device and storage medium. Background Art

[0002] The rapid development of the Internet has put forward higher requirements for the high availability and business continuity of information technology (IT) service systems. In the process of IT service system construction, the microservice architecture has been widely used due to its lightweight, flexible, and easy deployment characteristics. In the microservice architecture, there are many microservices in the system, and each microservice is an independent service.

[0003] In the related technology, the performance management tool (Application Performance Management, APM) can be used to implement the functions of microservice performance indicator monitoring and link tracking. However, in the construction of IT service systems, as the business scale continues to expand, the number of microservices continues to increase, and the dependencies between microservices are complicated, and even mesh dependencies appear, making it difficult to clearly know the dependencies between microservices. In addition, when using system performance management tools to monitor microservice performance indicators and track links, the scale of collected data is also getting larger and larger, and the storage cost of calling data between microservices is getting higher and higher. Summary of the invention

[0004] The present application provides a microservice dependency processing method, apparatus, device and storage medium, which is conducive to conveniently displaying the dependency relationship between microservices and reducing the storage cost of microservice-related data.

[0005] In a first aspect, the present application provides a method for processing microservice dependencies, the method comprising: obtaining link tracking data between each microservice in a microservice architecture, the link tracking data comprising multiple historical call records for each microservice, each historical call record comprising a first microservice and a second microservice with a dependency relationship, and first call interface information, the dependency relationship being used to indicate that the first microservice calls the second microservice through the first call interface; determining key call information of each call interface in the microservice architecture based on the link tracking data, the key call information being used to indicate at least one group of microservices that implement the dependency relationship through the corresponding call interface; generating a topology structure diagram including each microservice and each call interface based on the key call information of each call interface, and displaying the topology structure diagram.

[0006] In the second aspect, the present application provides a microservice dependency processing device, which includes: an acquisition module, used to obtain link tracking data between each microservice in a microservice architecture, the link tracking data including multiple historical call records for each microservice, each historical call record including a first microservice and a second microservice with a dependency relationship, and first call interface information, the dependency relationship is used to indicate that the first microservice calls the second microservice through the first call interface; a determination module, used to determine the key call information of each call interface in the microservice architecture according to the link tracking data, the key call information is used to indicate at least one group of microservices that implement the dependency through the corresponding call interface; a generation module, used to generate a topology structure diagram including each microservice and each call interface according to the key call information of each call interface, and display the topology structure diagram.

[0007] In a third aspect, the present application provides an electronic device, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores one or more computer programs executable by the at least one processor, and one or more of the computer programs are executed by the at least one processor so that the at least one processor can execute the above-mentioned microservice dependency processing method.

[0008] In a fourth aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program implements the above-mentioned microservice dependency processing method when executed by a processor / processing core.

[0009] The embodiments provided by the present application first obtain link tracking data between each microservice in a microservice architecture, where the link tracking data includes multiple historical call records for each microservice, where each historical call record includes a first microservice and a second microservice with a dependency relationship, and first call interface information, where the dependency relationship is used to indicate that the first microservice calls the second microservice through the first call interface; secondly, based on the link tracking data, key call information of each call interface in the microservice architecture is determined, where the key call information is used to indicate at least one group of microservices that implement the dependency relationship through the corresponding call interface; finally, based on the key call information of each call interface, a topology structure diagram including each microservice and each call interface is generated, and the topology structure diagram is displayed. Since the microservice dependency processing method of the present application can extract the key call information of each calling interface from the link tracking data between each microservice in the microservice architecture, the key call information is the information obtained after refining the historical call records of each microservice, and includes at least one group of microservices that implement dependencies through calling interfaces. Therefore, it is only necessary to analyze the key call information of each calling interface to obtain the dependencies between each microservice, thereby reducing the amount of data to be processed. Furthermore, since it is only necessary to store the key call information of each calling interface, it is beneficial to save storage space and control the cost of storage space. In addition, by generating a visual topology structure diagram including each microservice and each calling interface, it is helpful to help users clearly understand the dependencies between each microservice in the microservice architecture.

[0010] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present application, nor is it intended to limit the scope of the present application. Other features of the present application will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0011] The accompanying drawings are used to provide a further understanding of the present application and constitute a part of the specification. Together with the embodiments of the present application, they are used to explain the present application and do not constitute a limitation of the present application. The above and other features and advantages will become more apparent to those skilled in the art by describing detailed example embodiments with reference to the accompanying drawings. In the accompanying drawings:

[0012] Figure 1 It is a schematic diagram of the architecture of a performance management tool in the related technology;

[0013] Figure 2 A flowchart of a microservice dependency processing method provided in an embodiment of the present application;

[0014] Figure 3 A schematic diagram of the architecture of a microservice dependency processing system provided in an embodiment of the present application;

[0015] Figure 4 A block diagram of a microservice dependency processing device provided in an embodiment of the present application;

[0016] Figure 5 A block diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0017] In order to enable those skilled in the art to better understand the technical solution of the present application, the exemplary embodiments of the present application are described below in conjunction with the accompanying drawings, including various details of the embodiments of the present application to facilitate understanding, which should be considered as merely exemplary. Therefore, those of ordinary skill in the art should recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of the present application. Similarly, for the sake of clarity and conciseness, the description of well-known functions and structures is omitted in the following description.

[0018] In the absence of conflict, the embodiments of the present application and the features therein may be combined with each other.

[0019] As used herein, the term "and / or" includes any and all combinations of one or more of the associated listed items.

[0020] The terms used herein are only used to describe specific embodiments and are not intended to limit the present application. As used herein, the singular forms "a" and "the" are also intended to include plural forms, unless the context clearly indicates otherwise. It will also be understood that when the terms "including" and / or "made of" are used in this specification, the presence of the features, wholes, steps, operations, elements and / or components is specified, but the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or groups thereof is not excluded. "Connected" or "connected" and similar words are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect.

[0021] Unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by those of ordinary skill in the art. It will also be understood that terms such as those defined in commonly used dictionaries should be interpreted as having a meaning consistent with their meaning in the context of the relevant art and this application, and will not be interpreted as having an idealized or overly formal meaning unless explicitly defined herein.

[0022] In the embodiment of the present application, the microservice architecture is an architecture and organizational method for developing software. In the microservice architecture, each function of the system can correspond to an independent software unit, which can be called a microservice. As an example, when the microservice architecture is applied to the online shopping mall system, the business logic of the online shopping mall system is sorted out and multiple business functions are abstracted. Among them, multiple business functions may include, for example: user services, product services, order services, marketing services, logistics services, advertising services, data analysis services, etc. Each business function can be developed as an independent software unit to obtain corresponding microservices, such as user microservices, product microservices, order microservices, marketing microservices, logistics microservices, advertising microservices, data analysis microservices, etc. Each microservice can be packaged, deployed and upgraded independently to ensure that each microservice has a clear functional division.

[0023] In the microservice architecture, the independence between microservices can be reflected in the following aspects: each microservice can run in its own independent process, can use different data storage technologies, correspond to different databases, and can also be written in different programming languages. The microservice architecture enables the microservices to coordinate and cooperate with each other, and can also perform service management such as circuit breaking, current limiting, and downgrading on each microservice. Among them, service circuit breaking is a protection measure that separates the service from the resources it depends on to prevent system failure when the system is overloaded; service degradation is a method of temporarily blocking the service when the service request times out or resources are insufficient; service current limiting is a method of limiting the flow or function of the system when the system resources are insufficient to cope with a large number of requests.

[0024] In the microservice architecture, each microservice has an independently running process, and the corresponding microservice functions are completed through the process. Each microservice is deployed independently, multiple microservices can be flexibly combined, and access between microservices can be achieved through remote access protocols.

[0025] In some embodiments, the dependency between microservices can be used to indicate whether there is a calling relationship between microservices. As an example, microservice A calls microservice B, that is, the function of microservice A needs to rely on microservice B when it is implemented. In actual application scenarios, the microservice framework of a system is often composed of multiple microservices. When the system is gradually iterated, a service request may need to call multiple microservices, and multiple microservices can call each other, resulting in increasingly complex dependencies between microservices. Therefore, under the microservice architecture, a call request to a microservice often involves calls to other microservices in the system. In order to facilitate problem location, it is necessary to record how many service calls and their call relationships are generated within the microservice for each microservice call request. This process is called link tracking. For ease of understanding, the implementation process of link tracking of microservice call requests is briefly introduced below.

[0026] In some embodiments, the HTTP message header (HEADERS) can be parsed from the microservice call request. Each time a microservice call is made, the following information can be recorded in the HEADERS: call link identifier (TraceId), microservice identifier (SpanId), upstream microservice identifier (parentId), request time (RequestTime) and response time (ResponseTime). Among them, Trace represents the call link, for example, the path of a front-end request of the system through all back-end microservices. Each call link can be identified by a globally unique TraceId. Span represents the microservice called on the call link. Each Span has a unique identifier SpanId, and there is a parent-child relationship between spans. The upstream span is the parent span of the downstream span (identified by ParentID).

[0027] It can be seen that a complete call link of a microservice call request can be formed into a tree structure by connecting a group of spans with the same TraceId (throughout the entire link). In order to realize the link tracking of microservice call requests, when the request reaches the first microservice of the IT service system, a unique TraceId is created for the request. During the entire call process, each microservice called not only needs to record the TraceId, but also needs to record the SpanId and its own ParentID (to determine who its parent Span is), that is: each call to a microservice needs to carry the TraceId, and record its own ParentID and SpanID, so that the parent-child relationship between each microservice on the complete call link of a microservice call request can be organized. When you want to view the complete call link of a microservice call request, you only need to find all the call records of the request according to the TraceId, and then organize the entire call parent-child relationship through the ParentID and SpanId, so that the call records of each microservice on the call link of the request can be connected in series to form a complete request link.

[0028] In the related technology, the functions of microservice performance indicator monitoring and link tracking can be implemented through performance management tools (implementing the link tracking function of the service tracking framework). The current main performance management tools include the open source distributed monitoring system Cat, the call chain analysis tool Zipkin, the performance management tool Pinpoint based on distributed transaction tracking, the link tracking middleware SkyWalking, etc. The following takes the performance management tool Pinpoint as an example to illustrate the specific implementation method of call chain tracking and performance indicator monitoring of microservices in the related technology. It should be understood that the description using Pinpoint as an example cannot be interpreted as limiting the scope or implementation possibility of this solution. The processing method of microservice performance indicator monitoring and link tracking using other application performance management tools other than Pinpoint is basically consistent with the corresponding processing method of Pinpoint.

[0029] Figure 1 A schematic diagram of an application scenario of a performance management tool in related technology is shown. Figure 1 In the application scenario shown, the architecture of the performance management tool Pinpoint includes: a probe (Agent) component 10, a collector (Collector) component 20, a first storage component 30 and a first display (Web User Interface, WebUI) component 40. Figure 1 As shown, the application scenario also includes a business system 50, and the business system 50 includes one or more servers, such as server 1, server 2, ..., server N, where N is an integer greater than or equal to 1.

[0030] In some scenarios, multiple microservices on a microservice architecture may be deployed on one or more servers depending on the processing capabilities of the servers. When multiple microservices are deployed on multiple servers, illustratively, one microservice may be deployed on each server.

[0031] like Figure 1 As shown, the microservices running on each server can be introduced into the probe component 10. The probe component 10 is used to install the probe (agent) by adding a virtual machine (Java Virtual Machine, JVM) parameter based on a computer programming language when the microservice is started in a non-invasive manner (ensuring the integrity of the original program logic of the microservice, and the original program does not need to be modified). Each probe component 10 corresponds to a microservice, and each probe component 10 and the corresponding microservice can be deployed on the same server.

[0032] As an example, when microservice A is started, the probe component 10 can add JVM parameters to the startup command of the corresponding microservice. The JVM parameters include: the path of the Java archive file package (jar package) corresponding to the probe program, the microservice name (applicationName) and the probe identifier (agentId).

[0033] As a specific example:

[0034] The path of the jar package corresponding to the probe program is: "-javaagent: / opt / pinpoint-agent / pinpoint-bootstrap.jar";

[0035] The microservice name is "-Dpinpoint.applicationName=servicea", where servicea represents microservice A;

[0036] The probe identifier is "-Dpinpoint.agentId=servicea-8081".

[0037] In this example, each probe component 10 can be implemented as a probe associated with a microservice.

[0038] The probe component 10 is used to identify the call links of each microservice in the microservice framework through Java bytecode enhancement technology after the microservice corresponding to the probe component 10 is started (for example, by obtaining the call link identifier TraceId of each microservice to identify the corresponding call link), and obtain the link tracking data between each microservice in the microservice framework. The link tracking data may include: the ParentID and SpanID of each microservice on the corresponding call link, and the call records of each microservice are connected in series to form a complete call link to realize link tracking; the probe component 10 is also used to collect performance indicator data of each microservice on the call link, and use the link tracking data and performance indicator data of each microservice on the call link as monitoring data of the corresponding microservice.

[0039] The collection component 20 is used to receive the monitoring data reported by each probe component 10 and send the monitoring data to the first storage component 30. The monitoring data includes: link tracking data and performance indicator data between each microservice in the microservice framework.

[0040] The first storage component 30 is used to receive and store the monitoring data. Exemplarily, the storage component 30 may be a database HBase, and HBase may be in a cluster mode or a stand-alone mode, which is not specifically limited in the embodiments of the present application.

[0041] The first display component 40 is used to read the analyzed and sorted monitoring data of each microservice from the first storage component 30 and display it in the form of a web page.

[0042] In related technologies, Pinpoint, as a performance management tool, collects and stores data mainly including link tracking data and performance indicator data between microservices. In the construction of large-scale IT service systems, as the business scale continues to expand, data traffic and the number of microservices will increase. This will cause the performance management tool to monitor microservice performance indicators and track links. The collected and stored data will grow exponentially, which will lead to higher and higher storage costs, which is not conducive to storage cost control.

[0043] In an embodiment of the present application, a microservice architecture may provide one or more application programming interfaces (APIs) for each microservice. Multiple APIs may be aggregated under the same microservice. Different APIs under the same microservice may be used to implement different services belonging to the microservice. Each API may correspond to a uniform resource locator (URL) path, and the URL path is used to locate the service corresponding to the corresponding API. As an example, the specific services (requesting tokens, authenticating users, etc.) provided by different APIs of the same microservice (for example, all microservices used to perform identity management services) are different. Assuming a microservice named "OAuth" in the microservice architecture, which is a microservice used to perform identity management services, the microservice OAuth may include multiple different types of APIs, such as an API for requesting tokens, an API for authenticating users, and the like.

[0044] In related technologies, performance management tools such as Pinpoint can simply perform dependency analysis between microservices without further analyzing the API level of microservices, making it impossible to determine which API one microservice uses to call another microservice; and as Pinpoint continues to run, its query and analysis performance will significantly decline; in order to maintain Pinpoint's query and analysis performance, Pinpoint's operators and users usually regularly clean up the historical data of each microservice, but this can easily lead to the loss of some dependencies between microservices obtained based on historical data analysis.

[0045] The microservice dependency processing method according to the embodiment of the present application can be executed by an electronic device such as a terminal device or a server, and the terminal device can be a vehicle-mounted device, a user equipment (User Equipment, UE), a mobile device, a user terminal, a terminal, a cellular phone, a cordless phone, a personal digital assistant (Personal Digital Assistant, PDA), a handheld device, a computing device, a vehicle-mounted device, a wearable device, etc. The method can be implemented by a processor calling a computer-readable program instruction stored in a memory. The server may include an independent physical server, a server cluster consisting of multiple servers, or a cloud server capable of cloud computing.

[0046] Figure 2 A flowchart of a method for processing microservice dependencies provided in an embodiment of the present application. Figure 2 , the method may include the following steps.

[0047] S210, obtaining link tracking data between each microservice in the microservice architecture, where the link tracking data includes multiple historical call records of each microservice, each historical call record includes a first microservice and a second microservice with a dependency relationship, and first call interface information, where the dependency relationship is used to indicate that the first microservice calls the second microservice through the first call interface.

[0048] In this step, the first microservice and the second microservice can be any two microservices in the microservice framework of the predetermined business system, or the first microservice can be a microservice of other service systems outside the predetermined business system. In some embodiments, the predetermined business system can be different types of business systems. Exemplarily, different types of business systems include, but are not limited to: communication business systems, e-commerce business systems, social networking site business systems, payment business systems, etc. It should be understood that the types of the above-mentioned predetermined business systems are merely schematic illustrations. In actual application scenarios, the types of predetermined business systems can be flexibly set according to actual needs.

[0049] In some embodiments, link tracking data can be collected by a performance management tool. Figure 1 From the description, it can be seen that the data collected by the performance management tool can include not only link tracking data, but also performance indicator data. The data type is relatively complex, but the embodiment of the present application only needs to obtain the link tracking data between each microservice collected by the performance management tool, thereby ensuring that the data volume is controllable, which is conducive to controlling the cost of data storage.

[0050] S220, determining key call information of each call interface in the microservice architecture according to the link tracking data, where the key call information is used to indicate at least one group of microservices that implement dependency relationships through the corresponding call interface.

[0051] In this step, the link tracking data can be further simplified by extracting the key call information of each call interface, so as to determine at least one group of microservices that realize the dependency relationship through the corresponding call interface. For example, if microservice A (the first microservice) calls microservice B (the second microservice) through the first call interface, it is considered that the dependency relationship between microservice A and microservice B is realized through the first call interface.

[0052] It should be understood that the calling relationship in the embodiment of the present application is unidirectional, and the first microservice calls the second microservice through the first calling interface, wherein the calling relationship is: the first microservice calls the second microservice; wherein the first microservice is an upstream service and the second microservice is a downstream service.

[0053] S230, generating a topology structure diagram including each microservice and each calling interface according to the key calling information of each calling interface, and displaying the topology structure diagram.

[0054] In this step, the topology diagram can intuitively display the dependencies between the microservices realized by calling the interface. In some embodiments, the topology diagram includes multiple service nodes, each service node represents a microservice. As an example, if at least one group of microservices that realize the dependency through the first calling interface is determined to be the first microservice and the second microservice through key calling information, and the dependency indicates that the first microservice calls the second microservice through the first calling interface, then: an edge can be added between the service node corresponding to the first microservice and the service node corresponding to the second microservice, and the edge points from the service node corresponding to the first microservice to the service node corresponding to the second microservice, and the identification information of the first calling interface is added to the edge, and the identification information is used to identify the first calling interface.

[0055] The embodiments provided by the present application first obtain link tracking data between each microservice in a microservice architecture, where the link tracking data includes multiple historical call records for each microservice, where each historical call record includes a first microservice and a second microservice with a dependency relationship, and first call interface information, where the dependency relationship is used to indicate that the first microservice calls the second microservice through the first call interface; secondly, based on the link tracking data, key call information of each call interface in the microservice architecture is determined, where the key call information is used to indicate at least one group of microservices that implement the dependency relationship through the corresponding call interface; finally, based on the key call information of each call interface, a topology structure diagram including each microservice and each call interface is generated, and the topology structure diagram is displayed. Since the microservice dependency processing method of the present application can extract the key call information of each calling interface from the link tracking data between each microservice in the microservice architecture, the key call information is the information obtained after refining the historical call records of each microservice, and includes at least one group of microservices that implement dependencies through calling interfaces. Therefore, it is only necessary to analyze the key call information of each calling interface to obtain the dependencies between each microservice, thereby reducing the amount of data to be processed. Furthermore, since it is only necessary to store the key call information of each calling interface, it is beneficial to save storage space and control the cost of storage space. In addition, by generating a visual topology structure diagram including each microservice and each calling interface, it is helpful to help users clearly understand the dependencies between each microservice in the microservice architecture.

[0056] Combine the following Figure 3 , and continue to take Pinpoint, a performance management tool, as an example to describe in detail the microservice dependency processing method of the embodiment of the present application. The microservice dependency processing method of the embodiment of the present application is applied to a microservice dependency processing system, Figure 3The schematic diagram of the architecture of the microservice dependency processing system of the exemplary embodiment of the present application is shown. Figure 3 and Figure 1 The same structures are labeled the same. Figure 3 As shown in the figure, the architecture of the microservice dependency processing system is similar to Figure 1 The architecture of the performance management tool Pinpoint is basically the same, the difference is that the architecture of the microservice dependency processing system also includes: a data analysis component 31, a second storage component 32, a second display component 33 and an alarm component 34.

[0057] like Figure 1 and Figure 3 As shown, the collection component 20 of the performance management tool can send the monitoring data reported by each probe component 10 to the first storage component 30; wherein the monitoring data includes: link tracking data and performance indicator data between each microservice in the microservice framework.

[0058] Specifically, the collection component 20 of the performance management tool has an existing database write interface, and the collection component 20 of the performance management tool can send the monitoring data to the first storage component 30 through the existing database write interface.

[0059] In an embodiment of the present application, the collection component 20 of the performance management tool may also have a new data transmission interface; the step of obtaining link tracking data between each microservice in the microservice architecture in step S210 may specifically include: receiving the monitoring data sent by the collection component 20 of the performance management tool through the data analysis component 31, and obtaining the link tracking data between each microservice in the microservice architecture from the monitoring data.

[0060] In some embodiments, the data analysis component 31 may store the acquired link tracking data between the microservices in the microservice architecture in the second storage component 32 .

[0061] Exemplarily, the second storage component 32 can be a non-relational database, such as a network-oriented graph database Neo4j, which is a high-performance non-relational (NoSQL) database. Neo4j has the advantages of being embedded, high-performance, and lightweight, and can improve the storage and query efficiency of interface call data. It should be understood that the second database system can also be a relational database such as a database SQL based on structured query language, a database MySQL, etc., which can be specifically set according to actual needs.

[0062] In this embodiment, the collection component 20 of the performance management tool can report the monitoring data to the data analysis component 31 of the microservice dependency processing system. The data analysis component 31 obtains the link tracking data between each microservice in the microservice architecture from the received monitoring data, and stores the link tracking data to the second storage component 32.

[0063] In some embodiments, the collection component 20 of the performance management tool uses an asynchronous transmission method to transmit the monitoring data to the data analysis component 31. The asynchronous transmission method means that the collection component 20 can send the monitoring data to a specified data buffer (not shown in the figure), and transmit the monitoring data in the data buffer to the data analysis component 31 at predetermined intervals and / or when the remaining capacity of the data buffer is less than a predetermined capacity value. Exemplarily, the specified data buffer can be, for example, the memory space of an electronic device, and the electronic device is used to deploy the microservice dependency processing system of the embodiment of the present application.

[0064] In an embodiment of the present application, the data interface of the performance management tool can be modified, and a data transmission interface can be added to the collection component 20 on the basis of the existing database write interface, so that the collection component 20 can report the monitoring data to the data analysis component 31 of the microservice dependency processing system through the data transmission interface, and use the data analysis component 31 to obtain the link tracking data between each microservice in the microservice architecture from the received monitoring data (corresponding to step 210); in this embodiment, the data analysis component 31 can be used to: determine the key call information of each call interface in the microservice architecture based on the link tracking data (corresponding to step S220); the data analysis component 31 can also be used to: store the key call information of each call interface in the microservice architecture in the second storage component 32; the second display component 33 obtains the key call information of each call interface from the second storage component 32, generates a topology structure diagram including each microservice and each call interface, and displays the topology structure diagram (corresponding to step S230).

[0065] In some embodiments, step S220 may specifically include the following steps:

[0066] S11, obtaining a plurality of first target historical call records of calling a target calling interface from a plurality of historical call records, where the target calling interface is any one of the calling interfaces.

[0067] S12: Group the target historical call records having the same first microservice and second microservice among the plurality of first target historical call records into one group, to obtain a plurality of groups of second target historical call records.

[0068] Exemplarily, the target call interface is recorded as interface 1, and the multiple historical call records include, for example: the call record of microservice A calling microservice B through interface 1; and the historical call record of microservice A calling microservice C through interface 1, etc. Then, at least one call record of microservice A calling microservice B through interface 1 can be divided into one group, and at least one call record of microservice A calling microservice C through interface 1 can be divided into another group, thereby obtaining multiple groups of second target historical call records, in each group of second target historical call records, the upstream microservice and the downstream microservice are the same.

[0069] S13, acquiring multiple sets of second target historical call records of each calling interface, and generating key call information of each calling interface according to the multiple sets of second target historical call records of each calling interface.

[0070] Exemplarily, each set of second target historical call records of each calling interface includes at least the following information: a first microservice field, a second microservice field, a calling interface field, and a calling time field. Specifically, the first microservice field may be a microservice name or a microservice identifier, the calling interface field may be a URL path of the interface (used to locate the service function corresponding to the interface), and the calling time field is used to indicate the time when the calling interface was called.

[0071] Through the above steps S11-S13, the historical call records of any calling interface can be obtained from the multiple historical call records of each microservice contained in the link tracking data, and the historical call records can be grouped to group the historical call records of the same first microservice and the second microservice into one group, thereby providing a data basis for subsequently generating key call information of the corresponding calling interface according to each group of historical call records of each calling interface.

[0072] Illustratively, Table 1 shows a specific example of field data in a set of second target historical call records.

[0073] Table 1

[0074] First microservice name Second microservice name URL path corresponding to the interface Call time Microservice A Microservice B / v1 / api / test1 2022-11-01 12:00:00 Microservice A Microservice B / v1 / api / test1 2022-11-01 12:00:01 Microservice A Microservice B / v1 / api / test1 2022-11-01 12:00:02

[0075] It can be seen from Table 1 that for the API corresponding to the URL path " / v1 / api / test1", key call information can be extracted from multiple groups of second target historical call records shown in Table 1 (target historical call records with the same first microservice (microservice A) and second microservice (microservice B)).

[0076] In some embodiments, in S13, the step of generating key call information of each calling interface according to multiple sets of second target historical call records of each calling interface may specifically include:

[0077] S21, for each calling interface, obtain the preset field value of each second target historical call record in each group of second target historical call records; S22, generate a key call information record according to the preset field value of each second target historical call record, wherein each group of second target historical call records corresponds to a key call information record, each key call information record includes a preset field, and the field value of the preset field is the preset field value in the corresponding group of second target historical call records.

[0078] In this embodiment, for each calling interface, preset field values ​​can be extracted from each group of second target historical call records of the calling interface, and a key call information record can be generated based on the extracted preset field values. Based on the extraction of the preset field values ​​and the generation of the corresponding key call information records, data analysis, aggregation and integration of the historical call records of each calling interface in the microservice framework can be achieved, thereby improving data processing efficiency.

[0079] In some embodiments, the preset fields include at least one of the following: a first microservice field, a second microservice field, a call interface field, an interface call times field, and a last call time field.

[0080] Exemplarily, Table 2 shows specific examples of preset field values ​​of the second target historical call record.

[0081] Table 2

[0082]

[0083] In some embodiments, for a key call information record generated according to a preset field value of a second target historical call record, the key call information record can be stored in a second storage component (such as Figure 3 The second storage component 32 shown in the figure) can be used as the identification information of the key call information record to cache, calculate and update the interface call data in the second storage component 32.

[0084] In some embodiments, at least a portion of the key call information that meets the predetermined information acquisition condition can be obtained from all the key call information of each call interface to generate a topology diagram including each microservice and each call interface; wherein the predetermined information acquisition condition is that the last call time is within a predetermined time range. The predetermined time range can be customized according to actual needs and is not specifically limited in the embodiments of the present application.

[0085] In some embodiments, after step S230, the microservice dependency processing method further includes the following steps:

[0086] S31, when a first selection operation on a second calling interface in the topology diagram is detected, key calling information of the second calling interface is displayed.

[0087] Exemplarily, in the topology diagram, the service node corresponding to microservice A and the service node corresponding to microservice B are connected by an edge, which points from the service node corresponding to microservice A to the service node corresponding to microservice B, and the identification information of the second calling interface (for example, the URL path of the first calling interface) is added to the edge. In response to the selection operation of the identification information of the second calling interface, the above-mentioned key calling information of the calling interface can be displayed.

[0088] S32, when detecting a second selection operation for the second calling interface, determining whether the number of calls of the second calling interface meets a first preset condition, the first preset condition being that the number of calls is greater than a preset threshold.

[0089] S33: If the number of calls of the second calling interface does not meet the first preset condition, determine that the second calling interface is in a state where it is allowed to go offline, and highlight the second calling interface after going offline in the topology diagram.

[0090] Exemplarily, there may be a variety of ways of highlighting, such as red font display, yellow highlight display, bold display, etc., which are not specifically limited in the embodiments of the present application.

[0091] In this embodiment, a call interface can be selected in the topology map to display the corresponding key call information. For the selected call interface, it can be determined whether to offline the call interface according to whether the number of calls of the call interface meets the first preset condition. Among them, the first preset condition is that the number of calls is greater than the preset threshold. If the number of calls of the second call interface is not greater than the preset threshold, it indicates that the second call interface is not used frequently. At this time, the second call interface can be offline to avoid wasting resources.

[0092] Exemplarily, the preset threshold may be a value such as 100, 500, 1000, etc., and may be set according to actual needs, and is not specifically limited in the embodiments of the present application.

[0093] In some embodiments, if the number of calls to the second calling interface does not meet the first preset condition, the step of determining in S33 that the second calling interface is in a state that allows offline operation may specifically include: S41, determining whether the last call time of the second calling interface meets the second preset condition, the second preset condition being the interval between the last call time and the current time, which is less than the preset interval; S42, if the last call time of the second calling interface does not meet the second preset condition, determining that the second calling interface is in a state that allows offline operation.

[0094] Among them, the second preset condition is the interval between the last call time and the current time, which is less than the preset time. If the interval between the last call time and the current time of the second calling interface is greater than the preset time, it means that the second calling interface has not been used for a long time. At this time, the second calling interface can be offline to avoid wasting resources.

[0095] Exemplarily, the preset duration may be 6 months, 3 months, 1 month, 15 days, etc., and may be set according to actual needs, and the embodiments of the present application do not make any specific limitations.

[0096] In this embodiment, if the number of calls of the calling interface does not meet the corresponding condition, it can be further determined whether to take the calling interface offline based on whether the deactivation time of the calling interface meets the second preset condition.

[0097] In some embodiments, the microservice dependency processing method may further include: when a replacement notification for a third calling interface is detected, generating an alarm rule, the replacement notification is sent by any first microservice that can call the third calling interface, and the alarm rule is used to prompt other first microservices that can call the third calling interface, the remaining usage time of the third calling interface, and the fourth calling interface used to replace the third calling interface.

[0098] like Figure 3 As shown, the alarm component 34 in the microservice dependency processing system can be used to generate alarm rules. For example, it is assumed that both microservice A and microservice C can call microservice B by calling the third call interface, and the URL path of the third call interface is, for example, " / v1 / api1"; if microservice B already has a new call interface, recorded as the fourth call interface, the URL path of the fourth call interface is " / v2 / api2", and the third call interface will be invalid at the end of next month, then when the replacement notification for the third call interface issued by microservice A is detected, an alarm rule can be generated, and the alarm rule is used to prompt microservice C, and the prompt content includes: the remaining usage time of the third call interface, and the URL path of the fourth call interface that will replace the third call interface.

[0099] According to the embodiments of the present application, the amount of data that needs to be processed in the link tracking data can be reduced, so that the amount of data that needs to be stored can also be reduced accordingly, which is beneficial to controlling the cost of the corresponding storage space. When the amount of data is reduced and the storage space cost is controllable, the probability of deleting historical call records can be reduced, thereby reducing the risk of missing required data when processing microservice dependencies; and, according to the method, the topological structure diagram of each microservice and each calling interface in the microservice framework can be conveniently and quickly displayed. During the upgrade or transformation of each calling interface in the microservice architecture, alarm rules are generated for the calling interface that needs to be replaced, assisting the transformation and upgrade of the calling interface in the microservice architecture.

[0100] It can be understood that the above-mentioned various method embodiments mentioned in this application can be combined with each other to form a combined embodiment without violating the principle logic. Due to space limitations, this application will not go into details. Those skilled in the art can understand that in the above-mentioned method of the specific implementation method, the specific execution order of each step should be determined by its function and possible internal logic.

[0101] In addition, the present application also provides a microservice dependency processing device, an electronic device, and a computer-readable storage medium, all of which can be used to implement any microservice dependency processing method provided by the present application. The corresponding technical solutions and descriptions are referred to in the corresponding records of the method part and will not be repeated here.

[0102] Figure 4 A block diagram of a microservice dependency processing device provided in an embodiment of the present application. Figure 4 , an embodiment of the present application provides a microservice dependency processing device 400, and the microservice dependency processing device 400 may include the following modules.

[0103] An acquisition module 410 is used to acquire link tracking data between microservices in a microservice architecture, where the link tracking data includes multiple historical call records of each microservice, where each historical call record includes a first microservice and a second microservice having a dependency relationship, and first call interface information, where the dependency relationship indicates that the first microservice calls the second microservice through the first call interface;

[0104] A determination module 420 is used to determine key call information of each call interface in the microservice architecture according to the link tracking data, where the key call information is used to indicate at least one group of microservices that realize dependency relationships through the corresponding call interface;

[0105] The generation module 430 is used to generate a topology structure diagram including each microservice and each calling interface according to the key calling information of each calling interface, and display the topology structure diagram.

[0106] In some embodiments, the determination module 420 is specifically used to: obtain multiple first target historical call records of calling the target calling interface from multiple historical call records, where the target calling interface is any one of the calling interfaces; divide the target historical call records with the same first microservice and second microservice in the multiple first target historical call records into a group to obtain multiple groups of second target historical call records; obtain multiple groups of second target historical call records for each calling interface, and generate key call information for each calling interface based on the multiple groups of second target historical call records for each calling interface.

[0107] In some embodiments, when the determination module 420 is used to generate key call information of each calling interface based on multiple groups of second target historical call records of each calling interface, it is specifically used to: for each calling interface, obtain the preset field value of each second target historical call record in each group of second target historical call records; generate a key call information record based on the preset field value of each second target historical call record, wherein each group of second target historical call records corresponds to a key call information record, each key call information record includes a preset field, and the field value of the preset field is the preset field value in the corresponding group of second target historical call records.

[0108] In some embodiments, the preset fields include at least one of the following: a first microservice field, a second microservice field, a call interface field, an interface call times field, and a last call time field.

[0109] In some embodiments, the microservice dependency processing device 400 also includes: a display module, which is used to generate a topology structure diagram including each microservice and each calling interface, and after displaying the topology structure diagram, when a first selection operation for a second calling interface in the topology structure diagram is detected, the key calling information of the second calling interface is displayed; a judgment module, which is used to judge whether the number of calls of the second calling interface meets the first preset condition when detecting the second selection operation for the second calling interface, and the first preset condition is that the number of calls is greater than a preset threshold; an offline determination module, which is used to determine that the second calling interface is in an offline state if the number of calls of the second calling interface does not meet the first preset condition; the display module is also used to highlight the second calling interface after going offline in the topology structure diagram.

[0110] In some embodiments, if the number of calls to the second calling interface does not meet the first preset condition, the second calling interface is determined to be in an offline state that allows the user to log off. The judgment module is also used to: determine whether the last call time of the second calling interface meets the second preset condition, and the second preset condition is that the interval between the last call time and the current time is less than the preset time; the offline determination module is used to determine that the second calling interface is in an offline state that allows the user to log off if the last call time of the second calling interface does not meet the second preset condition.

[0111] In some embodiments, the microservice dependency processing device 400 also includes: a rule generation module, which is used to generate an alarm rule when a replacement notification for the third calling interface is detected, the replacement notification is sent by any first microservice that can call the third calling interface, and the alarm rule is used to prompt other first microservices that can call the third calling interface, the remaining usage time of the third calling interface, and the fourth calling interface used to replace the third calling interface.

[0112] The embodiments provided by the present application first obtain link tracking data between each microservice in a microservice architecture, where the link tracking data includes multiple historical call records for each microservice, where each historical call record includes a first microservice and a second microservice with a dependency relationship, and first call interface information, where the dependency relationship is used to indicate that the first microservice calls the second microservice through the first call interface; secondly, based on the link tracking data, key call information of each call interface in the microservice architecture is determined, where the key call information is used to indicate at least one group of microservices that implement the dependency relationship through the corresponding call interface; finally, based on the key call information of each call interface, a topology structure diagram including each microservice and each call interface is generated, and the topology structure diagram is displayed. Since the microservice dependency processing method of the present application can extract the key call information of each calling interface from the link tracking data between each microservice in the microservice architecture, the key call information is the information obtained after refining the historical call records of each microservice, and includes at least one group of microservices that implement dependencies through calling interfaces. Therefore, it is only necessary to analyze the key call information of each calling interface to obtain the dependencies between each microservice, thereby reducing the amount of data to be processed. Furthermore, since it is only necessary to store the key call information of each calling interface, it is beneficial to save storage space and control the cost of storage space. In addition, by generating a visual topology structure diagram including each microservice and each calling interface, it is helpful to help users clearly understand the dependencies between each microservice in the microservice architecture.

[0113] It should be clear that the present invention is not limited to the specific configurations and processes described in the above embodiments and shown in the figures. For the convenience and brevity of description, a detailed description of the known methods is omitted here, and the specific working processes of the systems, modules and units described above can refer to the corresponding processes in the aforementioned method embodiments, which will not be repeated here.

[0114] Figure 5 A block diagram of an electronic device provided in an embodiment of the present application.

[0115] Reference Figure 5 An embodiment of the present application provides an electronic device, which includes: at least one processor 501; at least one memory 502, and one or more I / O interfaces 503, connected between the processor 501 and the memory 502; wherein the memory 502 stores one or more computer programs that can be executed by at least one processor 501, and the one or more computer programs are executed by at least one processor 501, so that at least one processor 501 can execute the above-mentioned microservice dependency processing method.

[0116] The embodiment of the present application also provides a computer-readable storage medium on which a computer program is stored, wherein the computer program implements the above-mentioned microservice dependency processing method when executed by a processor / processing core. The computer-readable storage medium can be a volatile or non-volatile computer-readable storage medium.

[0117] An embodiment of the present application also provides a computer program product, including a computer-readable code, or a non-volatile computer-readable storage medium carrying the computer-readable code. When the computer-readable code runs in a processor of an electronic device, the processor in the electronic device executes the above-mentioned microservice dependency processing method.

[0118] It will be appreciated by those skilled in the art that all or some of the steps, systems, and functional modules / units in the methods disclosed above may be implemented as software, firmware, hardware, and appropriate combinations thereof. In a hardware implementation, the division between the functional modules / units mentioned in the above description does not necessarily correspond to the division of physical components; for example, a physical component may have multiple functions, or a function or step may be performed by several physical components in cooperation. Some or all physical components may be implemented as software executed by a processor, such as a central processing unit, a digital signal processor, or a microprocessor, or may be implemented as hardware, or may be implemented as an integrated circuit, such as an application-specific integrated circuit. Such software may be distributed on a computer-readable storage medium, which may include a computer storage medium (or a non-transitory medium) and a communication medium (or a temporary medium).

[0119] As is known to those of ordinary skill in the art, the term computer storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable program instructions, data structures, program modules or other data). Computer storage media include, but are not limited to, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), static random access memory (SRAM), flash memory or other memory technology, portable compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical disk storage, magnetic cassettes, magnetic tapes, magnetic disk storage or other magnetic storage devices, or any other medium that can be used to store desired information and can be accessed by a computer. In addition, it is known to those of ordinary skill in the art that communication media typically contain computer-readable program instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transmission mechanism, and may include any information delivery medium.

[0120] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.

[0121] The computer program instructions for performing the operation of the present application can be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. Computer-readable program instructions can be executed completely on the user's computer, partially on the user's computer, as an independent software package, partially on the user's computer, partially on the remote computer, or completely on the remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computer (for example, using an Internet service provider to connect through the Internet). In some embodiments, by using the state information of computer-readable program instructions to personalize electronic circuits, such as programmable logic circuits, field programmable gate arrays (FPGAs) or programmable logic arrays (PLAs), the electronic circuits can execute computer-readable program instructions, thereby realizing various aspects of the present application.

[0122] The computer program product described herein may be implemented in hardware, software, or a combination thereof. In one optional embodiment, the computer program product is embodied as a computer storage medium, and in another optional embodiment, the computer program product is embodied as a software product, such as a software development kit (SDK), etc.

[0123] Various aspects of the present application are described herein with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products according to the embodiments of the present application. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer-readable program instructions.

[0124] These computer-readable program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processor of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.

[0125] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operating steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.

[0126] The flow chart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to multiple embodiments of the present application. In this regard, each square box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and a part of a module, program segment or instruction includes one or more executable instructions for realizing the specified logical function. In some alternative implementations, the function marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two continuous square boxes can actually be executed substantially in parallel, and they can sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or action, or can be implemented with a combination of special-purpose hardware and computer instructions.

[0127] Example embodiments have been disclosed herein, and although specific terms are employed, they are used and should be interpreted only in a general illustrative sense and not for limiting purposes. In some instances, it will be apparent to those skilled in the art that, unless otherwise expressly noted, features, characteristics, and / or elements described in conjunction with a particular embodiment may be used alone or in combination with features, characteristics, and / or elements described in conjunction with other embodiments. Therefore, those skilled in the art will appreciate that various changes in form and detail may be made without departing from the scope of the present application as set forth in the appended claims.

Claims

1. A method for processing microservice dependencies, characterized in that: include: Acquire link tracking data between microservices in a microservice architecture, wherein the link tracking data includes multiple historical call records of each microservice, each historical call record includes a first microservice and a second microservice having a dependency relationship, and first call interface information, wherein the dependency relationship is used to indicate that the first microservice calls the second microservice through the first call interface; Determine, according to the link tracking data, key call information of each call interface in the microservice architecture, wherein the key call information is used to indicate at least one group of microservices that implement the dependency relationship through the corresponding call interface; According to the key calling information of each calling interface, a topological structure diagram including each microservice and each calling interface is generated, and the topological structure diagram is displayed.

2. The method according to claim 1, characterized in that Determining key call information of each call interface in the microservice architecture according to the link tracking data includes: Acquire, from the plurality of historical call records, a plurality of first target historical call records of calling a target calling interface, wherein the target calling interface is any one of the calling interfaces; Grouping the target historical call records having the same first microservice and second microservice among the multiple first target historical call records into one group to obtain multiple groups of second target historical call records; A plurality of groups of second target historical call records of each calling interface are obtained, and key call information of each calling interface is generated according to the plurality of groups of second target historical call records of each calling interface.

3. The method according to claim 2, characterized in that The generating key calling information of each calling interface according to the multiple groups of second target historical calling records of each calling interface includes: For each calling interface, obtaining a preset field value of each second target historical call record in each group of second target historical call records; A key call information record is generated according to the preset field values ​​of each second target historical call record, wherein each group of second target historical call records corresponds to a key call information record, each of the key call information records includes a preset field, and the field value of the preset field is the preset field value in the corresponding group of second target historical call records.

4. The method according to claim 3, characterized in that The preset fields include at least one of the following: First microservice field, second microservice field, calling interface field, interface call times field, and last call time field.

5. The method according to claim 1, characterized in that After generating a topology diagram including each microservice and each calling interface and displaying the topology diagram, the method further includes: When a first selection operation on a second calling interface in the topology structure diagram is detected, key calling information of the second calling interface is displayed; When detecting a second selection operation for the second calling interface, determining whether the number of calls of the second calling interface satisfies a first preset condition, the first preset condition being that the number of calls is greater than a preset threshold; If the number of calls of the second calling interface does not meet the first preset condition, the second calling interface is determined to be in an offline state, and the second calling interface after offline is highlighted in the topology diagram.

6. The method according to claim 5, characterized in that If the number of calls of the second calling interface does not meet the first preset condition, determining that the second calling interface is in an offline-allowed state includes: Determine whether the last call time of the second calling interface meets a second preset condition, where the second preset condition is that the interval between the last call time and the current time is less than a preset interval; If the last calling time of the second calling interface does not meet the second preset condition, it is determined that the second calling interface is in the offline-allowed state.

7. The method according to claim 5, characterized in that The method further comprises: When a replacement notification for the third calling interface is detected, an alarm rule is generated, where the replacement notification is sent by any first microservice that can call the third calling interface, and the alarm rule is used to prompt other first microservices that can call the third calling interface, the remaining usage time of the third calling interface, and the fourth calling interface used to replace the third calling interface.

8. A microservice dependency processing device, characterized in that: include: An acquisition module is used to acquire link tracking data between microservices in a microservice architecture, wherein the link tracking data includes multiple historical call records of each microservice, each historical call record includes a first microservice and a second microservice having a dependency relationship, and first call interface information, wherein the dependency relationship is used to indicate that the first microservice calls the second microservice through the first call interface; A determination module, configured to determine key call information of each call interface in the microservice architecture according to the link tracking data, wherein the key call information is used to indicate at least one group of microservices that implement the dependency relationship through the corresponding call interface; A generation module is used to generate a topology diagram including each microservice and each calling interface according to key calling information of each calling interface, and display the topology diagram.

9. An electronic device, characterized in that: include: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores one or more computer programs that can be executed by the at least one processor, and the one or more computer programs are executed by the at least one processor so that the at least one processor can execute the microservice dependency processing method as described in any one of claims 1-7.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the computer program implements the microservice dependency processing method according to any one of claims 1 to 7.

Citation Information

Cited By

  • Micro-service identity dynamic access control method and system

    CN122069072A