Application deployment method, apparatus, and system

By using the correspondence between application blueprints and resource indexes during application deployment, task script writing is simplified, solving the problems of high complexity and low efficiency in existing technologies, and achieving efficient application deployment.

CN112732273BActive Publication Date: 2025-11-21HUAWEI TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202011581815.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2017-09-19
Publication Date
2025-11-21
Estimated Expiration
2037-09-19

AI Technical Summary

Technical Problem

In the existing application deployment process, the complexity of writing task scripts leads to high complexity and low efficiency.

Method used

By acquiring application blueprints and resource indexes and establishing corresponding relationships, the deployment device acquires and stores application resources based on these relationships and executes executable commands, simplifying the process of writing task scripts.

Benefits of technology

It reduces the complexity of application deployment, improves deployment efficiency, and enables plug-and-play functionality and rapid adaptation to different application environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112732273B_ABST
    Figure CN112732273B_ABST
Patent Text Reader

Abstract

The application discloses an application deployment method, device and system, and relates to the field of application deployment. The method comprises the following steps: acquiring an application blueprint and a resource index of a to-be-deployed application allocated for a deployment device, wherein the application blueprint comprises a resource storage path and an executable command, and the resource index comprises a resource acquisition address; establishing a corresponding relationship among n groups of application blueprints, resource indexes and proxy identifiers based on the application blueprint and the resource index of the to-be-deployed application, wherein the proxy identifier is used for uniquely identifying the deployment device, and n is an integer greater than or equal to 1; and sending a deployment command to the deployment device, wherein the deployment command comprises the n groups of corresponding relationships, the deployment command is used for instructing the deployment device to acquire application resources through the resource acquisition address in each group of corresponding relationships, store the application resources according to the resource storage path, and execute the executable command after storing the application resources. The application reduces the complexity of application deployment and improves the efficiency of application deployment. The application is used for application deployment.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of cloud computing, and in particular to an application deployment method, device and system. BACKGROUND

[0002] Application deployment refers to a process of deploying packaged application resources to a specified server according to a series of well-arranged task processes, which includes code packaging, environment creation, context preparation, resource copying, application startup, running configuration, system hardening and the like.

[0003] The current application deployment is process-oriented, and the corresponding application deployment system includes a deployment engine, a resource server and a deployment agent. The deployment engine loads a task script and application resources stored in the resource server after being started. After receiving a deployment instruction triggered by a human or a third party, the deployment engine sends the task script and the application resources to the deployment agent, which performs application deployment based on the task script and the application resources.

[0004] However, since a corresponding task script needs to be developed by a technician during application deployment, and the task script is complex and takes a long time to write, the complexity of application deployment is high, and the deployment efficiency is low. SUMMARY

[0005] The present application provides an application deployment method, device and system, which can solve the problem of high complexity and low efficiency of application deployment. The technical solution is as follows:

[0006] In a first aspect, an application deployment method is provided, which is applied to a registration center, and the method comprises:

[0007] Obtaining an application blueprint and a resource index of a to-be-deployed application allocated for a deployment agent, wherein the application blueprint comprises a resource storage path and an executable command, and the resource index comprises a resource acquisition address;

[0008] Based on the application blueprint and the resource index of the to-be-deployed application, establishing a correspondence relationship of n groups of the application blueprint, the resource index and a proxy identifier, wherein the proxy identifier is used to uniquely identify the deployment agent, and n is an integer greater than or equal to 1;

[0009] Sending a deployment command to the deployment agent, wherein the deployment command comprises n groups of the correspondence relationship, and the deployment command is used to instruct the deployment agent to acquire application resources through the resource acquisition address in each group of the correspondence relationship, store the application resources according to the resource storage path, and execute the executable command after storing the application resources.

[0010] Since the application blueprint and the resource index have simple formats, simple basic knowledge is required to quickly write the corresponding relationship required for application deployment, without the need to write complex task scripts, thereby reducing the deployment threshold, and thus reducing the complexity of application deployment and improving the efficiency of application deployment.

[0011] The deployment device can feed back the corresponding execution result to the registration center through a deployment response after executing the executable command in each set of corresponding relationship, or the deployment device can feed back the execution result of the multiple sets of executable commands to the registration center through the same deployment response after executing the executable command in the multiple sets of corresponding relationship. Correspondingly, the registration center can determine the subsequent operation according to the execution result carried in the deployment response after receiving the deployment response. In this way, problems that occur in the interaction process between the registration center and the deployment device can be reduced. Optionally, the method further includes:

[0012] The registration center receives the deployment response sent by the deployment device, and the deployment response includes the execution result obtained by the deployment device executing the executable command.

[0013] Optionally, in different application environments, the complete to-be-deployed resource (that is, all resources that need to be deployed) required by the to-be-deployed application for deployment is different. The complete to-be-deployed resource may be deployed in one or more deployment devices according to different actual deployment scenarios and / or different application environments. Based on this, for a deployment device, the application blueprint and the resource index of the to-be-deployed application allocated to the deployment device include:

[0014] m resource indexes of the to-be-deployed application are received, and the application resources corresponding to the m resource indexes constitute the complete to-be-deployed resource of the to-be-deployed application in a specified application environment, where m is an integer greater than or equal to 1;

[0015] p application blueprints of the to-be-deployed application are received, and the storage paths of the p application blueprints correspond to the m resource indexes;

[0016] After receiving the subscription instruction of the deployment device, when the deployment device is a device in the specified application environment, at least one resource index in the m resource indexes is acquired as the resource index of the to-be-deployed application allocated to the deployment device, and the p application blueprints are acquired as the application blueprints of the to-be-deployed application allocated to the deployment device.

[0017] Optionally, when the deployment device is a device in the specified application environment, at least one resource index in the m resource indexes is acquired as the resource index of the to-be-deployed application allocated to the deployment device, and the p application blueprints are acquired as the application blueprints of the to-be-deployed application allocated to the deployment device.

[0018] determining at least one target deployment device for deploying the complete to-be-deployed resource in the designated application environment, the at least one target deployment device comprising the deployment device;

[0019] allocating, in the m resource indexes, a resource index for each of the target deployment devices;

[0020] allocating, in the p application blueprints, an application blueprint for each of the target deployment devices.

[0021] Optionally, due to different deployment scenarios and / or changes in the application environment (such as upgrading or rolling back of the application environment), some elements in the n groups of correspondences may change, and accordingly, the registration center sends an update command to the deployment device. The application deployment method further comprises:

[0022] when any element in the first correspondence changes, sending a first update command to the deployment device, the first update command comprising: a second correspondence, the second correspondence being the updated first correspondence, the application blueprint identifiers in the first correspondence and the second correspondence being the same, the first correspondence being any one of the n groups of correspondences.

[0023] In actual application, each deployment device needs to be registered in the registration center first, so as to be managed and deployed by the registration center subsequently. Optionally, before the application blueprint and the resource index allocated for the deployment device are obtained, the method further comprises:

[0024] receiving a registration request sent by the deployment device;

[0025] allocating the proxy identifier for the deployment device according to the registration request;

[0026] sending a registration request response to the deployment device, the registration request response comprising the proxy identifier.

[0027] Optionally, the registration center can further be configured with a first application programming interface and a second application programming interface, the first application programming interface being an interface for interacting with the deployment device, and the second application programming interface being an interface for interacting with the control terminal. It should be noted that the registration center can further interact with the control terminal by specifying an operation page, which can be a HyperText Markup Language (HTML) page, such as an HTML5 page. In the embodiments of the present application, the registration center obtains the application blueprint and the resource index provided by the control terminal through the second application programming interface or the specified operation page, and the registration center can further provide the deployment device with a corresponding relationship including the application blueprint and the resource index through the first application programming interface.

[0028] For example, the sending of the deployment command to the deployment device comprises:

[0029] The deployment command is sent to the deployment device through the first application programming interface of the registration center.

[0030] Optionally, the obtaining of the application blueprint and the resource index allocated for the deployment device comprises:

[0031] The application blueprint allocated for the deployment device is obtained through the first application programming interface or the specified operation page of the registration center.

[0032] The resource index allocated for the deployment device is obtained through the first application programming interface or the specified operation page of the registration center.

[0033] Optionally, the application resource comprises an application installation resource, an application configuration file, an executable file, a code file, or an application differential package.

[0034] In a second aspect, an application deployment method is provided, and the method is applied to a deployment device, and the method comprises:

[0035] The deployment command sent by the registration center is received, the deployment command comprising a corresponding relationship of n groups of application blueprints, resource indexes, and proxy identifiers, the proxy identifier being used for uniquely identifying the deployment device, the application blueprint comprising a resource storage path and an executable command, and the resource index comprising a resource acquisition address;

[0036] The application resource is acquired through the resource acquisition address in each group of the corresponding relationship, the application resource is stored according to the resource storage path, and after the application resource is stored, the executable command is executed.

[0037] Since the application blueprint and the resource index have simple formats, simple basic knowledge is required to quickly write the corresponding relationship required for application deployment, without the need to write complex task scripts, thereby reducing the deployment threshold, and thus reducing the complexity of application deployment and improving the efficiency of application deployment.

[0038] The deployment device can feed back the corresponding execution result to the registration center through a deployment response after executing the executable command in each set of corresponding relationships, or the deployment device can feed back the execution results of the multiple sets of executable commands to the registration center through the same deployment response after executing the executable commands in the multiple sets of corresponding relationships. Correspondingly, the registration center can determine the subsequent operation according to the execution result carried in the deployment response after receiving the deployment response. In this way, problems that occur in the interaction process between the registration center and the deployment device can be reduced.

[0039] Optionally, the deployment device can send a deployment response to the registration center after executing the executable command, where the deployment response includes an execution result obtained by the deployment device by executing the executable command.

[0040] Optionally, the application blueprint further includes an application blueprint identifier, and the application blueprint identifier allocated by the registration center corresponds to the application resource stored by the resource server in a one-to-one manner. Due to different deployment scenarios and / or changes in the application environment (such as upgrading or rolling back of the application environment), some elements in the n sets of corresponding relationships can change. Correspondingly, the registration center can send an update command to the deployment device. The application deployment method further includes the following steps:

