CN113778623A - Resource processing method and device, electronic equipment and storage medium - Google Patents

Resource processing method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN113778623A
CN113778623A CN202110991387.1A CN202110991387A CN113778623A CN 113778623 A CN113778623 A CN 113778623A CN 202110991387 A CN202110991387 A CN 202110991387A CN 113778623 A CN113778623 A CN 113778623A
Authority
CN
China
Prior art keywords
resource
server cluster
target
instance object
target instance
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202110991387.1A
Other languages
Chinese (zh)
Other versions
CN113778623B (en
Inventor
孙晓飞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Dajia Internet Information Technology Co Ltd
Original Assignee
Beijing Dajia Internet Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Dajia Internet Information Technology Co Ltd filed Critical Beijing Dajia Internet Information Technology Co Ltd
Priority to CN202110991387.1A priority Critical patent/CN113778623B/en
Publication of CN113778623A publication Critical patent/CN113778623A/en
Application granted granted Critical
Publication of CN113778623B publication Critical patent/CN113778623B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45562Creating, deleting, cloning virtual machine instances
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45591Monitoring or debugging support
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45595Network integration; Enabling network access in virtual machine instances

Abstract

The present disclosure relates to a resource processing method and apparatus, an electronic device, and a storage medium, wherein the method includes: monitoring an update message of resources in a first server cluster, wherein a target resource management module is a resource management module with unique processing authority in a plurality of resource management modules, when the update message indicates that the resources are changed, at least one third server cluster is selected from the plurality of second server clusters according to the resource use conditions of the plurality of second server clusters, and a target instance object is managed in the at least one third server cluster according to the update message, wherein the target instance object is an instance object determined according to the updated resources, and the target instance objects in different third server clusters respectively have unique identifications. The technical problem of low resource processing efficiency in the related technology is solved.

Description

Resource processing method and device, electronic equipment and storage medium
Technical Field
The present disclosure relates to the field of computers, and in particular, to a resource processing method and apparatus, an electronic device, and a storage medium.
Background
Currently, in the related art, in the process of performing multi-cluster management, a corresponding resource management module is generally configured for each cluster to perform resource processing in a multi-cluster scenario.
For example, kubernets is an open source for managing containerized applications on multiple hosts in a cloud platform, the goal of kubernets is to make deploying containerized applications simple and efficient, and kubernets provides a mechanism for application deployment, planning, updating, and maintenance. In the process of performing multi-cluster management in a kubernets scene, it is generally configured that each cluster deploys operator + multi-cluster management modules, each kubernets cluster deploys an operator, and the multi-cluster management modules are responsible for managing stateful services of each cluster.
However, since it is necessary to deploy operator for each kubernets cluster, resources cannot be fully utilized: when the resources used by a service exceed the remaining resource amount of a single cluster, the service cannot be created due to insufficient resources, and the total amount of the remaining resources of all the clusters meets the requirement, which causes a certain waste of resources and results in a technical problem of low resource processing efficiency.
Therefore, no effective solution exists at present for the technical problem of low efficiency of resource processing in the related art.
BRIEF SUMMARY OF THE PRESENT DISCLOSURE
The present disclosure provides a resource processing method and apparatus, an electronic device, and a storage medium, to at least solve the technical problem of low efficiency of resource processing in the related art. The technical scheme of the disclosure is as follows:
according to a first aspect of the embodiments of the present disclosure, there is provided a resource processing method, including: monitoring an update message of a resource in a first server cluster, wherein the first server cluster is used for storing the resource, the resource is used for managing a group of example objects according to an expected state, and the target resource management module is a resource management module with a unique processing authority in a plurality of resource management modules; when the update message indicates that the resource changes, selecting at least one third server cluster from a plurality of second server clusters according to the resource use conditions of the plurality of second server clusters; and managing target instance objects in the at least one third server cluster according to the update message, wherein the group of instance objects comprises the target instance objects, the target instance objects are instance objects determined according to the updated resources, and the target instance objects in different third server clusters respectively have unique identifiers.
Optionally, the resource comprises a customized resource CR generated based on the service creation request.
Optionally, the monitoring update messages of resources in the first server cluster includes: monitoring a first resource type of a resource to be processed in the first server cluster; and under the condition that the first resource type is determined to be the same as the target resource type which is allowed to be processed currently and the unique processing permission is acquired, acquiring an update message of the resource in the first server cluster.
Optionally, managing, in the at least one third server cluster, the target instance object according to the update message includes: obtaining the update message from the first server cluster, wherein the update message indicates that the resource updated at least one of: newly building the target instance object, modifying the target instance object, and deleting the target instance object; managing the target instance object in the at least one third server cluster based on the update message.
Optionally, based on the update message, managing the target instance object in the at least one third server cluster includes at least one of: in the case that the update message indicates that the target instance object needs to be newly created, creating a new target instance object in the at least one third server cluster; modifying the created target instance object in the at least one third server cluster in case the update message indicates that the target instance object needs to be modified; deleting the created target instance object in the at least one third server cluster in case the update message indicates that the target instance object needs to be deleted.
Optionally, the managing, in the at least one third server cluster, the target instance object according to the update message includes: monitoring the current state of the target instance object in the third server cluster under the condition that the target instance object is created to obtain a state result; and when the state result shows that the current state is different from the expected state, adjusting the target instance object according to the expected state.
Optionally, when the state result indicates that the current state is different from the expected state, adjusting the target instance object according to the expected state includes: selecting a fourth server cluster from the plurality of second server clusters when the state result indicates that a first instance object in the target instance objects is in an abnormal state, wherein the first instance object is any instance object in the target instance objects; and creating a second instance object in the fourth server cluster, and deleting the first instance object in the third server cluster, wherein the second instance object and the first instance object have the same identifier.
Optionally, when the state result indicates that the current state is different from the expected state, adjusting the target instance object according to the expected state includes: selecting a fifth server cluster among the plurality of second server clusters if the status result indicates that the third server cluster in which the target instance object is located is in a failure state; in the fifth server cluster, an instance object in a third server cluster in a failure state is created again, and the instance object in the third server cluster is deleted, wherein the instance object in the fifth server cluster and the instance object in the third server cluster in the failure state have the same identification.
According to a second aspect of the embodiments of the present disclosure, there is provided a resource processing system including: a first server cluster for storing resources; the target resource management module is used for monitoring the update message of the resource in the first server cluster, wherein the resource is used for managing a group of example objects according to an expected state, and the target resource management module is a resource management module with unique processing authority in a plurality of resource management modules; the target resource management module is further configured to select at least one third server cluster from the plurality of second server clusters according to resource usage conditions of the plurality of second server clusters when the update message indicates that the resource changes; the at least one third server cluster is configured to manage a target instance object according to the update message, where the group of instance objects includes the target instance object, the target instance object is an instance object determined according to the updated resource, and the target instance objects in different third server clusters have unique identifiers, respectively.
Optionally, the resource comprises a customized resource CR generated based on the service creation request.
Optionally, the target resource management module includes: a first monitoring unit, configured to monitor a first resource type of a resource to be processed in the first server cluster; and the first obtaining unit is used for obtaining the update message of the resource in the first server cluster under the condition that the first resource type is determined to be the same as the current target resource type allowed to be processed and the unique processing permission is obtained.
Optionally, the target resource management module is configured to manage a target instance object in the at least one third server cluster according to the update message by: obtaining the update information from the first server cluster, wherein the update information indicates that the resource updated at least one of: newly building the target instance object, modifying the target instance object, and deleting the target instance object; managing the target instance object in the at least one third server cluster based on the update information.
Optionally, the target resource management module is configured to manage the target instance object in the at least one third server cluster based on the update information by at least one of: in the case that the update information indicates that the target instance object needs to be newly created, creating a new target instance object in the at least one third server cluster; modifying the created target instance object in the at least one third server cluster in case the update information indicates that the target instance object needs to be modified; deleting the created target instance object in the at least one third server cluster in case the update information indicates that the target instance object needs to be deleted.
Optionally, the target resource management module is configured to adjust the target instance object according to the update message in at least one third server cluster by: monitoring the current state of the target instance object in the third server cluster under the condition that the target instance object is created to obtain a state result; and when the state result shows that the current state is different from the expected state, adjusting the target instance object according to the expected state.
Optionally, the target resource management module is configured to adjust the target instance object according to the expected state when the state result indicates that the current state is different from the expected state by: selecting a fourth server cluster from the plurality of second server clusters when the state result indicates that a first instance object in the target instance objects is in an abnormal state, wherein the first instance object is any instance object in the target instance objects; and creating a second instance object in the fourth server cluster, and deleting the first instance object in the third server cluster, wherein the second instance object and the first instance object have the same identifier.
Optionally, the target resource management module is configured to adjust the target instance object according to the expected state when the state result indicates that the current state is different from the expected state by: selecting a fifth server cluster among the plurality of second server clusters if the status result indicates that the third server cluster in which the target instance object is located is in a failure state; in the fifth server cluster, an instance object in a third server cluster in a failure state is created again, and the instance object in the third server cluster is deleted, wherein the instance object in the fifth server cluster and the instance object in the third server cluster in the failure state have the same identification.
According to a third aspect of the embodiments of the present disclosure, there is provided a resource processing apparatus including: the monitoring module is used for receiving a resource creating request of a first server cluster, wherein the resource creating request carries resource information of a target resource to be created; a selection module, configured to select at least one second server cluster from the plurality of second server clusters according to the resource information and resource usage statuses of the plurality of second server clusters; the management module is used for generating instance creation information respectively corresponding to the at least one second server cluster according to the resource information; and the creating module is used for creating instances by respectively adopting corresponding instance creating information in the at least one second server cluster, wherein the instances created in the at least one second server cluster form target instances corresponding to the target resources, and the target instances are created by the same resource management module and respectively have unique identifiers.
Optionally, the resource comprises a customized resource CR generated based on the service creation request.
Optionally, the listening module includes: a second monitoring unit, configured to monitor a first resource type of a resource to be processed in the first server cluster; and a second obtaining unit, configured to obtain an update message of a resource in the first server cluster when it is determined that the first resource type is the same as a target resource type currently allowed to be processed and the unique processing permission has been obtained.
Optionally, the apparatus is configured to manage a target instance object according to the update message in the at least one third server cluster by: obtaining the update information from the first server cluster, wherein the update information indicates that the resource updated at least one of: newly building the target instance object, modifying the target instance object, and deleting the target instance object; managing the target instance object in the at least one third server cluster based on the update information.
Optionally, the apparatus is configured to manage the target instance object in the at least one third server cluster based on the update information by at least one of: in the case that the update information indicates that the target instance object needs to be newly created, creating a new target instance object in the at least one third server cluster; modifying the created target instance object in the at least one third server cluster in case the update information indicates that the target instance object needs to be modified; deleting the created target instance object in the at least one third server cluster in case the update information indicates that the target instance object needs to be deleted.
Optionally, the apparatus is configured to adjust the target instance object according to the update message in at least one third server cluster by: monitoring the current state of the target instance object in the third server cluster under the condition that the target instance object is created to obtain a state result; and when the state result shows that the current state is different from the expected state, adjusting the target instance object according to the expected state.
Optionally, the apparatus is configured to adjust the target instance object according to the expected state when the state result indicates that the current state is different from the expected state by: selecting a fourth server cluster from the plurality of second server clusters when the state result indicates that a first instance object in the target instance objects is in an abnormal state, wherein the first instance object is any instance object in the target instance objects; and creating a second instance object in the fourth server cluster, and deleting the first instance object in the third server cluster, wherein the second instance object and the first instance object have the same identifier.
Optionally, the apparatus is configured to adjust the target instance object according to the expected state when the state result indicates that the current state is different from the expected state by: selecting a fifth server cluster among the plurality of second server clusters if the status result indicates that the third server cluster in which the target instance object is located is in a failure state; in the fifth server cluster, an instance object in a third server cluster in a failure state is created again, and the instance object in the third server cluster is deleted, wherein the instance object in the fifth server cluster and the instance object in the third server cluster in the failure state have the same identification.
According to a fourth aspect of the embodiments of the present disclosure, there is provided a resource processing electronic device, including: a processor; a memory for storing the processor-executable instructions; wherein the processor is configured to execute the instructions to implement the resource processing method as described above.
According to still another aspect of the embodiments of the present disclosure, there is also provided a computer-readable storage medium, in which a computer program is stored, wherein the computer program is configured to execute the above resource processing method when running.
The technical scheme provided by the embodiment of the disclosure at least brings the following beneficial effects: monitoring an update message of a resource in a first server cluster, wherein the first server cluster is used for storing the resource, the resource is used for managing a group of example objects according to an expected state, a target resource management module is a resource management module with a unique processing authority in a plurality of resource management modules, when the update message indicates that the resource is changed, at least one third server cluster is selected from the plurality of second server clusters according to the resource use conditions of the plurality of second server clusters, the target example objects are managed in the at least one third server cluster according to the update message through the resource management module with the unique processing authority according to the update message in a mode of managing the target example objects according to the update message, so as to determine the target example objects according to the updated resource, and the target example objects in different third server clusters are enabled to have unique identifiers respectively, furthermore, a resource management module is not required to be respectively deployed for each cluster, and global management is directly realized through the resource management module with the unique processing authority, so that the resource processing efficiency is improved, and the technical problem of low resource processing efficiency in the related technology is solved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the disclosure and are not to be construed as limiting the disclosure.
FIG. 1 is a flow diagram illustrating a resource handling method in accordance with an exemplary embodiment;
FIG. 2 is a flow diagram illustrating another resource handling method in accordance with an illustrative embodiment;
FIG. 3 is a flow diagram illustrating yet another resource handling method in accordance with an illustrative embodiment;
FIG. 4 is a schematic diagram of an application environment illustrating a resource handling method in accordance with an illustrative embodiment;
FIG. 5 is a block diagram illustrating a resource processing apparatus in accordance with an exemplary embodiment;
FIG. 6 is a block diagram illustrating an electronic device in accordance with an example embodiment.
Detailed Description
In order to make the technical solutions of the present disclosure better understood by those of ordinary skill in the art, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings.
It should be noted that the terms "first," "second," and the like in the description and claims of the present disclosure and in the above-described drawings are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the disclosure described herein are capable of operation in sequences other than those illustrated or otherwise described herein. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
First, partial nouns or terms appearing in the description of the embodiments of the present application are applicable to the following explanations:
operator: that is, the resource management module described below is an extension software of kubernets, and may include, but is not limited to, a management application and its components using a customized resource cr (custom resource), and generally manages stateful services. And the system is responsible for the behaviors of creating, updating, deleting and the like of the corresponding customized resource, and finally converts the customized resource into Pod (corresponding to a target instance object described below).
CR: custom resources (Custom resources) are an extension of the kubernets API, and a new Resource type is defined in the kubernets cluster, and each Resource type generally corresponds to an operator.
Stateful services: the name of each instance Pod of services like MySQL cluster (with master-slave state), fragment service (each fragment completes different functions, and all fragments can be combined to realize complete functions) and the like is unique and can not be replaced randomly, and different functions are distinguished through instance names.
The invention is illustrated below with reference to examples:
according to an aspect of the embodiment of the present invention, a resource processing method is provided, and optionally, in the embodiment, the resource processing method may be applied to a hardware environment formed by a server 101 and a terminal device 103 as shown in fig. 1. As shown in fig. 1, a server 101 is connected to a terminal 103 through a network, and may be configured to provide a service to a terminal device or a client installed on the terminal device, where the client may be a video client, an instant messaging client, a browser client, an education client, a game client, or the like. The database 105 may be provided on or separate from the server for providing data storage services for the server 101, such as a game data storage server, and the network may include, but is not limited to: a wired network, a wireless network, wherein the wired network comprises: a local area network, a metropolitan area network, and a wide area network, the wireless network comprising: bluetooth, WIFI, and other networks that enable wireless communication, terminal device 103 may be a client-configured terminal that may include, but is not limited to, at least one of: the server may be a single server, or a server cluster composed of a plurality of servers, or a cloud server, and may include but is not limited to a router or a gateway.
As shown in fig. 1, the resource processing method may be implemented in the user terminal 103 by the following steps:
s1, monitoring an update message of a resource in a first server cluster on a client installed on the terminal device 103, where the first server cluster is used to store the resource, the resource is used to manage a group of instance objects according to an expected state, and a target resource management module is a resource management module with a unique processing right among a plurality of resource management modules;
s2, when the update message indicates that the resource changes, on the client installed on the terminal device 103, selecting at least one third server cluster from the plurality of second server clusters according to the resource usage status of the plurality of second server clusters;
s3, managing target instance objects in at least one third server cluster according to the update message on the client installed on the terminal device 103, where a group of instance objects includes the target instance object, the target instance object is an instance object determined according to the updated resource, and the target instance objects in different third server clusters have unique identifiers, respectively.
Optionally, in this embodiment, the resource processing method may also be implemented by a server, for example, implemented in the server 101 shown in fig. 1; or by both the user terminal and the server.
The above is merely an example, and the present embodiment is not particularly limited.
Optionally, as an optional implementation manner, as shown in fig. 2, the resource processing method includes:
s202, monitoring an update message of a resource in a first server cluster, wherein the first server cluster is used for storing the resource, the resource is used for managing a group of example objects according to an expected state, and a target resource management module is a resource management module with a unique processing authority in a plurality of resource management modules;
s204, when the update message indicates that the resource changes, selecting at least one third server cluster from the plurality of second server clusters according to the resource use conditions of the plurality of second server clusters;
s206, managing target instance objects in at least one third server cluster according to the updating message, wherein one group of instance objects comprises the target instance objects, the target instance objects are determined according to the updated resources, and the target instance objects in different third server clusters respectively have unique identifiers.
Optionally, in this embodiment, the first server cluster may include, but is not limited to, a master cluster in a kubernets cluster, and receives an update message generated by the container platform according to a service request sent by a user, so as to manage the target instance object.
Optionally, in this embodiment, the configuring may include, but is not limited to, configuring any resource management module of the plurality of resource management modules as a unique target resource management module according to a global lock mechanism, so as to be used for managing the target instance object, and the determining may further include, but is not limited to, determining a resource management module associated with the first server cluster as a unique target resource management module, so as to be used for managing the target instance object.
It should be noted that the target resource management module has a unique processing right according to the global lock mechanism.
Optionally, in this embodiment, the resource may include, but is not limited to, an extension to a kubernets API, defined in a kubernets cluster, and is used to manage a target instance object through a target resource management module, where generally each type of resource corresponds to one resource management module.
Taking the customized Resource CR as an example, the CR Resource (Custom Resource), which is an extension to the kubernets API, is not necessarily available in the default kubernets installation. The customized resources may appear or disappear in the cluster during operation by way of dynamic registration, and the cluster administrator may update the customized resources independently of the cluster. Once a custom resource is installed, users can use kubecect to create and access objects therein as they do for built-in resources such as pods.
Of course, the above resources may also include, but are not limited to, resources outside of the kubernets platform, which is merely illustrated by kubernets.
Optionally, in this embodiment, the update message may include, but is not limited to, a message used for indicating a change condition of the resource (e.g., creating an instance object newly, modifying an instance object, deleting an instance object, and the like), and the target instance object is managed by the target resource management module according to the update message.
Optionally, in this embodiment, the resource usage status of the plurality of second server clusters may include, but is not limited to, an available resource situation of all second server clusters in a certain computing platform, for example, kubernets is taken as an example, and the second server clusters may include, but is not limited to, other kubernets besides the first server cluster.
Optionally, in this embodiment, the selecting at least one second server cluster from the plurality of second server clusters may include, but is not limited to, determining an available second server cluster from the second server clusters as the at least one second server cluster according to the resource usage condition, or determining an unavailable second server cluster from the second server clusters according to the resource usage condition, and determining other second server clusters except the unavailable second server cluster as the at least one second server cluster.
Optionally, in this embodiment, the target instance objects are created by a target resource management module, and each object having a unique identifier may include, but is not limited to, configuring the resource management module for the first server cluster, and managing the target instance object by using the target resource management module associated with the first server cluster, where the target instance object may include, but is not limited to, a pod instance.
Optionally, in this embodiment, the application scenario of the resource processing may include, but is not limited to, medical, financial, credit, bank, government, game, energy, education, security, building, traffic, internet of things, industry, and other application scenarios.
Specifically, taking kubernets cluster as an example, in the enterprises in different fields described above, a kubernets platform may be deployed using upstream open source or commercial software distribution or through cloud services. Cloud services provide simplified operation and fast time to market, while software distribution provides better multi-cloud support and manageability. Upstream open sources provide customizability, and the success of containers and kubernets requires various core and ancillary roles, depending on the use cases and maturity of the enterprise. It is important to have the necessary skills in platform engineering, operation and safety engineering.
Fig. 3 is a flowchart illustrating a method for resource processing according to an exemplary embodiment, where, as shown in fig. 3, the resource processing method may include, but is not limited to, the following steps:
s1, when the container cloud platform receives a service creation request of a user, generating a CR configuration, and then sending the creation request to a main Kubernets cluster (corresponding to the first server cluster) to create a CR resource (corresponding to the resource);
s2, the operator (corresponding to the aforementioned target resource management module) monitors the creation of the CR resource object (corresponding to the aforementioned monitoring update message), calculates the available resource status of all kubernets (corresponding to the aforementioned second server cluster), and selects one or more available kubernets (corresponding to the aforementioned third server cluster);
s3, the operator generates Pod (instance) configuration information according to the configuration information of the CR, creates a Pod request to a specific Kubernetes cluster, generates the Pod name according to a uniform rule, and ensures the global uniqueness;
s4, the Kubernetes cluster is responsible for creating Pod instances;
s5, the operator periodically inquires the Pod state and carries out state synchronization;
s6, the operator automatically creates the Pod with the same name for replacement when the Pod has abnormal condition.
According to the embodiment, an update message for monitoring resources in a first server cluster is adopted, wherein the first server cluster is used for storing resources, the resources are used for managing a group of instance objects according to an expected state, a target resource management module is a resource management module with a unique processing authority in a plurality of resource management modules, when the update message indicates that the resources are changed, at least one third server cluster is selected from the plurality of second server clusters according to the resource use conditions of the plurality of second server clusters, the target instance objects are managed in the at least one third server cluster according to the update message through the resource management module with the unique processing authority according to the update message in a manner of managing the target instance objects according to the update message, so as to determine the target instance objects according to the updated resources, and the target instance objects in different third server clusters are enabled to have unique identifiers respectively, furthermore, a resource management module is not required to be respectively deployed for each cluster, and global management is directly realized through the resource management module with the unique processing authority, so that the resource processing efficiency is improved, and the technical problem of low resource processing efficiency in the related technology is solved.
As an alternative, the resources include customized resources CR generated based on the service creation request.
Optionally, in this embodiment, the customized resource cr (custom resource) is an extension to the kubernets API. A custom resource represents a customization to a particular kubernet installation. However, many of the kubernets core functions are now implemented with custom resources, which makes kubernets more modular.
Specifically, the target resource may include, but is not limited to, being configured as a custom resource CR in the following cases:
1) a kubernets client library and CLI are used to create and change new resources.
2) kubecect can directly support your resources; for example, the kubecect get my-object object-name.
3) And constructing a new automation mechanism, monitoring the update event on the object, and executing CRUD operation on other objects or monitoring the update of the former by the latter.
4) An automation component is written to process updates to an object.
5) The Kubernetes API is used for conventions for fields such as.
6) An object is an abstraction of a set of controlled resources, or an inductive abstraction of other resources.
The above is merely an example, and the present embodiment is not limited in any way.
The customized resources can appear or disappear in the running cluster in a dynamic registration mode, and a cluster administrator can update the customized resources independently of the cluster, so that the technical effect of improving the efficiency of managing the customized resources is achieved.
As an optional scheme, the monitoring update messages of resources in the first server cluster includes:
monitoring a first resource type of a resource to be processed in the first server cluster;
and under the condition that the first resource type is determined to be the same as the target resource type which is allowed to be processed currently and the unique processing permission is acquired, acquiring an update message of the resource in the first server cluster.
Optionally, in this embodiment, the monitoring of the first resource type of the resource to be processed in the first server cluster may include, but is not limited to, being implemented by using a kubernets client, for example, a kube operator is a kubernets cluster deployment and multi-cluster management tool, provides a Web UI to support deployment of multiple kubernets clusters in an offline environment, and plans, deploys, and operates the kubernets cluster at a production level on a VMware, an OpenStack, and a physical machine through a Web UI. The system supports an intranet offline environment, supports a GPU and is provided with an internal application store.
Specifically, the first resource type may include, but is not limited to, periodically or according to a configuration parameter, listening for the pending resource, and the first resource type may include, but is not limited to, a customized resource CR and the like.
For example, fig. 4 is a schematic diagram illustrating an application environment of a resource processing method according to an exemplary embodiment, and as shown in fig. 4, the resource processing method may include, but is not limited to, the following steps:
s402, the container cloud platform sends a CR establishment request to a main Kubernets cluster;
s404, selecting an operator with unique processing authority as the operator corresponding to the CR;
s406, calculating the available resource conditions of the plurality of Kubernets, and screening out a proper Kubernets cluster as the second server cluster;
s408, according to the CR configuration information, generating a Pod instance creation request, and creating a Pod instance on the corresponding Kubernetes cluster.
According to the embodiment, a mode of monitoring the first resource type of the resource to be processed in the first server cluster, acquiring the update message of the resource in the first server cluster under the condition that the first resource type is determined to be the same as the current target resource type allowed to be processed and the unique processing permission is acquired is adopted, a resource management module is not required to be respectively deployed for each cluster, global management is directly realized through the resource management module with the unique processing permission, the resource processing efficiency is improved, and the technical problem that the resource processing efficiency is low in the related technology is solved.
As an optional solution, managing, in the at least one third server cluster, a target instance object according to the update message includes:
obtaining the update message from the first server cluster, wherein the update message indicates that the resource updated at least one of: newly building the target instance object, modifying the target instance object, and deleting the target instance object;
managing the target instance object in the at least one third server cluster based on the update message.
Optionally, in this embodiment, the update message may include, but is not limited to, a new target instance object, a modified target instance object, and a deleted target instance object.
Optionally, in this embodiment, the update message of the target resource may include, but is not limited to, an update message for maintaining the instance state to reach the expected state specified by the target resource.
For example, taking the target resource as a CR resource, the resource management device as an operator, and the instance as Pod, the following exemplary description is made:
1) when the CR resource is created, updated and deleted, the update message of the target resource is obtained, and the operator is used for creating, updating and deleting operations related to the update message on the Pod;
2) when the CR resources need to be expanded, acquiring an update message of the target resources, and creating a new Pod through an operator to achieve the expected number of instances carried in the update message; when the CR resource needs capacity reduction, acquiring an update message of a target resource, and deleting the Pod through an operator to achieve the expected number of instances carried in the update message;
3) when the Pending or deleted Pod instance is caused by insufficient resources, the same-name Pod is created in a new Kubernetes cluster through operator resource calculation to replace the original Pod; when a single cluster fails, the operator resource calculation is used for creating a Pod with the same name in the new Kubernets cluster and replacing the Pod instance of the failed cluster.
According to the embodiment, the method for updating the resource comprises the steps of acquiring an update message from a first server cluster, wherein the update message indicates that the resource updates at least one of the following contents: newly building a target instance object, modifying the target instance object and deleting the target instance object; based on the update message, the method for managing the target instance object in the at least one third server cluster can flexibly update the instance object according to the update message, such as new creation, modification, deletion and other management methods, so that global management is realized through the resource management module with the unique processing authority, the efficiency of resource processing is improved, and the technical problem of low efficiency of resource processing in the related art is solved.
As an optional solution, based on the update message, managing the target instance object in the at least one third server cluster includes at least one of:
in the case that the update message indicates that the target instance object needs to be newly created, creating a new target instance object in the at least one third server cluster;
modifying the created target instance object in the at least one third server cluster in case the update message indicates that the target instance object needs to be modified;
deleting the created target instance object in the at least one third server cluster in case the update message indicates that the target instance object needs to be deleted.
Optionally, in this embodiment, taking a newly created target instance object as an example, when the number of instance objects that need to be created in the resource increases, an update message of the newly created target instance object is triggered to be generated, so as to instruct the target resource management module to select a third server cluster in the second server cluster to create the target instance object.
Optionally, in this embodiment, taking modifying the target instance object as an example, in the case of an instance object that needs to be modified in the resource, an update message for generating the modified target instance object is triggered to instruct the target resource management module to modify the target instance object in the third server cluster.
Optionally, in this embodiment, taking deleting the target instance object as an example, in a case that the number of the instance objects that need to be created in the resource is reduced, an update message for deleting the target instance object is triggered to be generated, so as to instruct the target resource management module to delete the target instance object in the third server cluster.
According to the embodiment, under the condition that the update message indicates that the target instance object needs to be newly created, the new target instance object is created in the at least one third server cluster; modifying the created target instance object in the at least one third server cluster in case the update message indicates that the target instance object needs to be modified; under the condition that the update message indicates that the target instance object needs to be deleted, the created target instance object can be deleted in the at least one third server cluster in a flexible way according to the update message, and management modes such as new creation, modification, deletion and the like can be flexibly updated, so that global management is realized through the resource management module with the unique processing authority, the resource processing efficiency is improved, and the technical problem of low resource processing efficiency in the related technology is solved.
As an optional solution, the adjusting, in the at least one third server cluster, the target instance object according to the update message includes:
monitoring the current state of the target instance object in the third server cluster under the condition that the target instance object is created to obtain a state result;
and when the state result shows that the current state is different from the expected state, adjusting the target instance object according to the expected state.
Optionally, in this embodiment, the monitoring the state of the target instance object may include, but is not limited to, being implemented using a kubernets client.
Specifically, the state of the target instance object may be queried periodically or according to an expected state, which may be determined by comparing parameters such as the number of created instance objects, the load condition of the server cluster, the operation efficiency of the instance object with a predetermined threshold, and the state result may be determined by synchronizing the states.
According to the embodiment, the current state of the target instance object in the third server cluster is monitored under the condition that the target instance object is created, the state result is obtained, and the target instance object is adjusted according to the expected state in a mode that the current state and the expected state are different in the state result, so that the target instance object can be flexibly adjusted to the expected state according to the state of the target instance object in the third server cluster, therefore, the global management is realized through the resource management module with the unique processing right, the resource processing efficiency is improved, and the technical problem that the resource processing efficiency is low in the related technology is solved.
As an optional solution, the adjusting the target instance object according to the expected state when the state result indicates that the current state is different from the expected state based on the state result includes:
selecting a fourth server cluster from the plurality of second server clusters when the state result indicates that a first instance object in the target instance objects is in an abnormal state, wherein the first instance object is any instance object in the target instance objects;
and creating a second instance object in the fourth server cluster, and deleting the first instance object in the third server cluster, wherein the second instance object and the first instance object have the same identifier.
Optionally, in this embodiment, the determining that the first instance object is in the abnormal state may include, but is not limited to, determining that the first instance object is in the abnormal state when the first instance object is Pending or deleted due to insufficient resources.
Optionally, in this embodiment, the second server cluster selected from the plurality of second server clusters may actually include, but is not limited to, a server cluster whose resource status indicates availability, for example, a new kubernets cluster.
Optionally, in this embodiment, it may be understood that the second instance object and the first instance object have the same identifier, that is, the second instance object corresponding to the first instance object is created according to the identifier of the first instance object, and the first instance object is deleted, so as to ensure global uniqueness.
According to the embodiment, under the condition that the state result indicates that the first instance object in the target instance object is in an abnormal state, the fourth server cluster is selected from the multiple second server clusters, wherein the first instance object is any instance object in the target instance object, the second instance object is created in the fourth server cluster, and the first instance object in the third server cluster is deleted, and in the manner that the second instance object and the first instance object have the same identifier, the global management can be realized through the resource management module with the unique processing authority, so that the uniqueness of the identifier of the instance object in the global is ensured, the efficiency of resource processing is improved, and the technical problem that the efficiency of resource processing is low in the related technology is solved.
As an optional solution, when the state result indicates that the current state is different from the expected state, adjusting the target instance object according to the expected state includes:
selecting a fifth server cluster among the plurality of second server clusters if the status result indicates that the third server cluster in which the target instance object is located is in a failure state;
in the fifth server cluster, an instance object in a third server cluster in a failure state is created again, and the instance object in the third server cluster is deleted, wherein the instance object in the fifth server cluster and the instance object in the third server cluster in the failure state have the same identification.
Optionally, in this embodiment, the second server cluster being in the failure state may include, but is not limited to, the second server cluster being turned off, the second server cluster being overloaded, and the like, and the second server cluster being in the failure state may be replaced by acquiring a new second server cluster, where in the replacement process, the same instance object as that on the second server cluster in the failure state needs to be created in the new second server cluster, so as to ensure normal operation of the service.
According to the embodiment, under the condition that the state result indicates that the third server cluster in which the target instance object is located is in the fault state, a fifth server cluster is selected from the plurality of second server clusters, in the fifth server cluster, the instance object in the third server cluster in the fault state is created again, and the instance object in the third server cluster is deleted, wherein in the manner that the instance object in the fifth server cluster and the instance object in the third server cluster in the fault state have the same identifier, global management can be realized through the resource management module with the unique processing authority, and the server cluster in the fault state is replaced, so that normal operation of service is ensured, the efficiency of resource processing is improved, and the technical problem that the efficiency of resource processing is low in the related technology is solved.
The present disclosure is further explained below with reference to specific examples:
master Kubernetes cluster: the CR resource object is stored and read and written by the operator;
operator: monitoring the change of CR objects of the main Kubernetes cluster, screening out a proper cluster through a resource calculation module, and creating a Pod instance.
Specifically, the operator can deploy multiple copies to realize high availability; and only one operator is ensured to work at any time through a global locking mechanism. Since all the Pod of the same CR are created by the same operator, the instance name can be guaranteed to be globally unique.
The operator is responsible for part of multi-cluster management functions, and directly sends a Pod creation request to a corresponding Kubernets cluster according to the result of the resource calculation module.
operator maintains the Pod state to the expected state specified by the CR:
1) when the CR resource is subjected to creation, updating and deletion operations, the operator also performs related creation, updating and deletion operations on the Pod;
2) during CR capacity expansion, the operator achieves the expected number of instances by creating a new Pod; during CR capacity reduction, the operator deletes Pod to reach the expected number of instances;
3) when the Pod instance causes Pending or is deleted due to insufficient resources, the operator creates a Pod with the same name in the new Kubernetes cluster through resource calculation to replace the original Pod; when a single cluster fails, through operator resource calculation, a Pod with the same name is created in the new Kubernetes cluster, and the Pod instance of the failed cluster is replaced.
The corresponding service may be created in a manner including, but not limited to:
s1, when the container cloud platform receives a service creation request of a user, generating a CR configuration, and then sending the creation request to the main Kubernets cluster to create a CR resource;
s2, the operator monitors the creation of CR resource object, calculates all the available resource conditions of Kubernets to the resource calculation module, and selects one or more available Kubernets clusters;
s3, the operator generates Pod configuration information according to the configuration information of the CR, a Pod request is created to a specific Kubernets cluster, and the Pod name is generated according to a uniform rule, so that the global uniqueness is ensured;
s4, the bottom Kubernetes cluster is responsible for creating Pod instances;
s5, the operator periodically inquires the Pod state and carries out state synchronization; and when the Pod has an abnormal condition, automatically creating the Pod with the same name for replacement.
By the resource processing method, most codes of the operator are generated, and only specific service logic needs to be realized, the container cloud platform side only needs to interact with a single Kubernets cluster and can be realized without a plurality of cluster management modules, and the operator only needs to be deployed in the main Kubernets and does not need to be deployed in each Kubernets cluster.
In addition, the resource processing method has strong fault self-healing capability in the process of service processing, due to the monitoring mode adopted by the operator, the change of the cluster CR resources and the Pod resources can be sensed in real time, corresponding strategies are adopted according to the change, the fault Pod is replaced by the Pod with the same name, the operation is convenient, and the problem of naming index does not need to be considered.
In an exemplary embodiment, a resource processing system is also presented, comprising:
a first server cluster for storing resources;
the target resource management module is used for monitoring the update message of the resource in the first server cluster, wherein the resource is used for managing a group of example objects according to an expected state, and the target resource management module is a resource management module with unique processing authority in a plurality of resource management modules;
the target resource management module is further configured to select at least one third server cluster from the plurality of second server clusters according to resource usage conditions of the plurality of second server clusters when the update message indicates that the resource changes;
the at least one third server cluster is configured to manage a target instance object according to the update message, where the group of instance objects includes the target instance object, the target instance object is an instance object determined according to the updated resource, and the target instance objects in different third server clusters have unique identifiers, respectively.
As an alternative, the resources include customized resources CR generated based on the service creation request.
As an optional solution, the target resource management module includes:
a first monitoring unit, configured to monitor a first resource type of a resource to be processed in the first server cluster;
and the first obtaining unit is used for obtaining the update message of the resource in the first server cluster under the condition that the first resource type is determined to be the same as the current target resource type allowed to be processed and the unique processing permission is obtained.
As an optional solution, the system is configured to manage the target instance object according to the update message in the at least one third server cluster by:
obtaining the update message from the first server cluster, wherein the update message indicates that the resource updated at least one of: newly building the target instance object, modifying the target instance object, and deleting the target instance object;
managing the target instance object in the at least one third server cluster based on the update message.
As an optional solution, the system is configured to manage the target instance object in the at least one third server cluster based on the update message by at least one of:
in the case that the update message indicates that the target instance object needs to be newly created, creating a new target instance object in the at least one third server cluster;
modifying the created target instance object in the at least one third server cluster in case the update message indicates that the target instance object needs to be modified;
deleting the created target instance object in the at least one third server cluster in case the update message indicates that the target instance object needs to be deleted.
As an optional solution, the system is configured to manage a target instance object according to the update message in the at least one third server cluster by:
monitoring the current state of the target instance object in the third server cluster under the condition that the target instance object is created to obtain a state result;
and when the state result shows that the current state is different from the expected state, adjusting the target instance object according to the expected state.
As an alternative, the system is configured to adjust the target instance object according to the expected state when the state result indicates that the current state is different from the expected state by:
selecting a fourth server cluster from the plurality of second server clusters when the state result indicates that a first instance object in the target instance objects is in an abnormal state, wherein the first instance object is any instance object in the target instance objects;
and creating a second instance object in the fourth server cluster, and deleting the first instance object in the third server cluster, wherein the second instance object and the first instance object have the same identifier.
As an alternative, the system is configured to adjust the target instance object according to the expected state when the state result indicates that the current state is different from the expected state by:
selecting a fifth server cluster among the plurality of second server clusters if the status result indicates that the third server cluster in which the target instance object is located is in a failure state;
in the fifth server cluster, an instance object in a third server cluster in a failure state is created again, and the instance object in the third server cluster is deleted, wherein the instance object in the fifth server cluster and the instance object in the third server cluster in the failure state have the same identification.
FIG. 5 is a block diagram illustrating a resource processing apparatus according to an example embodiment. Referring to fig. 5, the apparatus includes a listening module 502, a selecting module 504, and a managing module 506.
The monitoring module 502 is configured to monitor an update message of a resource in a first server cluster, where the first server cluster is used to store the resource, the resource is used to manage a group of instance objects according to an expected state, and the target resource management module is a resource management module with a unique processing right among a plurality of resource management modules;
the selecting module 504 is configured to select at least one third server cluster from the plurality of second server clusters according to resource usage conditions of the plurality of second server clusters when the update message indicates that the resource changes;
the management module 506 is configured to manage target instance objects in the at least one third server cluster according to the update message, where the group of instance objects includes the target instance object, the target instance object is an instance object determined according to the updated resource, and the target instance objects in different third server clusters have unique identifiers respectively.
As an alternative, the resources include customized resources CR generated based on the service creation request.
As an optional solution, the apparatus is configured to monitor an update message of a resource in a first server cluster by: monitoring a first resource type of a resource to be processed in the first server cluster; and under the condition that the first resource type is determined to be the same as the target resource type which is allowed to be processed currently and the unique processing permission is acquired, acquiring an update message of the resource in the first server cluster.
As an optional solution, the apparatus is configured to manage the target instance object according to the update message in the at least one third server cluster by: obtaining the update information from the first server cluster, wherein the update information indicates that the resource updated at least one of: newly building the target instance object, modifying the target instance object, and deleting the target instance object; managing the target instance object in the at least one third server cluster based on the update information.
As an optional solution, the apparatus is configured to manage the target instance object in the at least one third server cluster based on the update information by at least one of: in the case that the update information indicates that the target instance object needs to be newly created, creating a new target instance object in the at least one third server cluster; modifying the created target instance object in the at least one third server cluster in case the update information indicates that the target instance object needs to be modified; deleting the created target instance object in the at least one third server cluster in case the update information indicates that the target instance object needs to be deleted.
As an optional solution, the apparatus is configured to adjust the target instance object according to the update message in at least one third server cluster by: monitoring the current state of the target instance object in the third server cluster under the condition that the target instance object is created to obtain a state result; and when the state result shows that the current state is different from the expected state, adjusting the target instance object according to the expected state.
As an alternative, the above apparatus is configured to adjust the target instance object according to the expected state when the state result indicates that the current state is different from the expected state, as follows: selecting a fourth server cluster from the plurality of second server clusters when the state result indicates that a first instance object in the target instance objects is in an abnormal state, wherein the first instance object is any instance object in the target instance objects; and creating a second instance object in the fourth server cluster, and deleting the first instance object in the third server cluster, wherein the second instance object and the first instance object have the same identifier.
As an alternative, the above apparatus is configured to adjust the target instance object according to the expected state when the state result indicates that the current state is different from the expected state, as follows: selecting a fifth server cluster among the plurality of second server clusters if the status result indicates that the third server cluster in which the target instance object is located is in a failure state; in the fifth server cluster, an instance object in a third server cluster in a failure state is created again, and the instance object in the third server cluster is deleted, wherein the instance object in the fifth server cluster and the instance object in the third server cluster in the failure state have the same identification.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
With respect to the apparatus of the above embodiments, any of the above steps may be performed by including, but not limited to, using the same or different modules.
FIG. 6 is a block diagram illustrating an electronic device for resource processing in accordance with an exemplary embodiment. As shown in fig. 6, the electronic device includes a processor 620 and a memory 610 for storing processor-executable instructions as described above. The processor is configured to execute instructions to implement the resource handling method described above. The electronic device in this embodiment may further include a transmission device 630, a display 640, and a connection bus 650. The transmission means 630 is used for receiving or transmitting data via a network. Examples of the network may include a wired network and a wireless network. In one example, the transmission device 630 includes a Network adapter (NIC) that can be connected to a router via a Network cable and other Network devices so as to communicate with the internet or a local area Network. In one example, the transmitter 630 is a Radio Frequency (RF) module, which is used to communicate with the internet in a wireless manner. The display 640 is used for displaying the original image and the target image; the connection bus 650 is used to connect the module components of the electronic device.
In an exemplary embodiment, a storage medium comprising instructions, such as the memory 610 comprising instructions, executable by the processor 620 of the electronic device to perform the above-described method is also provided. Alternatively, the storage medium may be a non-transitory computer readable storage medium, which may be, for example, a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
In an exemplary embodiment, there is also provided a computer program product comprising computer programs/instructions which, when executed by a processor, implement the above-described information transmission method.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (10)

