Multi-cluster system and elastic scaling method thereof, computing device cluster and medium
By introducing a management device into a multi-cluster system to collaboratively manage single-cluster and cross-cluster elastic scaling strategies, the problem of multi-cluster resource allocation and cross-cluster instance elastic scaling is solved, efficient resource utilization and load balancing are achieved, and management is reduced. cost.
Patent Information
- Application Number
- CN202310114694.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-02-14
- Publication Date
- 2024-08-23
AI Technical Summary
Existing technology cannot achieve reasonable allocation of resources among multiple server clusters and elastic scaling of instances across clusters, resulting in uneven resource utilization and high management costs.
By introducing management devices into multi-cluster systems, including status detection modules, scaling configuration management modules, and scaling execution modules, we collaboratively manage single-cluster and cross-cluster elastic scaling strategies to achieve cross-cluster level elastic scaling and integrate the overall elastic scaling configuration. Split it into a single cluster scaling configuration and assign it to each cluster for execution.
It achieves elastic scaling across cluster levels, makes full use of resources, reduces migration costs, avoids waste of resources, simplifies management, and ensures load balancing.
Smart Images

Figure CN118535309A
Abstract
Description
Technical Field
[0001] The present invention relates to the field of cloud computing technology, and in particular to a multi-cluster system, an elastic scaling method for the multi-cluster system, a computing device cluster, a computer-readable storage medium, and a computer program product containing instructions. Background Art
[0002] Multi-cloud and multi-cluster deployment has gradually become the norm. However, how to reasonably allocate resources among multiple server clusters has become a concern. In the existing technology, there are elastic scaling technologies for a single server cluster, but such technologies cannot achieve elastic scaling of instances across clusters. Currently, there is a lack of a technology that can reasonably scale and utilize resources in multiple clusters and achieve efficient and accurate elastic scaling. Summary of the invention
[0003] To this end, the present application is committed to providing a multi-cluster system, an elastic scaling method for a multi-cluster system, a computing device cluster, a computer-readable storage medium, and a computer program product containing instructions, which can achieve layered elastic scaling at both the single-cluster and cross-cluster levels, and can reduce migration costs, avoid major modifications to existing systems, and achieve compatibility with native elastic scaling systems.
[0004] On the one hand, the present application provides a multi-cluster system, including: multiple clusters, multiple clusters are deployed with applications, multiple instances of the applications are distributed in multiple clusters, each of the multiple clusters includes a native scaling module, the native scaling module is used to increase or decrease the number of instances in the cluster to achieve elastic scaling of instances in a single cluster; a management device is used to manage multiple clusters. The management device includes: a state detection module, which is used to detect the state of multiple clusters; a scaling configuration management module, which is used to manage the native scaling module configurations of multiple clusters; a scaling execution module, which is used to perform cross-cluster instance elastic scaling when the state detection module detects that the instance elastic scaling of a single cluster cannot be implemented.
[0005] According to this aspect, by making the elastic scaling strategy of a single cluster and the cross-cluster elastic scaling strategy work together to achieve elastic scaling at the cross-cluster level, the inherent management system and software of a single cluster can be fully utilized, and functions can be added on this basis, which can minimize the migration cost and achieve efficient two-layer elastic scaling.
[0006] According to a special embodiment of the present application, the scaling configuration management module splits the multi-cluster scaling configuration into multiple single-cluster scaling configurations according to the multi-cluster scaling configuration configured by the user, and allocates the multiple single-cluster scaling configurations to multiple clusters, and the native scaling module performs elastic scaling of instances of the single cluster according to the allocated single-cluster scaling configurations.
[0007] According to this embodiment, by dividing the overall elastic scaling configuration into individual elastic scaling configurations, hierarchical management of elastic scaling is achieved, and hierarchical elasticity of system resources is achieved, which is conducive to fully utilizing resources and reasonably allocating computing power.
[0008] According to a special embodiment of the present application, a multi-cluster scaling configuration includes a maximum number of multi-cluster instances and a minimum number of multi-cluster instances, a single-cluster scaling configuration includes a maximum number of single-cluster instances and a minimum number of single-cluster instances, after the multi-cluster scaling configuration is split into multiple single-cluster scaling configurations, the sum of the maximum number of single-cluster instances of the multiple clusters is equal to the maximum number of multi-cluster instances, the sum of the minimum number of single-cluster instances of the multiple clusters is greater than or equal to the minimum number of multi-cluster instances, and the native scaling module of the cluster performs elastic scaling of instances of the single cluster between the maximum number of single-cluster instances and the minimum number of single-cluster instances of the cluster.
[0009] According to this embodiment, by setting the maximum and minimum number of instances at the multi-cluster level, the maximum and minimum number of instances of a single cluster can be effectively controlled, thereby achieving simple and easy control and reducing the migration cost of the management system.
[0010] According to a particular embodiment of the present application, the scaling configuration management module adjusts the scaling configuration of a single cluster of the cluster according to the load conditions of the multiple clusters detected by the status detection module.
[0011] According to this embodiment, by adjusting the instance elastic scaling configuration of a single cluster, the distribution of the elastic scaling configuration between the clusters can be fully considered, and the elastic scaling configuration can be arranged as reasonably as possible to avoid uneven distribution.
[0012] According to a particular embodiment of the present application, a single-cluster scaling configuration includes a single-cluster maximum number of instances and a single-cluster minimum number of instances. The status detection module detects the single-cluster maximum number of instances, the current number of instances, and the resource status of the cluster. The scaling configuration management module periodically calculates the difference between the single-cluster maximum number of instances and the current number of instances to obtain the difference, and then sums the differences of multiple clusters to obtain the sum value. The scaling configuration management module redistributes the sum value to multiple clusters so that each cluster has a new single-cluster maximum number of instances.
[0013] According to this embodiment, by tuning various elastic scaling values, the maximum number of elastic scaling instances is redistributed, so that the load can be reasonably balanced and resources can be flexibly scheduled.
[0014] According to a particular embodiment of the present application, when the state detection module detects that resources of a first cluster among the multiple clusters are insufficient and resources of a second cluster among the multiple clusters are sufficient, the scaling execution module increases the number of instances in the second cluster.
[0015] According to this embodiment, by implementing resource allocation and corresponding capacity expansion operations among different clusters, the resource shortage situation of individual clusters can be solved and the load of each cluster can be balanced.
[0016] According to a special embodiment of the present application, when the status detection module detects that the resource utilization of a third cluster among multiple clusters is lower than a preset value and the resource utilization of a fourth cluster among multiple clusters whose priority is lower than the third cluster is lower than a preset value, the scaling execution module executes to maintain the number of instances of the third cluster, and the native scaling module of the fourth cluster reduces the number of instances in the fourth cluster.
[0017] According to this embodiment, it is possible to preferentially reduce the number of low-priority cluster instances. In addition, by reducing the capacity of clusters with too low resource utilization, it is possible to avoid the waste of cluster computing resources and arrange services reasonably.
[0018] On the other hand, the present application provides an elastic scaling method for a multi-cluster system, including: increasing or decreasing the number of instances of applications deployed in multiple clusters distributed in the clusters through the native scaling module of each cluster in the multiple clusters, so as to achieve elastic scaling of instances in a single cluster; managing the native scaling configurations of multiple clusters through the scaling configuration management module of the management device; detecting the status of multiple clusters through the status detection module of the management device, and when the status detection module detects that elastic scaling of instances in a single cluster cannot be implemented, executing elastic scaling of instances across clusters through the scaling execution module of the management device.
[0019] According to a particular embodiment of the present application, the native scaling configurations of multiple clusters are managed by a scaling configuration management module of a management device, including: splitting the multi-cluster scaling configuration into multiple single-cluster scaling configurations according to the multi-cluster scaling configuration configured by a user through the scaling configuration management module, and assigning the multiple single-cluster scaling configurations to the native scaling modules of the multiple clusters; and performing elastic scaling of instances of the single cluster according to the assigned single-cluster scaling configurations through the native scaling module.
[0020] According to a special embodiment of the present application, the multi-cluster scaling configuration includes a maximum number of multi-cluster instances and a minimum number of multi-cluster instances, and the single-cluster scaling configuration includes a maximum number of single-cluster instances and a minimum number of single-cluster instances. The scaling configuration management module splits the multi-cluster scaling configuration into multiple single-cluster scaling configurations according to the multi-cluster scaling configuration configured by the user, and assigns the multiple single-cluster scaling configurations to the native scaling modules of the multiple clusters, including: splitting the multi-cluster scaling configuration into multiple single-cluster scaling configurations, so that the sum of the maximum number of single-cluster instances of the multiple clusters is equal to the maximum number of multi-cluster instances, and the sum of the minimum number of single-cluster instances of the multiple clusters is greater than or equal to the minimum number of multi-cluster instances. Wherein, the native scaling module performs elastic scaling of the instances of the single cluster according to the assigned single-cluster scaling configuration, including: performing elastic scaling of the instances of the single cluster between the maximum number of single-cluster instances and the minimum number of single-cluster instances of the cluster through the native scaling module of the cluster.
[0021] According to a particular embodiment of the present application, the native scaling configurations of multiple clusters are managed by a scaling configuration management module of a management device, including: adjusting the scaling configuration of a single cluster of the cluster according to the load conditions of the multiple clusters detected by the status detection module through the scaling configuration management module.
[0022] According to a particular embodiment of the present application, a single-cluster scaling configuration includes a single-cluster maximum number of instances and a single-cluster minimum number of instances. The single-cluster scaling configuration of the cluster is adjusted through the scaling configuration management module according to the load conditions of multiple clusters detected by the status detection module, including: detecting the single-cluster maximum number of instances, the current number of instances, and the resource status of the cluster through the status detection module; periodically calculating the difference between the single-cluster maximum number of instances and the current number of instances through the scaling configuration management module to obtain the difference, and then summing the differences of multiple clusters to obtain the sum value; and redistributing the sum value to multiple clusters through the scaling configuration management module so that each cluster has a new single-cluster maximum number of instances.
[0023] According to a special embodiment of the present application, the status of multiple clusters is detected by a status detection module of a management device. When the status detection module detects that elastic scaling of instances of a single cluster cannot be implemented, elastic scaling of instances across clusters is performed by a scaling execution module of the management device, including: when the status detection module detects that the resources of a first cluster among the multiple clusters are insufficient and the resources of a second cluster among the multiple clusters are sufficient, the scaling execution module is used to increase the number of instances in the second cluster.
[0024] According to a special embodiment of the present application, the status of multiple clusters is detected by a status detection module of a management device. When the status detection module detects that elastic scaling of instances of a single cluster cannot be implemented, elastic scaling of instances across clusters is performed by a scaling execution module of the management device, including: when the status detection module detects that the resource utilization of a third cluster among the multiple clusters is lower than a preset value and the resource utilization of a fourth cluster among the multiple clusters whose priority is lower than the third cluster is lower than a preset value, the scaling execution module is used to maintain the number of instances of the third cluster, and the native scaling module of the fourth cluster reduces the number of instances in the fourth cluster.
[0025] On the other hand, the present application provides a computing device, the computing device including a processor and a memory, the processor being used to execute a computer program stored in the memory to implement the elastic scaling method of the multi-cluster system.
[0026] On the other hand, the present application provides a computing device cluster, which includes at least one computing device, each computing device including a processor and a memory; the processor of at least one computing device is used to execute instructions stored in the memory of at least one computing device, so that the computing device cluster executes the elastic scaling method of the above-mentioned multi-cluster system.
[0027] On the other hand, the present application provides a computer-readable storage medium, which stores a computer program, and the computer program is used to execute the elastic scaling method of the multi-cluster system.
[0028] On the other hand, the present application provides a computer program product including instructions, which, when executed by a computer device cluster, enables the computer device cluster to execute the elastic scaling method of the multi-cluster system.
[0029] The computing devices, computing device clusters, computer-readable storage media or computer program products provided above are all used to execute the elastic scaling method of the multi-cluster system provided above, and the elastic scaling method of the multi-cluster system corresponds to the specific characteristics of the multi-cluster system. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects of the corresponding schemes in the corresponding multi-cluster system provided above, which will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] The specific implementation of the present application is described in detail below with reference to the accompanying drawings, wherein:
[0031] Figure 1 A schematic diagram showing a process flow of a single cluster elastic scaling technology in the art is shown;
[0032] Figure 2 A schematic diagram showing a process flow of a cross-cluster elastic scaling technology in the art is shown;
[0033] Figure 3 A schematic diagram showing the structure of a multi-cluster system according to an embodiment of the present application is shown;
[0034] Figure 4 Show according to Figure 3 A schematic diagram of a process flow of distributing a telescoping configuration according to an embodiment;
[0035] Figure 5 Show according to Figure 3 A schematic diagram of a flow chart of a tuning method of an embodiment;
[0036] Figure 6 Show according to Figure 3 A schematic flow chart of a capacity expansion method according to an embodiment;
[0037] Figure 7 Show according to Figure 3 A schematic flow chart of a capacity reduction method according to an embodiment;
[0038] Figure 8 Show according to Figure 3 A schematic flow chart of another method for reducing the capacity of an embodiment;
[0039] Fig. 9 A schematic diagram showing a flow chart of an elastic scaling method for a multi-cluster system according to an embodiment of the present application;
[0040] Fig.10 A schematic diagram of the structure of a computing device according to an embodiment of the present application is shown. Fig.11 A schematic diagram of a computing device cluster according to an embodiment of the present application is shown. DETAILED DESCRIPTION
[0041] In order to make those skilled in the art understand the concept and thought of the present application more clearly, the present application is described in detail below in conjunction with specific embodiments. It should be understood that the embodiments provided herein are only a part of all embodiments that the present application may have. After reading the specification of the present application, those skilled in the art have the ability to make improvements, transformations, or replacements to part or all of the following embodiments, and these improvements, transformations, or replacements are also included in the scope of the present application.
[0042] In this document, the terms "one", "an" and other similar words are not intended to indicate that there is only one of the things described, but rather that the relevant description is only for one of the things described, and the things described may have one or more. In this document, the terms "comprises", "includes" and other similar words are intended to indicate logical relationships, and cannot be regarded as indicating spatial structural relationships. For example, "A includes B" is intended to indicate that B logically belongs to A, but does not mean that B is spatially located inside A. In addition, the meanings of the terms "comprises", "includes" and other similar words should be regarded as open, rather than closed. For example, "A includes B" is intended to indicate that B belongs to A, but B does not necessarily constitute the whole of A, and A may also include other elements such as C, D, and E.
[0043] In this document, the terms "first", "second" and other similar words are not intended to imply any order, quantity and importance, but are only used to distinguish different elements. In this document, the terms "embodiment", "present embodiment", "one embodiment" and "an embodiment" do not mean that the relevant description is only applicable to a specific embodiment, but rather that these descriptions may also be applicable to one or more other embodiments. Those skilled in the art should understand that in this document, any description made for a certain embodiment can be replaced, combined, or otherwise combined with the relevant description in one or more other embodiments, and the new embodiment produced by the replacement, combination, or other combination is easily conceivable by those skilled in the art and belongs to the scope of protection of this application.
[0044] In the embodiments of the present application, a cluster may refer to a server cluster, that is, a number of servers are gathered together to provide the same service. From the client's point of view, it is like there is only one server. The server cluster can use multiple computers for parallel computing to obtain a very high computing speed, and can also use multiple computers for backup, so that if any machine fails, the entire system can still operate normally. The server here can be a traditional server or a cloud server.
[0045] In each embodiment of the present application, a multi-cluster system may refer to a cluster federation, which may include a federated cluster and one or more sub-clusters. A federated cluster may be a member of a sub-cluster or may exist independently of a sub-cluster. A federated cluster may refer to a cluster in which a federated management system is deployed, which uniformly manages multiple sub-clusters. In each embodiment of the present application, a cluster or a single cluster refers to a single cluster constituting a multi-cluster system, which may be a federated cluster or a sub-cluster.
[0046] In each embodiment of the present application, an instance may refer to a piece of resources occupied by an application deployed in a server cluster, which may be an abstract concept (such as a replica) or a physical entity (such as a server). In a container orchestration engine (Kubernetes, K8s) cluster, an instance is represented as a container group (Pod). An application may refer to an application or a microservice, and the underlying layer corresponds to a single or multiple instances.
[0047] In the embodiments of the present application, elastic scaling may refer to a service that automatically adjusts computing power (e.g., the number of instances) according to business needs and policies. For example, it will automatically add or reduce the number of instances according to resource usage (e.g., CPU and / or memory). For example, elastic scaling may mean that the number of instances can be automatically increased or decreased according to computing power requirements. When the server traffic suddenly increases and computing power is tight, the number of cloud instances is increased until the traffic decreases and computing power is sufficient, and the number of instances is reduced.
[0048] As multi-cloud and multi-cluster deployment becomes the new normal for cloud native, more and more enterprises are using cluster federation to manage multiple sub-clusters. Each cluster will deploy a set of K8s systems, deploy multiple instances of an application in different K8s clusters through different strategies, and provide services at the same time. The deployment plan can be multiple deployment scenarios such as multi-active deployment in the same city, heterogeneous resource deployment, and multi-region deployment.
[0049] In multiple subclusters managed by a federated cluster, the CPU / memory load will change according to the business volume. The main K8s single cluster elasticity technologies are horizontal pod autoscaler (HPA) and vertical pod autoscaler (VPA). HPA scales the number of instances horizontally according to the CPU / memory utilization, and VPA scales the instance specifications vertically according to the CPU / memory utilization. However, in a multi-cluster scenario, single cluster elasticity technology cannot coordinate and manage multiple subcluster resources in a unified manner. The federation side also lacks the following features: 1) minimize the load on the federation side, 2) support multiple cross-cluster elasticity strategies, 3) subclusters have autonomous capabilities after a federated cluster management failure (i.e., subclusters scale the number of application instances according to the HPA and application load in the cluster), and 4) cross-cloud and cross-cluster elasticity coordination technology is implemented under the premise of compatibility with K8s native HPA (i.e., when receiving a scaling request, select the optimal subcluster to scale the number of application instances according to resources and strategies). Therefore, it is necessary to provide a cross-cloud and cross-cluster application elastic scaling method that can solve the above problems.
[0050] Typical single-cluster HPA elastic scaling technologies in this field include: Figure 1 As shown, it includes the following four steps.
[0051] 1) Single cluster configuration The acquisition module is responsible for collecting the CPU / memory load of all loads in a single cluster.
[0052] 2) The HPA configuration check module periodically calls the single cluster configuration acquisition module to obtain the corresponding configuration and current load value, and compares them with the trigger configuration and threshold configured by the user.
[0053] 3) If it exceeds the configuration, the HPA expansion module is triggered to trigger expansion; if it is lower than the configuration, the HPA expansion module is triggered to trigger reduction.
[0054] 4) The HPA scaling module receives the trigger from the HPA configuration detection module, and executes the modification of the number of replicas according to the configuration value, scaling the corresponding load. The algorithm for modifying the number of replicas is: expected number of replicas = round up [current number of replicas * (current configuration / expected configuration)]. For example, if the expected CPU utilization is 50%, the current one is 90%, and the current number of replicas is 11, then round up [11*(90% / 50%)] = 20.
[0055] The disadvantages of the single-cluster HPA elastic scaling technology in this field include: 1) it cannot support elastic scaling across clouds and clusters; 2) it cannot support unified elasticity across clouds and clusters, resulting in the inability to support multi-cluster scenarios.
[0056] Typical cross-cluster elastic scaling technologies in this field include: Figure 2 As shown, it includes the following four steps.
[0057] 1) The federated control cluster deploys a cluster federation elastic scaling agent in the sub-cluster, which periodically collects the transactions per second (TPS) load configuration in the current cluster and reports it to the data analysis controller of the control cluster.
[0058] 2) The data analysis controller analyzes the received configuration, processes the configuration data, and sends the processing and analysis results to the cluster replica controller and the traffic management controller.
[0059] 3) The traffic management controller receives data and obtains user configuration from the application programming interface server (API-Server) module, and sets the proportion of traffic routing responsible for balancing according to the configuration file and configuration data.
[0060] 4) The cluster replica controller receives data, obtains user configuration from the API-Server module, and sends scaling instructions to the cluster federation elastic scaling agent based on the configuration file and configuration data (TPS configuration). The cluster federation elastic scaling agent modifies the number of corresponding load instances in the cluster according to the instructions.
[0061] exist Figure 2 In the technology shown, when expanding, priority is given to expanding clusters with high priority, and when shrinking, priority is given to shrinking clusters with low priority. The expansion calculation method is: expected expansion instance = current number of instances * (current tps / maximum tps) - current number of instances, expected shrinking instance = current number of instances - current number of instances * (current tps / minimum tps), where maximum tps and minimum tps define elastic configuration. The cluster replica controller uniformly implements cross-cluster expansion and contraction (based on priority) for the expanded and contracted instances.
[0062] The shortcomings of cross-cluster elastic scaling technology in this field include the following four points. 1) After the control cluster fails, the sub-cluster cannot be scaled, and the overall functional reliability is poor; 2) It does not have the ability to manage hierarchical scaling, and the control cluster monitors configuration changes in real time and takes full control of scaling instances in real time, causing excessive pressure on the center side; 3) It is incompatible with K8s' native single-cluster HPA and cannot be enabled at the same time as the single-cluster HPA function. It is mainly based on TPS configuration rather than the CPU / memory of the single-cluster HPA, resulting in high user learning costs; 4) It only supports priority cross-cluster scaling strategies, and cannot support multiple cross-cluster scaling strategies.
[0063] Some embodiments of the present application, based on the management of the federated cluster, propose a cross-cloud and cross-cluster elastic scaling method that meets the following five characteristics. 1) Support hierarchical scaling management capabilities. When the sub-cluster can scale, autonomy is prioritized; when the sub-cluster cannot scale, the federal control cluster takes over and implements scaling in other clusters to achieve cross-cluster scaling; minimize the pressure on the federated cluster. 2) In the event of a federal control cluster failure, support sub-cluster scaling management autonomy, and the sub-cluster can also execute scaling instances according to the HPA configuration previously issued by the federal control cluster, but lacks cross-cluster capabilities, and the performance behavior is no different from that of the K8s single-cluster HPA. 3) The scaling management API is compatible with the K8s native HPA API, and users can migrate to the scaling management API of the present invention at a very low cost. 4) Support the configuration of custom cross-cluster elastic policies, such as priority scaling. 5) The sub-cluster load capacity is variable. In order to meet the optimal sub-cluster autonomy, the maximum and minimum number of instances of the sub-cluster HPA are overall tuned.
[0064] Some embodiments of the present application propose a federated cluster horizontal automatic scaling application program interface (FederatedHPA API, i.e., an API defined in some embodiments of the present application) compatible with K8s native HPA, and a set of layered cross-cluster elastic coordination systems, so as to realize that when a sub-cluster can be scaled, the sub-cluster scaling autonomy is prioritized, and when a sub-cluster cannot be scaled, the federation side performs cross-cluster scaling in combination with the strategy, so as to meet the requirements of layered elastic scaling, sub-cluster autonomy, minimize the pressure on the federation side, and customize multiple strategies. At the same time, the sub-cluster HPA is tuned to maximize the use of the autonomy of the sub-cluster.
[0065] Some embodiments of the present application are based on scenarios where the business load is balanced according to the instance load. For example, if cluster A has 5 instances and cluster B has 10 instances, the business load of cluster B is twice that of cluster A. Therefore, based on this premise, when scaling down, all subclusters are scaling down, and when scaling up, all subclusters are scaling up.
[0066] Some embodiments of the present application can achieve hierarchical elasticity across clusters and sub-cluster autonomy, and perform cross-cluster elasticity coordination when sub-clusters cannot be elastic. Without losing consistency, these modules can be centrally deployed on the central control plane or deployed in a sub-cluster.
[0067] The usage scenarios of some embodiments of the present application include but are not limited to the following three scenarios. 1) Hybrid elastic deployment of local Internet data center (IDC) clusters and public cloud clusters. When expanding capacity, the local IDC cluster is used first, and the public cloud cluster is used after the local IDC cluster is used up to minimize business consumption. 2) Hybrid elastic deployment of heterogeneous resources, such as X86 / ARM hybrid elastic deployment. When expanding capacity, X86 is used first to ensure business stability. 3) Multi-regional hybrid elastic deployment, such as multi-regional multi-cluster deployment in east and west China. When expanding capacity, cluster resources in western China are used first to alleviate energy shortages in eastern China.
[0068] Figure 3 A schematic diagram of the structure of a multi-cluster system according to an embodiment of the present application is shown.
[0069] According to this embodiment, the multi-cluster system 300 includes a plurality of clusters 310 and a management device 320 .
[0070] Among them, multiple clusters 310 are deployed with applications, and multiple instances of the applications are distributed in the multiple clusters 310. Each cluster 310 in the multiple clusters 310 includes a native scaling module 311, and the native scaling module 311 is used to increase or decrease the number of instances in the cluster 310 to achieve elastic scaling of instances in a single cluster.
[0071] The native scaling module 311 of the cluster 310 may be an HPA module for implementing HPA functions; or may be a VPA module, or other native technologies or systems that can implement elastic scaling of a single cluster.
[0072] The management device 320 is used to manage the multiple clusters 310 , and includes a state detection module 321 , a scaling configuration management module 322 , and a scaling execution module 323 .
[0073] In the case where the multi-cluster system is a cluster federation, the management device 320 may be a device installed in the federated cluster or a device installed in a sub-cluster. In particular, the management device 320 may be a part of a federated cluster management system.
[0074] The status detection module 321 is used to detect the status of the plurality of clusters 310 .
[0075] The state detection module 321 can detect the load of the cluster, the resource utilization of the cluster, the maximum number of instances and the minimum number of instances of the cluster, and can also detect other states of the cluster.
[0076] The scaling configuration management module 322 is used to manage native scaling configurations of the multiple clusters 310 .
[0077] Managing the native scaling configuration may include modifying the configuration based on which the native scaling module 311 performs elastic scaling, or other management methods.
[0078] The scaling execution module 323 is used to execute cross-cluster instance elastic scaling when the state detection module 321 detects that the single-cluster instance elastic scaling cannot be implemented.
[0079] The management device 320 according to the present application can be implemented through an API. For example, by adding functions to the API of the native HPA in the K8s cluster, the FederatedHPA API according to the present application is obtained. The following fields (API) are added according to the API of the present application.
[0080] FederatedMaxReplicas, which limits the maximum number of instances in multiple clusters.
[0081] FederatedMinReplicas, which limits the minimum number of instances in multiple clusters.
[0082] clusterAutoscalingPreferences represents a customized policy. This is just an example. You can customize any policy. Key attributes include cluster priority, cluster maximum elastic utilization, and cluster maximum and minimum number of instances.
[0083] autoscaleMultiClusterDelay indicates the cross-cluster elastic delay, which means that cross-cluster elastic scaling is not performed immediately. This delay can be set when the cluster can scale the number or specifications of nodes.
[0084] According to this embodiment, the multi-cluster system 300 can implement the distribution of elastic scaling configuration.
[0085] As an example, the scaling configuration management module splits the multi-cluster scaling configuration into multiple single-cluster scaling configurations according to the multi-cluster scaling configuration configured by the user, and assigns the multiple single-cluster scaling configurations to the native scaling modules of the multiple clusters. The native scaling modules perform elastic scaling of instances of the single cluster according to the assigned single-cluster scaling configurations.
[0086] As an example, a multi-cluster scaling configuration includes a maximum number of multi-cluster instances and a minimum number of multi-cluster instances, and a single-cluster scaling configuration includes a maximum number of single-cluster instances and a minimum number of single-cluster instances. After the multi-cluster scaling configuration is split into multiple single-cluster scaling configurations, the sum of the maximum number of single-cluster instances of multiple clusters is equal to the maximum number of multi-cluster instances, and the sum of the minimum number of single-cluster instances of multiple clusters is equal to the minimum number of multi-cluster instances. The native scaling module of the cluster performs elastic scaling of instances of the single cluster between the maximum number of single-cluster instances and the minimum number of single-cluster instances of the cluster.
[0087] The following takes a cluster federation as an example to describe in detail the distribution process of the elastic scaling configuration of the multi-cluster system 300 according to the present application.
[0088] Specifically, the federated cluster horizontal auto-scaling (FederatedHPA) issued by the user can be split into sub-cluster HPAs according to policies (including but not limited to priority, weight, customization) and other input information, and deployed in the sub-clusters.
[0089] Specifically, the FederatedHPA is split into the HPA of each sub-cluster and distributed, such as FederatedMaxReplicas is 100 and FederatedMinReplicas is 10. The strategy selects 2 clusters, and the distribution strategy is the current available resource ratio (central processing unit (CPU) available resources of cluster 1: CPU available resources of cluster 2 = 1:4), then the minimum number of instances / maximum number of instances of HPA of cluster 1 is 2 / 20, and the minimum number of instances / maximum number of instances of HPA of cluster 2 is 8 / 80.
[0090] See also Figure 4 The execution flow of distributing FederatedHPA is shown in the figure. When a user creates a FederatedHPA, the HPA corresponding to the subcluster is calculated according to the user-configured policy and subcluster resource information to ensure that the maximum number of instances of HPA in all subclusters is equal to FederatedMaxReplicas; at the same time, according to the policy calculation, when the minimum number of instances of HPA in each cluster is less than 1, it is set to 1; finally, the corresponding HPA is created in each subcluster.
[0091] During distribution, according to the previous example strategy, the following two different operations are performed.
[0092] 1) If there is a directly defined maximum and minimum number of instances for a subcluster, the corresponding HPA is created directly in the subcluster.
[0093] 2) If there is a priority relationship, the workload sent down is set to 0 for the low-priority cluster and the highest priority is set to the initial number of instances (when a cluster has HPA but the number of instances is 0, elasticity cannot be performed, so high-priority cluster resources can be used first).
[0094] According to this embodiment, the multi-cluster system 300 can achieve optimization of elastic scaling configuration.
[0095] As an example, the scaling configuration management module adjusts the scaling configuration of a single cluster according to the load conditions of the multiple clusters detected by the status detection module.
[0096] As an example, a single-cluster scaling configuration includes a single-cluster maximum number of instances and a single-cluster minimum number of instances. The status detection module detects the single-cluster maximum number of instances, the current number of instances, and the resource status (such as whether it is overloaded, etc.) of the cluster. The scaling configuration management module periodically calculates the difference between the single-cluster maximum number of instances and the current number of instances to obtain the difference, and then sums the differences of multiple clusters to obtain the sum value. The scaling configuration management module redistributes the sum value to multiple clusters so that each cluster has a new single-cluster maximum number of instances.
[0097] The following takes a cluster federation as an example to describe in detail the tuning process of the elastic scaling configuration of the multi-cluster system 300 according to the present application.
[0098] Specifically, the tuning algorithm of the sub-cluster HPA may include the following contents.
[0099] 1) Periodically obtain the maximum number of instances and the current number of instances of the HPA subcluster, calculate the sum of delta (maximum number of instances of the HPA single cluster - current number of instances) of all clusters, and modify the maximum number of instances of the HPA single cluster of all clusters to the current number of instances; then, based on the user-configured policy, redistribute the delta sum to the target cluster, and create or modify the maximum number of instances of the HPA single cluster in the corresponding cluster (if it is created, the minimum number of instances of a single cluster is 1).
[0100] 2) If the current number of instances of a subcluster is 0, and the maximum number of instances of a single HPA cluster is not 0, when tuning, the value of the maximum number of instances of a single cluster is all reallocated to other clusters, and the HPA resources of the current subcluster are deleted.
[0101] 3) When a cluster resource reaches the configured maximum utilization rate and the maximum number of instances in a single cluster has not yet been reached, the difference is reallocated to the target cluster as in step 1.
[0102] See also Figure 5 ,The state detection module deployed in the federated cluster will collect the HPA / instance number information from each sub-cluster, and the dynamic tuning module will calculate the HPA of the new sub-cluster based on the ,algorithm and user configured policies (including dynamic resource weights, maximum cluster ,usage rate, etc.) described above, and finally perform the sub-cluster HPA modification and ,adjustment.
[0103] According to this embodiment, the multi-cluster system 300 can achieve cross-cluster expansion.
[0104] As an example, when the state detection module detects that resources of a first cluster among the multiple clusters are insufficient and resources of a second cluster among the multiple clusters are sufficient, the scaling execution module increases the number of instances in the second cluster.
[0105] Insufficient resources may mean that CPU or memory resources are insufficient to provide the expected number of instances.
[0106] Specifically, you can receive elastic triggers, select a cluster according to the policy, and adjust the number of corresponding cluster instances. For example, there are two clusters: cluster 1 and cluster 2. Cluster 1 needs to expand two more instances due to insufficient resources. According to the policy selection, it is found that cluster 2 has idle resources and meets the selection policy, so two instances are added to cluster 2.
[0107] Specifically, the cross-cluster expansion decision algorithm may be in the following form.
[0108] After HPA is issued, the current resource utilization can be obtained from the HPA status of the sub-cluster (example below). If the current expected number of instances is equal to the maximum number of instances in a single cluster, and the utilization is greater than the average utilization set by HPA, cross-cluster expansion is triggered, and the number of expanded instances is = current number of instances * (current utilization - target utilization) / target utilization. Then, based on the calculated number of expanded instances, the optimal and available cluster is selected through the user-configured policy, and the corresponding number of instances is expanded in the target cluster.
[0109] See also Figure 6 ,When the number of instances is equal to the maximum number of instances in a single cluster of HPA and the average ,utilization of the HPA state is greater than the target average utilization, the ,policy elasticity module is triggered to perform cross-cluster expansion, and the target cluster selects the ,optimal cluster expansion based on the user configured policy.
[0110] Special attention should be paid to the fact that if there is a priority relationship, when the maximum number of instances of a single cluster is reached, the number of instances of the sub-priority cluster will be changed to the number of instances that need to be expanded (the number of instances of the sub-priority cluster should be 0 at this time), and the sub-cluster HPA expansion module will expand the capacity.
[0111] Specifically, if the subcluster does not reach the maximum number of instances of a single cluster to which the HPA is issued, the subcluster will first expand the instance through the native K8s expansion module. If the instance cannot be expanded (specifically, the maximum number of instances of a single cluster is not reached, and insufficient resources lead to inability to be elastic), the policy elasticity module will select the optimal and available cluster based on the number of instances that cannot be elastic through the user-configured policy, and expand the corresponding number of instances in the target cluster.
[0112] At this time, the number of instances in the sub-cluster cannot be scheduled due to insufficient resources. If there is a priority relationship, when resources are insufficient, the number of instances in the sub-priority cluster is changed to the number of instances that need to be expanded (the number of instances in the sub-priority cluster should be 0 at this time), and the sub-cluster HPA expansion module expands the capacity.
[0113] According to this embodiment, the multi-cluster system 300 can achieve cross-cluster scaling.
[0114] As an example, when the status detection module detects that the resource utilization of a third cluster among multiple clusters is lower than a preset value and the resource utilization of a fourth cluster among multiple clusters whose priority is lower than the third cluster is lower than a preset value, the scaling execution module executes to maintain the number of instances of the third cluster, and the native scaling module reduces the number of instances in the fourth cluster.
[0115] Resource utilization may mean that the CPU or memory resources in the cluster are lower than expected given the current number of instances.
[0116] Specifically, the cross-cluster scaling decision algorithm may include the following contents.
[0117] 1) If the policy configuration has a priority relationship, when scaling down (specifically, the number of instances is calculated in real time based on the HPA utilization rate, and scaling down is considered when the number of instances is less than the current number of instances), the number of instances of the high-priority cluster is maintained. After the number of instances of the low-priority cluster is scaled down to the minimum number of instances of a single cluster by the native K8s scaling module, the second-priority cluster is scaled down in the same way.
[0118] 2) If the policy configuration does not have a primary-secondary relationship such as master-slave or priority, when scaling down, the number of instances in each subcluster is controlled by the native K8s scaling module of each subcluster.
[0119] 3) When the current number of instances of all subclusters is equal to the minimum number of instances of a single cluster, if the sum of the current number of instances of all subclusters is greater than the minimum number of instances of multiple clusters, then according to the strategy, the number of instances of some clusters is changed to 0, and the capacity is gradually reduced until the sum of the current number of instances of all subclusters is equal to the minimum number of instances of multiple clusters.
[0120] See also Figure 7When receiving a request to scale down a sub-cluster, select the scale-down cluster according to the strategy. After selecting the target scale-down cluster, the native K8s scaling module of the target cluster is responsible for scaling down, and the policy elastic module maintains the number of instances of other clusters. After the number of instances of the target scale-down cluster is equal to the minimum number of instances of a single cluster of HPA, repeat the above steps. If there is no primary-secondary relationship, the scaling down of the sub-cluster is the responsibility of the native K8s scaling module, and the system does not participate in this solution.
[0121] See also Figure 8 , collect HPA / instance number information from each sub-cluster. When the number of instances in all sub-clusters is equal to the minimum number of instances in a single HPA cluster, and the sum of the minimum number of instances in a single HPA cluster is greater than the minimum number of instances in multiple clusters, choose to scale down to cluster 0 according to the strategy. This continues until the sum of the minimum number of instances in a single HPA cluster is equal to the minimum number of instances in multiple clusters.
[0122] Based on the above Figure 3 The system embodiment described above, the embodiment of the present application also provides an elastic scaling method for a multi-cluster system, and its flow chart is as follows Fig. 9 This method is applicable to the aforementioned Figure 3 The multi-cluster system shown in .
[0123] According to this embodiment, the elastic scaling method of a multi-cluster system includes steps S910 to S930, and each step is described below.
[0124] S910. Increase or decrease the number of instances of applications deployed in the multiple clusters and distributed in the clusters through the native scaling module of each cluster in the multiple clusters, so as to achieve elastic scaling of instances of a single cluster.
[0125] S920. Manage native scaling configurations of multiple clusters through a scaling configuration management module of a management device.
[0126] S930. Detect the status of multiple clusters through a status detection module of the management device. When the status detection module detects that elastic scaling of instances of a single cluster cannot be implemented, perform elastic scaling of instances across clusters through a scaling execution module of the management device.
[0127] It should be noted that the elastic scaling method of the multi-cluster system provided in the above embodiment is similar to Figure 3 The illustrated multi-cluster system embodiments respectively belong to the same concept, and their specific implementation processes are detailed in the multi-cluster system embodiments, which will not be repeated here.
[0128] Fig.10 It is a schematic diagram of the hardware structure of a computing device 1000 provided in an embodiment of the present application.
[0129] See also Fig.10The computing device 1000 includes a processor 1010, a memory 1020, a communication interface 1030, and a bus 1040, wherein the processor 1010, the memory 1020, and the communication interface 1030 are connected to each other via the bus 1040. The processor 1010, the memory 1020, and the communication interface 1030 may also be connected in other connection modes besides the bus 1040.
[0130] Among them, the memory 1020 can be various types of storage media, such as random access memory (RAM), read-only memory (ROM), non-volatile RAM (NVRAM), programmable ROM (PROM), erasable PROM (EPROM), electrically erasable PROM (EEPROM), flash memory, optical storage, hard disk, etc.
[0131] The processor 1010 may be a general-purpose processor, which may be a processor that performs specific steps and / or operations by reading and executing the contents stored in a memory (e.g., the memory 1020). For example, the general-purpose processor may be a central processing unit (CPU). The processor 1010 may include at least one circuit to perform Fig. 9 The illustrated embodiment provides all or part of the steps of the elastic scaling method for a multi-cluster system.
[0132] Among them, the communication interface 1030 includes input / output (I / O) interfaces, physical interfaces, and logical interfaces for interconnecting devices within the computing device 1000, as well as interfaces for interconnecting the computing device 1000 with other devices (such as other computing devices or user devices). The physical interface can be an Ethernet interface, an optical fiber interface, an ATM interface, etc. The communication interface 1030 can be connected to an external input device and an output device. For example, the input device can be a microphone or a microphone array for capturing voice input signals; it can be a communication network connector for receiving collected input signals from the cloud or other devices; it can also include, for example, a keyboard, a mouse, etc. The output device can output various information to the outside, including determined distance information, direction information, etc. The output device can include, for example, a display, a speaker, a printer, a communication network and a remote output device connected thereto, etc.
[0133] The bus 1040 may be any type of communication bus for interconnecting the processor 1010 , the memory 1020 , and the communication interface 1030 , such as a system bus.
[0134] The above devices may be arranged on independent chips, or at least partially or completely on the same chip. Whether to arrange each device independently on different chips or to integrate them on one or more chips often depends on the needs of product design. The embodiments of the present application do not limit the specific implementation form of the above devices.
[0135] Fig.10 The computing device 1000 shown is merely exemplary. During implementation, the computing device 1000 may also include other components, which are not listed one by one in this article.
[0136] The embodiment of the present application also provides a computing device cluster. The computing device cluster includes at least one computing device. The computing device can be a server, such as a central server, an edge server, or a local server in a local data center. In some embodiments, the computing device can also be a terminal device such as a desktop computer, a laptop computer, or a smart phone.
[0137] like Fig.11 As shown, the computing device cluster includes at least one computing device 1000. The memory 1020 in one or more computing devices 1000 in the computing device cluster may store the same instructions for executing the elastic scaling method of the multi-cluster system. One or more computing devices in the computing device cluster may be connected via a network, and specifically may be connected to the network via a communication interface in each computing device. The network may be a wide area network or a local area network, etc.
[0138] In some possible implementations, the memory 1020 of one or more computing devices 1000 in the computing device cluster may also store partial instructions for executing the elastic scaling method of the multi-cluster system. In other words, the combination of one or more computing devices 1000 can jointly execute the instructions for executing the elastic scaling method of the multi-cluster system.
[0139] It should be noted that the memory 1020 in different computing devices 1000 in the computing device cluster can store different instructions, which are respectively used to execute part of the functions of the management device of the multi-cluster system. That is, the instructions stored in the memory 1020 in different computing devices 1000 can implement the functions of one or more modules in the management device of the multi-cluster system.
[0140] An embodiment of the present application may also be a computer-readable storage medium on which computer program instructions are stored. When the computer program instructions are executed by a processor, the processor executes the steps in the elastic scaling method of a multi-cluster system according to various embodiments of the present application described above in this specification.
[0141] The computer readable storage medium can adopt any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can include, for example, but is not limited to, a system, device or device of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0142] The concepts, principles and ideas of the present application are described in detail above in conjunction with specific implementation methods (including embodiments and examples). Those skilled in the art should understand that the implementation methods of the present application are more than the several forms given above. After reading the application documents, those skilled in the art can make any possible improvements, replacements and equivalent forms to the steps, methods, devices and components in the above-mentioned implementation methods, and these improvements, replacements and equivalent forms should be deemed to fall within the scope of the present application. The scope of protection of the present application shall be subject only to the claims.
Claims
1. A multi-cluster system, characterized in that: include: Multiple clusters, wherein applications are deployed in the multiple clusters, multiple instances of the applications are distributed in the multiple clusters, each of the multiple clusters includes a native scaling module, and the native scaling module is used to increase or decrease the number of instances in the cluster to achieve elastic scaling of instances in a single cluster; A management device, used to manage the multiple clusters, the management device comprising: A status detection module, used to detect the status of the multiple clusters; A scaling configuration management module, used to manage native scaling configurations of the multiple clusters; The scaling execution module is used to execute cross-cluster instance elastic scaling when the state detection module detects that the instance elastic scaling of a single cluster cannot be implemented.
2. The multi-cluster system according to claim 1, characterized in that: The scaling configuration management module splits the multi-cluster scaling configuration into multiple single-cluster scaling configurations according to the multi-cluster scaling configuration configured by the user, and allocates the multiple single-cluster scaling configurations to the multiple clusters, and the native scaling module performs elastic scaling of instances of the single cluster according to the allocated single-cluster scaling configurations.
3. The multi-cluster system according to claim 2, characterized in that: The multi-cluster scaling configuration includes a maximum number of multi-cluster instances and a minimum number of multi-cluster instances, the single-cluster scaling configuration includes a maximum number of single-cluster instances and a minimum number of single-cluster instances, after the multi-cluster scaling configuration is split into multiple single-cluster scaling configurations, the sum of the maximum number of single-cluster instances of the multiple clusters is equal to the maximum number of multi-cluster instances, the sum of the minimum number of single-cluster instances of the multiple clusters is greater than or equal to the minimum number of multi-cluster instances, and the native scaling module of the cluster performs elastic scaling of instances of the single cluster between the maximum number of single-cluster instances and the minimum number of single-cluster instances of the cluster.
4. The multi-cluster system according to claim 1, characterized in that: The scaling configuration management module adjusts the single cluster scaling configuration of the cluster according to the load conditions of the multiple clusters detected by the status detection module.
5. The multi-cluster system according to claim 4, characterized in that: The single-cluster scaling configuration includes a single-cluster maximum number of instances and a single-cluster minimum number of instances. The status detection module detects the single-cluster maximum number of instances, the current number of instances, and the resource status of the cluster. The scaling configuration management module periodically calculates the difference between the single-cluster maximum number of instances and the current number of instances to obtain a difference value, and then sums the differences of the multiple clusters to obtain a sum value. The scaling configuration management module redistributes the sum value to the multiple clusters so that each cluster has a new single-cluster maximum number of instances.
6. The multi-cluster system according to claim 1, characterized in that: When the state detection module detects that resources of a first cluster among the multiple clusters are insufficient and resources of a second cluster among the multiple clusters are sufficient, the scaling execution module increases the number of instances in the second cluster.
7. The multi-cluster system according to claim 1, characterized in that: When the state detection module detects that the resource utilization of a third cluster among the multiple clusters is lower than a preset value and the resource utilization of a fourth cluster among the multiple clusters whose priority is lower than the third cluster is lower than a preset value, the scaling execution module maintains the number of instances of the third cluster, and the native scaling module of the fourth cluster reduces the number of instances in the fourth cluster.
8. A method for elastically scaling a multi-cluster system, characterized in that: include: Increasing or decreasing the number of instances of applications deployed in the multiple clusters and distributed in the clusters through the native scaling module of each cluster in the multiple clusters, so as to achieve elastic scaling of instances in a single cluster; Managing native scaling configurations of the plurality of clusters through a scaling configuration management module of a management device; The status of the multiple clusters is detected by the status detection module of the management device. When the status detection module detects that elastic scaling of instances of a single cluster cannot be implemented, elastic scaling of instances across clusters is performed by the scaling execution module of the management device.
9. The elastic expansion method according to claim 8, characterized in that: The managing the native scaling configurations of the plurality of clusters by the scaling configuration management module of the management device includes: By means of the scaling configuration management module, according to the multi-cluster scaling configuration configured by the user, the multi-cluster scaling configuration is split into a plurality of single-cluster scaling configurations, and the plurality of single-cluster scaling configurations are allocated to the plurality of clusters; The native scaling module performs elastic scaling of instances of a single cluster according to the allocated single cluster scaling configuration.
10. The elastic expansion method according to claim 9, characterized in that: The multi-cluster scaling configuration includes a maximum number of multi-cluster instances and a minimum number of multi-cluster instances, the single-cluster scaling configuration includes a maximum number of single-cluster instances and a minimum number of single-cluster instances, and the scaling configuration management module splits the multi-cluster scaling configuration into multiple single-cluster scaling configurations according to the multi-cluster scaling configuration configured by the user, and allocates the multiple single-cluster scaling configurations to the native scaling modules of the multiple clusters, including: Splitting the multi-cluster scaling configuration into multiple single-cluster scaling configurations, so that the sum of the maximum number of single-cluster instances of the multiple clusters is equal to the maximum number of multi-cluster instances, and the sum of the minimum number of single-cluster instances of the multiple clusters is greater than or equal to the minimum number of multi-cluster instances; The native scaling module performs elastic scaling of a single cluster according to the allocated single cluster scaling configuration, including: The native scaling module of the cluster performs elastic scaling of instances of a single cluster between a maximum number of instances of a single cluster and a minimum number of instances of a single cluster.
11. The elastic expansion method according to claim 8, characterized in that: The managing the native scaling configurations of the plurality of clusters by the scaling configuration management module of the management device includes: The scaling configuration management module adjusts the single cluster scaling configuration of the cluster according to the load conditions of the multiple clusters detected by the status detection module.
12. The elastic expansion method according to claim 11, characterized in that: The single cluster scaling configuration includes a maximum number of instances in a single cluster and a minimum number of instances in a single cluster, and adjusting the single cluster scaling configuration of the cluster according to the load conditions of the multiple clusters detected by the status detection module through the scaling configuration management module includes: Detecting the maximum number of instances, the current number of instances and the resource status of the cluster by the status detection module; The scaling configuration management module periodically calculates the difference between the maximum number of instances in the single cluster and the current number of instances to obtain a difference value, and then sums the difference values of the multiple clusters to obtain a sum value; The sum value is redistributed to the multiple clusters through the scaling configuration management module, so that each cluster has a new maximum number of instances of a single cluster.
13. The elastic expansion method according to claim 8, characterized in that: The state detection module of the management device is used to detect the state of the multiple clusters, and when the state detection module detects that the elastic scaling of the instance of a single cluster cannot be implemented, the elastic scaling of the instance across clusters is performed by the scaling execution module of the management device, including: When the state detection module detects that resources of a first cluster among the multiple clusters are insufficient and resources of a second cluster among the multiple clusters are sufficient, the scaling execution module increases the number of instances in the second cluster.
14. The elastic expansion method according to claim 8, characterized in that: The state detection module of the management device is used to detect the state of the multiple clusters, and when the state detection module detects that the elastic scaling of the instance of a single cluster cannot be implemented, the elastic scaling of the instance across clusters is performed by the scaling execution module of the management device, including: When the state detection module detects that the resource utilization of a third cluster among the multiple clusters is lower than a preset value and the resource utilization of a fourth cluster among the multiple clusters whose priority is lower than the third cluster is lower than a preset value, the scaling execution module is used to maintain the number of instances of the third cluster, and the native scaling module of the fourth cluster reduces the number of instances in the fourth cluster.
15. A computing device cluster, characterized in that: comprising at least one computing device, each computing device comprising a processor and a memory; The processor of the at least one computing device is used to execute instructions stored in the memory of the at least one computing device, so that the computing device cluster executes the elastic scaling method of the multi-cluster system according to any one of claims 8 to 14.
16. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and the computer program is used to execute the elastic scaling method of the multi-cluster system according to any one of claims 8 to 14.
17. A computer program product comprising instructions, characterized in that When the instruction is executed by a computer device cluster, the computer device cluster executes the elastic scaling method for a multi-cluster system as claimed in any one of claims 8 to 14.
Citation Information
Cited By
Data processing method, system and equipment based on capacity expansion and shrinkage and medium
CN122220034A
Multi-cluster system and elastic scaling method therefor, computing device cluster, and medium
EP4657256A1