[0041] receiving a first update command sent by the registration center, where the first update command is a command sent by the registration center to the deployment device after detecting that any element in a first corresponding relationship changes, the first update command includes a second corresponding relationship, the first corresponding relationship is any one of the n sets of corresponding relationships, the second corresponding relationship is an updated first corresponding relationship, and the application blueprint identifiers in the first corresponding relationship and the second corresponding relationship are the same;

[0042] detecting a target element that changes in the second corresponding relationship;

[0043] executing an action corresponding to the target element according to the second corresponding relationship.

[0044] Optionally, in one aspect, the executing the action corresponding to the target element according to the second corresponding relationship includes:

[0045] When the target element comprises a resource acquisition address and / or a resource storage path, an application resource is acquired through the resource acquisition address in the second correspondence relationship, and after the application resource is stored according to the resource storage path in the second correspondence relationship, an executable command in the second correspondence relationship is executed.

[0046] When the target element is an executable command, the executable command in the second correspondence relationship is executed.

[0047] On the other hand, the performing, according to the second correspondence relationship, of an action corresponding to the target element comprises:

[0048] When the target element comprises a resource storage path, an application resource stored locally is acquired according to a first resource storage path in the first correspondence relationship, and the application resource is stored again according to a second resource storage path in the second correspondence relationship.

[0049] The second correspondence relationship is used to replace the first correspondence relationship stored locally.

[0050] If the application resource downloaded through the first correspondence relationship is reserved, resource quick rollback can be realized in a subsequent process. The resource quick rollback process can comprise the following two implementation manners:

[0051] Optionally, in the first implementation manner, the quick rollback process comprises:

[0052] After the application resource stored locally is acquired according to the first resource storage path in the first correspondence relationship, and the application resource is stored again according to the second resource storage path in the second correspondence relationship, a correspondence relationship between the first resource storage path and the second resource storage path is recorded.

[0053] A rollback instruction sent by the registration center is received, and the rollback instruction is used to instruct rollback of a storage state of an application resource to a previous storage state.

[0054] The second resource storage path is acquired from the second correspondence relationship stored currently.

[0055] The first resource storage path is acquired based on the correspondence relationship between the first resource storage path and the second resource storage path.

[0056] The second resource storage path in the second correspondence relationship stored currently is updated to the first resource storage path.

[0057] Optionally, in the second implementation manner, the quick rollback process comprises:

[0058] obtaining the application resource stored locally according to the first resource storage path in the first correspondence relationship, and storing the application resource again according to the second resource storage path in the second correspondence relationship;

[0059] receiving a second update command sent by the registration center, the second update command being a command sent by the registration center to the deployment device after detecting that any element in the second correspondence relationship changes, the update command including a third correspondence relationship, the third correspondence relationship being the second correspondence relationship after being updated;

[0060] when the third correspondence relationship is different from the second correspondence relationship only in the resource storage path, and the resource storage path in the third correspondence relationship is the same as the first resource storage path recorded in the correspondence relationship, updating the second resource storage path in the second correspondence relationship to the first resource storage path.

[0061] In actual application, each deployment device needs to be registered in the registration center first, so as to be managed and applied by the registration center in subsequent application deployment process. Optionally, before receiving the deployment command sent by the registration center, the method further includes:

[0062] sending a registration request to the registration center;

[0063] receiving a registration request response sent by the registration center, the registration request response including the proxy identifier.

[0064] Optionally, the sending of the registration request to the registration center includes:

[0065] obtaining configuration information, the configuration information including information of a first application programming interface of the registration center;

[0066] sending the registration request to the registration center through the first application programming interface of the registration center;

[0067] The receiving of the deployment command sent by the registration center includes:

[0068] receiving the deployment command sent by the registration center through the first application programming interface of the registration center.

[0069] In a third aspect, a registration center is provided, including at least one module for implementing the application deployment method provided in the first aspect or any optional manner of the first aspect.

[0070] Fourthly, a deployment apparatus is provided, the deployment apparatus including at least one module for implementing the application deployment method provided in the second aspect or any alternative method of the second aspect.

[0071] Fifthly, an application deployment system is provided, which includes any of the registration centers of the third aspect and any of the deployment devices of the fourth aspect.

[0072] Sixthly, a computer-readable storage medium is provided, storing instructions that, when the computer-readable storage medium is run on a processing component, cause the processing component to perform the application deployment method provided by the first aspect or any optional method of the first aspect, or cause the processing component to perform the application deployment method provided by the second aspect or any optional method of the second aspect. The computer-readable storage medium may be a non-volatile readable storage medium.

[0073] In a seventh aspect, a computer program product comprising instructions is provided, which, when run on a processing component, causes the processing component to perform the application deployment method provided by the first aspect or any alternative method of the first aspect, or causes the processing component to perform the application deployment method provided by the second aspect or any alternative method of the second aspect.

[0074] The beneficial effects of the technical solution provided in this application are:

[0075] The application deployment method, apparatus, and system provided in this application embodiment have simple application blueprint and resource index formats. Only simple basic knowledge is required to quickly write the corresponding relationships needed for application deployment, eliminating the need to write complex task scripts. This reduces the orchestration threshold, thereby reducing the complexity of application deployment and improving the efficiency of application deployment.

[0076] Furthermore, the application deployment method, apparatus, and system provided in this application embodiment can establish a correspondence between the registration center and the application blueprint, resource index, and agent identifier. The deployment device can then obtain and store application resources and execute executable commands based on this correspondence to deploy the application resources. Since the application blueprint and resource index have simple formats, only basic knowledge is required to quickly write the correspondence required for application deployment. For different application environments, there is no need to develop different task scripts; only the correspondence needs to be established or adjusted to achieve environment adaptation. Therefore, the complexity of application deployment is effectively reduced, and deployment efficiency is improved.

[0077] The application deployment method, apparatus, and system provided in this application embodiment add executable commands after the application blueprint. Once the deployment device downloads the application resources, the executable commands can be executed. Technical personnel only need to configure appropriate executable commands on the application blueprint to achieve processes such as copying, transferring, downloading, decompressing, or installing. Therefore, no specialized scripting is required, reducing the time spent on scripting. Furthermore, the simple format of the application blueprint and resource index lowers the programming threshold; only basic knowledge is needed to write the necessary correspondences for application deployment. Moreover, the application relationship deployment process is plug-and-play, enabling rapid application deployment.

[0078] The application deployment method, apparatus and system provided in the embodiments of this application only require the establishment of at least one correspondence for application deployment for an application. For different application environments, only the correspondence needs to be newly created or adjusted, and the correspondence has high reusability.

[0079] The application deployment method, apparatus and system provided in this application embodiment occupy less network bandwidth and have a smaller impact on the load of the registration center because the correspondence used for application deployment is actually just a simple string concatenation.

[0080] Furthermore, in this application, the application resources can be application installation packages, application plugins, application configuration files, executable files, code files, or application differential packages. When the application resources are application plugins or application differential resources, incremental updates of the application can be realized, reducing the demand for network bandwidth and improving the application deployment speed. Attached Figure Description

[0081] Figure 1 This is a schematic diagram of the implementation environment of an application deployment system involved in an application deployment method provided in this application embodiment;

[0082] Figure 2 This is a schematic diagram of the implementation environment of the application deployment system involved in another application deployment method provided in this application embodiment;

[0083] Figure 3 This is a flowchart of an application deployment method provided in an embodiment of this application;

[0084] Figure 4 This is a flowchart illustrating the registration process of a deployment device provided in an embodiment of this application;

[0085] Figure 5 This is a structural block diagram of a registration center provided in an embodiment of this application;

[0086] Figure 6 This is a structural block diagram of a registration center acquisition module provided in an embodiment of this application;

[0087] Figure 7 This is a structural block diagram of another registration center provided in an embodiment of this application;

[0088] Figure 8 This is a structural block diagram of another registration center provided in the embodiments of this application;

[0089] Figure 9 This is a structural block diagram of a deployment device provided in an embodiment of this application;

[0090] Figure 10 This is a structural block diagram of another deployment device provided in the embodiments of this application;

[0091] Figure 11 This is a structural block diagram of another deployment device provided in the embodiments of this application;

[0092] Figure 12 This is a structural block diagram of another deployment device provided in the embodiments of this application;

[0093] Figure 13 This is a structural block diagram of a deployment device provided in an embodiment of this application;

[0094] Figure 14 This is a structural block diagram of a controller provided in an embodiment of this application. Detailed Implementation

[0095] Please see Figure 1 This illustration shows a schematic diagram of the implementation environment of the application deployment system involved in the application deployment method provided in some embodiments of this application. The application deployment system can be applied to systems on a Platform-as-a-Service (PaaS) platform, mobile application update systems, or service deployment engines. The application deployment system may include: a registration center 110, at least one deployment device 120, and a resource server 130.

[0096] The registration center 110 can be a single server, a server cluster consisting of several servers, or a cloud computing service center. The deployment device 120 can be an application server, physical machine, virtual machine, isolated server, smartphone, computer, multimedia player, e-reader, or wearable device, etc. The deployment device 120 is a device with agent software installed. The deployment device 120 deploys applications through the agent software. An application environment is created on the deployment device 120, which supports application deployment. This application environment can be an operating system or a container environment. Resource server 130 can be a single server, a server cluster consisting of several servers, or a cloud computing service center. Resource server 130 is used to store application resources to be deployed. These application resources may include: application installation resources, application plugins, application configuration files, database configuration files, executable files, code files, or application differential packages, etc., which are resources required to run the application. Among them, application installation resources may include the application itself, database resources, and / or load balancing resources. Furthermore, the application itself may include the application's installation package or compressed package.

[0097] The registration center 110 and the deployment device 120 can establish a connection via a wired or wireless network.

