Service instance offline method and device and electronic equipment

By using health detection components to set the downline status of the service instance and notifying the load balancing component in the microservice architecture of the container cloud cluster, the problem of poor timeliness of the registration status is solved, and the timeliness of the service instance when it is offline is improved, and traffic loss is avoided.

CN119987994APending Publication Date: 2025-05-13CHINA CITIC BANK CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411801758.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-09
Publication Date
2025-05-13

AI Technical Summary

Technical Problem

In the microservice architecture of container cloud cluster, the consumer's load balancing component determines whether the service instance survives by actively detecting the registration status of the provider's service instance. However, the registration status is poorly timely, resulting in the request being forwarded to the offline service instance, resulting in traffic loss.

Method used

Provide a service instance downlink method, which sets the health status of the target service instance to the downlink state through the health status processing interface of the health detection component, and sends the health status to the load balancing component through the health status acquisition interface, causing the load balancing component to delete the online status list of the service instance.

Benefits of technology

Improves the timeliness of Ribbon components to learn the downline status of service instances, avoids forwarding requests to downline service instances, and reduces traffic loss and requests not being processed.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119987994A_ABST
    Figure CN119987994A_ABST
Patent Text Reader

Abstract

The invention provides a service instance offline method, and relates to the technical field of computers, in particular to the technical field of container cloud and micro service. According to the specific implementation scheme, a health state processing interface of a health detection component corresponding to a target service instance is requested based on a first request instruction; the health detection component is configured to set the health state of the target service instance as an offline state in response to the request of the health state processing interface; in response to a received health state request instruction sent by a consumer, requesting a health state acquisition interface of the health detection component based on the health state request instruction; the health detection component is further configured to respond to the request of the health state acquisition interface, and send the health state of the target service state to the load balancing component; wherein the load balancing component is configured to respond to the fact that the health state of the target service instance is detected to be an offline state, and delete the target service instance in an online instance state list maintained by the load balancing component.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, and in particular to the field of container cloud and microservice technology. Background Art

[0002] At present, the software architecture design has replaced the traditional monolithic architecture with the container cloud cluster (such as Spring Cloud) architecture, which has become the mainstream practice in the industry. In the microservice architecture technology system of the entire container cloud cluster, microservice applications can run in different service instances, and each service instance runs based on a container.

[0003] In the microservice architecture of the container cloud cluster, a microservice service instance integrates the load balancing (Ribbon) component and the registration center client (Eureka Client). The service instance implements client load balancing based on the load balancing component. When the consumer accesses the provider's microservice, the consumer's load balancing component obtains the provider's various online service instances and selects one of the service instances to process the consumer's request, thereby achieving load balancing for the consumer.

[0004] However, the consumer's load balancing component determines whether the service instance is alive by actively detecting the registration status of each service instance of the provider. However, the timeliness of the registration status is very poor. Even if a service instance has been shut down for a long time, the consumer's load balancing component will still forward requests to the service instance, resulting in the request being unable to be processed and causing traffic loss. Summary of the invention

[0005] The present disclosure provides a service instance offline method, device and electronic device for solving at least one of the above technical problems.

[0006] According to one aspect of the present disclosure, a method for offline service instances is provided, wherein the method is applied to a provider, and a target service instance offline is deployed on the provider, and the method includes:

[0007] In response to a first request instruction, requesting a health status processing interface of a health detection component corresponding to the target service instance based on the first request instruction;

[0008] The health detection component is configured to, in response to a request to the health status processing interface of the health detection component, set the health status of the target service instance to an offline state; the first request instruction is generated in response to detecting that the target service instance is offline;

[0009] In response to receiving a health status request instruction sent by a load balancing component of a service instance of a consumer, requesting a health status acquisition interface of a health detection component corresponding to the target service instance based on the health status request instruction;

[0010] Wherein, the health detection component is also configured to, in response to a request for the health status acquisition interface of the health detection component, send the health status of the target service status to the load balancing component; wherein, the load balancing component is configured to, in response to detecting that the health status of the target service instance is an offline state, delete the target service instance from the online instance status list it maintains.

[0011] In some examples, after the method further comprises, in response to receiving the first request instruction and requesting the health status processing interface of the health detection component corresponding to the target service instance based on the first request instruction, the method further comprises:

[0012] In response to a second request instruction, requesting a registration information processing interface of a health detection component corresponding to the target service instance based on the second request instruction;

[0013] Among them, the health detection component is also configured to, in response to the registration information processing interface of the health detection component being requested, generate an offline request instruction and send it to the registration center client corresponding to the target service instance to interact with it; the registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table.

[0014] In some examples, when the registration information processing interface fails, the method further includes:

[0015] Requesting the forced offline interface provided by the registration center server through a third request instruction;

[0016] The registration center server is configured to, in response to a request for the forced offline interface of the registration center server, delete the registration information of the target service instance in the registration information table of the registration center server.

[0017] In some examples, after the second request instruction is received and the registration information processing interface of the health detection component corresponding to the target service instance is requested based on the second request instruction, the method further includes:

[0018] A countdown is performed based on a preset offline countdown duration, and when the countdown ends, the target service instance is closed.

[0019] According to another aspect of the present disclosure, a method for offline service instance is provided, wherein a load balancing component applied to a service instance of a consumer, the method comprising:

[0020] Sending a health status request instruction for a target service instance to a provider, and receiving a health status of the target service instance returned by the provider in response to the health status request instruction;

[0021] In response to detecting that the health status of the target service instance is an offline state, deleting the target service instance from the maintained online instance status list;

