Message processing method based on cloud management platform and cloud management platform
By defining and deploying message processing strategies on the cloud management platform, consumer instances process grayscale messages themselves, solving the problem that grayscale message processing affects routine message processing and improving business efficiency and service quality.
Patent Information
- Application Number
- CN202410094520.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2023-11-01
- Filing Date
- 2024-01-23
- Publication Date
- 2025-05-06
AI Technical Summary
In the cloud service system, the processing process of grayscale messages requires the participation of producer instances, MQ instances and consumer instances, which leads to all three beings perceived this process, affecting the processing of conventional messages and reducing business processing efficiency.
Through the cloud management platform, tenants can define and deploy message processing policies. Consumer instances determine whether the message is a grayscale message and process it according to the policy, avoiding the producer instance and MQ instance aware of the grayscale message processing process.
It reduces the impact of grayscale message processing on conventional message processing, improves business processing efficiency, and improves the service quality provided by the cloud management platform.
Smart Images

Figure CN119945924A_ABST
Abstract
Description
[0001] This application claims the priority of the Chinese patent application filed with the State Intellectual Property Office on November 1, 2023, with application number 202311443256.5 and invention name “A message processing method based on cloud management platform and cloud management platform”, all contents of which are incorporated by reference in this application. Technical Field
[0002] The embodiments of the present application relate to the field of cloud technology, and in particular to a message processing method based on a cloud management platform and a cloud management platform. Background Art
[0003] With the rapid development of cloud technology, cloud vendors can use message queue (MQ) instances as the message transmission medium between producer instances and consumer instances. In this way, the producer instance that provides messages and the consumer instance that consumes messages cannot perceive each other. Both face the MQ instance, which can ensure the information security between the producer instance and the consumer instance.
[0004] In the cloud service system of the related art, since the consumer instance can be converted between the non-grayscale instance and the grayscale instance, a grayscale message queue can be created in the MQ instance, and a grayscale switch can be created in the producer instance and the consumer instance. Then, the producer instance can decide whether to produce grayscale messages through the grayscale switch, and correspondingly, the consumer instance can decide whether to subscribe to the grayscale message queue through the grayscale switch to receive grayscale messages from the producer instance.
[0005] In the above process, the grayscale message processing requires the participation of the producer instance, MQ instance, and consumer instance. This grayscale message processing architecture causes all three to perceive this process. Since these three also need to process regular messages, the grayscale message processing process may affect the regular message processing process, resulting in reduced business processing efficiency. It can be seen that this grayscale message processing architecture requires a certain price. Summary of the invention
[0006] The embodiments of the present application provide a message processing method based on a cloud management platform and a cloud management platform, which can improve business processing efficiency and enhance the service quality that the cloud management platform can provide.
[0007] A first aspect of an embodiment of the present application provides a message processing method based on a cloud management platform. The cloud management platform implementing the method can be used to manage infrastructures that provide cloud services. The infrastructures may include consumer instances and producer instances. The method includes:
[0008] When a tenant needs to configure a message processing strategy for a consumer instance, the cloud management platform can provide a configuration interface to the tenant, so the tenant can send the message processing strategy customized by the tenant for the consumer instance to the configuration interface, so that the cloud management platform receives the tenant's message processing strategy through the configuration interface. Among them, the message processing strategy includes the matching relationship between the grayscale message label defined by the tenant and the grayscale instance label. The matching relationship means that if the message label carried by a message is the label of the grayscale message set by the tenant, it means that the message is a grayscale message, and if the version label carried by a consumer instance is the label of the grayscale instance set by the tenant, it means that the consumer instance is a grayscale instance. In this case, the two are matched.
[0009] After obtaining the message processing strategy from the tenant, the cloud management platform can deploy the message processing strategy in the tenant's consumer instance. At this point, the consumer instance has the function of processing grayscale messages. Then, when a consumer instance of the tenant receives (forwarded through the MQ instance) a message from the producer instance, the consumer instance can parse the message tag carried by the message from the message, obtain the version tag carried by the consumer instance, and then detect whether the message tag of the message is the tag of the grayscale message, and whether the version tag of the consumer instance is the tag of the grayscale instance. If the message tag of the message is the tag of the grayscale message, and the version tag of the consumer instance is the tag of the grayscale instance, it means that the message is a grayscale message and the consumer instance is a grayscale instance, and the two are matched, so the consumer instance can process the message, thereby obtaining the processing result of the message, and return it to the producer instance (forwarded through the MQ instance). At this point, the processing of the message is completed.
[0010] From the above method, it can be seen that: since the tenant defines the grayscale message label, the grayscale instance label and the matching relationship between the two and other new grayscale rules, and deploys them in the tenant's consumer instance, the consumer instance can judge whether a message is a grayscale message based on the grayscale message label, and judge whether it is a grayscale instance based on the grayscale instance label. If the message is a grayscale message and it is a grayscale instance, it means that it matches the message, so the consumer instance can directly process the message, thereby completing the processing of the grayscale message by itself. It can be seen that the new grayscale rule is only deployed in the consumer instance, and the consumer instance completes the processing of the grayscale message based on the grayscale rule alone. The producer instance and the MQ instance will not perceive this processing process. The producer instance and the MQ instance only need to execute according to the processing process of the regular message (the producer instance produces the message, and the MQ instance forwards the message). This can reduce the impact of the grayscale message processing process on the regular message processing process to a certain extent, thereby improving the business processing efficiency and improving the service quality that the cloud management platform can provide.
[0011] In a possible implementation, the message processing strategy is used to instruct the consumer instance to evaluate the message from the producer instance to obtain the evaluation value of the message. If the evaluation value of the message is less than a preset threshold, the consumer instance detects the message. In the above implementation, after the consumer instance receives the message from the producer instance, the consumer instance can first evaluate the message to obtain the evaluation value of the message. Then, the message sender instance can determine whether the evaluation value of the message is greater than or equal to the preset threshold. If the evaluation value of the message is less than the preset threshold, it means that the message has passed the quality of service (QoS) evaluation, so the consumer instance can detect whether the message tag of the message is the tag of the grayscale message, and whether the version tag of the consumer instance is the tag of the grayscale instance. It can be seen that before determining whether to perform grayscale control on the message, the consumer instance can perform QoS evaluation on the message in advance, and further implement subsequent grayscale control on the premise that the QoS evaluation passes. In this way, in the entire processing process of the message, the factors considered are more comprehensive, which is conducive to maintaining the stable operation of the entire cloud service system and further improving the service quality that the entire cloud service system can provide.
[0012] In one possible implementation, the message processing strategy is also used to indicate that if the evaluation value is greater than or equal to a preset threshold, the consumer instance processes the message to obtain the processing result of the message. In the aforementioned implementation, if the evaluation value of the message is greater than or equal to the preset threshold, it means that the message has not passed the QoS evaluation, so the consumer instance does not need to determine whether the message matches the consumer instance, but directly processes the message to obtain the processing result of the message, so as to quickly complete the processing of the message. It can be seen that before determining whether to perform grayscale control on the message, the consumer instance can perform QoS evaluation on the message in advance, and give priority to reliable distribution and processing of the message if the QoS evaluation fails. In this way, in the entire processing process of the message, the factors considered are more comprehensive, which is conducive to maintaining the stable operation of the entire cloud service system and further improving the service quality that the entire cloud service system can provide.
[0013] In one possible implementation, the message processing strategy is also used to indicate that if the message contains a tag of a non-grayscale message and the consumer instance contains a tag of a grayscale instance, the consumer instance does not process the message and returns the message. In the aforementioned implementation, if the message tag of the message is a tag of a non-grayscale message, and the version tag of the consumer instance is a tag of a grayscale instance, it means that the message is a non-grayscale message and the consumer instance is a grayscale instance, so the two are mismatched, and the consumer instance does not process the message and returns the message to the MQ instance, so the MQ instance can re-forward the message to the remaining consumer instances to let the non-grayscale instances in the remaining consumer instances process the message.
[0014] In one possible implementation, the message processing strategy is also used to indicate that if the message contains a label of a non-grayscale message and the consumer instance contains a label of a non-grayscale instance, the consumer instance processes the message to obtain a processing result of the message. In the aforementioned implementation, if the message label of the message is a label of a non-grayscale message, and the version label of the consumer instance is a label of a non-grayscale instance, it means that the message is a non-grayscale message and the consumer instance is a non-grayscale instance, and the two are matched by default, so the consumer instance processes the message to obtain a processing result of the message. Then, the consumer instance can return the processing result of the message to the producer instance that produced the message, and at this point, the processing of the message is completed.
[0015] In a possible implementation, the message processing strategy is also used to indicate that if the message contains a grayscale message tag and the consumer instance contains a non-grayscale instance tag, the consumer instance determines whether the remaining consumer instances contain grayscale instance tags. If the remaining consumer instances contain grayscale instance tags, the consumer instance updates the evaluation value of the message, does not process the message, and returns the message. In the aforementioned implementation, if the message tag of the message is a grayscale message tag, and the version tag of the consumer instance is a non-grayscale instance tag, it means that the message is a grayscale message and the consumer instance is a non-grayscale instance, and the two do not match. Therefore, the consumer instance can determine whether the version tags of the remaining consumer instances are grayscale instance tags. If the version tags of the remaining consumer instances are grayscale instance tags, it means that the message can be handed over to the grayscale instances in the remaining consumer instances for processing. Therefore, the consumer instance can update the evaluation value of the message in real time, does not process the message, and returns the message to the MQ instance. Then, the MQ instance can re-forward the message to the remaining consumer instances to hand over the message to the grayscale instances in the remaining consumer instances for processing.
[0016] In one possible implementation, the message processing strategy is also used to indicate that if the remaining consumer instances do not contain the label of the grayscale instance, the consumer instance processes the message to obtain the processing result of the message. In the aforementioned implementation, if the version labels of the remaining consumer instances are not the labels of the grayscale instance, it means that the message cannot be handed over to the remaining consumer instances for processing, so the consumer instance can directly process the message to obtain the processing result of the message. Then, the consumer instance can return the processing result of the message to the producer instance that produced the message, and the processing of the message is completed.
[0017] In a possible implementation, the evaluation value includes at least one of the following: the number of returns and the message processing delay.
[0018] In one possible implementation, the label of the grayscale message includes at least one of the following: information set by the tenant for a user who uses the producer instance, and information set by the tenant for a microservice or application running on the producer instance.
[0019] In a possible implementation, the label of the grayscale instance is the label of the new version set by the tenant for the consumer instance, and the label of the non-grayscale instance is the label of the old version set by the tenant for the consumer instance.
[0020] In one possible implementation, a consumer instance includes any of the following: a physical server, a bare metal server, a virtual machine, a micro virtual machine, and a container.
[0021] The second aspect of an embodiment of the present application provides a cloud management platform, which is used to manage an infrastructure for providing cloud services, wherein the infrastructure includes consumer instances and producer instances, and the cloud management platform includes: a receiving module, which is used to receive a message processing policy for a consumer instance from a tenant through a configuration interface, wherein the message processing policy includes a matching relationship between a label of a grayscale message and a label of a grayscale instance; a configuration module, which is used to configure a message processing policy in a consumer instance, wherein the message processing policy is used to instruct the consumer instance to detect a message from a producer instance, and if the message includes a label of a grayscale message and the consumer instance includes a label of a grayscale instance, the consumer instance processes the message to obtain a processing result of the message.
[0022] In one possible implementation, the message processing strategy is used to instruct the consumer instance to evaluate the message from the producer instance to obtain an evaluation value of the message. If the evaluation value of the message is less than a preset threshold, the consumer instance detects the message.
[0023] In a possible implementation, the message processing strategy is also used to indicate that if the evaluation value is greater than or equal to a preset threshold, the consumer instance processes the message to obtain a processing result of the message.
[0024] In one possible implementation, the message processing strategy is also used to indicate that if the message contains a tag of a non-grayscale message and the consumer instance contains a tag of a grayscale instance, the consumer instance does not process the message and returns the message.
[0025] In a possible implementation, the message processing strategy is also used to indicate that if the message contains a tag of a non-grayscale message and the consumer instance contains a tag of a non-grayscale instance, the consumer instance processes the message to obtain a processing result of the message.
[0026] In one possible implementation, the message processing strategy is also used to indicate that if the message contains the label of the grayscale message and the consumer instance contains the label of the non-grayscale instance, the consumer instance determines whether the remaining consumer instances contain the label of the grayscale instance. If the remaining consumer instances contain the label of the grayscale instance, the consumer instance updates the evaluation value of the message, does not process the message, and returns the message.
[0027] In a possible implementation, the message processing strategy is also used to indicate that if the remaining consumer instances do not contain the label of the grayscale instance, the consumer instance processes the message to obtain a processing result of the message.
[0028] In a possible implementation, the evaluation value includes at least one of the following: the number of returns and the message processing delay.
[0029] In one possible implementation, the label of the grayscale message includes at least one of the following: information set by the tenant for a user who uses the producer instance, and information set by the tenant for a microservice or application running on the producer instance.
[0030] In a possible implementation, the label of the grayscale instance is the label of the new version set by the tenant for the consumer instance, and the label of the non-grayscale instance is the label of the old version set by the tenant for the consumer instance.
[0031] In one possible implementation, a consumer instance includes any of the following: a physical server, a bare metal server, a virtual machine, a micro virtual machine, and a container.
[0032] A third aspect of an embodiment of the present application provides a computing device cluster, the computing device cluster includes at least one computing device, each computing device includes a processor and a memory: the memory is used to store instructions; the processor is used to enable the computing device cluster to execute the method described in the first aspect or any possible implementation method of the first aspect according to the instructions.
[0033] A fourth aspect of an embodiment of the present application provides a computer storage medium, which stores one or more instructions. When the instructions are executed by one or more computers, the one or more computers implement the method described in the first aspect or any possible implementation method of the first aspect.
[0034] A fifth aspect of the embodiments of the present application provides a computer program product, which stores instructions. When the instructions are executed by a computer, the computer implements the method described in the first aspect or any possible implementation method of the first aspect.
[0035] In an embodiment of the present application, when a tenant needs to configure a message processing strategy for a consumer instance, the tenant can send the tenant's message processing strategy for the consumer instance to the cloud management platform through the configuration interface provided by the cloud management platform. The message processing strategy contains the matching relationship between the label of the grayscale message and the label of the grayscale instance. Then, the cloud management platform can configure the message processing strategy in the tenant's consumer instance so that the consumer instance has the processing function for the grayscale message. Then, after the consumer instance receives the message from the producer instance, the consumer can detect the message. If the message contains the label of the grayscale message and the consumer instance contains the label of the grayscale instance, the consumer instance directly processes the message to obtain the processing result of the message. In the above process, since the tenant defines the grayscale message label, the grayscale instance label and the matching relationship between the two and other new grayscale rules, and deploys them in the tenant's consumer instance, the consumer instance can determine whether a message is a grayscale message based on the grayscale message label, and determine whether it is a grayscale instance based on the grayscale instance label. If the message is a grayscale message and it is a grayscale instance, it means that it matches the message, so the consumer instance can directly process the message, thereby completing the processing of the grayscale message by itself. It can be seen that the new grayscale rule is only deployed in the consumer instance, and the consumer instance completes the processing of the grayscale message based on the grayscale rule alone. The producer instance and the MQ instance will not perceive this processing process. The producer instance and the MQ instance only need to execute according to the processing process of the regular message (the producer instance produces the message, and the MQ instance forwards the message). This can reduce the impact of the grayscale message processing process on the regular message processing process to a certain extent, thereby improving the business processing efficiency and improving the service quality that the cloud management platform can provide. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] Figure 1 A schematic diagram of the structure of a cloud service system provided in an embodiment of the present application;
[0037] Figure 2 A schematic diagram of the structure of the cloud management platform provided in the embodiment of the present application;
[0038] Figure 3 A schematic diagram of a structure of a consumer instance provided in an embodiment of the present application;
[0039] Figure 4 A schematic diagram of a flow chart of a message processing method based on a cloud management platform provided in an embodiment of the present application;
[0040] Figure 5 A schematic diagram of an application example of the message processing method based on the cloud management platform provided in an embodiment of the present application;
[0041] Figure 6 Another schematic diagram of the structure of the cloud management platform provided in the embodiment of the present application;
[0042] Figure 7 A schematic diagram of a structure of a computing device provided in an embodiment of the present application;
[0043] Figure 8 A schematic diagram of the structure of a computing device cluster provided in an embodiment of the present application;
[0044] Fig. 9 A schematic diagram of computer devices in a computer cluster provided in an embodiment of the present application being connected via a network. DETAILED DESCRIPTION
[0045] The embodiments of the present application provide a message processing method based on a cloud management platform and a cloud management platform, which can improve business processing efficiency and enhance the service quality that the cloud management platform can provide.
[0046] The terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and need not be used to describe a specific order or sequential order. It should be understood that the terms used in this way can be interchangeable under appropriate circumstances, which is only to describe the distinction mode adopted by the objects of the same attributes when describing in the embodiments of the present application. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, so that the process, method, system, product or equipment comprising a series of units need not be limited to those units, but may include other units that are not clearly listed or inherent to these processes, methods, products or equipment.
[0047] With the rapid development of cloud technology, cloud vendors can use MQ instances as the message transmission medium between producer instances and consumer instances. In this way, the producer instance that provides the message and the consumer instance that consumes the message cannot perceive each other. Both are facing the MQ instance, which can ensure the information security between the producer instance and the consumer instance.
[0048] In the cloud service system of the related art, since the consumer instance can be updated from a non-grayscale instance to a grayscale instance (the grayscale instance is an instance of a new version, and the non-grayscale instance is an instance of an old version), a grayscale message queue can be created in the MQ instance, and a grayscale switch can be created in the producer instance and the consumer instance. Then, the producer instance can decide whether to produce grayscale messages through the grayscale switch, and correspondingly, the consumer instance can decide whether to subscribe to the grayscale message queue through the grayscale switch to receive grayscale messages from the producer instance (for example, these grayscale messages are usually used to test new version instances, i.e., grayscale instances, to determine whether the version update of the instance is feasible).
[0049] In the above process, the grayscale message processing requires the participation of the producer instance, MQ instance, and consumer instance. This grayscale message processing architecture causes all three to perceive this process. Since these three also need to process regular messages, the grayscale message processing process may affect the regular message processing process, resulting in reduced business processing efficiency. It can be seen that this grayscale message processing architecture requires a certain price.
[0050] Furthermore, the grayscale message processing architecture often relies on the producer instance and consumer instance to determine whether to generate and receive grayscale messages through grayscale switches. The factors considered are relatively one-sided, resulting in a lack of reliability in the processing of grayscale messages, which is not conducive to maintaining the stable operation of the entire cloud service system and the service quality that the entire cloud service system can provide.
[0051] In order to solve the above problems, the embodiment of the present application provides a message processing method based on a cloud management platform, which can be implemented through a cloud service system. Figure 1 A schematic diagram of the structure of the cloud service system provided in the embodiment of the present application is as follows: Figure 1 As shown in the figure, the cloud service system includes: the infrastructure that can provide cloud services and the cloud management platform that manages these infrastructures. The following first introduces the cloud management platform and the infrastructure respectively:
[0052] The cloud management platform can coordinate and manage all cloud instances included in the infrastructure of the entire cloud service system (for example, the cloud management platform can create exclusive cloud instances for tenants, which are used to run the tenants' applications or microservices. For example, messages can be transmitted between the tenants' cloud instances, and the cloud instances that produce messages can be used as producer instances, and the cloud instances that consume messages can be used as consumer instances. Then, the cloud management platform can deploy MQ instances between the producer instances and the consumer instances as a medium for transmitting messages between the two). It can also be open to tenants outside the system and respond to their requests. For example, the cloud management platform can provide various interfaces such as login interfaces and configuration interfaces for access by tenants' clients (for example, terminal devices used by tenants or browsers on terminal devices, etc.). Among them, the cloud management platform can authenticate the tenants' clients through the login interface, and after successful authentication, the tenants' clients can be allowed to log in to the cloud management platform. For another example, the cloud management platform can also send preset templates to the tenant's client through the editing interface, so the tenant's client can display the preset templates for the tenant to watch and use, so that the tenant can formulate elastic scaling policies for its exclusive scaling group on its client, and send the elastic scaling policies to the cloud management platform through the editing interface. For another example, the cloud management platform can also allow the tenant to send the message processing policy formulated by the tenant for its exclusive consumer instance to the cloud management platform through the client through the editing interface (the message processing policy usually includes the matching relationship between the label of the grayscale message and the label of the grayscale instance), and then the cloud management platform can configure the message processing policy in the tenant's consumer instance. Therefore, after the consumer instance receives the message forwarded by the MQ node from the producer instance, the consumer instance can determine whether the message is a grayscale message and whether it is a grayscale instance based on the message processing policy to determine whether it can process the message. This will not be expanded here.
[0053] like Figure 2 As shown ( Figure 2A structural diagram of a cloud management platform provided in an embodiment of the present application) The cloud management platform includes an interface module, a control module and a storage module, wherein the interface module includes the aforementioned login interface and editing interface, etc. The interface module can be used to receive the message processing strategy formulated by the tenant for the consumer instance and the new version of the consumer instance. The control module is used to deploy the new version and the label of the new version to some consumer instances of the tenant. Then, the consumer instance with the new version deployed is the grayscale instance, and the consumer instance without the new version deployed is the non-grayscale instance (whose version is the old version). It is worth noting that the grayscale instance also has the label of the new version, that is, the label of the grayscale instance, and the non-grayscale instance has the label of the old version, that is, the label of the non-grayscale instance. The control module can also be used to deploy the message processing strategy in the sidecar of the consumer instance. The sidecar can determine whether to forward the message from the producer instance forwarded by the MQ instance based on the message processing strategy, and further forward it to the consumer process of the consumer instance for processing. The storage module can be used to store the version labels of each consumer instance (for example, the label of the new version and the label of the old version, etc.) and the message processing strategy for each consumer instance, etc.
[0054] The infrastructure may include multiple cloud instances, which may include producer instances that produce messages, MQ instances that cache and forward messages, and consumer instances that consume messages. It should be noted that the embodiments of this application mainly involve consumer instances, and the following will introduce consumer instances in detail. Figure 3 As shown ( Figure 3 A structural diagram of a consumer instance provided in an embodiment of the present application), the consumer instance may include a sidecar (or agent) and a consumer process, one end of the sidecar of the consumer instance may be connected to the MQ instance for communication, and the other end of the sidecar of the consumer instance is connected to the consumer process of the consumer instance for communication. Then, after the cloud management platform deploys the message processing strategy on the sidecar, it is equivalent to configuring the processing function for the grayscale message for the sidecar. When the sidecar receives a message from the producer instance forwarded by the MQ instance, the sidecar can detect whether the message contains the label of the grayscale message and whether the consumer instance contains the label of the grayscale instance (that is, determine whether the message is a grayscale message and whether it is a grayscale instance), so as to determine whether to forward the message to the consumer for processing based on the detection result.
[0055] It should be noted that the producer instance and the consumer instance can belong to the same tenant (the tenant here can be understood as the developer of the application or microservice) or different tenants. In addition, the messages produced by the producer instance usually come from its users (the users here can be understood as the users of the application or microservice), so the message tag contained in the message usually has user information, which can be used by the sidecar to determine whether the message tag is a grayscale message tag, that is, whether the message is a grayscale message.
[0056] Furthermore, the producer instances, MQ instances and consumer instances can essentially be understood as cloud instances, which can be presented in a variety of ways. For example, these cloud instances can be physical servers designated by the cloud management platform. In another example, these cloud instances can also be virtual machines (VMs) created by the cloud management platform on physical servers through virtualization technology. In another example, these cloud instances can also be containers (docker) created by the cloud management platform on physical servers through virtualization technology. In another example, these cloud instances can also be micro virtual machines (microVM) created by the cloud management platform on physical servers through virtualization technology. In another example, these cloud instances can also be containers (docker) created by the cloud management platform on physical servers through virtualization technology. In another example, these cloud instances can also be bare metal servers designated by the cloud management platform, and so on.
[0057] Furthermore, cloud instances such as producer instances, MQ instances, and consumer instances can be set up at one or more sites. The sites can be presented in various forms. For example, one or more sites can be multiple regions in the infrastructure. For another example, one or more sites can be multiple availability zones in the infrastructure. For another example, one or more sites can be at least one edge site and at least one central cloud site in the infrastructure, and so on.
[0058] Based on the above cloud service system, it can be known that the cloud management platform, under the instruction of the tenant, deploys the message processing strategy in the consumer instance so that the consumer instance has the processing function for grayscale messages. After receiving the message from the producer instance, the consumer instance can judge whether the message is a grayscale message and whether it is a grayscale instance to determine whether it is suitable for processing the message. It can be seen that the processing of grayscale messages does not require the participation of producer instances and MQ instances. This can avoid the impact of grayscale message processing on regular message processing to a certain extent, thereby ensuring business processing efficiency. In order to further understand this process, the following is combined with Figure 4 A further description of this process is given in Figure 4A flowchart of a message processing method based on a cloud management platform provided in an embodiment of the present application) is shown in FIG. Figure 4 As shown, this method can be applied to Figure 1 The cloud service system shown in the figure includes a cloud management platform and infrastructure for providing cloud services, and the infrastructure includes consumer instances and producer instances. The method includes:
[0059] 401. The cloud management platform receives a message processing policy for a consumer instance from a tenant through a configuration interface. The message processing policy includes a matching relationship between a label of a grayscale message and a label of a grayscale instance.
[0060] In this embodiment, when the tenant needs to configure a message processing policy for a consumer instance, the cloud management platform can provide a configuration interface to the tenant's client (for example, a message processing policy input field in the tenant interface, etc.), so the tenant can send the tenant's customized message processing policy for the consumer instance to the configuration interface through the client, so that the cloud management platform receives the message processing policy through the configuration interface. It should be noted that the message processing policy may include a matching relationship between the label of the grayscale message set by the tenant for the consumer instance and the label of the grayscale instance. The matching relationship represents that if the message label carried by a message is the label of the grayscale message set by the tenant, it means that the message is a grayscale message, and if the version label (also called instance label) carried by a consumer instance is the label of the grayscale instance set by the tenant, it means that the consumer instance is a grayscale instance, that is, the message and the consumer instance match, so the message can be handed over to the consumer instance for processing.
[0061] Specifically, the label of the grayscale message can be presented in the following ways:
[0062] Since the messages received by the message sender instance are all from the producer instance, the tenant can set the grayscale message label around the producer instance. The grayscale message label can include one or more of the information set by the tenant for the user using the producer instance and the information set by the tenant for the microservice or application running on the producer instance. Among them, the information set by the tenant for the user using the producer instance can include one or more of the specific level set by the tenant for the user using the producer instance, the specific identity document (ID) set by the tenant for the user of the producer instance, the specific type set by the tenant for the message from the producer instance, the specific ID set by the tenant for the application or microservice running on the producer instance, etc.
[0063] Based on this, if the message tag of a message contains one or more of the above information, the message tag can be regarded as the tag of a grayscale message, that is, the message is a grayscale message. If the message tag of a message does not contain one or more of the above information, but other information, the message tag can be regarded as the tag of a non-grayscale message, that is, the message is a non-grayscale message.
[0064] For example, a tenant can set the label of a grayscale message to a specific level of the user using the producer instance, such as the label of a grayscale message is the user's level v0. Then, after the consumer instance receives the message forwarded by the MQ instance from the producer instance, the consumer instance can parse the message label carried by the message. If the message label indicates that the user's level is v0, the consumer instance can determine that the message label is a label for a grayscale message, that is, the message carries the label of a grayscale message, so it can be determined that the message is a grayscale message. If the message label indicates that the user's level is v1, the consumer instance can determine that the message label is a label for a non-grayscale message, that is, the message carries the label of a non-grayscale message, so it can be determined that the message is a non-grayscale message.
[0065] More specifically, the label of the grayscale instance can be presented in the following way:
[0066] Since tenants can update the version of consumer instances through the cloud management platform, for the new version of consumer instances, tenants can set a new version label in the consumer instances through the cloud management platform and use it as the label of the grayscale instance. For the old version of consumer instances, tenants can also set the old version label in the consumer instances through the cloud management platform and use it as the label of the non-grayscale instance.
[0067] Based on this, if the version tag of a consumer instance is a new version tag, the version tag can be regarded as the tag of the grayscale instance, that is, the consumer instance is a grayscale instance. If the version tag of a consumer instance is a new version tag, the version tag can be regarded as the tag of the grayscale instance, that is, the consumer instance is a grayscale instance.
[0068] For example, a tenant can set the label of a grayscale instance to use the label of version 2 of a consumer instance. Then, after the consumer instance receives the message forwarded by the MQ instance from the producer instance, the consumer instance can obtain its own version label. If the version label is a label of version 2, the consumer instance can determine that the version label is the label of the grayscale instance, that is, it is a grayscale instance. If the version label is a label of version 1, the consumer instance can determine that the version label is the label of a non-grayscale instance, that is, it is a non-grayscale instance.
[0069] 402. The cloud management platform configures a message processing strategy in the consumer instance. The message processing strategy is used to instruct the consumer instance to detect the message from the producer instance. If the message contains a grayscale message label and the consumer instance contains a grayscale instance label, the consumer instance processes the message and obtains a processing result of the message.
[0070] After obtaining the message processing strategy from the tenant, the cloud management platform can deploy the message processing strategy in the tenant's consumer instance. At this point, the consumer instance has the function of processing grayscale messages, so the subsequent operations performed by the consumer instance on the message of the producer instance can be understood as being implemented on the basis of this function. Then, when a consumer instance of the tenant receives a message from the producer instance forwarded by the MQ instance, the consumer instance can parse the message tag carried by the message from the message, obtain the version tag carried by the consumer instance, and then detect whether the message tag of the message is the tag of the grayscale message, and whether the version tag of the consumer instance is the tag of the grayscale instance.
[0071] If the message tag of the message is the tag of the grayscale message, and the version tag of the consumer instance is the tag of the grayscale instance, it means that the message is a grayscale message and the consumer instance is a grayscale instance, so the two are matched, and the consumer instance processes the message to obtain the processing result of the message. Subsequently, the consumer instance can return the processing result of the message to the producer instance that produced the message through the MQ instance, and the processing of the message is completed.
[0072] Specifically, before the consumer instance detects whether the message tag of the message is the tag of the grayscale message and whether the version tag of the consumer instance is the tag of the grayscale instance, the consumer instance may perform the following operations:
[0073] After the consumer instance receives the message forwarded by the MQ instance from the producer instance, the consumer instance can first evaluate the message to obtain the evaluation value of the message. Then, the message sender instance can determine whether the evaluation value of the message is greater than or equal to the preset threshold (the size of the threshold can be set according to actual needs and is not limited here). If the evaluation value of the message is less than the preset threshold, it means that the message has passed the business performance evaluation and is a message in the normal processing flow. Then, the consumer instance can detect whether the message tag of the message is the tag of the grayscale message, and whether the version tag of the consumer instance is the tag of the grayscale instance.
[0074] It should be noted that the evaluation value of the message may include one or more of the number of times the message is returned by (the consumer instance) and the processing delay of the message, etc. For example, if the number of times the message is returned is less than the preset number of times, the consumer instance can detect whether the message tag of the message is the tag of the grayscale message, and whether the version tag of the consumer instance is the tag of the grayscale instance. For another example, if the processing delay of the message is less than the preset delay, the consumer instance can detect whether the message tag of the message is the tag of the grayscale message, and whether the version tag of the consumer instance is the tag of the grayscale instance, etc.
[0075] More specifically, after the consumer instance determines whether the evaluation value of the message is greater than or equal to a preset threshold, the consumer instance may further perform the following operations:
[0076] If the evaluation value of the message is greater than or equal to the preset threshold, it means that the message has not passed the business performance evaluation and is a message in the emergency processing process. In this case, the consumer instance does not need to determine whether the message matches the consumer instance, but directly processes the message to obtain the processing result of the message, so as to quickly complete the processing of the message.
[0077] It should be noted that the evaluation value of the message may include one or more of the number of times the message is returned and the processing delay of the message, etc. For example, if the number of times the message is returned is greater than or equal to the preset number of times, the consumer instance may directly process the message to obtain the processing result of the message. For another example, if the processing delay of the message is greater than or equal to the preset delay, the consumer instance may directly process the message to obtain the processing result of the message, etc.
[0078] More specifically, after the consumer instance detects whether the message tag of the message is the tag of the grayscale message and whether the version tag of the consumer instance is the tag of the grayscale instance, the consumer instance may further perform the following operations:
[0079] If the message tag of the message is the tag of a non-grayscale message, and the version tag of the consumer instance is the tag of a grayscale instance, it means that the message is a non-grayscale message and the consumer instance is a grayscale instance, so the two are mismatched. The consumer instance does not process the message and returns the message to the MQ instance. Therefore, the MQ instance can re-forward the message to the remaining consumer instances so that the remaining consumer instances can perform the same operations as the consumer instance. I will not go into details here.
[0080] More specifically, after the consumer instance detects whether the message tag of the message is the tag of the grayscale message and whether the version tag of the consumer instance is the tag of the grayscale instance, the consumer instance may further perform the following operations:
[0081] If the message tag of the message is a tag of a non-grayscale message, and the version tag of the consumer instance is a tag of a non-grayscale instance, it means that the message is a non-grayscale message and the consumer instance is a non-grayscale instance, so the two are matched by default, and the consumer instance processes the message to obtain the processing result of the message. Subsequently, the consumer instance can return the processing result of the message to the producer instance that produced the message through the MQ instance, and the processing of the message is completed.
[0082] More specifically, after the consumer instance detects whether the message tag of the message is the tag of the grayscale message and whether the version tag of the consumer instance is the tag of the grayscale instance, the consumer instance may further perform the following operations:
[0083] If the message tag of the message is the tag of the grayscale message, and the version tag of the consumer instance is the tag of the non-grayscale instance, it means that the message is a grayscale message and the consumer instance is a non-grayscale instance, so the two are not matched. The consumer instance can determine whether the version tags of the remaining consumer instances are the tags of the grayscale instances (i.e., whether there are grayscale instances in the remaining consumer instances). If the version tags of the remaining consumer instances (any one of the consumer instances) are the tags of the grayscale instances (i.e., there are grayscale instances in the remaining consumer instances), it means that the message can be handed over to the remaining consumer instances for processing. Therefore, the consumer instance can update the evaluation value of the message in real time, and does not process the message, and returns the message to the MQ instance. Then, the MQ instance can re-forward the message to the remaining consumer instances so that the remaining consumer instances perform the same operations as the consumer instance, which will not be repeated here.
[0084] It should be noted that since the evaluation value of the message may include one or more of the number of times the message is returned and the processing delay of the message, when the consumer instance updates the evaluation value of the message, it can be achieved by adding one to the number of times the message is returned and appropriately increasing the processing delay of the message.
[0085] More specifically, after the consumer instance determines whether the version labels of other consumer instances are labels of the grayscale instance, the consumer instance may further perform the following operations:
[0086] If the version labels of other consumer instances are not the labels of the grayscale instance, it means that the message cannot be handed over to other consumer instances for processing, so the consumer instance can directly process the message to obtain the processing result of the message. Subsequently, the consumer instance can return the processing result of the message to the producer instance that produced the message through the MQ instance, and the processing of the message is completed.
[0087] In order to further understand the message processing method based on the cloud management platform provided in the embodiment of the present application, the method is further introduced below in conjunction with a specific application example. Figure 5 A schematic diagram of an application example of the message processing method based on the cloud management platform provided in the embodiment of the present application is shown in FIG. Figure 5 As shown, the application examples include:
[0088] Assume that a sidecar of a consumer instance receives a message forwarded by an MQ instance from a producer instance. The sidecar can perform the following steps:
[0089] (1) Evaluate the message (for example, QoS evaluation, etc.) to obtain an evaluation value of the message. Based on the evaluation value of the message, determine whether the evaluation of the message passes (for example, whether the evaluation value of the message is less than a certain threshold). If not (for example, the evaluation value of the message is less than a certain threshold), execute step (7); if passed, execute step (2).
[0090] (2) The sidecar determines whether the message is a grayscale message. If so, it executes step (3); if not, it executes step (5).
[0091] (3) The sidecar determines whether the consumer instance is a grayscale instance. If so, it executes step (7); if not, it executes step (4).
[0092] (4) The sidecar determines whether there is a grayscale instance among the other consumer instances. If not, it executes step (7); if so, it executes step (6).
[0093] (5) The sidecar determines whether the consumer instance is a non-grayscale instance. If so, it executes step (10); if not, it executes step (6).
[0094] (6) The sidecar updates the evaluation value of the message and returns the message to the MQ instance.
[0095] (7) The sidecar forwards the message to the consumer process of the consumer instance for processing.
[0096] In an embodiment of the present application, when a tenant needs to configure a message processing strategy for a consumer instance, the tenant can send the tenant's message processing strategy for the consumer instance to the cloud management platform through the configuration interface provided by the cloud management platform. The message processing strategy contains the matching relationship between the label of the grayscale message and the label of the grayscale instance. Then, the cloud management platform can configure the message processing strategy in the tenant's consumer instance so that the consumer instance has the processing function for the grayscale message. Then, after the consumer instance receives the message from the producer instance, the consumer can detect the message. If the message contains the label of the grayscale message and the consumer instance contains the label of the grayscale instance, the consumer instance directly processes the message to obtain the processing result of the message. In the above process, since the tenant defines the grayscale message label, the grayscale instance label and the matching relationship between the two and other new grayscale rules, and deploys them in the tenant's consumer instance, the consumer instance can determine whether a message is a grayscale message based on the grayscale message label, and determine whether it is a grayscale instance based on the grayscale instance label. If the message is a grayscale message and it is a grayscale instance, it means that it matches the message, so the consumer instance can directly process the message, thereby completing the processing of the grayscale message by itself. It can be seen that the new grayscale rule is only deployed in the consumer instance, and the consumer instance completes the processing of the grayscale message based on the grayscale rule alone. The producer instance and the MQ instance will not perceive this processing process. The producer instance and the MQ instance only need to execute according to the processing process of the regular message (the producer instance produces the message, and the MQ instance forwards the message). This can reduce the impact of the grayscale message processing process on the regular message processing process to a certain extent, thereby improving the business processing efficiency and improving the service quality that the cloud management platform can provide.
[0097] Furthermore, in the embodiment of the present application, the processing process for grayscale messages can be divided into two stages, the first stage is a comprehensive evaluation of the message, and the second stage is grayscale control of the message. Before the sidecar of the consumer instance determines whether to forward the message to the consumer process of the consumer instance for processing (i.e., grayscale control), the message can be comprehensively evaluated in advance to further implement subsequent grayscale control while ensuring the reliability of message distribution. In this way, in the process of processing grayscale messages, the factors considered are more comprehensive, which is conducive to maintaining the stable operation of the entire cloud service system and further improving the service quality that the entire cloud service system can provide.
[0098] The above is a detailed description of the message processing method based on the cloud management platform provided in the embodiment of the present application. The following is an introduction to the cloud management platform provided in the embodiment of the present application. Figure 6 Another structural diagram of the cloud management platform provided in the embodiment of the present application is as follows: Figure 6As shown in the figure, the cloud management platform is used to manage the infrastructure that provides cloud services. The infrastructure includes consumer instances and producer instances. The cloud management platform includes:
[0099] The receiving module 601 is used to receive a message processing strategy for a consumer instance from a tenant through a configuration interface. The message processing strategy includes a matching relationship between a label of a grayscale message and a label of a grayscale instance. For example, the receiving module 601 is used to implement Figure 4 Step 401 in the illustrated embodiment.
[0100] Configuration module 602 is used to configure a message processing strategy in the consumer instance. The message processing strategy is used to instruct the consumer instance to detect the message from the producer instance. If the message contains a grayscale message tag and the consumer instance contains a grayscale instance tag, the consumer instance processes the message to obtain a message processing result. For example, configuration module 602 is used to implement Figure 4 Step 402 in the illustrated embodiment.
[0101] In one possible implementation, the message processing strategy is used to instruct the consumer instance to evaluate the message from the producer instance to obtain an evaluation value of the message. If the evaluation value of the message is less than a preset threshold, the consumer instance detects the message.
[0102] In a possible implementation, the message processing strategy is also used to indicate that if the evaluation value is greater than or equal to a preset threshold, the consumer instance processes the message to obtain a processing result of the message.
[0103] In one possible implementation, the message processing strategy is also used to indicate that if the message contains a tag of a non-grayscale message and the consumer instance contains a tag of a grayscale instance, the consumer instance does not process the message and returns the message.
[0104] In a possible implementation, the message processing strategy is also used to indicate that if the message contains a tag of a non-grayscale message and the consumer instance contains a tag of a non-grayscale instance, the consumer instance processes the message to obtain a processing result of the message.
[0105] In one possible implementation, the message processing strategy is also used to indicate that if the message contains the label of the grayscale message and the consumer instance contains the label of the non-grayscale instance, the consumer instance determines whether the remaining consumer instances contain the label of the grayscale instance. If the remaining consumer instances contain the label of the grayscale instance, the consumer instance updates the evaluation value of the message, does not process the message, and returns the message.
[0106] In a possible implementation, the message processing strategy is also used to indicate that if the remaining consumer instances do not contain the label of the grayscale instance, the consumer instance processes the message to obtain a processing result of the message.
[0107] In a possible implementation, the evaluation value includes at least one of the following: the number of returns and the message processing delay.
[0108] In one possible implementation, the label of the grayscale message includes at least one of the following: information set by the tenant for a user who uses the producer instance, and information set by the tenant for a microservice or application running on the producer instance.
[0109] In a possible implementation, the label of the grayscale instance is the label of the new version set by the tenant for the consumer instance, and the label of the non-grayscale instance is the label of the old version set by the tenant for the consumer instance.
[0110] In one possible implementation, a consumer instance includes any of the following: a physical server, a bare metal server, a virtual machine, a micro virtual machine, and a container.
[0111] It should be noted that the information interaction, implementation process, etc. between the modules / units of the above-mentioned device are based on the same concept as the method embodiment of the present application, and the technical effects they bring are the same as those of the method embodiment of the present application. For specific contents, please refer to the description in the method embodiment shown above in the embodiment of the present application, and will not be repeated here.
[0112] See also Figure 7 , Figure 7 A schematic diagram of a computing device provided in an embodiment of the present application. Figure 7 As shown, the computing device 700 (which can be used to present the aforementioned cloud management platform) includes: a processor 701, a memory 702, a communication interface 703 and a bus 704. The processor 701, the memory 702 and the communication interface 703 are coupled via a bus (not marked in the figure). The memory 702 stores instructions. When the execution instructions in the memory 702 are executed, the computing device 700 executes the method executed by the cloud management platform in the above method embodiment.
[0113] The computing device 700 may be one or more integrated circuits configured to implement the above method, such as one or more application specific integrated circuits (ASIC), or one or more digital signal processors (DSP), or one or more field programmable gate arrays (FPGA), or a combination of at least two of these integrated circuit forms. For another example, when the unit in the device can be implemented in the form of a processing element scheduler, the processing element can be a general-purpose processor, such as a central processing unit (CPU) or other processor that can call a program. For another example, these units can be integrated together and implemented in the form of a system-on-a-chip (SOC).
[0114] The processor 701 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, transistor logic devices, hardware components or any combination thereof. A general-purpose processor may be a microprocessor or any conventional processor.
[0115] The memory 702 may be a volatile memory or a nonvolatile memory, or may include both volatile and nonvolatile memories. Among them, the nonvolatile memory may be a read-only memory (ROM), a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static RAM (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct rambus RAM (DR RAM).
[0116] The memory 702 stores executable program codes, and the processor 701 executes the executable program codes to respectively implement the functions of the aforementioned receiving module and configuration module, thereby implementing the above-mentioned message processing method based on the cloud management platform. That is, the memory 702 stores instructions for executing the above-mentioned message processing method based on the cloud management platform.
[0117] The communication interface 703 uses a transceiver module such as, but not limited to, a network interface card or a transceiver to implement communication between the computing device 700 and other devices or a communication network.
[0118] In addition to the data bus, the bus 704 may also include a power bus, a control bus, a status signal bus, etc. The bus may be a peripheral component interconnect express (PCIe) bus, or an extended industry standard architecture (EISA) bus, a unified bus (Ubus or UB), a compute express link (CXL), a cache coherent interconnect for accelerators (CCIX), etc. The bus may be divided into an address bus, a data bus, a control bus, etc.
[0119] See also Figure 8 , Figure 8 A schematic diagram of the structure of a computing device cluster provided in an embodiment of the present application. Figure 8 As shown, the computing device cluster 800 includes at least one computing device 700 .
[0120] like Figure 8 As shown, the computing device cluster 800 includes at least one computing device 700. The memory 702 in one or more computing devices 700 in the computing device cluster 800 may store the same instructions for executing the above-mentioned message processing method based on the cloud management platform.
[0121] In some possible implementations, the memory 702 of one or more computing devices 700 in the computing device cluster 800 may also respectively store some instructions for executing the above-mentioned message processing method based on the cloud management platform. In other words, the combination of one or more computing devices 700 can jointly execute the above-mentioned message processing method based on the cloud management platform.
[0122] It should be noted that the memory 702 in different computing devices 700 in the computing device cluster 800 can store different instructions, which are respectively used to execute part of the functions of the above-mentioned cloud management platform. That is, the instructions stored in the memory 702 in different computing devices 700 can implement the functions of one or more modules such as the receiving module and the configuration module.
[0123] In some possible implementations, one or more computing devices 700 in the computing device cluster 800 may be connected via a network, which may be a wide area network or a local area network.
[0124] See also Fig. 9 , Fig. 9A schematic diagram of computer devices in a computer cluster provided in an embodiment of the present application being connected via a network. Fig. 9 As shown, two computing devices 700A and 700B are connected via a network. Specifically, they are connected to the network via a communication interface in each computing device.
[0125] In a possible implementation, the memory in the computing device 700A stores instructions for executing functions of the receiving module and the like. Meanwhile, the memory in the computing device 700B stores instructions for executing functions of the configuration module and the like.
[0126] It should be understood that Fig. 9 The functions of the computing device 700A shown in FIG. 7 may also be completed by multiple computing devices. Similarly, the functions of the computing device 700B may also be completed by multiple computing devices.
[0127] The embodiment of the present application also relates to a computer storage medium, in which a program for signal processing is stored. When the program is run on a computer, the computer executes the following steps: Figure 4 The steps performed by the cloud management platform in the illustrated embodiment.
[0128] The present application also relates to a computer program product, which stores instructions, which, when executed by a computer, enable the computer to execute the following Figure 4 The steps performed by the cloud management platform in the illustrated embodiment.
[0129] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0130] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0131] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0132] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0133] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, read-only memory), random access memory (RAM, random access memory), disk or optical disk and other media that can store program code.
Claims
1. A message processing method based on a cloud management platform, characterized in that: The cloud management platform is used to manage the infrastructure for providing cloud services, the infrastructure including consumer instances and producer instances, and the method includes: The cloud management platform receives a message processing policy for the consumer instance from the tenant through a configuration interface, wherein the message processing policy includes a matching relationship between a label of a grayscale message and a label of a grayscale instance; The cloud management platform configures the message processing strategy in the consumer instance, and the message processing strategy is used to instruct the consumer instance to detect the message from the producer instance. If the message contains the label of the grayscale message and the consumer instance contains the label of the grayscale instance, the consumer instance processes the message to obtain the processing result of the message.
2. The method according to claim 1, characterized in that The message processing strategy is used to instruct the consumer instance to evaluate the message from the producer instance to obtain an evaluation value of the message. If the evaluation value of the message is less than a preset threshold, the consumer instance detects the message.
3. The method according to claim 2, characterized in that The message processing strategy is also used to indicate that if the evaluation value is greater than or equal to the preset threshold, the consumer instance processes the message to obtain a processing result of the message.
4. The method according to any one of claims 1 to 3, characterized in that: The message processing strategy is also used to indicate that if the message contains a tag of a non-grayscale message and the consumer instance contains a tag of the grayscale instance, the consumer instance does not process the message and returns the message.
5. The method according to any one of claims 1 to 4, characterized in that: The message processing strategy is also used to indicate that if the message contains the tag of the non-grayscale message and the consumer instance contains the tag of the non-grayscale instance, the consumer instance processes the message to obtain the processing result of the message.
6. The method according to any one of claims 1 to 5, characterized in that: The message processing strategy is also used to indicate that if the message contains the label of the grayscale message and the consumer instance contains the label of the non-grayscale instance, the consumer instance determines whether the remaining consumer instances contain the label of the grayscale instance. If the remaining consumer instances contain the label of the grayscale instance, the consumer instance updates the evaluation value of the message, does not process the message, and returns the message.
7. The method according to claim 6, characterized in that The message processing strategy is also used to indicate that if the remaining consumer instances do not contain the label of the grayscale instance, the consumer instance processes the message to obtain a processing result of the message.
8. The method according to any one of claims 1 to 7, characterized in that: The evaluation value includes at least one of the following: the number of returns and the processing delay of the message.
9. The method according to any one of claims 1 to 8, characterized in that: The tag of the grayscale message includes at least one of the following: information set by the tenant for a user who uses the producer instance, and information set by the tenant for a microservice or application running on the producer instance.
10. The method according to any one of claims 1 to 9, characterized in that: The label of the grayscale instance is the label of the new version set by the tenant for the consumer instance, and the label of the non-grayscale instance is the label of the old version set by the tenant for the consumer instance.
11. The method according to any one of claims 1 to 10, characterized in that: The consumer instance includes any one of the following: a physical server, a bare metal server, a virtual machine, a micro virtual machine, and a container.
12. A cloud management platform, characterized in that: The cloud management platform is used to manage the infrastructure for providing cloud services, the infrastructure including consumer instances and producer instances, and the cloud management platform includes: A receiving module, configured to receive a message processing strategy for the consumer instance from the tenant through a configuration interface, wherein the message processing strategy includes a matching relationship between a label of a grayscale message and a label of a grayscale instance; A configuration module is used to configure the message processing strategy in the consumer instance, and the message processing strategy is used to instruct the consumer instance to detect the message from the producer instance. If the message contains the label of the grayscale message and the consumer instance contains the label of the grayscale instance, the consumer instance processes the message to obtain the processing result of the message.
13. The cloud management platform according to claim 12, characterized in that: The message processing strategy is used to instruct the consumer instance to evaluate the message from the producer instance to obtain an evaluation value of the message. If the evaluation value of the message is less than a preset threshold, the consumer instance detects the message.
14. The cloud management platform according to claim 13, characterized in that: The message processing strategy is also used to indicate that if the evaluation value is greater than or equal to the preset threshold, the consumer instance processes the message to obtain a processing result of the message.
15. The cloud management platform according to any one of claims 12 to 14, characterized in that: The message processing strategy is also used to indicate that if the message contains a tag of a non-grayscale message and the consumer instance contains a tag of the grayscale instance, the consumer instance does not process the message and returns the message.
16. The cloud management platform according to any one of claims 12 to 15, characterized in that: The message processing strategy is also used to indicate that if the message contains the tag of the non-grayscale message and the consumer instance contains the tag of the non-grayscale instance, the consumer instance processes the message to obtain the processing result of the message.
17. The cloud management platform according to any one of claims 12 to 16, characterized in that: The message processing strategy is also used to indicate that if the message contains the label of the grayscale message and the consumer instance contains the label of the non-grayscale instance, the consumer instance determines whether the remaining consumer instances contain the label of the grayscale instance. If the remaining consumer instances contain the label of the grayscale instance, the consumer instance updates the evaluation value of the message, does not process the message, and returns the message.
18. The cloud management platform according to claim 17, characterized in that: The message processing strategy is also used to indicate that if the remaining consumer instances do not contain the label of the grayscale instance, the consumer instance processes the message to obtain a processing result of the message.
19. The cloud management platform according to any one of claims 12 to 18, characterized in that: The evaluation value includes at least one of the following: the number of returns and the processing delay of the message.
20. The cloud management platform according to any one of claims 12 to 19, characterized in that: The tag of the grayscale message includes at least one of the following: information set by the tenant for a user who uses the producer instance, and information set by the tenant for a microservice or application running on the producer instance.
21. The cloud management platform according to any one of claims 12 to 20, characterized in that: The label of the grayscale instance is the label of the new version set by the tenant for the consumer instance, and the label of the non-grayscale instance is the label of the old version set by the tenant for the consumer instance.
22. The cloud management platform according to any one of claims 12 to 21, characterized in that: The consumer instance includes any one of the following: a physical server, a bare metal server, a virtual machine, a micro virtual machine, and a container.
23. A computing device cluster, characterized in that: The computing device cluster includes at least one computing device, each computing device including a processor and a memory: The memory is used to store instructions; The processor is configured to cause the computing device cluster to execute the method according to any one of claims 1 to 11 according to the instructions.
24. A computer storage medium, characterized in that The computer storage medium stores one or more instructions, which, when executed by one or more computers, enable the one or more computers to implement the method of any one of claims 1 to 11.
25. A computer program product, characterized in that The computer program product stores instructions, which, when executed by a computer, enable the computer to implement the method according to any one of claims 1 to 11.