[0098] Furthermore, such as Figure 2 As shown, the registry center 110 can obtain the application blueprint and resource index of the application to be deployed allocated to the deployment device 120, and establish n sets of correspondence between application blueprints, resource indexes and agent identifiers (id) based on the application blueprint and resource index of the application to be deployed. The agent identifier (id) is used to uniquely identify the deployment device, and n is an integer greater than or equal to 1. After the registry center 110 allocates the n sets of correspondence to the corresponding deployment device 120, the deployment device 120 can obtain application resources from the resource server 130 according to the n sets of correspondence and perform the corresponding resource deployment.

[0099] The application blueprint includes at least: a resource storage path and an executable command (or instruction). The resource storage path indicates the path where application resources are stored after being acquired, for example, "C:\Program Files\appX". The executable command is the command that the deployment device 120 needs to execute after storing the acquired application resources according to the resource storage path in the application blueprint. It may include system update commands, restart commands, shutdown commands, install commands, and / or application run commands, etc. The executable command can be input from a control terminal, which can be manual or a third-party system (e.g., a control system running on a server).

[0100] Since the deployment device 120 may need to perform operations such as restarting the system after acquiring application resources, carrying executable commands in the application blueprint can enable the deployment device 120 to execute the corresponding commands after acquiring application resources, thereby automating and streamlining the download of application resources and the execution of corresponding commands.

[0101] In practical applications, in some scenarios, such as resource coverage scenarios or certificate access scenarios, there may be no corresponding executable commands. In this case, the executable command element in the application blueprint is empty. At this time, the application blueprint can also set the position of the executable command, and the character of the position is "NULL". Alternatively, the application blueprint can not set the position of the executable command. This application embodiment does not limit this.

[0102] Furthermore, to accurately identify application blueprints, an application blueprint can also include an application blueprint identifier (blueprint_id) to uniquely identify the application blueprint. This application blueprint identifier can be a string, such as a name, code, serial number, or a combination of preset characters (such as numbers), like blueprint_001. In practical applications, the application blueprint identifier assigned by the registry center 110 can correspond to the type of application resource stored on the resource server 130. For example, if the type of application resource is an appX installation package (i.e., the application resource is an installation package for the application appX), and this appX installation package has three versions: appX001, appX002, and appX003, the application blueprint identifier for each version of the appX installation package can be appXblueprint_001.

[0103] As shown above, an application blueprint can include at least two elements, and each pair of elements can be separated by a preset delimiter, such as an underscore, semicolon, colon, or space. For example, suppose an application blueprint includes three elements: an application blueprint identifier, a resource storage path, and an executable command. The application blueprint identifier is `blueprint_id`, the resource storage path is `resource_path`, the executable command is `refresh_cmd`, and the delimiter is a colon. Then, the format of this application blueprint can be: `blueprint_id:resource_path:refresh_cmd`. If the executable command is empty, the format of this application blueprint can be `blueprint_id:resource_path:NULL` or `blueprint_id:resource_path`.

[0104] A resource index includes at least the following: a resource retrieval address, which indicates the address for retrieving application resources. This address can be a Uniform Resource Identifier (URI), which typically consists of two parts: the first part is the resource retrieval protocol (or service method), such as Hypertext Transfer Protocol (HTTP), File Transfer Protocol (FTP), or Network File System (NFS); the second part is the specific address for retrieving the resource. This specific address includes the Internet Protocol (IP) address (sometimes also including the interface number) of the host storing the application resource, and the specific address of the application resource on the host, such as the directory and filename. In some scenarios, the specific address of the application resource on the host can be empty. For example, the resource retrieval address is "http: / / appX.com / ".

[0105] Furthermore, in order to accurately identify resource indexes, resource indexes may also include a resource index identifier (index_id) used to uniquely identify the resource index. The resource index identifier can be a string, such as a name, code, serial number, or a combination of preset characters (such as numbers), such as index_001.

[0106] As shown above, a resource index can include at least one element. When it includes at least two elements, each pair of elements can be separated by a preset delimiter, such as an underscore, semicolon, colon, or space. For example, assuming a resource index includes a resource index identifier and a resource retrieval address, where the resource index identifier is index_id, the resource retrieval address is resource_uri, and the delimiter is a colon, then the format of the resource index can be: index_id:resource_uri.

[0107] Furthermore, the registration center 110 can also be configured with a first application programming interface (API) and a second API. The first API is used to interact with the deployment device 120, and the second API is used to interact with the control terminal. It should be noted that the registration center 110 can also interact with the control terminal through a designated operation page, which can be a Hyper Text Markup Language (HTML) page, such as an HTML5 page. In this embodiment, the registration center 110 obtains the application blueprint and resource index provided by the control terminal through the second API or the designated operation page. The registration center 110 can also provide the deployment device 120 with the mapping relationship containing the application blueprint and resource index through the first API.

[0108] It should be noted that the application blueprints, resource indexes, and corresponding relationships mentioned above can all be manually compiled and then entered into the registry center.

[0109] This application provides an application deployment method, applicable to... Figure 1 and Figure 2 The application deployment system shown assumes that the application blueprint includes an application blueprint identifier, resource storage path, and executable commands, and the resource index includes a resource index identifier and resource retrieval address, such as... Figure 3 As shown in the example, this application uses the registration center as a deployment device for application deployment. The application deployment process for other deployment devices can refer to this one deployment device. The application deployment method includes:

[0110] Step 201: The deployment device registers with the registration center.

[0111] In this embodiment, each deployment device needs to register with the registration center before the registration center can perform subsequent management and application deployment processes. Optionally, such as Figure 4 As shown, the registration process of the deployment device in the registry center may include:

[0112] Step 2011: The deployment device sends a registration request to the registration center.

[0113] After the deployment device sends the registration request to the registration center, the registration center receives the registration request sent by the deployment device.

[0114] Optionally, the deployment device may first obtain configuration information, which includes information about the first application programming interface (API) of the registration center. For example, the information about the first API could be its identifier. Then, the deployment device sends a registration request to the registration center through the first API. Correspondingly, the registration center receives the registration request sent by the deployment device through the first API. The first API is an interface provided by the registration center for communication with the deployment device. The configuration information may be pre-configured in the agent software installed on the deployment device, and the deployment device can automatically obtain this configuration information from the agent software after power-on.

[0115] Step 2012: The registration center assigns an agent identifier (agent_id) to the deployment device based on the registration request.

[0116] In practical applications, the registration request may include a serial number identifying the deployment device, such as an IP address or a Media Access Control (MAC) address (also known as a physical address or hardware address). The registration center identifies the deployment device based on this serial number and assigns a unique agent identifier to it. It's important to note that this unique identifier means it can uniquely identify a deployment device among multiple deployment devices managed by the registration center; that is, the agent identifier is not repeated within the application deployment system. The agent identifier can be a string, such as a name, code, serial number, or a combination of preset characters (such as numbers), for example, agent_001. Optionally, the registration request may also include information such as the deployment device's port number.

[0117] The registration center can determine the application environment to which a deployment device belongs based on the serial number carried by the deployment device. For example, it can determine that the deployment device is in a production environment based on its IP address.

[0118] Step 2013: The registration center sends a registration request response to the deployment device, which includes an agent identifier.

[0119] The registration process is complete when the deployment device receives a registration request response from the registration center. In practical applications, the deployment device can also reply to the registration center with a response message carrying a proxy identifier after receiving the registration request response, informing the registration center that the deployment device has successfully received the proxy identifier and registration is complete. This can reduce problems that may occur during the interaction between the registration center and the deployment device.

[0120] Once the deployment device is registered with the registry center, the registry center can manage the deployment device and perform subsequent application resource deployment.

[0121] Step 202: The registry center obtains the application blueprint and resource index of the application to be deployed assigned to the deployment device. The application blueprint includes the resource storage path and executable commands, and the resource index includes the resource acquisition address.

[0122] In different application environments, the total number of resources that an application needs to deploy (i.e., all resources that need to be deployed) varies. For example, an application environment may include a development environment, a test environment, an acceptance testing environment, or a production environment. The total number of resources that an application needs to deploy differs in these different application environments.

[0123] Among them, the development environment is a server environment or isolated environment specifically used for application development. Its configuration matches the application to be developed. The development environment is an integrated runtime environment of C / C++ / Java / Python / Web development environments under Windows, Linux, or MacOS systems. The testing environment is used for application testing. It refers to the total amount of computer hardware, software, network equipment, and historical data necessary to complete application testing. Its configuration is generally less than or equal to that of the production environment. The integration environment is an environment for testing, verification, simulation, and modeling that integrates different application systems to form a new system. The production environment is the environment that is officially provided to the outside world. It is the environment delivered to customers for final use. This production environment can be a real environment.

[0124] For example, the complete deployment resources of the application to be deployed in the development and testing environments include the application ontology and application configuration files; in the integration environment, the complete deployment resources include the application ontology and database resources; and in the production environment, the complete deployment resources include the application ontology and load balancing resources. Furthermore, the complete deployment resources of the application to be deployed can be deployed on at least one target deployment device. The number of target deployment devices varies depending on the actual deployment scenario and the application environment.

[0125] Optionally, assuming the deployment device in step 201 is a device in a specified application environment (the specified application environment is the application environment where the application to be deployed currently needs to be deployed), the process of obtaining the application blueprint and resource index of the application to be deployed allocated to the deployment device may include:

[0126] Step A: Receive m resource indexes of the application to be deployed. The application resources corresponding to these m resource indexes constitute the complete deployment resources of the application in the specified application environment. Here, m is an integer greater than or equal to 1.

[0127] For example, if the specified application environment is an integrated environment, the application to be deployed is XXapp, and the complete resources to be deployed include the application body: XXapp.war and the application configuration file: application.properties, then two resource indexes can be set. The resource retrieval address in the first resource index is: http: / / 1.100.132.116 / repository / XXapp / AT / latest / XXapp.war, which indicates the retrieval address of the application body: XXapp.war; the resource retrieval address in the second resource index is: http: / / 1.100.132.116 / repository / XXapp / AT / latest / config / application.properties, which indicates the retrieval address of the application configuration file: application.properties.

