Resource management method and device, storage medium and electronic device

By generating and merging management tasks in the cloud management platform and performing resource management operations, the problem of slow resource release speed of cloud management platform in the failure self-healing scenario is solved, and the failure recovery speed of resource clusters is improved.

CN114726869BActive Publication Date: 2024-11-12CHINA CONSTRUCTION BANK
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210341708.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-02
Publication Date
2024-11-12
Estimated Expiration
2042-04-02

AI Technical Summary

Technical Problem

The cloud management platform cannot quickly release resources in the self-healing scenario of failure, resulting in a reduced recovery speed of resource clusters and the inability to take into account the needs of agile business and fine management.

Method used

By obtaining resource creation information, generating management tasks and adding them to the task queue and detection queue, reading target management tasks, merging pending management tasks, executable management tasks, updating task queues until there are no management tasks in the task queue, To achieve the rapid release of resource management.

Benefits of technology

It realizes rapid resource management process, improves the speed of resource cluster failure recovery, and meets the needs of rapid resource release in the self-healing scenario of failure.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114726869B_ABST
    Figure CN114726869B_ABST
Patent Text Reader

Abstract

The present invention provides a resource management method and device, a storage medium and an electronic device. The method comprises: adding each management task generated according to resource creation information to a task queue, and adding each management task to each detection queue; reading the first management task in the task queue, and taking the management task as a target management task; merging each pending management task corresponding to the target management task obtained in each detection queue to obtain an executable management task; executing the executable management task to implement the resource management operation corresponding to the executable management task; updating the task queue, and returning to the step of executing the first management task in the task queue until there is no management task in the task queue. By implementing resource management by executing management tasks, the process of managing resources does not require additional operations, and resources can be quickly released, thereby accelerating the recovery of resource clusters.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of resource management, and in particular to a resource management method and device, a storage medium and an electronic device. Background Art

[0002] Currently, most cloud management platforms have the ability to allocate resources and self-build internal enterprise management processes. They can meet the needs of enterprises to achieve self-service management processes when applying cloud computing resources. That is, resource allocation and other management functions are integrated into a complete set of user-oriented cloud computing resource delivery self-service through process orchestration, and this service can be used to manage resources in the cloud management platform.

[0003] The recovery speed of faulty resources in the cloud infrastructure fault self-healing scenario in the cloud management platform is one of the indicators of the normal operation of the cloud management platform. For faulty resource scenarios, resource configuration and other operations are required during resource management, which results in the inability to quickly release resources and reduces the speed of resource cluster fault recovery. Summary of the invention

[0004] In view of this, the present invention provides a resource management method and device, a storage medium and an electronic device, which can release resources and improve the speed of resource cluster failure recovery.

[0005] To achieve the above objectives, the embodiments of the present invention provide the following technical solutions:

[0006] The first aspect of the present invention discloses a resource management method, comprising:

[0007] Get resource creation information;

[0008] Creating computing resources based on the resource creation information and generating various management tasks;

[0009] Add each of the management tasks to a preset task queue;

[0010] Adding each of the management tasks to each preset detection queue;

[0011] Read the first management task in the task queue;

[0012] The read management task is used as the target management task;

[0013] Acquire each to-be-processed management task corresponding to the target management task in each of the detection queues;

[0014] Merging each of the pending management tasks to obtain an executable management task;

[0015] Executing the executable management task to implement a resource management operation corresponding to the executable management task on the computing resource;

[0016] The task queue is updated, and the step of reading the first management task in the task queue is returned to be executed until no management task exists in the task queue.

[0017] The above method may optionally further include:

[0018] Add the created computing resources to the preset resource cluster.

[0019] In the above method, optionally, the adding each of the management tasks to each of the preset detection queues includes:

[0020] determining a task type for each of the management tasks;

[0021] For each of the management tasks, a detection queue corresponding to the task type of the management task in each of the detection queues is determined as a target detection queue, and the management task is added to the target detection queue.

[0022] In the above method, optionally, the acquiring each to-be-processed management task corresponding to the target management task in each detection queue includes:

[0023] Parsing the target management task to obtain deployment object information in the target management task;

[0024] Each management task corresponding to the deployment object information in each detection queue is determined as a management task to be processed.

[0025] In the above method, optionally, the step of merging the management tasks to be processed to obtain executable management tasks includes:

