Application management system and method
By building a microservice application server and a registration center server, and using container management clusters to manage microservice applications, the problem of high complexity of single application management is solved and the efficiency of application management is improved.
Patent Information
- Application Number
- CN201910295567.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2019-04-12
- Publication Date
- 2025-01-21
- Estimated Expiration
- 2039-04-12
AI Technical Summary
Due to the large number of modules, single-unit applications have high management complexity, which reduces application management efficiency.
By building a microservice application server and a registration center server, the container management cluster is used to manage microservice applications. The registration center records the access address of the microservice application for unified management.
It improves the management efficiency of applications, simplifies the management process of applications, and realizes efficient and unified management of microservice applications.
Smart Images

Figure CN110134455B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to an application management system and method. Background Art
[0002] According to the needs of the enterprise business, you can build a monolithic application to achieve the construction of the corresponding product line or project. Among them, a monolithic application refers to an application program that contains all functions in an archive package. Since a monolithic application includes many modules, the management complexity of the application is high, which reduces the efficiency of application management. Summary of the invention
[0003] The embodiment of the present invention provides an application management system and method, which can improve the management efficiency of applications.
[0004] In a first aspect, an embodiment of the present invention provides an application management system, the application management system comprising: a microservice application server and a registration center server; the microservice application server is connected to the registration center server;
[0005] The microservice application server is configured with functional components, the microservice application server creates a container management cluster through the functional components, and the microservice application server is used to manage at least one container management unit created through the container management cluster, and at least one microservice application deployed in each container management unit; wherein the at least one microservice application is developed and generated based on a specified development architecture;
[0006] The registration center server is used to record the access address of the at least one microservice application obtained from the microservice application server for unified management; the access address is used to realize the access between the at least one microservice application and / or the access of the external application to the target application in the at least one microservice application.
[0007] Optionally, the application management system further includes a configuration center server; the configuration center server establishes a connection with the microservice application server, and the configuration center server is used to record configuration information that the at least one microservice application relies on during runtime.
[0008] Optionally, the application management system further includes a link monitoring center server; the link monitoring center server establishes a connection with the microservice application server, and the link monitoring center server is used to monitor call information between at least one microservice application.
[0009] Optionally, the application management system further includes a log cloud server; the log cloud server establishes a connection with the microservice application server, and the log cloud server is used to record log information generated by the at least one microservice application.
[0010] Optionally, the application management system further includes a database server, which establishes a connection with the microservice application server, and the database server is used to store business data related to the at least one microservice application.
[0011] Optionally, the microservice application server further includes a routing module of the specified development architecture;
[0012] The routing module is used to obtain the access address of the target application read from the registration center server when receiving an access request from the external application to the target application, and return the access address of the target application to the external application, so that the external application can access the target application through the access address of the target application.
[0013] Optionally, the microservice application server further includes a routing module of the specified development architecture; the routing module includes a load balancing unit, and there are multiple specified container management units running the target application; wherein:
[0014] The routing module is used to obtain the access address of the target application read from the registration center server when receiving an access request from an external application to the target application, and send the access address of the target application to the load balancing unit;
[0015] The load balancing unit is used to adopt a load balancing strategy to forward the access request to a target container management unit among a plurality of designated container management units according to the access address of the target application.
[0016] Optionally, the routing module is also used to identify whether the external application has access rights to the target application when receiving an access request from the external application to the application, and trigger the operation of obtaining the access address of the target application read from the registration center server when it is determined that the external application has access rights to the target application.
[0017] Optionally, the container management cluster includes a management node and at least one slave node, and the target application is deployed in the following manner:
[0018] The management node obtains a configuration file of a target application, and generates an image file according to the configuration file of the target application; the image file includes the target application; the management node instructs a designated slave node to create a target container management unit, and deploys the image file in the target container management unit; the management node defines an access address of an external application to the target application, so that the external application accesses the target application through the access address; the designated slave node runs the target application, and the target application writes the access address of the target application to a registration center.
[0019] Optionally, the designated slave node is an idle node selected by the management node from the at least one slave node according to resource utilization of the at least one slave node.
[0020] In a second aspect, an embodiment of the present invention provides an application management method, which is applied to a microservice application server, wherein the microservice application server is configured with functional components, and the microservice application server builds a container management cluster through the functional components, and the container management cluster includes a management node and at least one slave node, and the method includes:
[0021] The management node obtains a configuration file of the target application, and generates an image file according to the configuration file of the target application;
[0022] The management node instructs the designated slave node to create a target container management unit, and deploys the image file in the target container management unit;
[0023] The management node defines an access address of the external application to the target application, so that the external application accesses the target application through the access address of the target application;
[0024] The designated slave node runs the target application, and the target application writes the access address of the target application to the registration center server.
[0025] To summarize, the microservice application server can manage at least one container management unit created through the container management cluster, and at least one microservice application deployed in each container management unit; the registration center server can record the access address of at least one microservice application obtained from the microservice application server for unified management, thereby improving the management efficiency of the application. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0027] Figure 1 It is a schematic diagram of the architecture of an application management system provided by an embodiment of the present invention;
[0028] Figure 2 is a schematic diagram of the architecture of another application management system provided by an embodiment of the present invention;
[0029] Figure 3 It is a flowchart of an application management method provided by an embodiment of the present invention;
[0030] Figure 4 It is a flowchart of another application management method provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0031] The technical solutions in the embodiments of the present invention will be described below in conjunction with the accompanying drawings in the embodiments of the present invention.
[0032] See also Figure 1 , is a schematic diagram of an architecture of an application management system provided by an embodiment of the present invention. The application management system includes: a microservice application server 10 and a registration center server 20; the microservice application server 10 is connected to the information server 20.
[0033] The microservice application server 10 is configured with functional components, and the microservice application server 10 creates a container management cluster through the functional components. The microservice application server 10 is used to manage at least one container management unit created through the container management cluster, and at least one microservice application deployed in each container management unit; wherein the at least one microservice application is developed and generated based on a specified development architecture.
[0034] The at least one container management unit may be one or more container management units. For example, the at least one container management unit may include container management unit 1, or may also include container management unit 2 and container management unit 3. Each container management unit deploys at least one microservice application. For example, microservice application 1 and microservice application 2 are deployed in container management unit 1. Microservice application 1 and microservice application 2 are deployed in container management unit 2. Microservice application 3 is deployed in container management unit 3. Specifically, at least one microservice application deployed by each container management unit is deployed in a container included in each container management unit.
[0035] The registration center server 20 is used to record the access address of the at least one microservice application obtained from the microservice application server 10 for unified management; the access address is used to implement access between the at least one microservice application and / or access by an external application to a target application in the at least one microservice application. The target application may be any one or more applications in the microservice application.
[0036] In one embodiment, the access address of the at least one microservice application may be uploaded to the registration center server 20 by the at least one microservice application when the at least one microservice application is running.
[0037] In one embodiment, the container management cluster may include at least one management node and at least one slave node. The management node is responsible for the management function of the container management cluster, and the slave node is used to manage the container management unit created in the slave node and at least one microservice application deployed in the container management unit created in the slave node. Alternatively, the slave node may also be used to execute tasks such as tasks issued by the master node.
[0038] In one embodiment, when the container management cluster includes a management node and at least one slave node, the target application may be deployed in the following manner: the management node obtains a configuration file of the target application, and generates an image file according to the configuration file of the target application; the image file includes the target application; the management node instructs the designated slave node to create a target container management unit, and deploys the image file in the target container management unit; the management node defines an access address of an external application to the target application, so that the external application accesses the target application through the access address; the designated slave node runs the target application, and the target application writes the access address of the target application to the registration center. That is, the access address of the target application is defined by the management node, and is written to the registration center server by the target application.
[0039] In one embodiment, the operations performed by the management node can be partially replaced by the operations performed by the designated slave node according to the requirements of different scenarios, such as the management node obtaining the configuration file of the target application and generating the image file according to the configuration file of the target application, which can be replaced by the designated slave node obtaining the configuration file of the target application and generating the image file according to the configuration file of the target application. The embodiment of the present invention can effectively improve the efficiency of application deployment by having the designated slave node perform this operation.
[0040] In one embodiment, after the management node generates the image file according to the configuration file of the target application, the management node may also store the image file in an image warehouse, so that when the image file needs to be deployed, the image file can be obtained from the image warehouse.
[0041] In one embodiment, the management node instructs the designated slave node to create the target container management unit, specifically: the management node instructs the designated slave node to configure the target container management unit according to a preset deployment description file. The deployment description file may include any one or more of the following information: a processing capability parameter of a central processing unit allocated to the target container management unit, a data volume of a memory allocated to the target container management unit, an identifier of the image file imported into the target container management unit, a set number of copies, and environment variables.
[0042] In one embodiment, when at least one slave node is a plurality of slave nodes, the management node is further used to select an idle node with the lowest resource utilization rate from the plurality of slave nodes, and use the idle node as the designated slave node. That is, the designated slave node is an idle node selected from the at least one slave node by the management node according to the resource utilization rate of the at least one slave node. For example, the at least one slave node includes slave node 1, slave node 2, and slave node 3, then the designated slave node may be the idle node with the lowest resource utilization rate selected from the three slave nodes.
[0043] In one embodiment, when the at least one slave node is a plurality of slave nodes, the management node may further select nodes that meet resource requirements from the plurality of slave nodes according to a preset deployment description file, and select idle nodes from the nodes that meet resource requirements according to the resource utilization rate of the nodes that meet resource requirements, so as to use the idle nodes as designated slave nodes. That is, the designated slave node is a node that meets resource requirements selected from the plurality of slave nodes by the management node according to a preset deployment description file, and an idle node selected from the nodes that meet resource requirements according to the resource utilization rate of the nodes that meet resource requirements.
[0044] In one embodiment, the management node may also be connected to a designated code base, such as a GIT code base. When the management node monitors that the target application in the designated code base is modified, it generates a new image file, which includes the modified target application. The management node instructs the target slave node to create a new container management unit. The management node defines the access address of the external application to the modified target application so that the external application accesses the modified target application through the access address of the target application. The target slave node runs the modified target application, and the modified target application writes the access address of the modified target application to the registration center server 20. The target slave node may be the aforementioned designated slave node, or may not be the aforementioned designated slave node.
[0045] In one embodiment, the microservice application server 10 may further include a reverse proxy module, which is used to provide an entry service for the container management cluster so that external applications can pass through the reverse proxy module. For example, the reverse proxy module may be Ngnix.
[0046] Figure 1 In the application management system shown, the microservice application server can manage at least one container management unit created by the container management cluster, and at least one microservice application deployed in each container management unit; the registration center server can record the access address of at least one microservice application obtained from the microservice application server for unified management, thereby improving the management efficiency of the application.
[0047] In an application scenario, take the functional components as Kubernetes-related components, the container management cluster as the Kubernetes cluster, the container management unit as the pod, and the specified development architecture as the Spring Cloud development architecture as an example to briefly describe Figure 1 An embodiment provides an application management system, wherein the application management system comprises a microservice application server 10 and a registration center server 20. The microservice application server 10 is connected to the registration center server 20.
[0048] The microservice application server 10 is configured with Kubernetes related components, and the microservice application server 10 creates a Kubernetes cluster through the Kubernetes related components. The microservice application server 10 manages at least one pod created through the Kubernetes cluster, and at least one microservice application deployed in each pod. Each pod includes at least one container, and at least one microservice application deployed in each pod is deployed in the container included in each pod. At least one microservice application deployed in each pod is developed and generated based on the Spring Cloud development architecture.
[0049] The registration center server 20 can record the access address of at least one microservice application deployed in each pod obtained from the microservice application server 10 for unified management. The access address is used to realize the access between the at least one microservice application and / or the access of the external application to the target application in the at least one microservice application. For example, the at least one microservice application includes resource management service, order service, product service, and warehouse service. The registration center server 20 records the access addresses of the source management service, order service, product service, and warehouse service obtained from the microservice application server 10 for unified management.
[0050] based on Figure 1 The application management system shown in the figure, the embodiment of the present invention also provides another application management system. Figure 2 , which is an embodiment of the present invention Figure 1 The architecture shown is a schematic diagram of another application management system. The application management system may include: a microservice application server 10, a registration center server 20, and may also include a configuration center server 30, a link monitoring center server 40, a log cloud server 50, and a database server 60. The microservice application server 10 may establish connections with the registration center server 20, the link monitoring center server 30, the log cloud server 40, and the database server 50.
[0051] The configuration center server 30 is used to record the configuration information that the at least one microservice application relies on during operation. For example, the configuration information may include some metadata information such as the port and version number of the microservice application. By recording the configuration information in the configuration center server 30, it is convenient to send the configuration information to the corresponding microservice application, thereby facilitating the maintenance and operation of the corresponding microservice application.
[0052] The link monitoring center server 40 is used to monitor the call information between at least one microservice application. For example, the call information may include the number of calls, call success or failure, and frequent call time period. By monitoring the call information through the link center server 40, it is easy to grasp the call relationship between microservices.
[0053] The log cloud server 50 is used to record the log information generated by the at least one microservice application. The log information can be easily managed and viewed by the log cloud server, and the loss of log information can be effectively avoided. The log information is helpful to grasp the abnormal situation of the microservice application during operation.
[0054] The database server 60 is used to store business data related to the at least one microservice application. For example, if the at least one microservice application includes an order service, the business data related to the order service may include order information.
[0055] In one embodiment, the configuration center server 30 is an optional device of the application management system, and / or the link monitoring center server 40 is an optional device of the application management system, and / or the log cloud server 50 is an optional device of the application management system, and / or the database server 60 is an optional device of the application management system.
[0056] In one embodiment, the microservice application server 10 also includes a routing module of the specified development architecture; the routing module is used to obtain the access address of the target application read from the registration center server 20 when receiving an access request from the external application to the target application, and return the access address of the target application to the external application, so that the external application can access the target application through the access address of the target application.
[0057] In one embodiment, the routing module includes a load balancing unit, and there are multiple designated container management units running the target application; wherein: the routing module is used to obtain the access address of the target application read from the registration center server 20 when receiving an access request for the target application from an external application, and send the access address of the target application to the load balancing unit; the load balancing unit is used to adopt a load balancing strategy to forward the access request to a target container management unit in multiple designated container management units according to the access address of the target application. Specifically, when there are multiple designated container management units, there are also multiple access addresses of the target application. The load balancing unit can adopt a load balancing strategy to select a target access address from the multiple access addresses, and forward the access request to the container management unit corresponding to the target address in the multiple designated container units.
[0058] In one embodiment, the routing module is also used to identify whether the external application has access rights to the target application when receiving an access request from the external application to the application, and trigger the operation of obtaining the access address of the target application read from the registration center server 20 when it is determined that the external application has access rights to the target application.
[0059] As mentioned above, the access of external applications to target applications can be achieved through the routing module. For the access between at least one microservice application, it can be achieved without the routing module or through the routing module.
[0060] For the first case, the at least one microservice application includes a first application and a second application. The first application can query the access address of the second application from the registration center server 20 and access the second application through the access address of the second application.
[0061] For the second case, the at least one microservice application includes a first application and a second application, and the routing module is used to obtain the access address of the second application read from the registration center server when receiving an access request from the first application to the second application, and return the access address of the second application to the first application, so that the first application accesses the second application through the access address of the second application.
[0062] In one embodiment, the routing module includes a load balancing unit, and there are multiple first container management units running the second application; wherein: the routing module is used to obtain the access address of the second application read from the registration center server when receiving an access request from the first application to the second application, and send the access address of the second application to the load balancing unit; the load balancing unit is used to adopt a load balancing strategy to forward the access request to a second container management unit among the multiple first container management units according to the access address of the second application. Specifically, when there are multiple first container management units, there are also multiple access addresses for the second application. The load balancing unit can adopt a load balancing strategy to select a specified access address from the multiple access addresses, and forward the access request to the second container management unit corresponding to the specified address among the multiple first container units.
[0063] Figure 2In the application management system shown, the microservice application server can manage at least one container management unit created by the container management cluster, and at least one microservice application deployed in each container management unit; the registration center server can record the access address of at least one microservice application obtained from the microservice application server for unified management, and can also achieve division of labor and cooperation through the configuration center server 30, the link monitoring center server 40, the log cloud server 50, and the database server 60, thereby improving the management efficiency of the application.
[0064] In an application scenario, take the functional components as Kubernetes-related components, the container management cluster as Kubernetes cluster, the container management unit as pod, the specified development architecture as Spring Cloud development architecture, the routing module of the specified development architecture as Spring Cloud Zuul, and the load balancing unit as Spring Cloud Ribbon as an example to briefly describe Figure 2 The embodiment provides an application management system. The application management system includes: a microservice application server 10 and a registration center server 20. The microservice application server 10 is connected to the registration center server 20.
[0065] The microservice application server 10 is configured with Kubernetes related components, and the microservice application server 10 creates a Kubernetes cluster through the Kubernetes related components. The microservice application server 10 manages at least one pod created through the Kubernetes cluster, and at least one microservice application deployed in each pod. Each pod includes at least one container, and at least one microservice application deployed in each pod is deployed in the container included in each pod. At least one microservice application deployed in each pod is developed and generated based on the Spring Cloud development architecture.
[0066] The registration center server 20 can record the access address of at least one microservice application deployed in each pod obtained from the microservice application server 10 for unified management, and the access address is used to realize the access between the at least one microservice application and / or the access of the external application to the target application in the at least one microservice application.
[0067] The microservice application server may include Spring Cloud Zuul. When receiving an access request from the external application to the target application, Spring Cloud Zuul may obtain the access address of the target application read from the registration center server, and return the access address of the target application to the external application, so that the external application can access the target application through the access address of the target application.
[0068] In another application scenario, Spring Cloud Zuul includes Spring Cloud Ribbon, and there are multiple designated pods running the target application; when Spring Cloud Zuul receives an access request from an external application to the target application, it can obtain the access address of the target application read from the registration center server 20 and send the access address of the target application to Spring Cloud Ribbon; Spring Cloud Ribbon can adopt a load balancing strategy to forward the access request to the target pod among the multiple pods according to the access address of the target application.
[0069] In another application scenario, the at least one microservice application includes a first application and a second application. The first application can query the access address of the second application from the registration center server 20 and access the second application through the access address of the second application.
[0070] In another application scenario, the at least one microservice application includes a first application and a second application. When SpringCloud Zuul receives an access request from the first application to the second application, it obtains the access address of the second application read from the registration center server 20, and returns the access address of the second application to the first application, so that the first application accesses the second application through the access address of the second application.
[0071] In another application scenario, Spring Cloud Zuul includes Spring Cloud Ribbon, and there are multiple first container pods running the second application; when Spring Cloud Zuul receives an access request from the first application to the second application, it obtains the access address of the second application read from the registration center server 20, and sends the access address of the second application to Spring Cloud Ribbon; Spring Cloud Ribbon adopts a load balancing strategy to forward the access request to the second pod among the multiple first pods according to the access address of the second application.
[0072] See also Figure 3 , is a flow chart of an application management method provided by an embodiment of the present invention. The method can be applied to Figure 1 The microservice application server 10. The microservice application server 10 is configured with functional components, and the microservice application server 10 builds a container management cluster through the functional components, and the container management cluster includes a management node and at least one slave node. Specifically, the method may include the following steps:
[0073] S301: The management node obtains a configuration file of a target application, and generates an image file according to the configuration file of the target application.
[0074] The image file includes the target application. The configuration file may include an identifier of the target application, and may also include information such as startup parameters of the target application, for example, the startup parameters may be access network and operating environment.
[0075] In one embodiment, the management node generates an image file according to the configuration file of the target application, including: the management node obtains the target application according to the identifier of the target application included in the configuration file of the target application, and generates an image file including the target application.
[0076] In one embodiment, after the management node generates the image file according to the configuration file of the target application, the management node may store the image file in an image repository, so that when the image file needs to be deployed, the image file can be obtained from the image repository.
[0077] In one embodiment, after the management node generates the image file according to the configuration file of the target application, the management node may also store the image file in a local database, so that when the image file needs to be deployed, the image file can be obtained from the local database.
[0078] S302: The management node instructs the designated slave node to create a target container management unit, and deploys the image file in the target container management unit.
[0079] In the embodiment of the present invention, the management node may instruct the designated slave node to create a target container management unit, and deploy the image file in the target container management unit.
[0080] In one embodiment, the management node instructs the designated slave node to create the target container management unit, which may include: the management node instructs the designated slave node to configure the target container management unit according to a preset deployment description file. The deployment description file may include any one or more of the following information: a processing capacity parameter of a central processor allocated to the target container management unit, a data volume of a memory allocated to the target container management unit, an identifier of the image file imported into the target container management unit, a set number of copies, and an environment variable. For example, the processing capacity parameter may include a main frequency and a number of cores.
[0081] In one embodiment, when at least one slave node is a plurality of slave nodes, before the management node instructs the designated slave node to create the target container management unit, the management node may filter out an idle node with the lowest resource utilization rate from the plurality of slave nodes, and use the idle node as the designated slave node. That is, the designated slave node is an idle node that the management node filters out from the at least one slave node according to the resource utilization rate of the at least one slave node.
[0082] In one embodiment, when the at least one slave node is a plurality of slave nodes, before the management node instructs the designated slave node to create the target container management unit, the management node may also select nodes that meet the resource requirements from the plurality of slave nodes according to a preset deployment description file, and select idle nodes from the nodes that meet the resource requirements according to the resource utilization rate of the nodes that meet the resource requirements, so as to use the idle nodes as designated slave nodes. That is, the designated slave node is a node that meets the resource requirements selected by the management node from the plurality of slave nodes according to a preset deployment description file, and an idle node selected from the nodes that meet the resource requirements according to the resource utilization rate of the nodes that meet the resource requirements.
[0083] S303, the management node defines an access address of the external application to the target application, so that the external application accesses the target application through the access address of the target application;
[0084] S304: The designated slave node runs the target application, and the target application writes the access address of the target application to the registration center server.
[0085] In the embodiment of the present invention, the designated slave node can run the target application, and the target application writes the access address of the target application to the registration center server, so that the registration center server records the access address of the target application for unified management.
[0086] In one embodiment, the management node can be connected to a designated code base, such as a GIT code base. The management node can also generate a new image file when monitoring that the target application in the designated code base is modified. The new image file includes the modified target application. The management node instructs the target slave node to create a new container management unit. The management node defines the access address of the external application to the modified target application so that the external application can access the modified target application through the access address. The target slave node runs the modified target application, and the modified target application writes the access address of the modified target application to the registration center server. The target slave node may be the aforementioned designated slave node or may not be the aforementioned designated slave node.
[0087] visible, Figure 3 In the illustrated embodiment, the management node can generate an image file based on the acquired configuration file of the target application; the management node can instruct the designated slave node to create a target container management unit to deploy the image file in the target container management unit; the management node can define an access address of the external application to the target application so that the external application accesses the target application through the access address; the designated slave node can run the target application, and the target application writes the access address of the target application to the registration center server, thereby improving the deployment efficiency of the application.
[0088] See also Figure 4 , is a flow chart of another application management method provided by an embodiment of the present invention. The method can be applied to Figure 1 In the microservice application server 10. The microservice application server 10 is configured with functional components, and the microservice application server 10 builds a container management cluster through the functional components, and the container management cluster includes a management node and at least one slave node. The microservice application server also includes a routing module. Specifically, the method may include the following steps:
[0089] S401: The management node obtains a configuration file of a target application, and generates an image file according to the configuration file of the target application.
[0090] S402: The management node instructs the designated slave node to create a target container management unit, and deploys the image file in the target container management unit.
[0091] S403, the management node defines an access address of the external application to the target application, so that the external application accesses the target application through the access address of the target application;
[0092] S404: The designated slave node runs the target application, and the target application writes the access address of the target application to the registration center server.
[0093] Among them, steps S401-S404 can be found in Figure 3 The steps S301 to S304 in the embodiment are not described in detail in the embodiment of the present invention.
[0094] S405. When the routing module receives an access request from the external application to the target application, it obtains the access address of the target application read from the registration center server, and returns the access address of the target application to the external application, so that the external application can access the target application through the access address of the target application.
[0095] In the embodiment of the present invention, the routing module can read the address of the target application from the registration center, and when receiving the access request of the external application to the target application, obtain the access address of the target application read from the registration center server, and return the access address of the target application to the external application, so that the external application can access the target application through the access address of the target application.
[0096] In one embodiment, the routing module includes a load balancing unit, and there are multiple designated container management units running the target application; the routing module can also obtain the access address of the target application read from the registration center server when receiving an access request for the target application from an external application, and send the access address of the target application to the load balancing unit; the load balancing unit is used to adopt a load balancing strategy to forward the access request to a target container management unit in multiple designated container management units according to the access address of the target application. Specifically, when there are multiple designated container management units, there are also multiple access addresses of the target application. The load balancing unit can adopt a load balancing strategy to select a target access address from the multiple access addresses, and forward the access request to the container management unit corresponding to the target address in the multiple designated container units.
[0097] In one embodiment, the routing module can also identify whether the external application has access rights to the target application when receiving an access request from the external application to the application, and when determining that the external application has access rights to the target application, trigger the operation of obtaining the access address of the target application read from the registration center server.
[0098] visible, Figure 4In the illustrated embodiment, the management node can generate an image file according to the configuration file of the acquired target application, and can instruct the designated slave node to create a target container management unit to deploy the image file in the target container management unit; the management node can define the access address of the target application to the external application; the designated slave node can run the target application, and the target application writes the access address of the target application to the registration center server; when the routing module receives the access request of the external application to the target application, it obtains the access address of the target application read from the registration center server, and returns the access address of the target application to the external application, so that the external application accesses the target application through the access address of the target application, thereby facilitating the calling process of the external application to the microservice application. The calling process is made safer and more reliable.
Claims
1. An application management system, characterized in that: The application management system includes: a microservice application server, a registration center server, a configuration center server, a link monitoring center server, a log cloud server and a database server; the microservice application server is connected to the registration center server, the link monitoring center server, the log cloud server and the database server respectively; The microservice application server is configured with a functional component, and the microservice application server creates a container management cluster through the functional component. The microservice application server is used to manage at least one container management unit created through the container management cluster, and at least one microservice application deployed in each container management unit; wherein the at least one microservice application is developed and generated based on a specified development architecture, and the container management unit is obtained according to a preset deployment description file configuration, and the deployment description file includes: a processing capacity parameter of a central processing unit allocated to the container management unit, a data volume of a memory allocated to the container management unit, an identifier of an image file imported into the container management unit, a set number of copies, and environment variables; The registration center server is used to record the access address of the at least one microservice application obtained from the microservice application server for unified management; the access address is used to implement access between the at least one microservice application and / or access by an external application to a target application in the at least one microservice application; The microservice application server further includes a routing module of the designated development architecture; the routing module is used to, upon receiving an access request from the external application to the target application, identify whether the external application has access rights to the target application, and when determining that the external application has access rights to the target application, obtain an access address of the target application read from the registration center server, and return the access address of the target application to the external application, so that the external application can access the target application through the access address of the target application; The container management cluster includes a management node and at least one slave node, the management node is connected to a designated code library, and the management node is used to generate a new image file when monitoring that the target application in the designated code library is modified, instruct the target slave node to create a new container management unit, and define the access address of the external application to the modified target application, so that the external application can access the modified target application through the access address; the target slave node runs the modified target application, and the modified target application writes the access address of the modified target application to the registration center server; the target slave node is determined as follows: according to the processing capacity parameter, the data volume, the identifier of the image file imported into the container management unit, the number of copies and the environment variables, the slave node that meets the resource requirements is selected from multiple slave nodes, and according to the resource utilization of the slave nodes that meet the resource requirements, the node with the lowest resource utilization rate is selected from the slave nodes that meet the resource requirements as the target slave node; The configuration center server is used to record the configuration information that the at least one microservice application depends on during runtime, wherein the configuration information includes at least two types of metadata information, and the at least two types of metadata information include a port and a version number of the microservice application; The link monitoring center server is used to monitor the call information between at least one microservice application; the call information includes the number of calls, call success or failure, and frequent call time period; The log cloud server is used to record the log information generated by the at least one microservice application; The database server is used to store business data related to the at least one microservice application.
2. The application management system according to claim 1, characterized in that: The routing module includes a load balancing unit, and there are multiple designated container management units running the target application; wherein: The routing module is used to send the access address of the target application to the load balancing unit; The load balancing unit is used to adopt a load balancing strategy to forward the access request to a target container management unit among a plurality of designated container management units according to the access address of the target application.
3. The application management system according to claim 1, characterized in that: The container management cluster includes a management node and at least one slave node, and the target application is deployed in the following manner: The management node obtains a configuration file of the target application, and generates an image file according to the configuration file of the target application; the image file includes the target application; the management node instructs the designated slave node to create a target container management unit, and deploys the image file in the target container management unit; The management node defines an access address of the external application to the target application, so that the external application accesses the target application through the access address; The designated slave node runs the target application, and the target application writes the access address of the target application to the registration center.
4. An application management method, characterized in that: Applied to a microservice application server, the microservice application server is respectively connected to a registration center server, a configuration center server, a link monitoring center server, a log cloud server and a database server, the microservice application server is configured with functional components, the microservice application server builds a container management cluster through the functional components, the container management cluster includes a management node and at least one slave node, the management node is connected to a specified code library; the method includes: The management node obtains a configuration file of the target application, and generates an image file according to the configuration file of the target application; The management node instructs the designated slave node to create a target container management unit, and deploys the image file in the target container management unit; the target container management unit is obtained according to a preset deployment description file configuration, and the deployment description file includes: a processing capacity parameter of a central processing unit allocated to the target container management unit, a data volume of a memory allocated to the target container management unit, an identifier of the image file imported into the target container management unit, a set number of copies, and environment variables; The management node defines an access address of the external application to the target application, so that the external application accesses the target application through the access address of the target application; wherein the microservice application server further comprises a routing module for specifying a development architecture; the routing module is used to identify whether the external application has access rights to the target application when receiving an access request from the external application to the target application, and when determining that the external application has access rights to the target application, obtain the access address of the target application read from the registration center server, and return the access address of the target application to the external application, so that the external application accesses the target application through the access address of the target application; The designated slave node runs the target application, and the target application writes the access address of the target application to the registration center server; When the management node monitors that the target application in the designated code base is modified, it generates a new image file, instructs the target slave node to create a new container management unit, and defines the access address of the external application to the modified target application, so that the external application can access the modified target application through the access address; the target slave node runs the modified target application, and the modified target application writes the access address of the modified target application to the registration center server; the target slave node is determined as follows: according to the processing capacity parameter, the data volume, the identifier of the image file imported into the container management unit, the number of copies and the environment variables, the slave node that meets the resource requirements is screened out from multiple slave nodes, and according to the resource utilization of the slave nodes that meet the resource requirements, the node with the lowest resource utilization rate is screened out from the slave nodes that meet the resource requirements as the target slave node; The configuration center server is used to record the configuration information that the at least one microservice application depends on during operation, wherein the configuration information includes at least two types of metadata information, and the at least two types of metadata information include the port and version number of the microservice application; The link monitoring center server is used to monitor the call information between at least one microservice application; the call information includes the number of calls, call success or failure, and frequent call time period; The log cloud server is used to record the log information generated by the at least one microservice application; The database server is used to store business data related to the at least one microservice application.
Citation Information
Patent Citations
Microservice management method and system based on artificial intelligence service cloud platform
CN108418862A
Container application deployment method and device, computer equipment and storage medium
CN108958927A