[0128] Step B: Receive p application blueprints of the application to be deployed. The storage paths of these p application blueprints correspond to m resource indexes.

[0129] The resource storage paths of these p application blueprints are used to store resources obtained through m resource indices, where m and p can be equal or unequal. For example, resources obtained through one or more of the m resource indices can be stored through the resource storage path of one application blueprint.

[0130] For example, taking the example in step A again, the resource storage path in the application blueprint corresponding to the application ontology XXapp.war obtained through the resource retrieval address in the first resource index is / at / tomcat / webapps / ; the resource storage path in the application blueprint corresponding to the application configuration file application.properties obtained through the resource retrieval address in the second resource index is / at / tomcat / webapps / XXapp / resources / .

[0131] In practice, the registry center receives application blueprints and resource indexes in steps A and B above as follows:

[0132] The control terminal (manual or third-party system) directly inputs the application blueprint and resource index assigned to the deployment device into the registry center from the backend, and the registry center obtains the application blueprint and resource index accordingly.

[0133] On the one hand, the registry center can provide a second application programming interface (API), which is the interface for communication between the registry center and the backend control terminal. The registry center can obtain the application blueprint of the application to be deployed through the second API; it can also obtain the resource index of the application to be deployed through the second API.

[0134] On the other hand, the registration center can provide a designated operation page, which is the page on which the control terminal inputs information to the registration center. This page can be a network operation page, i.e., a webpage, or a client operation page. This application embodiment does not limit this. The registration center can obtain the application blueprint of the application to be deployed through the designated operation page; it can also obtain the resource index of the application to be deployed through the designated operation page.

[0135] Step C: After receiving the subscription instruction from the deployment device, obtain at least one resource index from m resource indexes as the resource index of the application to be deployed to the deployment device, and obtain p application blueprints as the application blueprints of the application to be deployed to the deployment device.

[0136] In this embodiment, the subscription instruction is used to subscribe to an application in the registry center. The subscription instruction can be triggered by either the deployment device or the control terminal. When the subscription instruction is triggered by the deployment device, typically in step 201, the deployment device includes the subscription instruction in the registration request. This subscription instruction indicates the application to be subscribed to. When the registry center has complete resources for the subscribed application to be deployed (in practical applications, the registry center may not have prepared the corresponding resources when the deployment device registers), the registry center can allocate resource indexes and application blueprints to the deployment device for subsequent application deployment. When the subscription instruction is triggered by the control terminal, the control terminal can trigger the subscription instruction through a second application programming interface or a specified operation page. For example, when an application needs to be deployed in a test environment, the control terminal triggers the subscription instruction, and the registry center can allocate resource indexes and application blueprints to the deployment device in that test environment for subsequent application deployment.

[0137] Optionally, since the complete resource to be deployed may be deployed in one or more target deployment devices depending on the actual deployment scenario and / or the application environment, step C may include: the registry center determining at least one target deployment device for deploying the complete resource to be deployed in the specified application environment, the at least one target deployment device including the deployment device in step 201 above; assigning a resource index to each target deployment device among m resource indexes; and assigning an application blueprint to each target deployment device among p application blueprints. Since the deployment device in step 201 belongs to the at least one target deployment device, the registry center also determines the resource index and application blueprint assigned to the deployment device.

[0138] Step 203: Based on the application blueprint and resource index of the application to be deployed, the registration center establishes a correspondence between n sets of application blueprints, resource indexes and proxy identifiers.

[0139] Once the registry center obtains the application blueprint, resource index, and agent identifier allocated to the deployment device, it can establish a correspondence between the three. In practical applications, the process of establishing this correspondence is controlled by the control terminal (manual or third-party system) to execute the registry center. On one hand, the control terminal can directly input the established correspondence through the second application programming interface or a designated operation page. That is, the registry center executes steps 202 and 203 simultaneously, and obtaining the correspondence completes the process of obtaining the application blueprint, resource index, and agent identifier, and establishing the correspondence. On the other hand, the control terminal can also control the registry center to generate the corresponding correspondence through a designated operation page after the registry center obtains the application blueprint, resource index, and agent identifier. For example, the registry center displays the application blueprint, resource index, and agent identifier obtained by the registry center on the designated operation page, and then the control terminal controls the registry center to establish n sets of correspondences through drag-and-drop, single-click, and / or double-click operations.

[0140] For example, the final established correspondence can be in the format of: blueprint_id:index_id:agent_id, or blueprint_id-index_id-agent_id.

[0141] Step 204: The registration center sends a deployment command to the deployment device. The deployment command includes n sets of correspondences.

[0142] Optionally, the registration center sends a deployment command to the deployment device through the first application programming interface. This deployment command instructs the deployment device to obtain application resources through the resource acquisition addresses in each set of correspondences, store the application resources according to the resource storage path, and execute executable commands after storing the application resources.

[0143] Step 205: The deployment device obtains application resources through the resource acquisition address in each group of correspondences, stores the application resources according to the resource storage path, and executes executable commands after storing the application resources.

[0144] After receiving the deployment command sent by the registry center, the deployment device can include the following: the correspondence between n sets of application blueprints, resource indexes and agent identifiers. The registry center can then obtain application resources through the resource acquisition address in each set of correspondences, store the application resources according to the resource storage path, and execute executable commands after storing the application resources.

[0145] For example, suppose the deployment command carries a mapping relationship: the deployment device ID is agent_001, the application resource is the appX002 (i.e., the second version of appX) installation package, the corresponding application blueprint identifier is appXblueprint_001, the resource index identifier is index_001, the application blueprint is: appXblueprint_001: C:\Program Files\appX:Install_cmd&run_cmd, where Install_cmd represents the installation command and run_cmd represents the run command, and the resource index is: index_001: http: / / appX.com / . Then the mapping relationship carried in the deployment command can be appXblueprint_001:index_001:agent_001, the resource acquisition address is "http: / / appX.com / ", the resource storage path is "C:\Program Files\appX", and the executable commands are the installation command and the run command. The deployment device obtains the appX002 installation package via "http: / appX.com / " and stores it in the folder "C:\Program Files\appX". After storage, it executes the installation and run commands for the appX002 installation package.

[0146] Step 206: The deployment device sends a deployment response to the registration center. The deployment response includes the execution result obtained by the deployment device from executing the executable command.

[0147] Optionally, after executing all executable commands in a set of correspondences, the deployment device can send the execution results back to the registry center via a deployment response. Alternatively, after executing all executable commands in multiple sets of correspondences, the deployment device can send the execution results of all multiple sets of executable commands back to the registry center via a single deployment response. Accordingly, upon receiving the deployment response, the registry center can determine subsequent operations based on the execution results carried in the deployment response. This reduces problems that may arise during the interaction between the registry center and the deployment device.

[0148] For example, the execution result may include a feedback status identifier and feedback status information. The feedback status identifier indicates whether the command execution was successful or failed. For example, the feedback status can be 0 or 1, where 0 represents successful execution and 1 represents failed execution. The feedback status information carries the reason for failure when the executable command fails. When the executable command executes successfully, the feedback status information is empty. For example, when the feedback status is 1, the feedback status information includes permission error, resource acquisition address error, or response timeout, etc. The registry center can perform corresponding manual intervention when the executable command fails. For example, if the feedback status information includes permission error, the permissions of the deployment device can be modified; if the feedback status information includes resource acquisition address error, the resource acquisition address can be modified; if the feedback status information includes response timeout, the reason for the deployment device's response timeout can be queried and processed accordingly.

[0149] Step 207: When any element in the first correspondence changes, the registry center sends a first update command to the deployment device. The first update command includes: a second correspondence, which is the updated first correspondence. The application blueprint identifier in the first correspondence and the second correspondence are the same. The first correspondence is any one of the n correspondences.

[0150] In actual implementation, due to different deployment scenarios and / or changes in the application environment (such as application environment upgrades or rollbacks), some elements in the n sets of correspondences may change. Accordingly, the registration center will send an update command to the deployment device.

[0151] In this embodiment of the application, the application blueprint identifier can correspond to the type of application resource stored on the resource server. Changes in elements other than the application blueprint identifier in the first correspondence can be regarded as an update of the first correspondence. Of course, when the application blueprint identifier of a correspondence in the registry changes, it can be regarded as a new correspondence. Its usage process can refer to steps 204 to 206 above.

[0152] Step 208: The deployment device performs the action corresponding to the second correspondence.

[0153] In the embodiments of this application, the deployment device can perform the action corresponding to the second correspondence in various ways. The embodiments of this application will illustrate the following two ways.

[0154] In the first method, the deployment device as a whole performs the actions corresponding to the second correspondence.

[0155] For example, the deployment device can obtain application resources through the resource acquisition address in the second correspondence, store the application resources according to the resource storage path in the second correspondence, and execute the executable commands in the second correspondence. The process can be referred to step 205 above.

[0156] In the second method, the deployment device executes the action corresponding to the target element that has changed in the second correspondence.

[0157] First, the deployment device detects the target element that has changed in the second correspondence.

[0158] Since the deployment device obtained the first correspondence in step 204, after receiving the first update command sent by the registry center, the deployment device can first compare the correspondence carried in the first update command with the application blueprint identifier of the currently stored correspondence. If the application blueprint identifiers are the same, it means that the currently stored correspondence is the first correspondence, and the correspondence carried in the first update command is the second correspondence, that is, the second correspondence is the updated first correspondence. Then, based on the first correspondence, the device detects the elements that have changed in the second correspondence and determines these elements as target elements. Specifically, the deployment device compares the first correspondence with the second correspondence and determines the different elements as target elements.

[0159] Then, the deployment device executes the action corresponding to the target element according to the second correspondence.

[0160] In this application embodiment, the target element updated in the second correspondence relationship is different from that in the first correspondence relationship, and the actions performed by the deployment device are different. This application embodiment will be illustrated with the following two possible implementation methods as examples:

[0161] In the first possible implementation, when the target element includes a resource acquisition address and / or a resource storage path, the deployment device acquires the application resource through the resource acquisition address in the second correspondence, and after storing the application resource according to the resource storage path in the second correspondence, executes the executable command in the second correspondence. For example, referring to the example in step 205 above, the second correspondence is appXblueprint_001:index_002:agent_001, the application blueprint is: appXblueprint_001:D:\Program Files\appX:Install_cmd&run_cmd, and the resource index is: index_002:http: / appX2.com / . The elements in the second correspondence that change relative to the first correspondence are the resource acquisition address: "http: / appX2.com / " and the resource storage path: "D:\Program Files\appX". The deployment device then re-acquires the appX002 installation package via "http: / appX2.com / " and stores the appX002 installation package in the folder "D:\Program Files\appX". After storage, it executes the installation command and run command for the appX002 installation package.

[0162] In the second possible implementation, when the target element includes an executable command, the deployment device executes the executable command in the second correspondence.

[0163] For example, referring to the example in step 205 above, the second correspondence is appXblueprint_001:index_001:agent_001, the application blueprint is: appXblueprint_001:C:\Program Files\appX:update_cmd, where "update_cmd" is the update command, and the resource index is: index_001:http: / appX.com / . The element that changes in the second correspondence compared to the first correspondence is the executable command: "update_cmd". Therefore, the deployment device only needs to execute the update command for the appX002 installation package.

[0164] The actions performed using the first and second implementation methods described above are fewer than those performed by directly executing the actions corresponding to the second correspondence in the first method, and are therefore more efficient.

[0165] In this application embodiment, application resource updates include various scenarios, such as application upgrades, application resource rollbacks, and configuration file updates. This application embodiment will use application upgrades and application resource rollbacks as examples for illustration:

[0166] The first feasible method among the first and second methods mentioned above can be used to upgrade applications. Upgrading an application refers to the process of replacing a low-version application resource with a high-version application resource for the same type of application resource.

[0167] Specifically, when an application upgrade is required, the control terminal can update the application blueprint and / or resource index in the first correspondence for the updated application resources in the resource server (the version of the application resources is higher than the version of the application resources before the update) to obtain the second correspondence. Then, the action corresponding to the second correspondence can be executed using the first method or the first feasible method of the second method.

[0168] For example, referring to the example in step 205 above, assuming the upgraded application resource is the appX003 (i.e., the third version of appX) installation package, optionally, the control terminal can replace the appX002 installation package corresponding to the resource acquisition address "http: / / appX.com / " with the appX003 installation package. Then, the resource storage path in the application blueprint is updated from "C:\Program Files\appX" to "D:\Program Files\appX" to obtain a second correspondence. After obtaining this second correspondence, the deployment device obtains the appX003 installation package through "http: / / appX.com / " and stores the appX003 installation package in the folder "D:\Program Files\appX". After storage, the installation and run commands for the appX003 installation package are executed to upgrade the appX application.

[0169] Optionally, the control unit can update the resource retrieval address "http: / / appX.com / " in the resource index to "http: / / appX3.com / ", corresponding to the appX003 installation package. Then, it updates the resource storage path in the application blueprint from "C:\Program Files\appX" to "D:\Program Files\appX" to obtain a second mapping. After obtaining this second mapping, the deployment device retrieves the appX003 installation package via "http: / / appX3.com / " and stores it in the folder "D:\Program Files\appX". After storage, it executes the installation and run commands for the appX003 installation package to upgrade the appX application.

[0170] Optionally, the control terminal can also update the resource retrieval address "http: / / appX.com / " in the resource index to "http: / / appX3.com / " to obtain a second mapping. After obtaining this second mapping, the deployment device retrieves the appX003 installation package through "http: / / appX3.com / " and stores the appX003 installation package in the folder "C:\Program Files\appX". After storage, it executes the installation and run commands for the appX003 installation package to upgrade the appX application.

[0171] Using the first feasible method among the first and second methods mentioned above, application resource rollback can also be achieved. Application resource rollback refers to the process of rolling back the storage state of application resources to the previous storage state.

[0172] Specifically, when application resource rollback is required, the control terminal can update the application blueprint and / or resource index in the first correspondence for the updated application resources to obtain the second correspondence. Then, the action corresponding to the second correspondence can be executed using the first method or the first feasible method of the second method.

[0173] For example, referring to the example in step 205 above, assuming the rolled-back application resource is the appX001 (i.e., the first version of appX) installation package, optionally, the control terminal can replace the appX002 installation package corresponding to the resource acquisition address "http: / / appX.com / " with the appX001 installation package. Then, the resource storage path in the application blueprint is updated from "C:\Program Files\appX" to "D:\Program Files\appX" to obtain a second correspondence. After obtaining this second correspondence, the deployment device obtains the appX001 installation package through "http: / / appX.com / " and stores the appX001 installation package in the folder "D:\Program Files\appX". After storage, the installation and run commands for the appX001 installation package are executed to achieve the rollback of the appX application.

[0174] Optionally, the control unit can update the resource retrieval address "http: / appX.com / " in the resource index to "http: / appX1.com / ", corresponding to the appX001 installation package. Then, it updates the resource storage path in the application blueprint from "C:\Program Files\appX" to "D:\Program Files\appX" to obtain a second mapping. After obtaining this second mapping, the deployment device retrieves the appX001 installation package via "http: / appX1.com / " and stores it in the folder "D:\Program Files\appX". After storage, it executes the installation and run commands for the appX001 installation package to achieve the rollback of the appX application.

[0175] Optionally, the control terminal can update the resource retrieval address "http: / / appX.com / " in the resource index to "http: / / appX1.com / " to obtain a second mapping. After obtaining this second mapping, the deployment device retrieves the appX001 installation package through "http: / / appX1.com / " and stores the appX001 installation package in the folder "C:\Program Files\appX". After storage, it executes the installation and run commands for the appX001 installation package to achieve the rollback of the appX application.

[0176] It should be noted that when the target element includes a resource storage path, the deployment device can perform the corresponding action using either the first feasible method described above, or the third feasible method described below:

[0177] The third possible implementation involves the deployment device obtaining the application resource from local storage according to the first resource storage path in the first correspondence, and then storing the application resource again according to the second resource storage path in the second correspondence. The deployment device then replaces the first correspondence in local storage with the second correspondence, i.e., it overwrites the first correspondence with the second correspondence. For example, referring to the example in step 205 above, the second correspondence is appXblueprint_001:index_001:agent_001, the application blueprint is: appXblueprint_001:D:\Program Files\appX:Install_cmd&run_cmd, and the resource index is: index_001:http: / appX.com / . The element in the second correspondence that changes relative to the first correspondence is the resource storage path: "D:\Program Files\appX". The first resource storage path is "C:\Program Files\appX", and the second resource storage path is "D:\Program Files\appX". The deployment device can obtain the appX002 installation package through "C:\Program Files\appX" and store the appX002 installation package in the folder "D:\Program Files\appX". Then, the second correspondence is used to replace the first correspondence.

[0178] The third implementation method performs fewer actions than the first implementation method and is more efficient.

[0179] Furthermore, after replacing the first correspondence with the second correspondence using the third possible method, the application resources downloaded through the first correspondence can be deleted. For example, in step 205, the appX002 installation package is stored in "C:\Program Files\appX" according to the first correspondence. After storing the appX002 installation package in "D:\Program Files\appX" using the third possible method, the appX002 installation package stored in "C:\Program Files\appX" is deleted.

[0180] However, if the application resources downloaded through the first mapping are retained, a fast rollback of resources can be achieved in subsequent processes. This fast rollback process can include the following two implementation methods:

[0181] The first implementation method includes the following fast rollback process:

[0182] Step A1: After obtaining the application resources stored locally according to the first resource storage path in the first correspondence relationship, and storing the application resources again according to the second resource storage path in the second correspondence relationship, the deployment device records the correspondence relationship between the first resource storage path and the second resource storage path.

[0183] For example, the first resource storage path is C:\Program Files\appX, and the second resource storage path is D:\Program Files\appX. The corresponding relationship between the first resource storage path and the second resource storage path is C:\Program Files\appX-D:\Program Files\appX. Of course, the above relationship can also be recorded in other ways, and this application embodiment does not limit this.

[0184] Step A2: The deployment device receives a rollback instruction sent by the registry center. This rollback instruction is used to indicate that the storage state of the application resources should be rolled back to the previous storage state.

[0185] In this embodiment, when a quick rollback is required, the control terminal can trigger the registry center to create a rollback instruction. This rollback instruction is used to instruct the application resource's storage state to be rolled back to the previous storage state. This rollback instruction is generated for the case where only the resource storage path has changed in the above correspondence.

[0186] Step A3: The deployment device obtains the second resource storage path from the currently stored second correspondence.

[0187] Step A4: The deployment device obtains the first resource storage path based on the correspondence between the first resource storage path and the second resource storage path.

[0188] Step A5: The deployment device updates the second resource storage path in the currently stored second correspondence to the first resource storage path.

[0189] For example, the first correspondence could be appXblueprint_001:index_001:agent_001, the resource acquisition address could be "http: / appX.com / ", the resource storage path could be "C:\Program Files\appX", and the executable commands could be the installation command and the run command. After receiving the rollback command, the deployment device obtains the second resource storage path "D:\Program Files\appX" from the second mapping relationship, queries the mapping relationship between the first and second resource storage paths C:\Program Files\appX-D:\Program Files\appX, and obtains the first resource storage path "C:\Program Files\appX". Then, it updates the second resource storage path in the second mapping relationship to the first resource storage path, resulting in the first mapping relationship as appXblueprint_001:index_001:agent_001. The application blueprint is: appXblueprint_001:D:\Program Files\appX:Install_cmd&run_cmd, and the resource index is: index_001:http: / appX.com / .

[0190] The second implementation method, the fast rollback process includes:

[0191] Step B1: After obtaining the application resources stored locally according to the first resource storage path in the first correspondence relationship and storing the application resources again according to the second resource storage path in the second correspondence relationship, the deployment device records the correspondence relationship between the first resource storage path and the second resource storage path.

[0192] Step B1 can be referred to step A1 above, and will not be repeated in this embodiment of the application.

[0193] Step B2: The deployment device receives a second update command sent by the registry center. The second update command is a command sent by the registry center to the deployment device after detecting a change in any element in the second correspondence. The update command includes a third correspondence, which is the updated second correspondence. The application blueprint identifier in the second correspondence and the third correspondence are the same.

[0194] Step B2 can be referred to step 207 above, and will not be repeated in this embodiment of the application.

[0195] Step B3: When the third correspondence and the second correspondence differ only in the resource storage path, and the resource storage path in the third correspondence is the same as the first resource storage path recorded in the correspondence, update the second resource storage path in the second correspondence to the first resource storage path.

[0196] Since the deployment device obtained the second correspondence in step 207, after receiving the second update command sent by the registry center, it can detect the changed elements in the third correspondence based on the second correspondence. This detection process can refer to the second method provided in step 208 above. Specifically, the deployment device can first compare the correspondence carried in the second update command with the application blueprint identifier of the currently stored correspondence. If the application blueprint identifiers are the same, it indicates that the currently stored correspondence is the second correspondence, and the correspondence carried in the second update command is the third correspondence, meaning the third correspondence is the updated second correspondence. Then, it detects the changed elements in the third correspondence based on the second correspondence and identifies these elements as target elements. Specifically, the deployment device compares the second and third correspondences and identifies the different elements as target elements. When the third correspondence differs from the second correspondence only in the resource storage path, and the resource storage path in the third correspondence is the same as the first resource storage path recorded in the correspondence, the second resource storage path in the second correspondence is updated to the first resource storage path. This path update process can refer to steps A3 to A5 above.

[0197] When the third correspondence and the second correspondence differ only in the resource storage path, and the resource storage path in the third correspondence differs from the first resource storage path recorded in the correspondence, the action corresponding to the third correspondence can be executed by referring to the first feasible method in the first method and the second method described above. This application embodiment will not elaborate further on this.

[0198] In summary, the application deployment method provided in this application embodiment has a simple format for application blueprints and resource indexes. Only basic knowledge is required to quickly write the corresponding relationships needed for application deployment, eliminating the need to write complex task scripts. This lowers the orchestration threshold, thereby reducing the complexity of application deployment and improving its efficiency.

[0199] In related technologies, because deployment processes differ for different application environments (such as development, testing, integration, or production environments), technicians need to develop different task scripts to adapt to these environments. For example, for the same application, technicians may need to provide two sets of task scripts for the development and testing environments. This results in high application deployment complexity and low deployment efficiency.

[0200] The application deployment method provided in this application embodiment allows the registration center to establish a correspondence based on the application blueprint, resource index, and agent identifier. The deployment device can then obtain and store application resources and execute executable commands based on this correspondence to deploy the application resources. Since the application blueprint and resource index have simple formats, only basic knowledge is required to quickly write the correspondence needed for application deployment. For different application environments, there is no need to develop different task scripts; only the correspondence needs to be established or adjusted to achieve environment adaptation. Therefore, the complexity of application deployment is effectively reduced, and deployment efficiency is improved.

[0201] For ease of understanding, this application embodiment uses an application to be deployed, XXapp, as an example. Assume the complete resources to be deployed for this application include the application itself, database resources, and load balancing resources. The registry center address is http: / / register.deploysystem.internal:8080. Referring to step 201, the deployment device can register with the registry center based on this address. Assume the application XXapp needs to be deployed in four application environments: development environment, testing environment, integration environment, and production environment. In different application environments, different deployment relationships can be established for the same application, as shown in Table 1. The application blueprint includes three parts: application blueprint identifier: blueprint_id, resource storage path: resource_path, and executable command: refresh_cmd. The resource index includes two parts: resource index identifier: Index and resource retrieval address: Resource_uri.

[0202] Taking the development environment as an example, referring to Table 1, in the development environment, the application to be deployed, XXapp, needs to be deployed on one deployment device. The agent ID of the deployment device is Agent-01. The complete resources to be deployed for the application XXapp include the compressed package app.war and the application configuration file app.config. On this deployment device, Agent-01 needs to be assigned two sets of correspondences. Referring to the correspondence format in step 203, these two sets of correspondences can be Agent-01-XXApp.app.war-XXApp.app.war and Agent-01-XXApp.app.application.properties-XXApp.app.config, respectively.

[0203] In the corresponding relationship: Agent-01-XXApp.app.war-XXApp.app.war, the application blue...Figure X XApp.app.war includes: XXApp.app.war- / dev / tomcat / webapps / - / dev / tomcat / bin / restart.sh, and the resource index XXApp.app.war includes: XXApp.app.war-http: / / 1.100.132.116 / repository / XXapp / a100150 / build99 / XXapp.war;

[0204] In the corresponding relationship: Agent-01-XXApp.app.application.properties-XXApp.app.config, the application blue... Figure X XApp.app.application.properties includes: XXApp.app.application.properties- / dev / tomcat / webapps / XXapp / resources / - / dev / tomcat / bin / restart.sh, and the resource index XXApp.app.config includes: XXApp.app.config-http: / / 1.100.132.116 / repository / XXapp / a100150 / build56 / config / application.properties. The mapping relationships required for allocation in other application environments in Table 1 can be referenced from the explanation of the mapping relationships required for allocation in the development environment described above; this application embodiment will not repeat them here.

[0205] It should be noted that in development and testing environments, generally only updates to the application itself are considered. Referring to Table 1, in the development environment, there is a deployment device, agent01. The complete resources for the application to be deployed, XXapp, include the compressed file app.war and the application configuration file app.config. After deploying the compressed file XXapp.war in deployment device agent01, if updates to the compressed file are needed, refer to steps 207 and 208. The control end only needs to modify the application blueprint. Figure X By accessing the resource index XXApp.app.war containing the resource_uri, you can update the compressed package under the path / dev / tomcat / webapps / , and then execute the corresponding refresh_cmd command to start the XXapp service.

[0206] In the test environment, there is a deployment device agent02. The complete resources for the application XXapp to be deployed include the compressed file app.war and the application configuration file app.config. After deploying the compressed file XXapp.war on deployment device agent02, if updates to the compressed file are needed, refer to steps 207 and 208. The control end only needs to modify the application blueprint. Figure X By accessing the resource index XXApp.app.war corresponding to XApp.app.war, you can update the compressed package under the path / test / tomcat / webapps / , and then execute the corresponding refresh_cmd to start the XXapp service.

[0207] In integrated and production environments, besides focusing on application updates, updates to database or load balancing resources may also be required. Referring to Table 1, in the integrated environment, there are two deployment devices, agent03 and agent04. The complete resources to be deployed for the application XXapp include the compressed file app.war and application configuration file app.config, which need to be deployed in deployment device agent03, and the database resource db.binary and load balancing resource db.config, which need to be deployed in deployment device agent04. After deploying the compressed file XXapp.war in deployment device agent03, if updates to the compressed file are needed, refer to steps 207 and 208. The control end only needs to modify the application blueprint. Figure X By accessing the resource index `resource_uri` in `XXApp.app.war` corresponding to `XApp.app.war`, you can update the compressed package under the ` / at / tomcat / webapps / ` path. Then, executing the corresponding `refresh_cmd` command will start the `XXapp` service. After deploying the database resource `db.binary` in the deployment device `agent04`, if you need to update the database resource, refer to steps 207 and 208. The control end only needs to modify the application blueprint. Figure X By accessing the resource_uri in the resource index XXApp.app.db.binary corresponding to XApp_db.binary, you can update the database resources under the path / at / db / mysql / . Then, by executing the corresponding refresh_cmd, you can achieve silent installation of the database resources.

[0208] In the production environment, there are three deployment devices: agent05, agent06, and agent07. The complete resources for the application XXapp to be deployed include the compressed file app.war and application configuration file app.config to be deployed in deployment device agent05; the database resource db.binary and database configuration file db.config to be deployed in deployment device agent06; and the load balancing resource lb.config to be deployed in deployment device agent07. After deploying the load balancing resource lb.config in deployment device agent07, if updates to the load balancing resource are needed, refer to steps 207 and 208. The control end only needs to modify the application blue... Figure X By accessing the resource index XXApp.app.lb.config corresponding to XApp_lb.config, you can update the database resources under the path / prod / lb / nginx / conf / , and then execute the corresponding refresh_cmd to achieve silent installation of load balancing resources.

[0209] It should be noted that the above update process is only illustrative. In actual applications, configuration files can also be updated. For example, updating the application configuration file can be achieved by reloading the application configuration file through the resource_uri in the resource index corresponding to the application blueprint. This embodiment will not elaborate on this further.

[0210] Table 1

[0211]

[0212]

[0213]

[0214] As can be seen from the above examples, the application deployment method provided in this application embodiment does not require the development of different task scripts for different application environments. It only needs to establish or adjust the corresponding relationship to achieve environment adaptation. Furthermore, the corresponding relationship in different environments can be reused or referenced with each other. For example, the corresponding relationship assigned to deployment device Agent-02 in the test environment in Table 1 above can be set with reference to the corresponding relationship assigned to deployment device Agent-01 in the development environment. The corresponding relationship in the two environments can be referenced with each other or simply modified. Therefore, the complexity of application deployment is effectively reduced and the deployment efficiency is improved.

[0215] Traditional process-oriented application deployment methods require writing corresponding task scripts for each action in the application deployment process, resulting in a long script writing cycle, especially for scripts involving processes such as copying, transmitting, downloading, decompressing, or installing.