[0026] Determining the task type of each of the management tasks to be processed;

[0027] Matching the task type of each of the pending management tasks with the preset task rules to determine the task execution type;

[0028] Each of the to-be-processed management tasks is merged to obtain an executable management task corresponding to the task execution type.

[0029] In the above method, optionally, the updating process of the task queue includes:

[0030] Each management task corresponding to the deployment object information is determined in the task queue, and each determined management task is deleted from the task queue to complete the update of the task queue.

[0031] A second aspect of the present invention discloses a resource management device, comprising:

[0032] A first acquisition unit, used to acquire resource creation information;

[0033] A generating unit, configured to create computing resources based on the resource creation information and generate various management tasks;

[0034] A first adding unit, used for adding each of the management tasks to a preset task queue;

[0035] A second adding unit, used for adding each of the management tasks to each preset detection queue;

[0036] A reading unit is used to read the first management task in the task queue;

[0037] A determination unit, used for taking the read management task as a target management task;

[0038] A second acquisition unit, configured to acquire, in each of the detection queues, each to-be-processed management task corresponding to the target management task;

[0039] A merging processing unit, used for merging the management tasks to be processed to obtain executable management tasks;

[0040] An execution unit, configured to execute the executable management task and implement a resource management operation corresponding to the executable management task on the computing resource;

[0041] The updating unit is used to update the task queue and, when there is a management task in the updated task queue, call the reading unit to execute the step of reading the first management task in the task queue.

[0042] The above device may optionally further include:

[0043] The third adding unit is used to add the created computing resources to the preset resource cluster.

[0044] In the above device, optionally, the second adding unit includes:

[0045] A first determining subunit, configured to determine a task type of each management task;

[0046] The adding subunit is used to determine, for each of the management tasks, a detection queue in each of the detection queues corresponding to the task type of the management task as a target detection queue, and add the management task to the target detection queue.

[0047] In the above device, optionally, the second acquisition unit includes:

[0048] A parsing subunit, used to parse the target management task and obtain the deployment object information in the target management task;

[0049] The second determining subunit is used to determine each management task corresponding to the deployment object information in each detection queue as a management task to be processed.

[0050] In the above device, optionally, the merging processing unit includes:

[0051] A third determining subunit is used to determine the task type of each of the management tasks to be processed;

[0052] A matching subunit, used for matching the task type of each of the management tasks to be processed with the preset task rules to determine the task execution type;

[0053] The merging processing subunit is used to merge the various management tasks to be processed to obtain executable management tasks corresponding to the task execution type.

[0054] In the above device, optionally, the updating unit includes:

[0055] The updating subunit is used to determine each management task corresponding to the deployment object information in the task queue, and delete each determined management task from the task queue to complete the update of the task queue.

[0056] A third aspect of the present invention discloses a storage medium, which includes stored instructions, wherein when the instructions are executed, a device where the storage medium is located is controlled to execute the resource management method as described above.

[0057] A fourth aspect of the present invention discloses an electronic device, comprising a memory and one or more instructions, wherein the one or more instructions are stored in the memory and are configured to be executed by one or more processors to perform the resource management method as described above.

[0058] Compared with the prior art, the present invention has the following advantages:

[0059] The present invention provides a resource management method and device, a storage medium and an electronic device. The method comprises: adding each management task generated according to resource creation information to a task queue, and adding each management task to each detection queue; reading the first management task in the task queue, and taking the management task as a target management task; merging and processing each pending management task corresponding to the target management task obtained in each detection queue to obtain an executable management task; executing the executable management task to implement the resource management operation corresponding to the executable management task; updating the task queue, and returning to the step of executing the first management task in the task queue until there is no management task in the task queue. By implementing resource management by executing management tasks, the process of managing resources does not require additional operations and waiting, and resource management can be implemented, so that resources can be released quickly and the speed of resource cluster recovery can be accelerated. BRIEF DESCRIPTION OF THE DRAWINGS

[0060] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.

[0061] Figure 1 A method flow chart of a resource management method provided by an embodiment of the present invention;

[0062] Figure 2 A flow chart of a method for adding various management tasks to various preset detection queues provided in an embodiment of the present invention;

[0063] Figure 3 An example diagram of a management task in a queue provided by an embodiment of the present invention;

