Method and device for visual upgrading of enterprise-level application systems based on container cloud platform
Through the visual upgrade methods and devices of enterprise-level application systems based on container cloud platform, the simplified upgrade of the container cloud platform application system is achieved, the upgrade threshold is lowered, browser operations are supported, and intuitive upgrade status display and batch upgrade functions are provided, which solves the problem of high complexity in the application system of container cloud platform.
Patent Information
- Application Number
- CN202510599914.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-12
- Publication Date
- 2025-08-12
- Estimated Expiration
- 2045-05-12
AI Technical Summary
The application system upgrade of container cloud platform is complex and has a large workload. Especially in distributed deployment scenarios, manual upgrades are difficult and time difference. The existing batch upgrade solutions are complex and difficult to meet the frequent upgrade needs of enterprise-level application systems.
Design a visual upgrade method and device for enterprise-level application systems based on container cloud platform, set up front-end interface and back-end services through the B/S architecture to realize the interaction between container and cloud platform, configure password-free login and file mount, provide a visual upgrade interface, support immediate execution, timed execution, version rollback and batch upgrade functions, and use cascading functions to achieve batch upgrades for distributed deployment.
This greatly lowers the threshold for upgrading the container cloud platform application system, and maintainers can complete the upgrade without being familiar with the concept of the cloud platform, provide intuitive upgrade progress and status display, and simplifies the upgrade workload in distributed deployment scenarios.
Smart Images