[0216] The application deployment method provided in this application adds executable commands to the application blueprint. Once the deployment device downloads the application resources, these commands can be executed. Technical personnel only need to configure appropriate executable commands on the application blueprint to perform processes such as copying, transferring, downloading, decompressing, or installing. Therefore, no specialized scripting is required, reducing scripting time. Furthermore, the simple format of the application blueprint and resource index lowers the programming threshold; only basic knowledge is needed to create the necessary correspondences for application deployment. Moreover, the application relationship deployment process is plug-and-play, enabling rapid application deployment.

[0217] Furthermore, traditional process-oriented application deployment methods require writing targeted task scripts for different application environments, resulting in poor reusability of these scripts. In contrast, the application deployment method provided in this application embodiment only requires establishing at least one mapping relationship for application deployment. For different application environments, only this mapping relationship needs to be created or adjusted, resulting in high reusability.

[0218] Furthermore, traditional process-oriented application deployment methods require the deployment engine to send a large number of task scripts and application resources to the deployment device simultaneously if multiple applications or multiple tasks of an application need to be deployed at the same time. This increases the load on the deployment engine, increases the demand for network bandwidth, and can easily cause system bottlenecks.

[0219] The application deployment method provided in this application embodiment uses only simple string concatenation for the correspondence used for application deployment, which consumes less network bandwidth and has a smaller impact on the load of the registration center.

[0220] Furthermore, in this embodiment, the application resources can be application installation packages, application plugins, application configuration files, executable files, code files, or application differential packages. When the application resources are application plugins or application differential resources, incremental updates of the application can be realized, reducing the demand for network bandwidth and improving the application deployment speed.

[0221] It should be noted that the order of the steps in the application deployment method provided in this application embodiment can be appropriately adjusted, and the steps can also be added or removed as appropriate. For example, some steps in step 201 and step 202 can be interchanged. Any variation methods that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the protection scope of this application, and therefore will not be elaborated further.

[0222] Figure 5 This is a registration center 30 shown according to an exemplary embodiment. The registration center can be the registration center in the above method embodiment. The registration center 30 includes: an acquisition module 301, an establishment module 302, and a first sending module 303.

[0223] The acquisition module 301 is used to acquire the application blueprint and resource index of the application to be deployed allocated to the deployment device. The application blueprint includes the resource storage path and executable commands, and the resource index includes the resource acquisition address.

[0224] Module 302 is used to establish n sets of correspondences between the application blueprint, the resource index and the proxy identifier based on the application blueprint and resource index of the application to be deployed. The proxy identifier is used to uniquely identify the deployment device, and n is an integer greater than or equal to 1.

[0225] The first sending module 303 is used to send the deployment command to the deployment device. The deployment command includes n sets of correspondences. The deployment command is used to instruct the deployment device to obtain application resources through the resource acquisition address in each set of correspondences, store the application resources according to the resource storage path, and execute the executable command after storing the application resources.

[0226] In summary, the registration center provided in this application embodiment has a simple format for the application blueprint and resource index obtained by the acquisition module. Only simple basic knowledge is required to quickly write the corresponding relationship required for application deployment, without having to write complex task scripts. This reduces the orchestration threshold and thus reduces the complexity of application deployment and improves the efficiency of application deployment.

[0227] Optional, such as Figure 6 As shown, the acquisition module 301 includes: a first receiving submodule 3011, a second receiving submodule 3012, and an acquisition submodule 3013.

[0228] The first receiving submodule 3011 is used to receive m resource indices of the application to be deployed. The application resources corresponding to the m resource indices constitute the complete deployment resources of the application to be deployed in the specified application environment, where m is an integer greater than or equal to 1.

[0229] The second receiving submodule 3012 is used to receive p application blueprints of the application to be deployed, and the storage paths of the p application blueprints correspond to the m resource indexes.

[0230] The acquisition submodule 3013 is used to, after receiving the subscription instruction of the deployment device, when the deployment device is a device in the specified application environment, acquire at least one of the m resource indexes as the resource index of the application to be deployed allocated to the deployment device, and acquire the p application blueprints as the application blueprints of the application to be deployed allocated to the deployment device.

[0231] Accordingly, the acquisition submodule 3013 can be used to determine at least one target deployment device for deploying the complete resource to be deployed in the specified application environment, the at least one target deployment device including the deployment device, and in the m resource indexes, assign a resource index to each target deployment device, and in the p application blueprints, assign an application blueprint to each target deployment device.

[0232] Figure 7 This is a registration center 30 according to an exemplary embodiment. The registration center 30 may include: an acquisition module 301, an establishment module 302, a first sending module 303, and a second sending module 304.

[0233] The second sending module 304 is used to send a first update command to the deployment device when any element in the first correspondence changes. The first update command includes: a second correspondence, which is the updated first correspondence. The application blueprint identifier in the first correspondence and the second correspondence are the same. The first correspondence is any one of the n groups of correspondences.

[0234] Figure 8 The present invention relates to a registration center 30 according to an exemplary embodiment, the registration center 30 including: an acquisition module 301, an establishment module 302, a first sending module 303, a second sending module 304, a receiving module 305, an allocation module 306, and a third sending module 307.

[0235] The receiving module 305 is used to receive a registration request sent by the deployment device before obtaining the application blueprint and resource index allocated to the deployment device.

[0236] The allocation module 306 is used to allocate the agent identifier to the deployment device according to the registration request.

[0237] The third sending module 307 is used to send a registration request response to the deployment device, the registration request response including the agent identifier.

[0238] Optionally, the first sending module 303 can be used to send the deployment command to the deployment device through the first application programming interface of the registry center.

[0239] In this application embodiment, the application resource may include: application installation resources, application configuration files, executable files, code files, or application differential packages.

[0240] Figure 9 This is a deployment device 40 shown according to an exemplary embodiment, which may include a first receiving module 401 and a first acquiring module 402.

[0241] The first receiving module 401 is used to receive the deployment command sent by the registration center. The deployment command includes: the correspondence between n sets of application blueprints, resource indexes and agent identifiers. The agent identifier is used to uniquely identify the deployment device. The application blueprint includes the resource storage path and executable commands. The resource index includes the resource acquisition address.

[0242] The first acquisition module 402 is used to acquire application resources through the resource acquisition address in each group of the corresponding relationship, store the application resources according to the resource storage path, and execute the executable command after storing the application resources.

[0243] Figure 10 This is a deployment device 40 according to an exemplary embodiment, wherein the application blueprint further includes an application blueprint identifier, and the application blueprint identifier assigned by the registry corresponds one-to-one with the application resources stored in the resource server. The deployment device 40 may include: a first receiving module 401, a first obtaining module 402, a second receiving module 403, a detection module 404, and an execution module 405.

[0244] The second receiving module 403 is used to receive a first update command sent by the registration center. The first update command is a command sent by the registration center to the deployment device after detecting a change in any element in the first correspondence. The first update command includes: a second correspondence, the first correspondence being any one of the n correspondences, the second correspondence being the updated first correspondence, and the application blueprint identifier in the first correspondence and the second correspondence being the same.

[0245] The detection module 404 is used to detect the target element that has changed in the second correspondence.

[0246] The execution module 405 is used to execute the action corresponding to the target element according to the second correspondence.

[0247] Firstly, the execution module 405 can be used for:

[0248] When the target element includes a resource acquisition address and / or a resource storage path, the application resource is acquired through the resource acquisition address in the second correspondence, and after the application resource is stored according to the resource storage path in the second correspondence, the executable command in the second correspondence is executed; when the target element is an executable command, the executable command in the second correspondence is executed.

[0249] Secondly, the execution module 405 can be used for:

[0250] When the target element includes a resource storage path, the application resource in local storage is obtained according to the first resource storage path in the first correspondence relationship, and the application resource is stored again according to the second resource storage path in the second correspondence relationship; and the first correspondence relationship in local storage is replaced with the second correspondence relationship.

[0251] Figure 11 The present invention relates to a deployment apparatus 40 according to an exemplary embodiment, the deployment apparatus 40 comprising: a first receiving module 401, a first acquiring module 402, a second receiving module 403, a detection module 404, an execution module 405, a first recording module 406, a third receiving module 407, a second acquiring module 408, a third acquiring module 409, and a first updating module 410.

[0252] The first recording module 406 is used to record the correspondence between the first resource storage path and the second resource storage path after the application resource is obtained locally according to the first resource storage path in the first correspondence relationship and the application resource is stored again according to the second resource storage path in the second correspondence relationship.

[0253] The third receiving module 407 is used to receive the rollback instruction sent by the registration center, which is used to indicate that the storage state of the application resources be rolled back to the previous storage state.

[0254] The second acquisition module 408 is used to acquire the second resource storage path from the currently stored second correspondence.

[0255] The third acquisition module 409 is used to acquire the first resource storage path based on the correspondence between the first resource storage path and the second resource storage path.

[0256] The first update module 410 is used to update the second resource storage path in the currently stored second correspondence to the first resource storage path.

[0257] Figure 12The present invention relates to a deployment apparatus 40 according to an exemplary embodiment, which may include: a first receiving module 401, a first acquiring module 402, a second receiving module 403, a detection module 404, an execution module 405, a second recording module 411, a fourth receiving module 412, and a second updating module 413.

[0258] The second recording module 411 is used to record the correspondence between the first resource storage path and the second resource storage path after obtaining the application resource stored locally according to the first resource storage path in the first correspondence relationship and storing the application resource again according to the second resource storage path in the second correspondence relationship.

[0259] The fourth receiving module 412 is used to receive a second update command sent by the registration center. The second update command is a command sent by the registration center to the deployment device after detecting a change in any element in the second correspondence. The update command includes a third correspondence, which is the updated second correspondence.

[0260] The second update module 413 is used to update the second resource storage path in the second correspondence to the first resource storage path when the third correspondence and the second correspondence are different only in the resource storage path, and the resource storage path in the third correspondence is the same as the first resource storage path recorded in the correspondence.

[0261] Figure 13 The present invention relates to a deployment apparatus 40 according to an exemplary embodiment, which may include: a first receiving module 401, a first acquiring module 402, a sending module 414 and a fifth receiving module 415.

[0262] The sending module 414 is used to send a registration request to the registration center before receiving the deployment command sent by the registration center.