[0064] Figure 4 A flow chart of a method for obtaining each to-be-processed management task corresponding to a target management task in each detection queue provided for the implementation of the present invention;

[0065] Figure 5 A flow chart of a method for merging various pending management tasks to obtain executable management tasks provided in an embodiment of the present invention;

[0066] Figure 6 A diagram showing an example scenario of a resource management method provided by an embodiment of the present invention;

[0067] Figure 7 A schematic diagram of the structure of a resource management device provided by an embodiment of the present invention;

[0068] Figure 8 A schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0069] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0070] In this application, the terms "comprises", "comprising" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprising a ..." does not exclude the presence of other identical elements in the process, method, article or device comprising the element.

[0071] The present invention relates to cloud computing platform, cloud management platform, banking IT management, resource management, fault self-healing, etc., and provides relevant descriptions of cloud computing platform, cloud management platform, banking IT management, resource management, fault self-healing:

[0072] Cloud computing platform, also known as cloud platform, refers to a platform that can provide various cloud services such as IaaS, PaaS, SaaS, etc. Cloud service is a way of dynamically, on-demand, and flexibly scalable acquisition of resources, software or application services through the Internet. It can also be called a commodity.

[0073] Cloud Management Platform (CMP) is a product form in the enterprise cloud strategy first proposed by Gartner. Cloud Management Platform is a management platform independent of IaaS and PaaS. It manages the cloud computing resources required for application operation based on cloud API, realizes a unified management view of resources, realizes the integration and delivery of internal enterprise processes, and finally realizes self-service of cloud platform.

[0074] Banking IT management refers to IT management requirements for banking IT deployment, maintenance management, etc. based on the characteristics of banking business, such as system user password management, resource monitoring management, configuration management, and other related management processes and management functions that serve the system operation and maintenance management.

[0075] Resource management refers to the management of resources throughout their entire life cycle, from construction to operation to extinction, including changes in the configuration of various resources during the life cycle.

[0076] Fault self-healing refers to real-time detection of alarms, pre-diagnosis and analysis, automatic fault recovery, and connecting peripheral systems to achieve a closed loop of the entire process. For cloud infrastructure-level fault self-healing, it usually refers to real-time detection of faulty resources, isolation of faulty resources, recovery of resources, and configuration of related management and control functions for the recovery resources.

[0077] With the rapid development of information technology and the gradual personalization and agility of banking business, the demand for the delivery of underlying infrastructure resources supporting the operation of banking business has become more personalized and agile. At the same time, with the refinement of IT management and the improvement of digital capabilities in the banking industry, the control requirements for resource delivery have become more refined and comprehensive, which means that there are more control links and more detailed control in the resource delivery process. In the context of increasingly agile demand and more refined control, higher requirements are placed on the delivery capabilities of infrastructure resources. On the one hand, infrastructure resources must be released more quickly, and on the other hand, more refined management functions must be implemented in the resource delivery process. Especially in the fault self-healing scenario, it is necessary to quickly isolate the faulty resources and quickly release replacement resources without user perception to meet the business operation requirements. At the same time, the corresponding internal management functions of the enterprise must be implemented. For traditional cloud service delivery, resource release and resource control functions are often serialized in a resource delivery process. This resource delivery function design cannot take into account the dual needs of business agility and refined control under the above background.

[0078] At present, most cloud management platforms have the ability to allocate resources and build internal enterprise management processes by themselves, which can meet the needs of enterprises to realize self-service management processes when applying cloud computing resources, that is, resource allocation and other management functions are integrated into a set of self-service cloud computing resource delivery for users through process orchestration. This design is an ideal implementation method for most application scenarios. The enterprise management function configuration is completed at the same time as resource delivery. However, for cloud infrastructure fault self-healing scenarios, it cannot restore the resource supporting related control function configuration in time when restoring resources, especially when the control function is becoming more and more refined, that is, when the control configuration function nodes are increasing. If the traditional resource delivery method is used, the recovery resources will be delivered after all the control function configurations are implemented, which cannot meet the real-time requirements of fault self-healing.

[0079] Therefore, in the fault self-healing scenario of the cloud management platform, in order to ensure the normal operation of the cloud management platform, how to quickly release resources and make the cluster resource self-healing speed meet the demand has become an urgent problem that staff need to solve.

[0080] The present invention can be used in many general or special computing device environments or configurations, such as personal computers, server computers, handheld or portable devices, tablet devices, multi-processor devices, distributed computing environments including any of the above devices or devices, etc. The execution subject of the present invention can be a computer processor or server.

[0081] Reference Figure 1 , is a method flow chart of a resource management method provided by an embodiment of the present invention, and is specifically described as follows:

[0082] S101: Obtain resource creation information.

[0083] Obtain resource creation information sent by resource management personnel or operation and maintenance personnel. The resource creation information includes resource requirement information for creating computing resources and information about creating management tasks.

[0084] S102: Create computing resources based on the resource creation information, and generate various management tasks.

[0085] The resource creation information is parsed to obtain resource requirement information and task creation information in the resource creation information; computing resources are created based on the resource requirement information, and various management tasks are generated based on the task creation information.

[0086] Preferably, after the computing resources are created, the computing resources may be added to a preset resource cluster, where the resource cluster is a collection of the created computing resources.

[0087] S103: Add each management task to a preset task queue.

[0088] In the method provided by the embodiment of the present invention, a task queue is pre-set, and the task queue may be a first-in-first-out queue.

[0089] Each management task generated is added to a preset task queue. Preferably, the management tasks can be added according to the order in which they are generated, or according to the urgency of executing the management tasks, or randomly. Furthermore, the present invention has multiple ways of adding each management task to the preset task queue, and is not limited to the adding method in the above example.

[0090] S104: Add each management task to each preset detection queue.

[0091] Preferably, the present invention sets a plurality of detection queues, each detection queue corresponds to a different task type, that is, each task type corresponds to a detection queue.

[0092] Reference Figure 2, which is a flow chart of a method for adding various management tasks to various preset detection queues provided by an embodiment of the present invention, and is specifically described as follows:

[0093] S201: Determine the task type of each management task.

[0094] Each management task is parsed to obtain the task type identifier of each management task, and the task type of each management task is determined based on the task type identifier; preferably, the task types in the embodiment of the present invention include but are not limited to three types: new creation, expansion and contraction, and recycling, and each task type corresponds to a detection queue; preferably, task1 is a task type identifier whose task type is new creation, task2 is a task type identifier whose task type is expansion and contraction, and task3 is a task type identifier whose task type is recycling.

[0095] S202: For each management task, determine a detection queue corresponding to the task type of the management task in each detection queue as a target detection queue, and add the management task to the target detection queue.

[0096] Exemplarily, when the task type of the management task is new creation, the monitoring corresponding to the new creation in each detection queue is determined as a target detection queue, and the management task is added to the target detection queue.

[0097] Reference Figure 3 , which is an example diagram of management tasks in a queue provided in an embodiment of the present invention. As shown in the figure, the detection queue 1 in the figure stores newly created management tasks, the detection queue 2 stores expansion and reduction management tasks, and the detection queue 3 stores recycled management tasks; the task queue is used to store all management tasks. Figure 3 An example diagram showing how to read a management task from a task queue, process the read task, and then update the task queue and each detection queue. Figure 3 Part A in the example may be a management task queue and a management task in each detection queue before the management task is read. Figure 3 Part B in the example may be a part after the management tasks in the task queue and each detection queue are updated after the management tasks are read.

[0098] Depend on Figure 3From the content of Part A, it can be seen that the task queue contains a total of 9 tasks, among which the task type identifiers of management task 1, management task 2 and management task 4 in the task queue are all task1, then management task 1, management task 2 and management task 4 are all saved in detection queue 1; the task type identifiers of management task 3, management task 6 and management task 7 in the task queue are all task2, then management task 3, management task 6 and management task 7 are saved in detection queue 2; the task identifiers of management task 5, management task 8 and management task 9 in the task queue are all task3, then management task 5, management task 8 and management task 9 are saved in detection queue 3.

[0099] By using the task identifier of the management task, each management task is classified and saved, which is conducive to the management of each management task.

[0100] S105: Determine whether there is a management task in the task queue. If it is determined that there is a management task in the detection queue, execute S106; if it is determined that there is no management task in the detection queue, execute S112.

[0101] When judging whether there is a management task in the task queue, it is actually judging whether the task queue is empty. If there is no management task in the task queue, it means that the task queue is empty, and step S112 is executed at this time. If there is a management task in the task queue, it means that the task queue is not empty, and step S106 is executed at this time.

[0102] S106: Read the first management task in the task queue.

[0103] When there are management tasks in the task queue, read the first management task in the task queue, refer to Figure 3 In part A of the task queue, the first management task in the task queue is management task 1.

[0104] S107: The read management task is used as the target management task.

[0105] The management task read is used as the target management task, and the description of S106 is continued. Figure 3 Management Task 1 in is used as the target management task.

[0106] S108: Acquire each to-be-processed management task corresponding to the target management task in each detection queue.

[0107] Reference Figure 4 , a flowchart of a method for obtaining each pending management task corresponding to a target management task in each detection queue provided by the present invention is specifically described as follows:

[0108] S401: Parse the target management task to obtain deployment object information in the target management task.

[0109] Furthermore, the deployment object information may be information of a virtual machine, see Figure 3 In the A part, unit1, unit2, unit8, and unit10 in the figure are all deployment object information, and different deployment object information corresponds to different deployment objects.

[0110] S402: Determine each management task corresponding to the deployment object information in each detection queue as a management task to be processed.

[0111] The deployment object information of the target management task is compared with the deployment object information of each management task in each detection queue, and each management task in each detection queue that is consistent with the deployment object information of the target management task is determined as a pending management task. Further, after the management task in the detection queue that is consistent with the deployment object information of the target management task is determined as a pending management task, the management task has been extracted from the detection queue and does not exist in the detection queue.

[0112] Exemplarily, continuing the description of S106, when the target management task is management task 1, the deployment object information of management task 1 is unit1, then management task 1 in detection task 1, management task 3 in detection queue 2, and management task 5 in detection queue 3 are all pending management tasks.

[0113] S109: Merge the various management tasks to be processed to obtain executable management tasks.

[0114] Reference Figure 5 , which is a flowchart of a method for merging various pending management tasks to obtain executable management tasks provided by an embodiment of the present invention, and is specifically described as follows:

[0115] S501: Determine the task type of each management task to be processed.

[0116] In the method provided in the embodiment of the present invention, it is necessary to determine the task type of each management task to be processed. For the description of the task type, please refer to Figure 2 The relevant instructions in will not be repeated here.

[0117] S502: Match the task type of each management task to be processed with the preset task rules to determine the task execution type.

[0118] Preferably, the contents of the preset task rules are described, specifically: task1+task2=updatetask1 (note: task2 has been configured to update task1); task1+task3=0 (task canceled); task2+task3=0 (task canceled); task1+task2+task3=0 (task canceled).

[0119] In the method provided by the embodiment of the present invention, the task execution type includes two types, one is task cancellation and the other is configuration update.

[0120] Exemplarily, continuing from the description in step S402, when the target management task is management task 1, the target management but not the management tasks to be processed are management task 1 in detection task 1, management task 3 in detection queue 2, and management task 5 in detection queue 3; the task type of management task 1 in detection queue 1 is task1 type, the task type of management task 3 in detection queue 2 is task2 type, the task type of management task 5 in detection queue 3 is task3 type, and task1+task2+task3=0 (task canceled), and the determined task execution type is the task cancellation type.

[0121] S503: Merge the management tasks to be processed to obtain executable management tasks corresponding to the task execution type.

[0122] Continuing with the description in S502, management task 1, management task 3 and management task 5 are merged to obtain an executable management task whose task execution type is a task cancellation type.

[0123] In the method provided by the embodiment of the present invention, by merging the various pending management tasks corresponding to the deployment object information of the target management task, the final task execution type can be detected to facilitate the execution of the corresponding resource management operation.

[0124] S110: Execute the executable management task to implement resource management operations corresponding to the executable management task on computing resources.

[0125] Preferably, when the task execution type is a cancel type, when executing the executable management task, the task may be canceled, or the computing resources corresponding to the executable management task may be canceled or destroyed, and step S111 is executed immediately.

[0126] Furthermore, when the task execution type of the executable management task is an update type, resource management operations such as resource data management, management tool installation and deployment, and monitoring deployment can be performed on the computing resources, thereby realizing resource delivery and restoring faulty resources.

[0127] Execute executable management tasks to manage computing resources. You can destroy computing resources without waiting for the management process of the computing resources to end, thereby speeding up the release of computing resources and the recovery of faulty resources.

[0128] S111: Update the task queue and return to execute S105.

[0129] Preferably, after the task queue is updated, each detection queue is also updated.

[0130] The specific process of updating the task queue is as follows: determining each management task corresponding to the deployment object information in the task queue, and deleting each management task determined from the task queue to complete the update of the task queue; Figure 3 In part A of S106, the target management task is management task 1, the deployment object information of management task 1 is unit1, and the management tasks corresponding to unit1 in the task queue also include management tasks 3 and 5. Management tasks 3 and 5 are deleted from the task queue, that is, the task queue is updated. Figure 3 Part B in the updated task queue is shown in the figure. Figure 3 In part B, detection queue 1, detection queue 2, and detection queue 3 are all updated detection queues. At this time, there is no management task corresponding to the deployment object information of the target management task in the detection queue.

[0131] Preferably, after the task queue is updated, the management tasks in the task queue have been refreshed, referring to Figure 3 In part B, the first management task in the task queue is management task 2. Therefore, after returning to execute S105 and determining that there is a management task in the task queue, when executing step S106, management task 2 is read.

[0132] In the method provided in the embodiment of the present invention, the purpose of updating the task queue is to delete each management task corresponding to the deployment object information of the target management task, so that the management tasks that have been merged can be deleted, thereby avoiding the repeated execution of the same operation, speeding up the execution of management tasks in the task queue, so that resources can be quickly released in the fault self-healing scenario, improving the efficiency of resource management, and making the resource cluster fault recovery speed meet the requirements.

[0133] S112: End.

[0134] In the method provided by the embodiment of the present invention, each management task generated according to resource creation information is added to the task queue, and each management task is added to each detection queue; the first management task in the task queue is read; the read management task is used as the target management task, and each pending management task corresponding to the target management task is obtained in each detection queue; each pending management task is merged to obtain an executable management task; the executable management task is executed to implement the resource management operation corresponding to the executable management task; the task queue is updated, and the step of executing the first management task in the read task queue is returned until there is no management task in the task queue. By using resource creation information to generate management tasks, using management tasks to implement the management of resources in the fault self-healing scenario, after executing the executable management task obtained by merging each pending management task corresponding to the target management task, the resource management operation corresponding to the executable management task can be implemented, and the whole process does not require additional operations. In the fault self-healing scenario, resources can be quickly released, and the speed of resource cluster fault recovery is improved.

[0135] The resource management method provided by the present invention abandons the common cloud management platform, which serializes the enterprise management process such as resource creation and management function configuration implementation, and adopts the method of separating resource creation from resource management. In the resource creation layer, resources are released quickly and in real time according to the fault self-healing requirements to meet the cluster fault recovery requirements; in the resource management layer, according to the enterprise management requirements, the configuration and implementation of a series of enterprise IT management and control processes such as resource configuration information management, user password management, and monitoring information management are gradually completed to ensure closed-loop resource management. Between the resource creation layer and the resource management layer, different queues of resources to be managed are divided according to resource creation types and subsequent resource management requirements. The deployment object (minimum deployment implementation unit) and task type are used as detection unique values ​​between queues. Through the preset task processing logic, when the deployment objects in the detection unique values ​​are the same but the task types are different, the tasks are merged or cancelled according to the preset processing logic, to ensure the closed-loop and consistency of resource management after resource creation, and to accelerate the speed of resource release, so that the self-healing of the resource cluster can meet the requirements.

[0136] Furthermore, the method provided by the present invention is compared with the traditional cloud management platform resource management method. The traditional cloud management platform resource management method is mostly a serial process of resource creation, resource control and management to ensure the standardized configuration and management of all resources. However, this method is not suitable for fault self-healing scenarios. Fault self-healing scenarios will have frequent destruction and creation actions, and the serial process needs to complete the overall process of creation or destruction before the next action can be performed, which affects the rapid self-healing of the cluster. Figure 6, which is a scenario example diagram of the resource management method provided by the embodiment of the present invention. The resource management method proposed by the present invention divides resource creation and resource management into two sub-processes. The two sub-processes are connected by a resource management task scheduling module. The resource management task scheduling module is implemented by a task queue and multiple detection queues. The resource creation sub-process only includes resource change operations. All resource change operations will generate management tasks. The resource management task scheduling module will detect each management task, merge tasks according to rules, and trigger the resource management sub-process. Specifically, the target management task is determined in the task queue, and each pending management task corresponding to the target management task is determined in each detection queue. Each pending management task is merged to obtain an executable management task. Executing the executable management task is to trigger the resource management sub-process. Further, the resource management sub-process also includes resource management operations such as resource data management, management tool installation and deployment, monitoring deployment, and resource destruction. Further, the operation of destroying resources directly destroys the resources to complete the operation. In this way, the release or destruction of resources in the cluster in the fault self-healing scenario does not need to wait for the end of the resource management process, and all existing resources are scheduled by the task management module to ensure the closed loop of resource management.

[0137] Preferably, the present invention solidifies the task rules by using the task management method of task queue + detection queue, performs task detection on each management task in the task queue, updates the task queue and executes the management task according to the detection result, realizes resource management, improves the speed of releasing resources, and makes the resource failure recovery speed meet the demand.

[0138] and Figure 1 Correspondingly, the embodiment of the present invention provides a resource management device for supporting Figure 1 In the real life implementation of the method shown, the device can be configured in a computer terminal. Figure 7 , is a schematic diagram of the structure of the device, and the specific description is as follows:

[0139] The first acquisition unit 701 is used to acquire resource creation information;

[0140] A generating unit 702, configured to create computing resources based on the resource creation information and generate various management tasks;

[0141] A first adding unit 703 is used to add each of the management tasks to a preset task queue;

[0142] A second adding unit 704, configured to add each of the management tasks to each of the preset detection queues;

[0143] The reading unit 705 is used to read the first management task in the task queue;

[0144] A determination unit 706, configured to use the read management task as a target management task;

[0145] A second acquisition unit 707 is used to acquire each to-be-processed management task corresponding to the target management task in each detection queue;

[0146] A merging processing unit 708, configured to merge the management tasks to be processed to obtain executable management tasks;

[0147] An execution unit 709 is configured to execute the executable management task and implement a resource management operation corresponding to the executable management task on the computing resource;

[0148] The updating unit 710 is used to update the task queue and, when there is a management task in the updated task queue, call the reading unit to execute the step of reading the first management task in the task queue.

[0149] In the device provided by the embodiment of the present invention, each management task generated according to resource creation information is added to the task queue, and each management task is added to each detection queue; the first management task in the task queue is read; the read management task is used as the target management task, and each pending management task corresponding to the target management task is obtained in each detection queue; each pending management task is merged to obtain an executable management task; the executable management task is executed to implement the resource management operation corresponding to the executable management task; the task queue is updated, and the step of executing the first management task in the task queue is returned until there is no management task in the task queue. By using resource creation information to generate management tasks, using management tasks to implement the management of resources in the fault self-healing scenario, after executing the executable management task obtained by merging each pending management task corresponding to the target management task, the resource management operation corresponding to the executable management task can be implemented, and the whole process does not require additional operations. In the fault self-healing scenario, resources can be quickly released, and the speed of resource cluster fault recovery is improved.

[0150] The device provided in the embodiment of the present invention may also be configured as follows:

[0151] The third adding unit is used to add the created computing resources to a preset resource cluster.

[0152] In the device provided by the embodiment of the present invention, the second adding unit 704 may be configured as follows:

[0153] A first determining subunit, configured to determine a task type of each management task;

[0154] The adding subunit is used to determine, for each of the management tasks, a detection queue in each of the detection queues corresponding to the task type of the management task as a target detection queue, and add the management task to the target detection queue.

[0155] In the device provided by the embodiment of the present invention, the second obtaining unit 707 may be configured as follows:

[0156] A parsing subunit, used to parse the target management task and obtain the deployment object information in the target management task;

[0157] The second determining subunit is used to determine each management task corresponding to the deployment object information in each detection queue as a management task to be processed.

[0158] In the device provided by the embodiment of the present invention, the merging processing unit 708 may be configured as follows:

[0159] A third determining subunit is used to determine the task type of each of the management tasks to be processed;

[0160] A matching subunit, used for matching the task type of each of the management tasks to be processed with the preset task rules to determine the task execution type;

[0161] The merging processing subunit is used to merge the various management tasks to be processed to obtain executable management tasks corresponding to the task execution type.

[0162] In the device provided by the embodiment of the present invention, the updating unit 710 may be configured as follows:

[0163] The updating subunit is used to determine each management task corresponding to the deployment object information in the task queue, and delete each determined management task from the task queue to complete the update of the task queue.

[0164] An embodiment of the present invention further provides a storage medium, which includes stored instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the above-mentioned resource management method.

[0165] The embodiment of the present invention further provides an electronic device, the structural diagram of which is shown in FIG. Figure 8 As shown, it specifically includes a memory 801 and one or more instructions 802, wherein the one or more instructions 802 are stored in the memory 801 and are configured to be executed by one or more processors 803 to execute the one or more instructions 802 to perform the above resource management method.

[0166] The specific implementation processes and derivative methods of the above-mentioned embodiments are all within the protection scope of the present invention.

[0167] Each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can refer to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system or system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can refer to the partial description of the method embodiment. The system and system embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without creative work.

[0168] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0169] The above description of the disclosed embodiments enables one skilled in the art to implement or use the present invention. Various modifications to these embodiments will be apparent to one skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but rather to the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A resource management method, characterized in that: include: Get resource creation information; Creating computing resources based on the resource creation information and generating various management tasks; Add each of the management tasks to a preset task queue; Adding each of the management tasks to each preset detection queue; Read the first management task in the task queue; The read management task is used as the target management task; Acquire each to-be-processed management task corresponding to the target management task in each of the detection queues; Merging each of the pending management tasks to obtain an executable management task; Executing the executable management task to implement a resource management operation corresponding to the executable management task on the computing resource; Performing an update process on the task queue, and returning to the step of executing the first management task in the task queue, until no management task exists in the task queue; The step of merging the management tasks to be processed to obtain executable management tasks includes: Determining the task type of each of the management tasks to be processed; Matching the task type of each of the pending management tasks with the preset task rules to determine the task execution type; Each of the to-be-processed management tasks is merged to obtain an executable management task corresponding to the task execution type.

2. The method according to claim 1, characterized in that Also includes: Add the created computing resources to the preset resource cluster.

3. The method according to claim 1, characterized in that The adding each of the management tasks to each of the preset detection queues includes: determining a task type for each of the management tasks; For each of the management tasks, a detection queue corresponding to the task type of the management task in each of the detection queues is determined as a target detection queue, and the management task is added to the target detection queue.

4. The method according to claim 1, characterized in that: The acquiring each to-be-processed management task corresponding to the target management task in each of the detection queues includes: Parsing the target management task to obtain deployment object information in the target management task; Each management task corresponding to the deployment object information in each detection queue is determined as a management task to be processed.

5. The method according to claim 4, characterized in that The updating process of the task queue includes: Each management task corresponding to the deployment object information is determined in the task queue, and each determined management task is deleted from the task queue to complete the update of the task queue.

6. A resource management device, characterized in that: include: A first acquisition unit, used to acquire resource creation information; A generating unit, configured to create computing resources based on the resource creation information and generate various management tasks; A first adding unit, used for adding each of the management tasks to a preset task queue; A second adding unit, used for adding each of the management tasks to each preset detection queue; A reading unit is used to read the first management task in the task queue; A determination unit, used for taking the read management task as a target management task; A second acquisition unit, configured to acquire, in each of the detection queues, each to-be-processed management task corresponding to the target management task; A merging processing unit, used for merging the management tasks to be processed to obtain executable management tasks; An execution unit, configured to execute the executable management task and implement a resource management operation corresponding to the executable management task on the computing resource; An updating unit, used for updating the task queue and, when there is a management task in the updated task queue, calling the reading unit to execute the step of reading the first management task in the task queue; Wherein, the merging processing unit includes: A third determining subunit is used to determine the task type of each of the management tasks to be processed; A matching subunit, used for matching the task type of each of the management tasks to be processed with the preset task rules to determine the task execution type; The merging processing subunit is used to merge the various management tasks to be processed to obtain executable management tasks corresponding to the task execution type.

7. The device according to claim 6, characterized in that Also includes: The third adding unit is used to add the created computing resources to a preset resource cluster.

8. A storage medium, characterized in that: The storage medium includes stored instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the resource management method according to any one of claims 1 to 5.

9. An electronic device, characterized in that: The system comprises a memory and a processor, and one or more instructions, wherein the one or more instructions are stored in the memory and configured to be executed by one or more processors as the resource management method according to any one of claims 1 to 5.