1. A resource processing method is applied to a target resource management module and comprises the following steps:
monitoring an update message of a resource in a first server cluster, wherein the first server cluster is used for storing the resource, the resource is used for managing a group of example objects according to an expected state, and the target resource management module is a resource management module with a unique processing authority in a plurality of resource management modules;
when the update message indicates that the resource changes, selecting at least one third server cluster from a plurality of second server clusters according to the resource use conditions of the plurality of second server clusters;
and managing target instance objects in the at least one third server cluster according to the update message, wherein the group of instance objects comprises the target instance objects, the target instance objects are instance objects determined according to the updated resources, and the target instance objects in different third server clusters respectively have unique identifiers.
2. The method of claim 1, wherein the resource comprises a customized resource CR generated based on a service creation request.
3. The method of claim 1, wherein listening for update messages for resources in the first cluster of servers comprises:
monitoring a first resource type of a resource to be processed in the first server cluster;
and under the condition that the first resource type is determined to be the same as the target resource type which is allowed to be processed currently and the unique processing permission is acquired, acquiring an update message of the resource in the first server cluster.
4. The method of claim 1, wherein managing target instance objects in the at least one third server cluster according to the update message comprises:
obtaining the update message from the first server cluster, wherein the update message indicates that the resource updated at least one of: newly building the target instance object, modifying the target instance object, and deleting the target instance object;
managing the target instance object in the at least one third server cluster based on the update message.
5. The method according to claim 1, wherein managing target instance objects in the at least one third server cluster according to the update message comprises:
monitoring the current state of the target instance object in the third server cluster under the condition that the target instance object is created to obtain a state result;
and when the state result shows that the current state is different from the expected state, adjusting the target instance object according to the expected state.
6. A resource processing system, comprising:
a first server cluster for storing resources;
the target resource management module is used for monitoring the update message of the resource in the first server cluster, wherein the resource is used for managing a group of example objects according to an expected state, and the target resource management module is a resource management module with unique processing authority in a plurality of resource management modules;
the target resource management module is further configured to select at least one third server cluster from the plurality of second server clusters according to resource usage conditions of the plurality of second server clusters when the update message indicates that the resource changes;
the at least one third server cluster is configured to manage a target instance object according to the update message, where the group of instance objects includes the target instance object, the target instance object is an instance object determined according to the updated resource, and the target instance objects in different third server clusters have unique identifiers, respectively.
7. A resource processing apparatus, comprising:
the monitoring module is used for monitoring an update message of a resource in a first server cluster, wherein the first server cluster is used for storing the resource, the resource is used for managing a group of example objects according to an expected state, and the target resource management module is a resource management module with a unique processing right in a plurality of resource management modules;
a selection module, configured to select at least one third server cluster from the plurality of second server clusters according to resource usage conditions of the plurality of second server clusters when the update message indicates that the resource changes;
a management module, configured to manage a target instance object in the at least one third server cluster according to the update message, where the group of instance objects includes the target instance object, the target instance object is an instance object determined according to the updated resource, and the target instance objects in different third server clusters have unique identifiers, respectively.
8. An electronic device, comprising:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the resource handling method of any of claims 1 to 5.
9. A computer-readable storage medium, wherein instructions in the computer-readable storage medium, when executed by a processor of an electronic device, enable the electronic device to perform the resource processing method of any of claims 1 to 5.
10. A computer program product comprising a computer program, characterized in that the computer program realizes the resource handling method of any of claims 1 to 5 when executed by a processor.
CN202110991387.1A 2021-08-26 2021-08-26 Resource processing method and device, electronic equipment and storage medium Active CN113778623B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110991387.1A CN113778623B (en) 2021-08-26 2021-08-26 Resource processing method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110991387.1A CN113778623B (en) 2021-08-26 2021-08-26 Resource processing method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113778623A true CN113778623A (en) 2021-12-10
CN113778623B CN113778623B (en) 2024-04-16