[0263] The fifth receiving module 415 is used to receive the registration request response sent by the registration center, which includes the agent identifier.

[0264] Optionally, the sending module 414 is configured to: obtain configuration information, which includes information about the first application programming interface of the registry center; and send a registration request to the registry center through the first application programming interface of the registry center.

[0265] The first receiving module 401 is used to receive deployment commands sent by the registry center through the first application programming interface of the registry center.

[0266] In summary, the deployment apparatus provided in this application embodiment has the advantages of simple application blueprint and resource index formats received by the first receiving module. Only basic knowledge is required to quickly write the corresponding relationships needed for application deployment without having to write complex task scripts, thus reducing the orchestration threshold and improving the efficiency of application deployment.

[0267] This application provides a deployment system, characterized in that the system includes: any of the above-mentioned registration centers 30 and any of the above-mentioned deployment devices 40.

[0268] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0269] Please refer to Figure 14 It shows a schematic diagram of the structure of a controller 500 provided in an embodiment of this application, see below. Figure 14 The controller 500 includes a processor 510, a communication interface 520, and a memory 530. The communication interface 520 and the memory 530 are respectively connected to the processor 510. For example, Figure 14 As shown, the communication interface 520 and the memory 530 are connected to the processor 510 via the bus 540.

[0270] The processor 510 can be a central processing unit (CPU), and the processor 510 includes one or more processing cores. The processor 510 executes various functional applications and data processing by running software programs.

[0271] There can be multiple communication interfaces 520. The communication interface 520 is used for the controller 500 to communicate with external devices, such as displays, third-party devices (e.g., storage devices, mobile terminals, etc.).

[0272] The memory 530 may include, but is not limited to, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), flash memory, and optical memory. The memory 530 is responsible for information storage; for example, it is used to store software programs.

[0273] Optionally, the controller 500 may also include: an input / output (I / O) interface ( Figure 14 (Not shown in the image). The I / O interface is connected to the processor 510, the communication interface 520, and the memory 530.

[0274] I / O interfaces can be, for example, Universal Serial Bus (USB).

[0275] In this embodiment, the processor 510 is configured to execute instructions stored in the memory 530, and the processor 530 implements the instructions. Figure 3 The implementation examples provide the application deployment method.

[0276] The processor 510 can be used to execute steps 201, 205, and 208 as described above, for example:

[0277] Obtain the application blueprint and resource index of the application to be deployed, which are allocated to the deployment device. The application blueprint includes resource storage paths and executable commands, and the resource index includes resource acquisition addresses.

[0278] Based on the application blueprint and resource index of the application to be deployed, establish n sets of correspondences between the application blueprint, the resource index and the proxy identifier, where the proxy identifier is used to uniquely identify the deployment device, and n is an integer greater than or equal to 1;

[0279] The deployment command is sent to the deployment device. The deployment command includes n sets of correspondences. The deployment command is used to instruct the deployment device to obtain application resources through the resource acquisition address in each set of correspondences, store the application resources according to the resource storage path, and execute the executable command after storing the application resources.

[0280] Alternatively, processor 510 can be used to perform steps 201, 202, 203, 204, and 207 above, for example:

[0281] The system receives a deployment command sent by the registration center. The deployment command includes: a correspondence between n sets of application blueprints, resource indexes, and proxy identifiers. The proxy identifier is used to uniquely identify the deployment device. The application blueprint includes a resource storage path and an executable command. The resource index includes a resource acquisition address.

[0282] The application resources are obtained by acquiring the resource acquisition address in each of the corresponding relationships, the application resources are stored according to the resource storage path, and the executable command is executed after storing the application resources.

[0283] It should be noted that the application deployment device provided in the above embodiments is only an example of the division of the above functional modules. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the application deployment device and application deployment method embodiments provided in the above embodiments belong to the same concept, and the specific implementation process can be found in the method embodiments, which will not be repeated here.

[0284] In this application, the term "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. Additionally, the character " / " in this document generally indicates that the preceding and following related objects have an "or" relationship.

[0285] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. An application deployment method, characterized in that, The method is applied to a registration center, and the method includes: Receive registration requests from deployment devices; A proxy identifier is assigned to the deployment device according to the registration request, wherein the proxy identifier is used to identify the deployment device; Obtain the application blueprint and resource index of the application to be deployed. The application blueprint includes executable commands, and the resource index includes resource acquisition addresses, which are the acquisition addresses of application resources. Establish the correspondence between the application blueprint, the resource index, and the proxy identifier; A deployment command is sent to the deployment device, wherein the deployment command includes the correspondence, and the deployment command is used to instruct the deployment device to obtain the application resource through the resource acquisition address in the correspondence and execute the executable command.

2. The method according to claim 1, characterized in that, Sending the deployment command to the deployment device includes: The deployment command is sent to the deployment device through the first application programming interface of the registration center.

3. The method according to claim 1 or 2, characterized in that, The process of obtaining the application blueprint and resource index of the application to be deployed includes: The registry center provides a second application programming interface or operation page. The registry center obtains the application blueprint and resource index provided by the control terminal through the second application programming interface or the operation page. The control terminal is either manual or a third-party system.

4. The method according to claim 1 or 2, characterized in that, The process of obtaining the application blueprint and resource index of the application to be deployed includes: Receive m resource indexes of the application to be deployed, wherein the application resources corresponding to the m resource indexes constitute the complete deployment resources of the application in the specified application environment, and m is an integer greater than or equal to 1; Receive p application blueprints of the application to be deployed, wherein the storage paths of the p application blueprints correspond to the m resource indexes; Upon receiving the subscription instruction, when the deployment device is a device in the specified application environment, at least one resource index from the m resource indexes is obtained as the resource index of the application to be deployed allocated to the deployment device, and the p application blueprints are obtained as the application blueprints of the application to be deployed allocated to the deployment device.

5. The method according to claim 4, characterized in that, When the deployment device is a device in the specified application environment, obtaining at least one resource index from the m resource indexes as the resource index of the application to be deployed allocated to the deployment device, and obtaining the p application blueprints as the application blueprints of the application to be deployed allocated to the deployment device, includes: Determine at least one target deployment device for deploying the complete resource to be deployed in the specified application environment, the at least one target deployment device including the deployment device; Among the m resource indices, a resource index is assigned to each of the target deployment devices; In the p application blueprints, an application blueprint is assigned to each of the target deployment devices.

6. The method according to claim 1 or 2, characterized in that, The application resources include: application installation resources, application configuration files, executable files, code files, or application differential packages.

7. The method according to claim 1 or 2, characterized in that, The method further includes: Based on the application blueprint and the resource index, the application to be deployed is deployed in multiple application environments, including one or more of a test environment, a development environment, and an integration environment.

8. The method according to claim 1 or 2, characterized in that, The executable commands include installation commands.

9. A registration center device, characterized in that, The registration center equipment includes: The receiving module is used to receive registration requests from the deployment device; An allocation module is configured to allocate a proxy identifier to the deployment device according to the registration request, wherein the proxy identifier is used to identify the deployment device; The acquisition module is used to acquire the application blueprint and resource index of the application to be deployed. The application blueprint includes executable commands, and the resource index includes resource acquisition addresses, which are the acquisition addresses of application resources. A module is established to create a correspondence between the application blueprint, the resource index, and the proxy identifier; The first sending module is used to send a deployment command to the deployment device, wherein the deployment command includes the correspondence, and the deployment command is used to instruct the deployment device to obtain the application resource through the resource acquisition address in the correspondence and execute the executable command.

10. The registration center device according to claim 9, characterized in that, The first sending module is used to send the deployment command to the deployment device through the first application programming interface of the registration center device.

11. The registration center device according to claim 9 or 10, characterized in that, The acquisition module is also used for: A second application programming interface or operation page is provided, through which the registration center obtains the application blueprint and resource index provided by the control terminal, wherein the control terminal is a manual or third-party system.

12. The registration center device according to claim 9 or 10, characterized in that, The acquisition module includes: The first receiving submodule is used to receive m resource indexes of the application to be deployed, wherein the application resources corresponding to the m resource indexes constitute the complete deployment resources of the application to be deployed in the specified application environment, and m is an integer greater than or equal to 1. The second receiving submodule is used to receive p application blueprints of the application to be deployed, wherein the storage paths of the p application blueprints correspond to the m resource indexes; The acquisition submodule is used, after receiving the subscription instruction, when the deployment device is a device in the specified application environment, to acquire at least one of the m resource indexes as the resource index of the application to be deployed allocated to the deployment device, and to acquire the p application blueprints as the application blueprints of the application to be deployed allocated to the deployment device.

13. The registration center device according to claim 12, characterized in that, The acquisition submodule is used for: Determine at least one target deployment device for deploying the complete resource to be deployed in the specified application environment, the at least one target deployment device including the deployment device; Among the m resource indices, a resource index is assigned to each of the target deployment devices; In the p application blueprints, an application blueprint is assigned to each of the target deployment devices.

14. The registration center device according to claim 9 or 10, characterized in that, The application resources include: application installation resources, application configuration files, executable files, code files, or application differential packages.

15. The registration center device according to claim 9 or 10, characterized in that, The acquisition module is also used for: Based on the application blueprint and the resource index, the application to be deployed is deployed in multiple application environments, including one or more of a test environment, a development environment, and an integration environment.

16. The registration center device according to claim 9 or 10, characterized in that, The executable commands include installation commands.

17. A controller, characterized in that, The controller includes a processor, a communication interface, and a memory. The communication interface and the memory are respectively connected to the processor. The processor is configured to execute instructions stored in the memory. The processor implements the application deployment method according to any one of claims 1 to 8 by executing the instructions.

18. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores instructions that, when the computer-readable storage medium is run on a processing component, cause the processing component to perform the application deployment method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Application program deployment method, deployment main control computer, deployment client side and cluster

    CN103455346A

  • System to generate a deployment plan for a cloud infrastructure according to logical, multi-tier application blueprint

    US20130232498A1