Figure CN120122971B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of information technology, and in particular relates to a method and device for visually upgrading an enterprise-level application system based on a container cloud platform. Background Art
[0002] Compared with traditional deployment architectures, container cloud platforms have multiple advantages. These advantages can effectively solve the problems existing in traditional deployment architectures and meet the complex needs of enterprise-level application systems.
[0003] 1) The container cloud platform standardizes the operating environment through container images, shielding the differences in environment configuration during application deployment and improving the stability of business applications.
[0004] 2) The container cloud platform can achieve centralized management of hosts, storage, and networks, dynamically replace and supplement resources, and improve resource utilization.
[0005] 3) The container cloud platform enables cross-data center switching, ensuring high availability. In the event of a disaster, it can maintain uninterrupted system operations and minimize data loss.
[0006] Therefore, when deploying enterprise-level application systems, for performance and other considerations, people tend to use high-availability deployment solutions. Using a container cloud platform architecture is a mainstream choice. One of the more widespread solutions is to deploy application systems based on a Kubernetes-based container cloud platform to achieve high availability, flexibility, and scalability of application services.
[0007] However, container cloud platforms have a certain user threshold. Application system upgrades are complex and labor-intensive, requiring maintenance personnel to undergo a period of training before mastering the upgrade and routine maintenance methods for application systems on container cloud platforms. Furthermore, in customized enterprise business systems, system upgrades are frequent, creating a significant burden.
[0008] Furthermore, in larger enterprises, where a single application system is insufficient to meet the massive demand, a distributed deployment solution is often adopted. This involves deploying a container-based cloud platform application system in each subsidiary, with the headquarters system serving as the root node and the branch application systems serving as child nodes. All application systems must maintain consistent versions and upgrades at the same pace. Manually performing upgrades sequentially is labor-intensive and time-consuming, while existing batch upgrade solutions are also complex and labor-intensive. Summary of the Invention
[0009] The purpose of the present invention is to provide a method and device for visually upgrading enterprise-level application systems based on a container cloud platform, which greatly reduces the upgrade threshold for application systems based on a container cloud platform. Maintenance personnel can complete the iterative upgrade of application systems without having to be familiar with cloud platform-related concepts and operating commands.
[0010] In order to achieve the above object, the technical solution of the present invention is as follows:
[0011] A method for visually upgrading an enterprise-level application system based on a container cloud platform, comprising:
[0012] S1. Based on the B / S architecture of the container cloud platform application system, a front-end interface for uploading upgrade packages and sending upgrade operation commands, as well as a back-end service for interacting with the container cloud platform, is set up;
[0013] S2. Ensure that the container where the upgrade service resides always runs on the designated node of the application system cluster of the container cloud platform;
[0014] S3. Mount the container cloud platform running file to the container where the upgrade service is located;
[0015] S4. Configure the password-free login for the container where the upgrade service is located and the host machine of the node to be upgraded.
[0016] S5. Upload the upgrade package to the designated node through the front-end interface. After receiving the upgrade operation command, the back-end service decompresses the upgrade package in the container where the upgrade service is located, calls the container cloud platform command to complete the update of the image version and configuration file, and calls the database cluster to complete the update of the table structure and data.
[0017] Furthermore, in step S1, the front-end interface sets the functions of immediate execution, scheduled execution, version rollback, and upgrade status display; it also sets the batch upgrade function during distributed deployment of the container cloud platform, and realizes batch upgrade through the cascading function of the distributed deployment application system.
[0018] Furthermore, the specific method of step S2 includes: modifying the orchestration file of the container where the upgrade service is located, and configuring the nodeSelector parameter to be the node name of the specified node, so as to ensure that the upgrade service always runs on the specified node.
[0019] Furthermore, step S3 specifically includes: designating a control node of the container cloud platform, and mounting the kubernetes configuration file and the run directory of containerd on the control node into the container where the upgrade service is located in a shared manner.
[0020] Furthermore, step S4 specifically includes: generating an ssh key on the host machine of the node to be upgraded, mounting the ssh key to the ssh directory of the container where the upgrade service is located through a shared storage directory, and remotely connecting the container where the upgrade service is located to the node to be upgraded through a preset ssh tool.
[0021] On the other hand, the present invention also proposes a visual upgrade device for enterprise-level application systems based on a container cloud platform, comprising:
[0022] B / S architecture module: Based on the B / S architecture of the container cloud platform application system, it provides a front-end interface for uploading upgrade packages and sending upgrade operation commands, as well as back-end services for interacting with the container cloud platform.
[0023] Service module: Ensures that the container where the upgrade service resides always runs on the designated node of the application system cluster of the container cloud platform;
[0024] Mounting module: mounts the container cloud platform running file to the container where the upgrade service is located;
[0025] Password-free module: configures password-free login for the container where the upgrade service is located and the host machine of the node to be upgraded;
[0026] Execution module: upload the upgrade package to the designated node through the front-end interface. After receiving the upgrade operation command, the back-end service decompresses the upgrade package in the container where the upgrade service is located, calls the container cloud platform command to complete the update of the image version and configuration file, and calls the database cluster to complete the update of the table structure and data.
[0027] Furthermore, in the B / S architecture module, the front-end interface is equipped with functions such as immediate execution, scheduled execution, version rollback, and upgrade status display. It also provides a batch upgrade function for distributed deployment of the container cloud platform, and implements batch upgrades through the cascading function of the distributed deployment application system.
[0028] Furthermore, the service module includes: modifying the orchestration file of the container where the upgrade service is located, and configuring the nodeSelector parameter to be the node name of the specified node, so as to ensure that the upgrade service always runs on the specified node.
[0029] Furthermore, the mounting module includes: specifying a control node of the container cloud platform, and mounting the kubernetes configuration file and the run directory of containerd on the control node into the container where the upgrade service is located in a shared manner.
[0030] Furthermore, the password-free module includes: generating an ssh key on the host machine of the node to be upgraded, mounting the ssh key to the ssh directory of the container where the upgrade service is located through a shared storage directory, and the container where the upgrade service is located remotely connects to the node to be upgraded through a preset ssh tool.
[0031] Compared with the prior art, the present invention has the following beneficial effects:
[0032] (1) The present invention is deployed based on a container cloud platform and has obvious advantages in terms of performance, maintainability, and scalability.
[0033] (2) The present invention provides a visual upgrade method based on the front-end interface of the application system, which can be completed through the browser. It can intuitively display the upgrade progress, upgrade status, and upgrade results, and provide functions such as rollback, scheduled upgrade, and cascade upgrade.
[0034] (3) The present invention breaks down the barriers between the application system and the container cloud platform, realizes the self-upgrade of the application system within the cloud platform, and greatly reduces the upgrade and maintenance threshold of the application system on the container cloud platform.
[0035] (4) The present invention uses the cascading function to achieve batch upgrades of multiple application systems based on the container cloud platform, greatly reducing the workload of application system upgrades in distributed deployment scenarios. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] Figure 1 This is a schematic diagram of a B / S architecture application system based on a container cloud platform according to Example 1 of the present invention.
[0037] Figure 2 This is a schematic diagram of a visualized upgrade workflow of a B / S architecture application system based on a container cloud platform according to Example 1 of the present invention.
[0038] Figure 3 This is a schematic diagram of the scheduled upgrade process of Example 1 of the present invention.
[0039] Figure 4 This is a schematic diagram of the upgraded process of Example 1 of the present invention. DETAILED DESCRIPTION
[0040] It should be noted that, in the absence of conflict, the embodiments of the present invention and the features in the embodiments may be combined with each other.
[0041] The purpose of the present invention is to visualize and simplify the application system upgrade work of the container cloud platform, which can be completed through the browser interface. The operational difficulty of upgrading the application system on the container cloud platform is greatly reduced. Based on this purpose, the design idea of the present invention is to initiate the cloud platform level operation from the application level through the interaction between the application system and the container cloud platform, so as to realize the visual upgrade and iteration of the application system itself on the application system, thereby greatly reducing the threshold for application system upgrades based on the container cloud platform. Customers do not need to be familiar with cloud platform-related concepts and operation commands to complete the iterative upgrade of the application system. And through the cascading function of the application system, it is possible to push upgrades to multiple sets of distributed deployed application systems at the same time.
[0042] The design concept of the present invention will be further described below with reference to the accompanying drawings and specific embodiments.
[0043] Example 1:
[0044] Due to the characteristics of container cloud platforms, an application system cluster based on a container cloud platform typically consists of multiple physical machine nodes (a minimum of three, an unlimited maximum, and typically 6-10 in low-load scenarios). Application systems typically include dozens or hundreds of services, each replicated to 3-10 replica containers based on load pressure. Consequently, an enterprise-level application system cluster of this type may have hundreds of running containers, which are randomly distributed across worker nodes based on a scheduling algorithm. The container cloud platform control layer is responsible for management, scheduling, upgrades, and maintenance.
[0045] To achieve self-upgrade of application systems in this architecture, the key point is to break down the barriers between the application systems running within the cluster and the upper-level container cloud control layer responsible for managing the application system cluster, and to upgrade dozens of services and hundreds of containers in the application system by calling the container cloud control layer.
[0046] To solve this problem, this embodiment designs the following steps:
[0047] S1. Based on the B / S architecture of the container cloud platform application system, a front-end interface for uploading upgrade packages and sending upgrade operation commands, as well as a back-end service for interacting with the container cloud platform, is set up;
[0048] like Figure 1 The figure shows a high-availability deployment architecture based on a container cloud platform in this embodiment. In the service layer, each server implements load balancing through K8S container orchestration. A distributed database and distributed cache are set up in the storage layer. On this basis, a B / S architecture is established. Upgrade operations can be performed through the browser interface in the user layer. The browser connects to the service layer through the DNS server.
[0049] The design functions of the front-end interface and back-end services of the B / S architecture include the following:
[0050] (1) Upload the upgrade package from the front-end interface, and the back-end service completes the application system version update. In this embodiment, the compiled upgrade package is uploaded through the browser interface. The back-end service receives the upgrade package and verifies whether the upgrade package's MD5, naming rules, architecture, upgrade script, etc. match and comply with the specifications. If it fails, an error prompt is returned. If it passes, it is saved to the shared storage directory.
[0051] (2) Upgrade operations include immediate execution and scheduled execution; support for canceling scheduled upgrades before the time is up.
[0052] The immediate execution calls the upgrade service to execute the preset upgrade script (the script is a fixed template). The script steps are divided into calling the command of the container cloud platform to update the service image, remotely copying the configuration file to the application helm container, copying the static file to the shared storage directory, and connecting to the database cluster to update the database table structure.
[0053] The scheduled execution starts a timer and executes at the set time (not too close to the current time). During the upgrade process, a Redis lock is used to ensure the uniqueness of the upgrade task, ensuring that only one upgrade task can be executed at a time.
[0054] After the upgrade script is executed, the upgrade status and detailed upgrade log are returned and displayed on the front-end interface.
[0055] (3) The front-end interface provides a "rollback" function, and the back-end service supports rolling back to the version before the upgrade. During the rollback, only the image and configuration files are rolled back. The database is designed to be backward compatible and does not require rollback.
[0056] Specifically, before each upgrade, the application image and configuration files are automatically backed up. If the upgrade results don't meet your expectations, you can roll back to the previous version with a single click. To roll back, replace the upgraded application image and configuration files with the backed-up ones and restart the service for the changes to take effect.
[0057] (4) The front-end interface supports viewing the upgrade status and version number of the current domain and subdomain.
[0058] (5) The front-end interface supports viewing the upgrade records of the current domain.
[0059] (6) The upgrade status is defined as follows:
[0060] All statuses: Empty, Pending Upgrade (not yet scheduled), Upgrading (upgrade request sent), Upgrade Successful, Upgrade Failed, Rolling Back, Rollback Successful, Rollback Failed.
[0061] Status of executable upgrade: empty, upgrade successful, upgrade failed, rollback successful.
[0062] Status where upgrade can be canceled: Pending upgrade.
[0063] Status where rollback can be performed: Upgrade successful.
[0064] The definition of upgrade results includes: upgrade success, upgrade failure, rollback success, and rollback failure.
[0065] (7) The front-end interface provides a backup function. Backup is performed before upgrading for abnormal rollback.
[0066] (8) The front-end interface provides a "batch upgrade" function. Batch upgrades are achieved through the cascading function of the enterprise container cloud platform. The cascading function is that when the enterprise adopts a distributed deployment solution, the application system based on the container cloud platform is cascaded with the headquarters system as the root node and the branch application system as the child node. During batch upgrades, the back-end service sends upgrade instructions through the application system's own cascading function, and can batch upgrade multiple application system clusters deployed in a distributed manner on the root node application system, and intuitively display the current version and upgrade status of all sub-application systems.
[0067] S2. Keep the container where the upgrade service resides running on the designated node.
[0068] In this step, modify the deployment.yaml file of the container where the upgrade service resides and configure the nodeSelector parameter to the name of the specified node to ensure that the upgrade service always runs on this node.
[0069] S3. Mount the container cloud platform running file to the container where the upgrade service is located;
[0070] The Kubernetes configuration file and the containerd run directory are key files for running the Container Cloud Platform. They exist on every physical machine hosting a Container Cloud Platform controller node (typically located at ~ / kube / and / run / containerd / ). You can choose either one. In this implementation, the first controller node is specified. The Kubernetes configuration file and containerd run directory on that node are mounted as a shared directory into the container hosting the upgrade service. The upgrade service container can now execute Container Cloud Platform control layer commands to perform operations such as upgrading and restarting the service container.
[0071] S4. Configure the password-free login for the container where the upgrade service is located and the host machine of the node to be upgraded.
[0072] The node to be upgraded is the node to be upgraded. For example, the first management node in the cluster is selected as the upgrade node. During the application system deployment phase, an SSH key is generated on the host machine of the upgrade node. This key is mounted to the SSH directory within the upgrade service container using a shared storage directory. From within the container, you can remotely access the upgrade node using the pre-configured SSH tool. You can also use the SCP command to copy static files and configuration files (i.e., the files and configuration files to be upgraded extracted from the upgrade package) within the upgrade service container to the configuration file directory in the container cloud platform control center. By executing control-layer commands, you can update and reload the application service configuration files.
[0073] S5. Upload the upgrade package through the front-end interface of the B / S architecture. After receiving the upgrade operation command, the back-end service decompresses the upgrade package, calls the container cloud platform command to complete the update of the image version and configuration file, and calls the database cluster to complete the update of the table structure and data.
[0074] After opening the channel between the application system and the cloud platform control center through steps S2-S4, the administrator can upload the upgrade package through the front-end interface. After the back-end service decompresses the upgrade package, it calls the container cloud platform command to complete the update of the image version and configuration file, and calls the database cluster to complete the update of the table structure and data. The specific process is as follows Figure 2 As shown, Figure 3 for Figure 2 In the timing execution process, Figure 4 This is the process after the upgrade is completed.
[0075] In addition, a backup is performed before each upgrade for visual rollback; during the execution, the status and logs are recorded and returned to the front-end interface for display.
[0076] If batch upgrade is required, the upgrade command is sent through the application system's own cascading function. Multiple application system clusters deployed in a distributed manner on the root node application system can be upgraded in batches, and the current version and upgrade status of all sub-application systems can be displayed intuitively.
[0077] Batch upgrade relies on the cascading function of the application system of this embodiment. If this function is not available, the upgrade interface of each application system can be called in batches (consistent with the interface called when initiating the upgrade from the browser on the root node application system), and batch upgrade can also be completed.
[0078] The method described in this embodiment, for the first time, is based on a container cloud platform cluster (multiple physical nodes, dozens or hundreds of container replicas), breaking down the barriers between the application system and the container cloud platform control layer, enabling upgrade operations at the application system level. Self-upgrades of cloud platform-based application systems can be completed through a browser, allowing for intuitive viewing of upgrade progress, status, and logs, as well as scheduled upgrades and rollbacks. This significantly simplifies the upgrade and maintenance requirements for application systems on the container cloud platform. It also provides a solution for batch upgrading application systems on dozens of container cloud platform clusters in a distributed deployment scenario, significantly reducing the upgrade and maintenance workload in this scenario.
[0079] Example 2:
[0080] This embodiment provides a visual upgrade device for an enterprise-level application system based on a container cloud platform, including:
[0081] B / S architecture module: Based on the B / S architecture of the container cloud platform application system, it provides a front-end interface for uploading upgrade packages and sending upgrade operation commands, as well as back-end services for interacting with the container cloud platform.
[0082] Service module: Ensures that the container where the upgrade service resides always runs on the designated node of the application system cluster of the container cloud platform;
[0083] Mounting module: mounts the container cloud platform running file to the container where the upgrade service is located;
[0084] Password-free module: configures password-free login for the container where the upgrade service is located and the host machine of the node to be upgraded;
[0085] Execution module: upload the upgrade package to the designated node through the front-end interface. After receiving the upgrade operation command, the back-end service decompresses the upgrade package in the container where the upgrade service is located, calls the container cloud platform command to complete the update of the image version and configuration file, and calls the database cluster to complete the update of the table structure and data.
[0086] In the B / S architecture module, the front-end interface is equipped with functions such as immediate execution, scheduled execution, version rollback, and upgrade status display. It also provides a batch upgrade function for distributed deployment of the container cloud platform, and implements batch upgrades through the cascading function of the distributed deployment application system.
[0087] The service module includes: modifying the orchestration file of the container where the upgrade service is located, configuring the nodeSelector parameter to the node name of the specified node to ensure that the upgrade service always runs on the specified node.
[0088] The mounting module includes: specifying a control node of the container cloud platform, and mounting the kubernetes configuration file and the run directory of containerd on the control node into the container where the upgrade service is located in a shared manner.
[0089] The password-free module includes: generating an ssh key on the host machine of the node to be upgraded, mounting the ssh key to the ssh directory of the container where the upgrade service is located through a shared storage directory, and the container where the upgrade service is located remotely connects to the node to be upgraded through a preset ssh tool.
[0090] The enterprise-level application system visualization upgrade device based on the container cloud platform proposed in this embodiment can execute the enterprise-level application system visualization upgrade method based on the container cloud platform described in Example 1, and has the same technical effect as Example 1.
[0091] The above-described embodiments are merely preferred implementations of the present invention and are intended to help understand the method and core concepts of the present application. The scope of protection of the present invention is not limited to the above-described embodiments. All technical solutions within the scope of protection of the present invention are within the scope of protection of the present invention. It should be noted that for those skilled in the art, various improvements and modifications that do not depart from the principles of the present invention should also be considered within the scope of protection of the present invention.
Claims
1. A method for visually upgrading an enterprise-level application system based on a container cloud platform, characterized in that: include: S1. Based on the B / S architecture of the container cloud platform application system, a front-end interface is set up for uploading upgrade packages and sending upgrade operation commands, as well as a back-end service that interacts with the container cloud platform and completes application system version updates and upgrades; S2. Ensure that the container where the upgrade service resides always runs on the designated node of the application system cluster of the container cloud platform; S3. Mount the container cloud platform running file to the container where the upgrade service is located; S4. Configure the password-free login for the container where the upgrade service is located and the host machine of the node to be upgraded. S5. The user layer uploads the upgrade package to the designated node through the front-end interface. After receiving the upgrade operation command, the back-end service decompresses the upgrade package in the container where the upgrade service is located, calls the container cloud platform command to complete the update of the image version and configuration file, and calls the database cluster to complete the update of the table structure and data; The specific method of step S2 includes: modifying the orchestration file of the container where the upgrade service is located, configuring the nodeSelector parameter to the node name of the specified node, so that the upgrade service always runs on the specified node; Step S3 specifically includes: specifying a control node of the container cloud platform, and mounting the kubernetes configuration file and the containerd run directory on the control node into the container where the upgrade service is located in a shared manner; Step S4 specifically includes: generating an ssh key on the host machine of the node to be upgraded, mounting the ssh key to the ssh directory of the container where the upgrade service is located through a shared storage directory, and remotely connecting the container where the upgrade service is located to the node to be upgraded through a preset ssh tool.
2. The method for visually upgrading an enterprise-level application system based on a container cloud platform according to claim 1, characterized in that: In step S1, the front-end interface sets the functions of immediate execution, scheduled execution, version rollback, and upgrade status display; it also sets the batch upgrade function during distributed deployment of the container cloud platform, and realizes batch upgrade through the cascading function of the distributed deployment application system.
3. A visual upgrade device for enterprise-level application systems based on a container cloud platform, characterized in that: include: B / S architecture module: Based on the B / S architecture of the container cloud platform application system, it provides a front-end interface for uploading upgrade packages and sending upgrade operation commands, as well as back-end services for interacting with the container cloud platform to complete application system version updates and upgrades; Service module: Ensures that the container where the upgrade service resides always runs on the designated node of the application system cluster of the container cloud platform; Mounting module: mounts the container cloud platform running file to the container where the upgrade service is located; Password-free module: configures password-free login for the container where the upgrade service is located and the host machine of the node to be upgraded; Execution module: The user layer uploads the upgrade package to the designated node through the front-end interface. After receiving the upgrade operation command, the back-end service decompresses the upgrade package in the container where the upgrade service is located, calls the container cloud platform command to complete the update of the image version and configuration file, and calls the database cluster to complete the update of the table structure and data; The service module includes: modifying the orchestration file of the container where the upgrade service is located and configuring the nodeSelector parameter to the node name of the specified node to ensure that the upgrade service always runs on the specified node; The mounting module includes: specifying a control node of the container cloud platform, and mounting the kubernetes configuration file and the containerd run directory on the control node to the container where the upgrade service is located in a shared manner; The password-free module includes: generating an ssh key on the host machine of the node to be upgraded, mounting the ssh key to the ssh directory of the container where the upgrade service is located through a shared storage directory, and the container where the upgrade service is located remotely connects to the node to be upgraded through a preset ssh tool.
4. The enterprise-level application system visualization upgrade device based on the container cloud platform according to claim 3 is characterized in that: In the B / S architecture module, the front-end interface is equipped with functions such as immediate execution, scheduled execution, version rollback, and upgrade status display. It also provides a batch upgrade function for distributed deployment of the container cloud platform, and implements batch upgrades through the cascading function of the distributed deployment application system.
Citation Information
Patent Citations
K8S-based containerized application one-key deployment method and system
CN117369945A
Application development and deployment method based on cloud platform and cloud platform system
CN118353887A
Cluster upgrading method, device and system, storage medium and computer program product
CN119938090A