[0022] The provider sends the health status of the target service instance according to the above method.

[0023] In some examples, the health status request instruction is sent by polling according to a preset query cycle.

[0024] According to another aspect of the present disclosure, a method for offline service instances is provided, wherein a health detection component applied to the offline target service instance comprises:

[0025] In response to the health status processing interface being requested based on the first request instruction, setting the health status of the target service instance to an offline state;

[0026] In response to the health status acquisition interface being requested based on the health status request instruction, sending the health status of the target service status to the load balancing component of the service instance of the consumer;

[0027] The load balancing component is configured to delete the target service instance from the online instance status list maintained by the load balancing component in response to detecting that the health status of the target service instance is offline;

[0028] Among them, the first request instruction and the health status request instruction are generated based on the above method.

[0029] In some examples, after the health status of the target service instance is set to an offline state in response to the health status processing interface being requested based on the first request instruction, the method further includes:

[0030] In response to the registration information processing interface being requested based on the second request instruction, generating an offline request instruction and sending it to the registration center client corresponding to the target service instance to interact with it;

[0031] The registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table;

[0032] Wherein, the second request instruction is generated based on the above method.

[0033] According to another aspect of the present disclosure, a service instance offline device is provided, wherein the device includes:

[0034] A first request module, configured to respond to a first request instruction and request a health status processing interface of a health detection component corresponding to the target service instance based on the first request instruction;

[0035] The health detection component is configured to, in response to a request to the health status processing interface of the health detection component, set the health status of the target service instance to an offline state; the first request instruction is generated in response to detecting that the target service instance is offline;

[0036] A health request module, configured to respond to a health status request instruction sent by a load balancing component of a service instance of a consumer, and request a health status acquisition interface of a health detection component corresponding to the target service instance based on the health status request instruction;

[0037] Wherein, the health detection component is also configured to, in response to a request for the health status acquisition interface of the health detection component, send the health status of the target service status to the load balancing component; wherein, the load balancing component is configured to, in response to detecting that the health status of the target service instance is an offline state, delete the target service instance from the online instance status list it maintains.

[0038] In some examples, the apparatus further includes:

[0039] A second request module, configured to respond to a second request instruction and request a registration information processing interface of a health detection component corresponding to the target service instance based on the second request instruction;

[0040] Among them, the health detection component is also configured to, in response to the registration information processing interface of the health detection component being requested, generate an offline request instruction and send it to the registration center client corresponding to the target service instance to interact with it; the registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table.

[0041] In some examples, when the registration information processing interface fails, the apparatus further includes:

[0042] A forced offline module, used to request a forced offline interface provided by the registration center server through a third request instruction;

[0043] The registration center server is configured to, in response to a request for the forced offline interface of the registration center server, delete the registration information of the target service instance in the registration information table of the registration center server.

[0044] In some examples, the apparatus further includes:

[0045] The countdown module is used to perform countdown waiting based on a preset offline countdown duration, and close the target service instance when the countdown waiting ends.

[0046] According to another aspect of the present disclosure, a service instance offline device is provided, wherein the device includes:

[0047] A health status request module, used to send a health status request instruction for a target service instance to a provider, and receive the health status of the target service instance returned by the provider in response to the health status request instruction;

[0048] A state maintenance module, configured to delete the target service instance from a maintained online instance state list in response to detecting that the health state of the target service instance is an offline state;

[0049] The provider sends the health status of the target service instance according to the above method.

[0050] In some examples, the health status request instruction is sent by polling according to a preset query cycle.

[0051] According to another aspect of the present disclosure, a service instance offline device is provided, wherein the device includes:

[0052] A state setting module, configured to set the health state of the target service instance to an offline state in response to the health state processing interface being requested based on the first request instruction;

[0053] A status sending module, configured to send the health status of the target service status to a load balancing component of a service instance of a consumer in response to a health status acquisition interface being requested based on a health status request instruction;

[0054] The load balancing component is configured to delete the target service instance from the online instance status list maintained by the load balancing component in response to detecting that the health status of the target service instance is offline;

[0055] Among them, the first request instruction and the health status request instruction are generated based on the above method.

[0056] In some examples, the apparatus further includes:

[0057] A registration information modification module, configured to generate an offline request instruction in response to the registration information processing interface being requested based on the second request instruction, and send the offline request instruction to the registration center client corresponding to the target service instance to interact with the registration center client;

[0058] The registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table;

[0059] Wherein, the second request instruction is generated based on the above method.

[0060] According to another aspect of the present disclosure, there is provided an electronic device, comprising:

[0061] at least one processor; and

[0062] a memory communicatively connected to the at least one processor; wherein,

[0063] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the above method.

[0064] According to another aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to cause the computer to execute the above method.

[0065] According to another aspect of the present disclosure, a computer program product is provided, comprising a computer program, wherein the computer program implements the above method when executed by a processor.

[0066] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0067] The accompanying drawings are used to better understand the present solution and do not constitute a limitation of the present disclosure.

[0068] Figure 1 It is a flowchart of a method for offline service instance provided by the first embodiment of the present disclosure;

[0069] Figure 2 This is a schematic diagram of an exemplary microservice structure;

[0070] Figure 3 It is a flowchart of another service instance offline method provided by the first embodiment of the present disclosure;

[0071] Figure 4 It is a flowchart of a method for offline service instance provided by the second embodiment of the present disclosure;

[0072] Figure 5 is a structural diagram of a service instance offline device provided in the third embodiment of the present disclosure;