Family

ID=78839726

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110991387.1A Active CN113778623B (en) 2021-08-26 2021-08-26 Resource processing method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113778623B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114363175A (en) * 2022-03-01 2022-04-15 北京金山云网络技术有限公司 Cluster monitoring method and device and electronic equipment
CN114884668A (en) * 2022-03-17 2022-08-09 阿里巴巴(中国)有限公司 Resource management method and computer-readable storage medium
CN114936048A (en) * 2022-05-10 2022-08-23 北京达佳互联信息技术有限公司 Configuration management method and device, electronic equipment and storage medium
CN115277652A (en) * 2022-06-29 2022-11-01 北京百度网讯科技有限公司 Inference service-based streaming media processing method and device, and electronic equipment
CN115396290A (en) * 2022-06-29 2022-11-25 北京车网科技发展有限公司 Automatic fault recovery method, device and service system
CN115623008A (en) * 2022-11-14 2023-01-17 杭州谐云科技有限公司 Index construction method and system for Kubernets resource

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111277460A (en) * 2020-01-17 2020-06-12 江苏满运软件科技有限公司 ZooKeeper containerization control method and device, storage medium and electronic equipment
CN111405055A (en) * 2020-03-23 2020-07-10 北京达佳互联信息技术有限公司 Multi-cluster management method, system, server and storage medium
CN112104723A (en) * 2020-09-07 2020-12-18 腾讯科技(深圳)有限公司 Multi-cluster data processing system and method
CN112905306A (en) * 2021-03-29 2021-06-04 建信金融科技有限责任公司 Multi-cluster container management method and device, electronic equipment and storage medium
CN113031874A (en) * 2021-03-26 2021-06-25 网易(杭州)网络有限公司 Cache processing method, device, equipment and storage medium based on Kubernetes cluster

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111277460A (en) * 2020-01-17 2020-06-12 江苏满运软件科技有限公司 ZooKeeper containerization control method and device, storage medium and electronic equipment
CN111405055A (en) * 2020-03-23 2020-07-10 北京达佳互联信息技术有限公司 Multi-cluster management method, system, server and storage medium
CN112104723A (en) * 2020-09-07 2020-12-18 腾讯科技(深圳)有限公司 Multi-cluster data processing system and method
CN113031874A (en) * 2021-03-26 2021-06-25 网易(杭州)网络有限公司 Cache processing method, device, equipment and storage medium based on Kubernetes cluster
CN112905306A (en) * 2021-03-29 2021-06-04 建信金融科技有限责任公司 Multi-cluster container management method and device, electronic equipment and storage medium

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114363175A (en) * 2022-03-01 2022-04-15 北京金山云网络技术有限公司 Cluster monitoring method and device and electronic equipment
CN114884668A (en) * 2022-03-17 2022-08-09 阿里巴巴(中国)有限公司 Resource management method and computer-readable storage medium
CN114936048A (en) * 2022-05-10 2022-08-23 北京达佳互联信息技术有限公司 Configuration management method and device, electronic equipment and storage medium
CN114936048B (en) * 2022-05-10 2024-03-19 北京达佳互联信息技术有限公司 Configuration management method, device, electronic equipment and storage medium
CN115277652A (en) * 2022-06-29 2022-11-01 北京百度网讯科技有限公司 Inference service-based streaming media processing method and device, and electronic equipment
CN115396290A (en) * 2022-06-29 2022-11-25 北京车网科技发展有限公司 Automatic fault recovery method, device and service system
CN115396290B (en) * 2022-06-29 2023-11-17 北京车网科技发展有限公司 Automatic fault recovery method, device and service system
CN115277652B (en) * 2022-06-29 2024-03-22 北京百度网讯科技有限公司 Streaming media processing method and device based on reasoning service and electronic equipment
CN115623008A (en) * 2022-11-14 2023-01-17 杭州谐云科技有限公司 Index construction method and system for Kubernets resource