[0073] Figure 6 is a structural schematic diagram of a service instance offline device provided in a fourth embodiment of the present disclosure;

[0074] Figure 7 is a structural diagram of a service instance offline device provided in a fifth embodiment of the present disclosure;

[0075] Figure 8 is a structural diagram of a service instance offline device provided by a sixth embodiment of the present disclosure;

[0076] Fig. 9 The block diagram is a block diagram of an electronic device for implementing the method of the embodiment of the present disclosure. DETAILED DESCRIPTION

[0077] The following is a description of exemplary embodiments of the present disclosure in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Similarly, for the sake of clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.

[0078] In the absence of conflict, the various embodiments of the present disclosure and the various features therein may be combined with each other.

[0079] As used herein, the term "and / or" includes any and all combinations of one or more of the associated listed items.

[0080] The terminology used herein is for describing particular embodiments only and is not intended to limit the present disclosure.As used herein, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.

[0081] Unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by those of ordinary skill in the art. It will also be understood that terms such as those defined in commonly used dictionaries should be interpreted as having a meaning consistent with their meaning in the context of the relevant art and the present disclosure, and will not be interpreted as having an idealized or overly formal meaning unless explicitly defined as such herein.

[0082] The service instance offline method according to the present disclosure can be executed by an electronic device such as a terminal device or a server, and the terminal device can be a vehicle-mounted device, a user equipment (User Equipment, UE), a mobile device, a user terminal, a terminal, a cellular phone, a cordless phone, a personal digital assistant (Personal Digital Assistant, PDA), a handheld device, a computing device, a vehicle-mounted device, a wearable device, etc. The method can be implemented by a processor calling a computer-readable program instruction stored in a memory. Alternatively, the service instance offline method provided by the present disclosure can be executed by a server.

[0083] In the first embodiment disclosed, see Figure 1 , Figure 1 A flow chart of a method for offline service instance provided by the first embodiment of the present disclosure is shown. The method is applied to the provider, and the method includes:

[0084] S101 . In response to a first request instruction, request a health status processing interface of a health detection component corresponding to a target service instance based on the first request instruction.

[0085] The health detection component is configured to set the health status of the target service instance to an offline state in response to a request to the health status processing interface of the health detection component; the first request instruction is generated in response to detecting that the target service instance is offline.

[0086] S102: In response to receiving a health status request instruction sent by a load balancing component of a service instance of a consumer, request a health status acquisition interface of a health detection component corresponding to a target service instance based on the health status request instruction.

[0087] The health detection component is also configured to send the health status of the target service to the load balancing component in response to a request for the health status acquisition interface of the health detection component; the load balancing component is configured to delete the target service instance from the online instance status list it maintains in response to detecting that the health status of the target service instance is offline.

[0088] The method provided by the present disclosure can be applied in a scenario of a microservice architecture composed of a container cloud cluster (such as Spring Cloud), see Figure 2 , Figure 2 A structural diagram of a microservice architecture to which the method provided by the present disclosure is applied is shown. The microservice architecture includes multiple microservices. In the figure, two microservices are taken as an example, one of which is called a provider and the other is called a consumer.

[0089] It should be noted that in this disclosure, for the sake of distinction, the service instance of the consumer is called the "service instance", and the service instance of the provider is called the "target service instance". There is no essential difference between the two, except for the different roles in the call relationship. In this disclosure, when a microservice requests a service instance of another microservice, the microservice that initiates the request is called the consumer, and the microservice that is requested is called the provider. The provider and the consumer can exchange roles due to the change of the request direction, and there is no restriction here.

[0090] Each microservice is deployed on the container cloud platform. Specifically, a microservice application can run in multiple service instances. Each service instance runs based on deployment in a container. A container group (pod) contains one or more service instances. The service instances of each microservice (such as the provider and consumer in the figure) are connected to the registration center server (Eureka server). The registration center server is used to realize the registration and dynamic discovery of service instances, so that the service instance call is unbound from the Internet Protocol address. The registration center server provides a registration service for service instances. After each service instance is started, it will register with the registration center server, so that the registration information table in the registration center server will store the registration information of all available service instances.

[0091] Continue to see Figure 2 , a service instance (including the target service instance) includes:

[0092] The health detection component (i.e., health component) provides functions such as health check to monitor and manage the health status of microservice instances. In the present disclosure, the original monitoring component (Spring Boot Actuator) of Spring Cloud is deeply customized and modified into a health component. Specifically, the function of dynamically modifying the health status of service instances is added to the health detection component. Among them, the health detection component adds a health status processing interface ( / health:POST interface) and customizes the health status acquisition interface ( / health:GET interface). When the / health:POST interface is requested, the health detection component will immediately modify the health status of its corresponding service instance (that is, the offline target service instance) to the offline state, thereby realizing the ability to modify the health status of the target service instance in real time when it goes offline; when the / health:GET interface is requested by the consumer's load balancing component, the health status of the service instance corresponding to the health detection component itself is sent to the consumer's load balancing component. When the service instance goes offline, the consumer's load balancing component can be immediately informed, so that the offline service instance is no longer selected as the receiving object of the consumer's request.

[0093] In addition, the health detection component has also added a registration information processing interface ( / unregister:POST interface). When the / unregister:POST interface is requested, the health detection component will request the registration center client of the service instance where the health detection component is located, that is, notify the registration center client that the service instance is offline, so that the registration center client can do corresponding processing.

[0094] The Eureka client is configured to perform two actions after receiving a request from the health check component (generated based on the request of the / unregister:POST interface): the first action is to close the Eureka client, thereby avoiding the interaction between the Eureka client and the Eureka server, and thus avoiding the occurrence of offline service instances on the Eureka server; the second action is to immediately notify the Eureka server of the offline service instance, so that the Eureka server can delete the registration information of the service instance from the registration information table, thereby ensuring that the incrementally started application will not pull the registration information of the offline service instance from the Eureka server.

[0095] A load balancing component (such as a Ribbon component) can be built into the client of the registration center. The microservice implements the load balancing of the client of the registration center based on the load balancing component. Specifically, when the consumer microservice accesses the provider microservice, the consumer's load balancing component selects a service instance from the service instances that are online in the provider to process the access request, thereby realizing client load balancing. In the present disclosure, the Ribbon component is customized to define the HttpPing class. The HttpPing class re-implements the active detection interface (IPing interface). Such a setting can change the strategy of the Ribbon component to determine whether the service instance is alive. Specifically: In the related art, the Ribbon component of the consumer determines the survival status of the service instance by actively detecting the registration information of each service instance of the provider from the service end of the registration center, and the timeliness of the registration information is very poor. In the present disclosure, the Ribbon component of the service instance of the consumer obtains the health status of each service instance of the provider by requesting the / health:GET interface provided by each health detection component of each service instance of the provider. Since the health status is modified in real time, the survival status of the service instance with better timeliness can be obtained. In addition, the modified Ribbon component of the present application periodically requests the / health:GET interface of the health detection component of each service instance according to a preset query cycle, so as to obtain the health status of each service instance. The query cycle in the present disclosure is short, for example, it can be set to 10 seconds. In this way, each service instance is polled, and according to the obtained health status of each service instance, the all instance status list (allServerList) and the online instance status list (upServerList) are maintained, wherein allServerList includes the health status of all service instances; upServerList only includes service instances whose health status is online. The Ribbon component selects the service instance to which the request is to be forwarded from the upServerList, thereby effectively improving the timeliness of the Ribbon component in knowing the survival status of the service instance, and can immediately avoid forwarding the request to the offline service instance for processing.

[0096] Through the above method, in the present disclosure, when the target service instance of the provider is to go offline, the manager of the provider will immediately generate a first request instruction to request the health status processing interface of the health detection component of the target service instance, and the health detection component of the target service instance will immediately modify the health status of the target service instance to the offline state; and the Ribbon component of the service instance of the consumer will periodically request the health status acquisition interface of the health detection component of all service instances of the provider through the health status request instruction to obtain the health status of all service instances, including the health status of the target service instance, so that the Ribbon component can know in real time from the health status of the target service instance that it is offline, and therefore delete the offline target service instance from the upServerList maintained by itself, so that no request will be forwarded to the offline target service instance. In this way, the timeliness of the Ribbon component knowing that the service instance is offline can be improved, thereby avoiding the situation where the request is forwarded to the offline service instance, resulting in traffic loss and the request is not processed.

[0097] For some examples, see Figure 3 , Figure 3 A flow chart of another method for offline service instance provided by the first embodiment of the present disclosure is shown, and the method further includes:

[0098] S101 . In response to a first request instruction, request a health status processing interface of a health detection component corresponding to a target service instance based on the first request instruction.

[0099] The health detection component is configured to set the health status of the target service instance to an offline state in response to a request to the health status processing interface of the health detection component; the first request instruction is generated in response to detecting that the target service instance is offline.

[0100] S102: In response to receiving a health status request instruction sent by a load balancing component of a service instance of a consumer, request a health status acquisition interface of a health detection component corresponding to a target service instance based on the health status request instruction.

[0101] The health detection component is also configured to send the health status of the target service to the load balancing component in response to a request for the health status acquisition interface of the health detection component; the load balancing component is configured to delete the target service instance from the online instance status list it maintains in response to detecting that the health status of the target service instance is offline.

[0102] S103: In response to the second request instruction, request a registration information processing interface of a health detection component corresponding to the target service instance based on the second request instruction.

[0103] The health detection component is further configured to, in response to a request to the registration information processing interface of the health detection component, generate an offline request instruction and send it to the registration center client corresponding to the target service instance to interact with the registration center client.

[0104] The registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table.

[0105] It should be noted that in the present disclosure, the registration center client performs two actions in response to the offline request instruction: the first action is to close the registration center client; the second action is to interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table. The order of executing the first action and the second action can be interchanged, that is, the execution order of the first action and the second action is not limited.

[0106] In related services, after a service instance goes offline, it should be ensured that the registration information of the offline service instance is deleted immediately on the registration center server or its registration status is reset to the offline status. Otherwise, the incrementally started application (microservice) will still pull the registration information of the offline service instance when pulling the registration information of each service instance from the registration center server, thereby forwarding the request to the offline service instance. In related technologies, the registration center client provides two interfaces to implement the service instance offline function, namely the offline interface ( / service-registry / instance-status:POST interface) and the pause interface ( / pause:POST interface). The restart interface needs to rely on the restart annotation (RestartEndpoint annotation). The RestartEndpoint annotation will expose the restart interface ( / restart:POST interface). Accessing the restart interface can restart the application, but this method has security risks, so it is not recommended to enable it. The offline interface can reset the registration status of the service instance to the offline status. Although this can achieve the purpose of taking the service instance offline, if the service instance in the container is only restarted by the container (container) instead of the container group (pod) being pulled up again, the registration status of the service instance will be abnormal.

[0107] In the present application, when the target service instance goes offline, the registration information processing interface of the health detection component of the target service instance will be requested immediately, so that the health detection component will immediately request the registration center client. The registration center client is configured to: after receiving the request of the health detection component (generated based on the registration information processing interface being requested), it will perform two actions: the first action is to close the registration center client. In this way, the interaction between the registration center client and the registration center server can be avoided, thereby avoiding the appearance of offline service instances on the registration center server; the second action is to immediately and proactively notify the registration center server that the target service instance is offline, so that the registration center server can delete the registration information of the service instance from the registration information table. In this way, the registration center server can delete the registration information of the offline service instance in real time, which greatly improves the timeliness compared to related technologies, thereby ensuring that the incrementally started application will not pull the registration information of the offline service instance from the registration center server, and other service instances can be registered normally when the container is restarted. Moreover, this process is completed by the interaction between the health detection component of the provider's target service instance and the registration center client of the target service instance. The registration center client does not need to expose the port to the outside, and the entire process is completed inside the target service instance, so there is no security risk of exposing the port in related technologies.

[0108] In some examples, after S103, when the registration information processing interface fails, the method further includes:

[0109] S104: Request the forced offline interface provided by the registration center server through a third request instruction.

[0110] The registration center server is configured to delete the registration information of the target service instance in the registration information table of the registration center server in response to a request for a forced offline interface of the registration center server.

[0111] In some cases, the registration information processing interface may fail (for example, the service instance appears to be suspended), resulting in the inability to use the registration information processing interface. In this case, you can also request the forced offline interface ( / eureka / apps / {service-id} / {instance-id} interface) provided by the registration center server, where the forced offline interface is requested through a third request instruction, and the third request instruction includes the identifier of the service instance (instance-id). The registration center server will respond to the request for the forced offline interface and perform the action of deleting the registration information of the target service instance based on the identifier. Through the registration information processing interface and the forced offline interface, there can be double protection to ensure that the registration center server deletes the registration information of the offline target service instance.

[0112] For some examples, see Figure 3 , after S103 or S104, the method further includes:

[0113] S105: Countdown waiting is performed based on a preset offline countdown duration, and when the countdown waiting ends, the target service instance is closed.

[0114] Specifically, shutting down the target service instance includes:

[0115] Close the process of the target service instance and recycle the container resources of the container corresponding to the target service instance.

[0116] In order to ensure that the service instance can process all the received requests before being completely shut down, you can set a countdown time for going offline. The specific time can be set as needed, for example, 25 seconds, so that sufficient time can be reserved for the target service instance to process all requests before going offline, avoiding request failure and traffic loss. In addition, sufficient time is reserved to ensure that the consumer's ribbon component deletes the target service instance from the upServerList. After the countdown ends, the container corresponding to the target service instance can be closed to complete resource recycling.

[0117] It should be noted that the execution order of S102 can be exchanged with any step in S103-S105. In other words, S101, S103-S105 are the provider's processes, and S102 is the provider's response after receiving the consumer's request. The execution order depends on the timing of receiving the consumer's request, which is not limited here.

[0118] It should be noted that S101-S105 can be encapsulated as a script with multiple function functions, and the script is deployed in the provider manager. In S101, when it is detected that the target service instance is offline, the provider manager calls the first function function and generates a first request instruction to request the health status processing interface of the health detection component of the target service instance, so that the target service instance executes S101; in S103, after executing S101, the provider manager calls the second function function and generates a second request instruction to request the registration information processing interface, so that the target service instance executes S103; in S104, when the registration information processing interface fails, the provider manager generates a forced offline interface provided by the registration center server through a third request instruction; in S105, after executing S104, the provider manager calls the third function function, and the third function function will countdown and wait according to the preset offline countdown duration, and return when the countdown wait ends, and then close the target service instance.

[0119] In disclosing the second embodiment, see Figure 4 , Figure 4A flow chart of a method for offline service instance provided by the second embodiment of the present disclosure is shown. The method is applied to the load balancing component of the service instance of the consumer, and the method includes:

[0120] S201: Send a health status request instruction for a target service instance to a provider, and receive the health status of the target service instance returned by the provider in response to the health status request instruction.

[0121] S202: In response to detecting that the health status of the target service instance is offline, deleting the target service instance from the maintained online instance status list.

[0122] The provider sends the health status of the target service instance according to the method (S101-S102) of the first embodiment of the present disclosure.

[0123] In some examples, the health status request instruction is sent by polling according to a preset query cycle.

[0124] Specifically, the query period can be set as needed, for example, to 10 seconds.

[0125] When the consumer microservice accesses the provider microservice, the consumer's load balancing component selects a service instance from the online service instances of the provider to process the access request, thereby achieving client load balancing.

[0126] In the related art, the Ribbon component of the consumer determines the survival status of the service instance by actively detecting the registration information of each service instance of the provider from the registration center server, but the timeliness of the registration information is very poor.

[0127] In the present disclosure, the Ribbon component of the consumer's service instance obtains the health status of each service instance of the provider by requesting the / health:GET interface provided by each health detection component of each service instance of the provider. Since the health status is modified in real time, the survival status of the service instance with better timeliness can be obtained.

[0128] In addition, the Ribbon component of the present application periodically requests the / health:GET interface of the health detection component of each service instance according to a preset query cycle, so as to obtain the health status of each service instance. The query cycle in the present disclosure is short. In this way, the Ribbon component actively polls each service instance within a short cycle, and maintains a list of all instance status (allServerList) and an online instance status list (upServerList) based on the health status of each service instance obtained, wherein allServerList includes the health status of all service instances; upServerList only includes service instances whose health status is online. The Ribbon component selects the service instance to which the request is to be forwarded from the upServerList, thereby effectively improving the timeliness of the Ribbon component in knowing the survival status of the service instance, and can immediately avoid forwarding the request to the offline service instance for processing.

[0129] In the present disclosure, when the target service instance is to go offline (i.e., the pod of the target service instance initiates a shutdown action), a request is made through the first interface provided by the health detection component, so that the health detection component sets the health status of the target service instance to the offline state in real time. In the present disclosure, the ribbon component will actively query the health status of each service instance (obtained through the fifth interface provided by the health detection component). When the health status of the target service instance is found to be offline, the target service instance is randomly deleted from the upServerList maintained by itself, so that external requests will no longer be forwarded to the target service instance, avoiding traffic loss caused by failure to process requests. In this way, the health status of the service instance to be offline (target service instance) can be modified in real time, which greatly improves the timeliness of the Ribbon component's response to the status of the offline service instance, and can promptly delete the offline service instance from the candidate service instances, avoiding selecting the offline service instance as the instance for receiving requests during load balancing operations.

[0130] In disclosing the third embodiment, see Figure 5 , Figure 5 A flow chart of a method for offline service instance provided in the third embodiment of the present disclosure is shown. The method is applied to the health detection component of the offline target service instance, and the method includes:

[0131] S301: In response to a health status processing interface being requested based on a first request instruction, setting the health status of a target service instance to an offline status.

[0132] S302: In response to the health status acquisition interface being requested based on the health status request instruction, send the health status of the target service status to the load balancing component of the service instance of the consumer.

[0133] The load balancing component is configured to delete the target service instance from the online instance status list maintained by the load balancing component in response to detecting that the health status of the target service instance is offline.

[0134] Among them, the first request instruction and the health status request instruction are generated based on the method (S101-S102) of the first embodiment of the present disclosure.

[0135] In some examples, after S301, the method further includes:

[0136] S303: In response to the registration information processing interface being requested based on the second request instruction, generate an offline request instruction and send it to the registration center client corresponding to the target service instance to interact with it.

[0137] The registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table.

[0138] The second request instruction is generated based on the method ( S103 ) of the first embodiment of the present disclosure.

[0139] It should be noted that the execution order of S303 can be before S302 or after S302. In other words, S301 and S303 are the provider's processes, and S302 is the provider's response after receiving the consumer's request. The execution order depends on the timing of receiving the consumer's request, which is not limited here.

[0140] The health detection component provides functions such as health checks to monitor and manage the health status of microservice instances. In the present disclosure, a function of dynamically modifying the health status of service instances is added to the health detection component. Among them, the health detection component has added a health status processing interface ( / health:POST interface) and a customized health status acquisition interface ( / health:GET interface). When the / health:POST interface is requested, the health detection component will immediately modify the health status of its corresponding service instance (that is, the offline target service instance) to an offline state, thereby realizing the ability to modify the health status of the target service instance in real time when it goes offline; when the / health:GET interface is requested by the consumer's load balancing component, the health status of the service instance corresponding to the health detection component itself is sent to the consumer's load balancing component. When the service instance goes offline, the consumer's load balancing component can be immediately informed, so that the offline service instance is no longer selected as the receiving object of the consumer's request.

[0141] In addition, the health detection component has also added a registration information processing interface ( / unregister:POST interface). When the / unregister:POST interface is requested, the health detection component will request the registration center client of the service instance where the health detection component is located, that is, notify the registration center client that the service instance is offline, so that the registration center client can do corresponding processing.

[0142] In the third embodiment disclosed, based on Figure 1 The same principle, Figure 6 A service instance offline device 60 provided in a fourth embodiment of the present disclosure is shown, and the device includes:

[0143] The first request module 601 is used to respond to the first request instruction and request the health status processing interface of the health detection component corresponding to the target service instance based on the first request instruction;

[0144] The health detection component is configured to, in response to a request to the health status processing interface of the health detection component, set the health status of the target service instance to an offline state; the first request instruction is generated in response to detecting that the target service instance is offline;

[0145] A health request module 602 is used to respond to a health status request instruction sent by a load balancing component of a service instance of a consumer, and request a health status acquisition interface of a health detection component corresponding to a target service instance based on the health status request instruction;

[0146] The health detection component is also configured to send the health status of the target service to the load balancing component in response to a request for the health status acquisition interface of the health detection component; the load balancing component is configured to delete the target service instance from the online instance status list it maintains in response to detecting that the health status of the target service instance is offline.

[0147] In some examples, the apparatus further includes:

[0148] A second request module, configured to respond to a second request instruction and request a registration information processing interface of a health detection component corresponding to the target service instance based on the second request instruction;

[0149] Among them, the health detection component is also configured to, in response to a request for the registration information processing interface of the health detection component, generate an offline request instruction and send it to the registration center client corresponding to the target service instance to interact with it; the registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table.

[0150] In some examples, when the registration information processing interface fails, the apparatus further includes:

[0151] A forced offline module, used to request a forced offline interface provided by the registration center server through a third request instruction;

[0152] The registration center server is configured to delete the registration information of the target service instance in the registration information table of the registration center server in response to a request for a forced offline interface of the registration center server.

[0153] In some examples, the apparatus further includes:

[0154] The countdown module is used to perform a countdown based on a preset offline countdown duration, and shut down the target service instance when the countdown ends.

[0155] In the fourth embodiment disclosed, based on Figure 4 The same principle, Figure 7 A service instance offline device 70 provided in the fifth embodiment of the present disclosure is shown, and the device includes:

[0156] The health status request module 701 is used to send a health status request instruction for a target service instance to a provider, and receive the health status of the target service instance returned by the provider in response to the health status request instruction;

[0157] A state maintenance module 702 is configured to delete the target service instance from the maintained online instance state list in response to detecting that the health state of the target service instance is an offline state;

[0158] The provider sends the health status of the target service instance according to the above method.

[0159] In some examples, the health status request instruction is sent by polling according to a preset query cycle.

[0160] In some examples, the apparatus further includes:

[0161] In the disclosed fifth embodiment, based on Figure 5 The same principle, Figure 8 A service instance offline device 80 provided in the sixth embodiment of the present disclosure is shown, and the device includes:

[0162] A state setting module 801 is used to set the health state of the target service instance to an offline state in response to the health state processing interface being requested based on the first request instruction;

[0163] A status sending module 802 is used to send the health status of the target service status to the load balancing component of the service instance of the consumer in response to the health status acquisition interface being requested based on the health status request instruction;

[0164] The load balancing component is configured to delete the target service instance from the online instance status list maintained by the load balancing component in response to detecting that the health status of the target service instance is offline;

[0165] Among them, the first request instruction and the health status request instruction are generated based on the above method.

[0166] In some examples, the apparatus further includes:

[0167] A registration information modification module, configured to generate an offline request instruction in response to the registration information processing interface being requested based on the second request instruction, and send the offline request instruction to the registration center client corresponding to the target service instance to interact with the target service instance;

[0168] The registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table;

[0169] The second request instruction is generated based on the above method.

[0170] In the technical solution disclosed herein, the acquisition, storage and application of user personal information involved are in compliance with the provisions of relevant laws and regulations and do not violate public order and good morals.

[0171] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium and a computer program product.

[0172] Fig. 9 A schematic block diagram of an example electronic device 900 that can be used to implement an embodiment of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.

[0173] like Fig. 9As shown, the device 900 includes a computing unit 901, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 902 or a computer program loaded from a storage unit 908 into a random access memory (RAM) 903. In the RAM 903, various programs and data required for the operation of the device 900 can also be stored. The computing unit 901, the ROM 902, and the RAM 903 are connected to each other via a bus 904. An input / output (I / O) interface 905 is also connected to the bus 904.

[0174] A number of components in the device 900 are connected to the I / O interface 905, including: an input unit 906, such as a keyboard, a mouse, etc.; an output unit 907, such as various types of displays, speakers, etc.; a storage unit 908, such as a disk, an optical disk, etc.; and a communication unit 909, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 909 allows the device 900 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.

[0175] The computing unit 901 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 901 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 901 performs the various methods and processes described above, such as the service instance offline method. For example, in some embodiments, the service instance offline method may be implemented as a computer software program, which is tangibly contained in a machine-readable medium, such as a storage unit 908. In some embodiments, part or all of the computer program may be loaded and / or installed on the device 900 via the ROM 902 and / or the communication unit 909. When the computer program is loaded into the RAM 903 and executed by the computing unit 901, one or more steps of the service instance offline method described above may be performed. Alternatively, in other embodiments, the computing unit 901 may be configured as a service instance offline method in any other appropriate manner (e.g., by means of firmware).

[0176] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0177] The program code for implementing the method of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that the program code, when executed by the processor or controller, enables the functions / operations specified in the flow chart and / or block diagram to be implemented. The program code may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.

[0178] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0179] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0180] The systems and techniques described herein may be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system may be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.

[0181] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship of client and server is generated by computer programs running on respective computers and having a client-server relationship with each other. The server may be a cloud server, a server of a distributed system, or a server combined with a blockchain.

[0182] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document does not limit this.

[0183] The above specific implementations do not constitute a limitation on the protection scope of the present disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present disclosure shall be included in the protection scope of the present disclosure.

Claims

1. A method for offline service instance, wherein: Applied to a provider, the offline target service instance is deployed on the provider, and the method includes: In response to a first request instruction, requesting a health status processing interface of a health detection component corresponding to the target service instance based on the first request instruction; The health detection component is configured to, in response to a request to the health status processing interface of the health detection component, set the health status of the target service instance to an offline state; the first request instruction is generated in response to detecting that the target service instance is offline; In response to receiving a health status request instruction sent by a load balancing component of a service instance of a consumer, requesting a health status acquisition interface of a health detection component corresponding to the target service instance based on the health status request instruction; Wherein, the health detection component is also configured to, in response to a request for the health status acquisition interface of the health detection component, send the health status of the target service status to the load balancing component; wherein, the load balancing component is configured to, in response to detecting that the health status of the target service instance is an offline state, delete the target service instance from the online instance status list it maintains.

2. The method according to claim 1, wherein: After the method further comprises, in response to receiving the first request instruction, requesting the health status processing interface of the health detection component corresponding to the target service instance based on the first request instruction: In response to a second request instruction, requesting a registration information processing interface of a health detection component corresponding to the target service instance based on the second request instruction; Among them, the health detection component is also configured to, in response to the registration information processing interface of the health detection component being requested, generate an offline request instruction and send it to the registration center client corresponding to the target service instance to interact with it; the registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table.

3. The method according to claim 2, wherein: In the case where the registration information processing interface fails, the method further includes: Requesting the forced offline interface provided by the registration center server through a third request instruction; The registration center server is configured to, in response to a request for the forced offline interface of the registration center server, delete the registration information of the target service instance in the registration information table of the registration center server.

4. The method according to claim 2 or 3, wherein: After the method, in response to receiving the second request instruction, requests the registration information processing interface of the health detection component corresponding to the target service instance based on the second request instruction, further comprises: A countdown is performed based on a preset offline countdown duration, and when the countdown ends, the target service instance is closed.

5. A method for offline service instance, wherein: A load balancing component applied to a service instance of a consumer, the method comprising: Sending a health status request instruction for a target service instance to a provider, and receiving a health status of the target service instance returned by the provider in response to the health status request instruction; In response to detecting that the health status of the target service instance is an offline state, deleting the target service instance from the maintained online instance status list; The provider sends the health status of the target service instance according to the method described in claim 1.

6. The method according to claim 5, wherein: The health status request instruction is sent by polling according to a preset query cycle.

7. A method for offline service instance, wherein: A health detection component applied to a target service instance that is offline, the method comprising: In response to the health status processing interface being requested based on the first request instruction, setting the health status of the target service instance to an offline state; In response to the health status acquisition interface being requested based on the health status request instruction, sending the health status of the target service status to the load balancing component of the service instance of the consumer; The load balancing component is configured to delete the target service instance from the online instance status list maintained by the load balancing component in response to detecting that the health status of the target service instance is offline; Wherein, the first request instruction and the health status request instruction are generated based on the method described in claim 1.

8. The method according to claim 7, wherein: After the health status of the target service instance is set to an offline state in response to the health status processing interface being requested based on the first request instruction, the method further includes: In response to the registration information processing interface being requested based on the second request instruction, generating an offline request instruction and sending it to the registration center client corresponding to the target service instance to interact with it; The registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table; Wherein, the second request instruction is generated based on the method described in claim 2.

9. A service instance offline device, wherein: The device includes: A first request module, configured to respond to a first request instruction and request a health status processing interface of a health detection component corresponding to a target service instance based on the first request instruction; The health detection component is configured to, in response to a request to the health status processing interface of the health detection component, set the health status of the target service instance to an offline state; the first request instruction is generated in response to detecting that the target service instance is offline; A health request module, configured to respond to a health status request instruction sent by a load balancing component of a service instance of a consumer, and request a health status acquisition interface of a health detection component corresponding to the target service instance based on the health status request instruction; Wherein, the health detection component is also configured to, in response to a request for the health status acquisition interface of the health detection component, send the health status of the target service status to the load balancing component; wherein, the load balancing component is configured to, in response to detecting that the health status of the target service instance is an offline state, delete the target service instance from the online instance status list it maintains.

10. The device according to claim 9, wherein: The device also includes: A second request module, configured to respond to a second request instruction and request a registration information processing interface of a health detection component corresponding to the target service instance based on the second request instruction; Among them, the health detection component is also configured to, in response to the registration information processing interface of the health detection component being requested, generate an offline request instruction and send it to the registration center client corresponding to the target service instance to interact with it; the registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table.

11. The device according to claim 10, wherein: In the case where the registration information processing interface fails, the device further comprises: A forced offline module, used to request a forced offline interface provided by the registration center server through a third request instruction; The registration center server is configured to, in response to a request for the forced offline interface of the registration center server, delete the registration information of the target service instance in the registration information table of the registration center server.

12. The device according to claim 10 or 11, wherein: The device also includes: The countdown module is used to perform countdown waiting based on a preset offline countdown duration, and close the target service instance when the countdown waiting ends.

13. A service instance offline device, wherein: The device includes: A health status request module, used to send a health status request instruction for a target service instance to a provider, and receive the health status of the target service instance returned by the provider in response to the health status request instruction; A state maintenance module, configured to delete the target service instance from a maintained online instance state list in response to detecting that the health state of the target service instance is an offline state; The provider sends the health status of the target service instance according to the method described in claim 1.

14. The device according to claim 13, wherein: The health status request instruction is sent by polling according to a preset query cycle.

15. A service instance offline device, wherein: The device includes: A state setting module, configured to set the health state of the target service instance to an offline state in response to the health state processing interface being requested based on the first request instruction; A status sending module, configured to send the health status of the target service status to a load balancing component of a service instance of a consumer in response to a health status acquisition interface being requested based on a health status request instruction; The load balancing component is configured to delete the target service instance from the online instance status list maintained by the load balancing component in response to detecting that the health status of the target service instance is offline; Wherein, the first request instruction and the health status request instruction are generated based on the method described in claim 1.

16. The device according to claim 15, wherein: The device also includes: A registration information modification module, configured to generate an offline request instruction in response to the registration information processing interface being requested based on the second request instruction, and send the offline request instruction to the registration center client corresponding to the target service instance to interact with the registration center client; The registration center client is configured to, in response to the offline request instruction, close the registration center client and interact with the registration center server so that the registration center server deletes the registration information of the target service instance in the registration information table; Wherein, the second request instruction is generated based on the method described in claim 2.

17. An electronic device comprising: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method described in any one of claims 1-4, and / or can execute the method described in any one of claims 5-6, and / or can execute the method described in any one of claims 7-8.

18. A non-transitory computer-readable storage medium storing computer instructions, wherein: The computer instructions are used to cause the computer to execute the method according to any one of claims 1-4, and / or to execute the method according to any one of claims 5-6, and / or to execute the method according to any one of claims 7-8.

19. A computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the computer program implements the method according to any one of claims 1 to 4, and / or the method according to any one of claims 5 to 6, and / or the method according to any one of claims 7 to 8.