Also Published As

Publication number Publication date
CN113778623B (en) 2024-04-16

Similar Documents

Publication Publication Date Title
CN113778623A (en) Resource processing method and device, electronic equipment and storage medium
US10887404B2 (en) Method and apparatus for virtualized network function chaining management
US10644952B2 (en) VNF failover method and apparatus
CN107465767B (en) Data synchronization method and system
CN107534570B (en) Computer system, method and medium for virtualized network function monitoring
CN105122936B (en) Service distribution processing method and related device
EP3002930A1 (en) Method, system, terminal and device management server for installing software components
CN107005426B (en) Method and device for managing life cycle of virtual network function
EP2712443A1 (en) Method of and system for managing computing resources
EP2541868A1 (en) Method and device for terminal management based on right control
CN107404509B (en) Distributed service configuration system and information management method
CN108632063B (en) Method, device and system for managing network slice instances
CN110932914B (en) Deployment method, deployment device, hybrid cloud system architecture and computer storage medium
US20090070425A1 (en) Data processing system, method of updating a configuration file and computer program product
CN115086330B (en) Cross-cluster load balancing system
CN113347037B (en) Data center access method and device
CN113742031A (en) Node state information acquisition method and device, electronic equipment and readable storage medium
EP2104274A1 (en) Method, system, dm client and dm server for installing software component
CN112698992B (en) Disaster recovery management method and related device for cloud cluster
CN112583630A (en) Device management method, device, system, device and storage medium
CN111708668B (en) Cluster fault processing method and device and electronic equipment
CN111897643A (en) Thread pool configuration system, method, device and storage medium
CN107071069B (en) Method and device for transparently switching data traffic to user, storage medium and electronic equipment
CN107547622B (en) Resource adjusting method and device
CN105338058A (en) Application updating method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant