Flow switching method and device based on available area, equipment, medium and product
By using load balancers and switching tools on the private cloud platform, fast traffic switching in case of failures within the Availability Zone is achieved, solving the problem that private cloud services cannot respond quickly, and improving business processing efficiency and high availability.
Patent Information
- Application Number
- CN202510291086.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-12
- Publication Date
- 2025-07-01
AI Technical Summary
Private cloud services cannot quickly switch traffic when they fail within the Availability Zone, resulting in inefficient business processing.
By receiving service processing requests, using a load balancer to select the Availability Zone collection, select the first Availability Zone to respond to the request, and conduct real-time detection of the microservices in the Availability Zone. When a fault is detected, use the switching tool to switch traffic to ensure business continuity.
It realizes rapid switching of traffic when a failure occurs, improving the high availability and service processing efficiency of private cloud services.
Smart Images

Figure CN120238489A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the technical field of private cloud service architectures, and in particular, to a traffic switching method, apparatus, device, medium, and product based on availability zones. Background Art
[0002] The switching technology adopted by the traditional mainframe architectures in the financial industry (usually using IBM's z series or I series operating systems) is usually completed through primary-backup switching between different availability zones (AZs). With the widespread completion of core cloud migration in the domestic financial industry, the architecture of the core system has become more complex, bringing more difficulties to rapid service switching. Currently, the core system architectures in the domestic financial industry generally adopt distributed microservice architectures and integrate multiple different technology stacks such as OpenStack, VMware, Kubernetes, etc. The high-availability service capabilities are mainly achieved by deploying service instances in different availability zones (AZs), and a global load balancing device is built at the traffic entrance for management.
[0003] However, in the actual use of the current cloud-based switching technology, since private clouds often integrate multiple technology stacks, it is difficult to achieve a unified switching effect among multiple technology stacks. In addition, private clouds generally adopt complex architectures, making it difficult to achieve rapid AZ switching. Furthermore, due to distributed computing and complex business links in private clouds, it is difficult to achieve precise traffic switching.
[0004] The above content is only used to assist in understanding the technical solution of this application, and does not represent an admission that the above content is prior art. Summary of the Invention
[0005] The main objective of this application is to provide a traffic switching method, apparatus, device, medium, and product based on availability zones, aiming to solve the technical problem that traffic cannot be quickly switched when a failure occurs within the availability zone of a private cloud service.
[0006] To achieve the above objective, this application proposes a traffic switching method based on availability zones. The method is applied to a private cloud platform and includes:
[0007] Receiving a service processing request;
[0008] According to the service processing request, selecting a first availability zone from an availability zone set through a load balancer, and responding to the service processing request through the first availability zone;
[0009] Detecting the overall response situation of the availability zone set to obtain a detection result;
[0010] In the case where the detection result is a fault message, perform traffic switching through a switching tool to obtain a traffic switching result.
[0011] In one embodiment, before the step of selecting a first available zone from the set of available zones through a load balancer according to the service processing request and responding to the service processing request through the first available zone, the method further includes:
[0012] Receive a service registration request from a service platform;
[0013] Perform microservice deployment and available zone deployment according to the service registration request to obtain a microservice application instance;
[0014] Register the microservice application instance in a microservice registry to obtain a microservice registration result.
[0015] In one embodiment, the step of selecting a first available zone from the set of available zones through a load balancer according to the service processing request and responding to the service processing request through the first available zone includes:
[0016] Parse the service processing request to obtain a request source address;
[0017] According to the request source address, perform health detection on the set of available zones through the microservice registry to obtain latency information and load information of several available zones in the set of available zones;
[0018] According to the latency information and load information, select a first available zone from the set of available zones through the load balancer and route the service processing request to the first available zone;
[0019] Respond to the service processing request through the first available zone.
[0020] In one embodiment, the step of detecting the overall response situation of the set of available zones to obtain a detection result includes:
[0021] Perform service traffic monitoring according to the service processing request to obtain service response metrics;
[0022] Query the logs of the services in the first available zone to obtain application service logs, where the application service logs include database health status and application instance information;
[0023] Perform fault detection on the service response metrics, database health status, and application instance information to obtain a detection result.
[0024] In one embodiment, the switching tool includes a control layer and a resource layer. The step of performing traffic switching through the switching tool to obtain a traffic switching result when the detection result is a fault message includes:
[0025] Analyze the service fault message through the resource layer to obtain the north-south traffic and east-west traffic of the microservice;
[0026] According to the north-south traffic, perform resource scheduling analysis on the set of available zones through a load balancer to obtain a scheduling analysis result;
[0027] Based on the scheduling analysis result, switch the north-south traffic to the second available zone through the control layer to obtain a north-south traffic switching result;
[0028] According to the east-west traffic, query through the microservice registry to obtain microservice call information;
[0029] Based on the microservice call information, switch the east-west traffic to the third available zone through the control layer to obtain an east-west traffic switching result;
[0030] Summarize the east-west traffic switching result and the north-south traffic switching result to obtain a traffic switching result.
[0031] In one embodiment, after the step of performing traffic switching through the switching tool to obtain a traffic switching result when the detection result is a fault message, the method further includes:
[0032] Parse the fault message to obtain a fault log, fault data, and fault metrics;
[0033] Perform aggregation analysis through the fault log, fault data, and fault metrics to obtain the root cause of the fault;
[0034] Based on the root cause of the fault, optimize the configuration of the microservice in the first available zone to obtain an optimization result;
[0035] According to the optimization result, perform a functional test on the first available zone through an automated test tool to obtain a test result;
[0036] If the test result is a pass, restore the usage permission of the first available zone through the microservice registry;
[0037] If the test result is a fail, generate a fault handling document based on the root cause of the fault, the optimization result, and the test result.
[0038] In addition, to achieve the above object, the present application also proposes a traffic switching device based on availability zones. The traffic switching device based on availability zones is applied to a private cloud platform, and the device includes:
[0039] A receiving module, configured to receive a service processing request;
[0040] A response module, configured to select a first availability zone from the set of availability zones through a load balancer according to the service processing request, and respond to the service processing request through the first availability zone;
[0041] A detection module, configured to detect the overall response situation of the set of availability zones to obtain a detection result;
[0042] A switching module, configured to perform traffic switching through a switching tool when the detection result indicates a fault message, to obtain a traffic switching result.
[0043] In addition, to achieve the above object, the present application also proposes a traffic switching device based on availability zones. The device includes: a memory, a processor, and a computer program stored on the memory and executable on the processor. The computer program is configured to implement the steps of the traffic switching method based on availability zones as described above.
[0044] In addition, to achieve the above object, the present application also proposes a storage medium. The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, it implements the steps of the traffic switching method based on availability zones as described above.
[0045] In addition, to achieve the above object, the present application also provides a computer program product. The computer program product includes a computer program. When the computer program is executed by a processor, it implements the steps of the traffic switching method based on availability zones as described above.
[0046] One or more technical solutions proposed by the present application have at least the following technical effects:
[0047] A method, device, equipment, medium and product for traffic switching based on availability zones proposed in an embodiment of the present application receive a service processing request; according to the service processing request, select a first availability zone from an availability zone set through a load balancer, and respond to the service processing request through the first availability zone; detect the overall response situation of the availability zone set to obtain a detection result; in the case where the detection result is a fault message, perform traffic switching through a switching tool to obtain a traffic switching result. Thus, after receiving a service processing request, select an availability zone set through a load balancer, use the selected first availability zone to respond to the service processing request, and perform real-time detection on the microservices in the first availability zone during the processing. In the case where a fault message within the availability zone range is detected, perform traffic switching through a switching tool to obtain a traffic switching result, solving the problem that traffic cannot be quickly switched when a private cloud service fails and improving the efficiency of traffic switching. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] The accompanying drawings herein are incorporated into the specification and constitute a part of this specification, showing embodiments consistent with the present application and used together with the specification to explain the principles of the present application.
[0049] To more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following briefly introduces the accompanying drawings required for use in the description of the embodiments or the prior art. Obviously, for those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0050] Figure 1 It is a schematic flowchart provided for Embodiment 1 of the method for traffic switching based on availability zones of the present application;
[0051] Figure 2 It is a schematic diagram of the overall architecture related to the method for traffic switching based on availability zones of the present application;
[0052] Figure 3 It is a schematic flowchart provided for Embodiment 2 of the method for traffic switching based on availability zones of the present application;
[0053] Figure 4 It is a schematic diagram of traffic switching through a switching tool related to the method for traffic switching based on availability zones of the present application;
[0054] Figure 5 It is a schematic diagram of traffic switching for north-south traffic and east-west traffic related to the method for traffic switching based on availability zones of the present application;
[0055] Figure 6 It is a schematic flowchart of the method for traffic switching based on availability zones provided for Embodiment 2 of the present application;
[0056] Figure 7 This is a schematic diagram of the module structure of the traffic switching device based on availability zones according to an embodiment of the present application;
[0057] Figure 8 This is a schematic diagram of the device structure of the hardware operating environment involved in the traffic switching method based on availability zones according to an embodiment of the present application.
[0058] The implementation, functional features and advantages of the present application will be further described with reference to the accompanying drawings in combination with embodiments. Detailed implementation manners
[0059] It should be understood that the specific embodiments described herein are only used to explain the technical solutions of the present application and are not used to limit the present application.
[0060] For a better understanding of the technical solutions of the present application, the following will be described in detail in combination with the accompanying drawings of the specification and specific implementation manners.
[0061] The main solution of the embodiment of this application is as follows: Receive a service registration request from a service platform; perform microservice deployment and availability zone deployment according to the service registration request to obtain microservice application instances; register the microservice application instances into a microservice registry to obtain a microservice registration result. Analyze the service processing request to obtain the request source address; according to the request source address, perform health detection on the availability zone set through the microservice registry to obtain the latency information and load information of several availability zones in the availability zone set; according to the latency information and load information, select an availability zone from the availability zone set through the load balancer to obtain a first availability zone, and route the service processing request to the first availability zone; respond to the service processing request through the first availability zone. Perform service traffic monitoring according to the service processing request to obtain service response metrics; query the logs of the microservices in the first availability zone to obtain application service logs, where the application service logs include database health status and application instance information; perform fault detection on the service response metrics, database health status, and application instance information to obtain a detection result. Analyze the microservice fault information through the resource layer to obtain the north-south traffic and east-west traffic of the microservices; according to the north-south traffic, perform resource scheduling analysis on the availability zone set through the load balancer to obtain a scheduling analysis result; based on the scheduling analysis result, switch the north-south traffic to a second availability zone through the control layer to obtain a north-south traffic switching result; according to the east-west traffic, query through the microservice registry to obtain microservice call information; based on the microservice call information, switch the east-west traffic to a third availability zone through the control layer to obtain an east-west traffic switching result; summarize the east-west traffic switching result and the north-south traffic switching result to obtain a traffic switching result. Analyze the fault information to obtain fault logs, fault data, and fault metrics; perform aggregation analysis through the fault logs, fault data, and fault metrics to obtain the root cause of the fault; based on the root cause of the fault, perform configuration optimization on the microservices in the first availability zone to obtain an optimization result; according to the optimization result, perform functional testing on the first availability zone through an automated testing tool to obtain a test result; if the test result is a pass, restore the usage permission of the first availability zone through the microservice registry; if the test result is a fail, generate a fault handling document through the root cause of the fault, the optimization result, and the test result. Thus, the problem that traffic cannot be quickly switched when a private cloud service fails is solved, traffic switching is realized, and the efficiency of traffic switching is improved.Based on the solution of the present invention, starting from the problems that existing emergency switching tools cannot quickly respond and handle failures at the AZ level in reality, and the handling efficiency and results do not meet expectations, a traffic switching method based on availability zones is designed, and the effectiveness of the traffic switching method based on availability zones of the present invention is verified when switching traffic. Finally, the efficiency of traffic switching by the method of the present invention has been significantly improved.
[0062] In this embodiment, for the convenience of description, the following will be described with the traffic switching device based on availability zones as the execution subject.
[0063] Since the core system architecture in the financial industry generally adopts a distributed microservices architecture in the prior art and integrates multiple different technology stacks such as OpenStack, VMware, Kubernetes, etc. Among them, the high-availability service capability is mainly achieved by deploying service instances in different availability zones (AZs). However, private clouds often integrate multiple technology stacks with each other, and it is difficult to achieve a unified switching effect among multiple technology stacks. For example, private clouds generally adopt complex architectures and it is difficult to achieve rapid AZ switching. In addition, due to distributed computing and complex business links in private clouds, it is difficult to achieve precise traffic switching. Therefore, the traffic switching efficiency in the prior art will also decrease.
[0064] The present application provides a solution. In a private cloud platform, after receiving a user's service processing request, a first availability zone is selected from the set of availability zones through a load balancer to respond to the request. At the same time, the microservices in the first availability zone are detected. In the case of detecting a failure, traffic is switched through a switching tool to obtain a traffic switching result, providing better services for users.
[0065] As can be seen from the above embodiments, the present application receives a service processing request; according to the service processing request, a first availability zone is selected from the set of availability zones through a load balancer, and the service processing request is responded to through the first availability zone; the overall response situation of the set of availability zones is detected to obtain a detection result; in the case where the detection result shows failure information, traffic is switched through a switching tool to obtain a traffic switching result. Thus, after receiving a service processing request, a set of availability zones is selected through a load balancer, the selected first availability zone is used to respond to the service processing request, and the microservices in the first availability zone are detected in real time during the processing. In the case of detecting microservice failure information, traffic is switched through a switching tool to obtain a traffic switching result, solving the problem that traffic cannot be quickly switched when a private cloud service fails and improving the traffic switching efficiency.
[0066] It should be noted that the execution subject of this embodiment can be a computing service device with data processing, network communication, and program running functions, such as a tablet computer, a personal computer, a mobile phone, etc., or an electronic device capable of implementing the above functions, a traffic switching device based on an availability zone, etc. Hereinafter, a traffic switching device based on an availability zone will be taken as an example to illustrate this embodiment and the following embodiments.
[0067] Based on this, the embodiment of the present application provides a traffic switching method based on an availability zone. Referring to Figure 1 , Figure 1 is a schematic flowchart of the first embodiment of the traffic switching method based on an availability zone of the present application.
[0068] In this embodiment, the traffic switching method based on an availability zone includes steps S01 to S07:
[0069] Step S01, receiving a service processing request;
[0070] Before the solution of this embodiment is elaborated, it should be clear that after the core system of the financial industry is migrated to the cloud, the main problems faced by the existing technology are concentrated in aspects such as multi-technology stack integration, complex architecture, distributed computing environment, global load balancing, automation level, and monitoring and diagnosis capabilities. These problems make it difficult to achieve fast, accurate, and consistent switching effects during the switching process of the availability zone (AZ), thereby affecting the high availability and continuity of the service. To solve these problems, this embodiment starts from the private cloud platform and preferentially receives service processing requests sent by users. Among them, the private cloud platform in this embodiment can be understood as a business platform of an enterprise facing actual users. For example, an APP developed by a bank has functions such as account query, fund transfer, and purchase of financial products. Therefore, the service processing request received here is described by taking the user's fund transfer request as an example.
[0071] Step S05, according to the service processing request, selecting a first availability zone from the availability zone set through a load balancer, and responding to the service processing request through the first availability zone;
[0072] After receiving a specific business processing request from a user, such as a fund transfer request, several levels of analysis are required to determine the available zone for specific processing, including historical analysis. For example, if the user has used such a function, the corresponding access connection, the available zone used, the database used, etc. may be stored in the cache information, which can respond to the user's business request faster. However, in the actual use process, on the payday of each month, there may be a large number of users making fund transfers. Therefore, in order to ensure the stable operation of the platform, in this embodiment, the load balancer selects an available zone from the set of available zones to obtain the first available zone for business processing, and then the first available zone responds to the business processing request. Among them, the available zone (Availability Zone, abbreviated as AZ) is a core concept in cloud computing, referring to multiple independent data centers or data center clusters divided by a cloud service provider within a geographical region (Region). Each available zone is designed to be isolated from each other and has independent power, cooling, network, and physical security facilities to ensure that when a failure occurs in one available zone, other available zones can still operate normally. The load balancer is a device or service used to distribute network traffic among multiple servers or computing resources. Its main purpose is to optimize resource utilization, maximize throughput, reduce response time, and avoid overloading a single server, thereby improving the availability and reliability of the system. In the prior art, the load balancer is widely used in scenarios such as cloud computing, Web services, databases, and microservice architectures, and is one of the core components of modern distributed systems.
[0073] Step S06, detect the overall response situation of the set of available zones to obtain a detection result;
[0074] During the process of an available zone processing a business processing request, due to various reasons, there may be a situation where the available zone fails to process the business request. If it cannot be discovered and processed in time, it will lead to a poor user experience. Therefore, in this embodiment, the set of available zones is detected in real time to obtain a detection result. It should be clear that the detection here mainly analyzes the overall situation of the set of available zones, including the inter-region network access status, physical machines, database status, and application key business indicators, etc., in order to obtain the detection of whether the current first available zone has a failure.
[0075] Step S07, in the case where the detection result shows failure information, perform traffic switching through a switching tool to obtain a traffic switching result.
[0076] When the detection result shows a fault message (which can be a site-level fault), it is necessary to immediately switch the traffic of the service processing request to avoid losses to the greatest extent. In this embodiment, the traffic is switched through a switching tool, achieving a fast traffic switch and obtaining a traffic switch result.
[0077] The overall architecture in this embodiment is as Figure 2 shown. As a private cloud platform for the core system of the financial industry, the platform publishes a multi-AZ high-availability deployment specification for applications to constrain the architecture of business systems on the cloud. The specification requires that business application instances are all stateless and multi-active, and must be evenly deployed in multiple availability zones. Moreover, the instances in a single AZ can carry all the business traffic during normal and peak periods. For different business systems, routing gateways need to be independently deployed in each AZ, and different business systems cannot share a routing gateway to avoid the spread of faults caused by gateway problems. Among them, the routing gateway is mounted under the global traffic manager GTM through LTM to achieve traffic scheduling of business traffic between different AZs. And the switching tool can isolate the routing gateway AZ of a single business system according to the user request to isolate external request access to the faulty AZ. In addition, the system internally adopts a microservices deployment framework, and the platform provides a unified microservices registry to register and discover and manage microservices, monitor the microservice status in real time, and designs a set of traffic scheduling algorithms to allocate traffic to downstream instances according to the weights and response times of service instances to ensure that no single instance undertakes too much load.
[0078] In the above solution, the business requests are preferentially allocated by the load balancer, and the availability zone with less load is used for business processing. When a microservice in the availability zone fails, the traffic sent to the availability zone is switched through the switching tool, providing users with better-quality service processing and achieving fast traffic switching when microservices fail. It should be clear that the switching method in this embodiment has unique advantages in the financial industry data center and meets the high real-time and high reliability requirements of financial transactions.
[0079] Specifically, before the above step S05 of selecting an availability zone from the set of availability zones through the load balancer according to the service processing request to obtain a first availability zone and responding to the service processing request through the first availability zone, the method further includes:
[0080] Step S02, receiving a service registration request from the service platform;
[0081] Step S03, performing microservice deployment and availability zone deployment according to the service registration request to obtain microservice application instances;
[0082] Step S04, registering the microservice application instances in the microservice registry to obtain a microservice registration result.
[0083] Before the available zone responds to the service processing request, the microservices also need to be registered in the microservice registry for subsequent management and allocation. In this embodiment, microservice deployment and available zone deployment will be performed according to the service registration request sent by the service platform to obtain specific microservice application instances. The process of microservice registration in this embodiment is as follows:
[0084] (1) Service registration request parsing: Receive the service registration request and parse the key information in the request, including: microservice name, version number, dependent services, resource requirements (CPU, memory, storage, etc.), available zone (AZ) deployment requirements (such as cross-available zone deployment, single-available zone deployment), and high availability requirements (such as whether multi-copy deployment is required). Subsequently, store the parsed information in the service registry (such as Consul, Eureka, Nacos, etc.);
[0085] (2) Microservice deployment planning: According to business requirements and resource constraints, formulate a microservice deployment plan, such as determining the number and distribution of available zones (AZs) for deployment, determining the number of instances in each available zone, and determining whether cross-region (Region) deployment is required. Subsequently, select a deployment platform (such as Kubernetes, Docker Swarm, etc.) and an orchestration tool (such as Helm, Terraform, etc.);
[0086] (3) Resource allocation and scheduling: Allocate computing resources (such as virtual machines, containers) in the target available zone (AZ). Then, according to the deployment plan, schedule microservice instances to the specified available zone. Finally, ensure that the resource allocation meets high availability and performance requirements (such as CPU, memory, network bandwidth);
[0087] (4) Microservice deployment and startup: Deploy the microservice image (such as Docker image) to the computing resources in the target available zone. Then, start the microservice instance and configure the running parameters (such as environment variables, configuration files). Finally, register the microservice instance in the service registry to ensure that it can be discovered and called by other services;
[0088] (5) Cross-available zone traffic distribution: First, configure a load balancer (such as AWS ALB, Nginx, HAProxy) to achieve cross-available zone traffic distribution. Then, set the load balancing policy (such as round-robin, weighted round-robin, least connections). Finally, bind the load balancer to the microservice instances to ensure that traffic can be correctly distributed to each available zone;
[0089] (6) Health Check and Fault Recovery: Configure a health check mechanism to regularly detect the running status of microservice instances. If a failure occurs in a certain instance or availability zone, automatically switch the traffic to other healthy instances or availability zones, record the fault information and trigger an alarm to notify the operation and maintenance team for handling.
[0090] (7) Monitoring and Log Collection: Deploy a monitoring system (such as Prometheus, Grafana) to monitor the performance metrics of microservices in real time (such as CPU usage, response time), configure a log collection system (such as ELK Stack, Fluentd) to centrally store and analyze the log data of microservices. Finally, set alarm rules to trigger an alarm when performance metrics or logs are abnormal;
[0091] (8) Delivery of Microservice Application Instances: Verify the functions and performance of microservice instances to ensure they meet business requirements, then return the access addresses of microservice instances (such as API gateway address, load balancer address) to the private cloud platform. Finally, record the deployment results, including the number of instances, availability zone distribution, resource usage, etc.
[0092] More specifically, in the above step S05, the step of selecting an availability zone from the set of availability zones through a load balancer according to the service processing request and responding to the service processing request through the first availability zone includes:
[0093] Step S051, parse the service processing request to obtain the request source address;
[0094] Step S052, according to the request source address, perform a health check on the set of availability zones through the microservice registry to obtain the latency information and load information of several availability zones in the set of availability zones;
[0095] Step S053, according to the latency information and load information, select an availability zone from the set of availability zones through the load balancer to obtain the first availability zone, and route the service processing request to the first availability zone;
[0096] Step S054, respond to the service processing request through the first availability zone.
[0097] As shown in the above content of this embodiment, in order to facilitate the rapid processing of service requests, the source address of the service request will be parsed in this embodiment to more quickly learn the user's frequently used functions or whether there is cached information. Subsequently, based on the request source address, the service and historical information that the user wants to perform are known. At this time, the health check of the available zone set is performed through the microservice registry to obtain the latency information and load information of each available zone. Finally, based on the latency information and load information, the available zone is selected through the load balancer to obtain the first available zone for service processing, and the service processing request is routed to the first available zone, and the service processing request is responded to through the first available zone.
[0098] In the above solution, the load balancer is preferentially used for the first available zone screening, which reduces the probability of the available zone failure at the beginning and provides a better service for users.
[0099] Through the above solution in this embodiment, specifically by receiving a service processing request; according to the service processing request, selecting the first available zone from the available zone set through the load balancer, and responding to the service processing request through the first available zone; detecting the overall response situation of the available zone set to obtain a detection result; in the case where the detection result is a failure message, performing traffic switching through a switching tool to obtain a traffic switching result. Thus, after receiving the service processing request, the available zone set is selected through the load balancer, the selected first available zone is used to respond to the service processing request, and the microservices in the first available zone are detected in real time during the processing. In the case where a microservice failure message is detected, traffic switching is performed through a switching tool to obtain a traffic switching result, which solves the problem that traffic cannot be quickly switched when a private cloud service fails and improves the efficiency of traffic switching.
[0100] Based on the first embodiment of this application, in the second embodiment of this application, the same or similar content as in the above-mentioned first embodiment can be referred to the above introduction and will not be repeated hereinafter. On this basis, please refer to Figure 3 In step S06 of obtaining the detection result by detecting the overall response situation of the available zone set, the traffic switching method based on the available zone further includes steps S061 to S063:
[0101] Step S061, performing service traffic monitoring according to the service processing request to obtain service response metrics;
[0102] Step S062, querying the logs of the microservices in the first available zone to obtain application service logs, where the application service logs include database health status and application instance information;
[0103] Step S063: Perform fault detection on the service response metrics, database health status, and application instance information to obtain a detection result.
[0104] When Application as a Service (AAS) quickly locates the fault scope in different dimensions, previous distributed cloud platforms often adopted the integration method of multiple technology stacks. This easily leads to the situation that faults affecting services may come from different technology stacks. Common faults include, for example, physical machine downtime, database faults, network faults, business link faults, etc. The stage that takes the longest time is often to locate the fault cause and determine the fault impact. Therefore, this embodiment provides a set of panoramic observable tools, which are integrated from Infrastructure as a Service (IaaS), Platform as a Service (PaaS), and Software as a Service (SaaS). Therefore, the observable tools in this embodiment mainly provide the following monitoring capabilities:
[0105] (1) Real-time monitoring of business traffic: application transaction volume, success rate, response time, TPS, etc., application status monitoring (application heartbeat, service status, instance status, running status, etc.), business metrics (application logs, custom errors, API requests, etc.);
[0106] (2) Monitoring of cloud platform components: Aggregate analysis of key metrics of applications related to core components of the cloud platform;
[0107] (3) Monitoring of computing resources: Metrics such as CPU, memory, storage, and network card rate of virtual machines and Docker;
[0108] (4) Monitoring of database status: Number of database connections, database status, etc.
[0109] In this embodiment, it is possible to preferentially monitor business traffic according to business processing requests, check whether the business traffic flows into the microservice application instance for processing normally, obtain service response metrics, and thus clarify whether the current business processing is blocked. Subsequently, query the logs of the microservice that responds to the business processing request to obtain the application service log, including the health status of the database during the service process and the information of the application instance. Finally, perform aggregate analysis on the service response metrics, database health status, and application instance information to obtain the detection result of the current microservice.
[0110] Specifically, in the above embodiment, step S07, in the case where the detection result is a fault message, the step of performing traffic switching through a switching tool to obtain a traffic switching result includes:
[0111] Step S071: Analyze the microservice failure information through the resource layer to obtain the north-south traffic and east-west traffic of the microservice;
[0112] Step S072: According to the north-south traffic, perform resource scheduling analysis on the set of available zones through the load balancer to obtain a scheduling analysis result;
[0113] Step S073: Based on the scheduling analysis result, switch the north-south traffic to the second available zone through the control layer to obtain a north-south traffic switching result;
[0114] Step S074: According to the east-west traffic, query through the microservice registry to obtain microservice call information;
[0115] Step S075: Based on the microservice call information, switch the east-west traffic to the third available zone through the control layer to obtain an east-west traffic switching result;
[0116] Step S076: Aggregate the east-west traffic switching result and the north-south traffic switching result to obtain a traffic switching result.
[0117] It should be clear that during the process of switching microservice traffic, it is necessary to consider not only the traffic connected to users by microservices (i.e., north-south traffic), but also the traffic between microservices within the platform (i.e., east-west traffic). At the same time, in order to improve the switching speed, permission security prevention and control, ensure data security and operation compliance during the switching process, in this embodiment, the switching tool is divided into two layers, namely the control layer and the resource layer. In the control layer, the "north-south" and "east-west" traffic switching tools are packaged as a whole, and while issuing switching instructions, they are processed in parallel. At the same time, at the tool level, a comprehensive operation monitoring and auditing function is provided, providing detailed operation records and real-time execution status monitoring for easy troubleshooting and operation compliance management. In the resource layer, load balancing and application resources are "pooled", and physical and logical isolation is achieved within each AZ, achieving a good fault isolation effect.
[0118] In terms of the overall technical architecture of this embodiment, as Figure 4 shown, it adopts a design in which the underlying infrastructure application and the upper-layer business application are completely decoupled from each other, and an application for independent implementation of emergency management is deployed. When performing AZ-level switching of the cloud system, the "north-south" and "east-west" traffic of the upper-layer business applications of the platform are isolated with one key, while ensuring that the underlying infrastructure application can provide normal external services.
[0119] For the "north-south" traffic, that is, the traffic distributed to the routing application through the load balancing device and then finally transferred to the application instances for external services for processing, which is collectively referred to as external traffic here. The overall application systems of the cloud platform adopt a standardized mode of providing external services through domain names. When the upper-layer service attempts to access the service through the domain name, the load balancing device distributes the traffic to a VIP through the DNS resolution policy and then forwards the request to the actual service instances at the back end. However, there are more than five thousand applications and more than twenty thousand application instances in a certain AZ. In case of an AZ-level failure, due to the performance bottleneck of the load balancing device, the application instances cannot be removed in large batches in parallel (LTM layer) for the external access service traffic. Coupled with the time for problem location and decision-making, it will lead to too long switching time. Therefore, in this embodiment, Figure 5 As shown, the level of external traffic switching is moved up, and the VIPs in a certain AZ are independently set as a set. The switching tool layer issues a switching instruction, and the domain names within the same set are executed in parallel (GTM layer). All VIPs in this AZ can be removed within one minute, achieving the effect of quickly isolating the external traffic. At the same time, the in-transit transactions will not be interrupted, and the newly issued traffic will be forwarded by the load balancer to the remaining several VIPs for processing. For the "east-west" traffic, that is, the traffic directly called between the internal microservices of the system. Since these applications will update actions such as going online, going offline, and updating to the microservice registry in real time as Figure 4 shown in the microservice isolation instruction in, and the registry stores the mutual call relationships between applications, the instance status in the faulty AZ can be quickly set to abnormal, and the internal microservice calls will be notified that this instance is unavailable, so as to forward the traffic to the remaining several available AZs.
[0120] More specifically, in the above embodiment, after the step S07 of performing traffic switching through the switching tool to obtain a traffic switching result when the detection result is a fault message, the method further includes:
[0121] Step S08, parsing the fault message to obtain a fault log, fault data, and fault metrics;
[0122] Step S09, performing aggregation analysis through the fault log, fault data, and fault metrics to obtain the root cause of the fault;
[0123] Step S10, performing configuration optimization on the microservices in the first available zone based on the root cause of the fault to obtain an optimization result;
[0124] Step S11, according to the optimization result, performing a functional test on the first available zone through an automated test tool to obtain a test result;
[0125] Step S12, if the test result is passed, restore the usage permission of the first available zone through the microservice registry center;
[0126] Step S13, if the test result is not passed, generate a fault handling document based on the root cause of the fault, the optimization result, and the test result.
[0127] After completing the traffic switch in this embodiment, it is also necessary to record the corresponding information for faster resolution in case of the same problem in the future. The specific solutions include:
[0128] (1) Obtain specific fault indicators from each system according to the microservice fault information, including collecting fault information (extracting fault logs from the microservice's logging system (such as ELK Stack, Fluentd)), obtaining fault data (such as CPU usage, memory occupancy, request latency) from the monitoring system (such as Prometheus, Grafana), and obtaining fault indicators (such as error rate, timeout rate, service unavailable time) from the alarm system (such as PagerDuty, Zabbix);
[0129] (2) Parse the obtained information: First, use a log parsing tool (such as Logstash, Fluentd) to structure the fault logs, then store the fault data and fault indicators in a time series database (such as InfluxDB, Prometheus) for subsequent analysis, and finally output the structured fault logs, fault data, and fault indicators;
[0130] (3) Aggregate and analyze to obtain the root cause of the fault: First, perform data aggregation, that is, aggregate the fault logs, fault data, and fault indicators according to the time line to generate a fault timeline graph, then use a data analysis tool (such as Pandas, Spark) to perform correlation analysis on the data, and finally perform root cause analysis, that is, use a machine learning model (such as decision tree, clustering analysis) or a rule engine (such as Drools) to analyze the root cause of the fault. Among them, common root causes include: insufficient resources (such as CPU, memory exhaustion), network problems (such as high latency, packet loss), code defects (such as null pointer exceptions, infinite loops), and configuration errors (such as too short timeout settings, too small thread pool), etc. The final output result is a root cause of fault report, which clarifies the specific cause of the fault.
[0131] (4) Perform configuration optimization based on the root cause of the fault: First, formulate an optimization plan according to the root cause of the fault and propose targeted optimization measures. For example, if there is insufficient resources, increase the CPU or memory quota; if there are network problems, optimize the network configuration or switch the network link; if there are code defects, repair the code and redeploy; and if there are configuration errors, adjust parameters such as the timeout time and thread pool size;
[0132] Subsequently, use configuration management tools (such as Ansible, Chef) or container orchestration tools (such as Kubernetes) to update the microservice configuration and deploy the optimized configuration to the microservice instances in the first available zone.
[0133] (5) Conduct functional testing through automated testing tools: including designing test cases. According to the functional requirements of the microservices, design test cases covering core functions (including unit testing, integration testing, and performance testing), then execute the tests. Use automated testing tools (such as Jenkins, Selenium, JUnit) to test the microservices in the first available zone, and finally record the test results, including the passing rate, failed test cases, and performance metrics.
[0134] (6) Restore the usage permission of the first available zone in the case of passing the test, that is, restore the usage permission of the first available zone through the microservice registry (such as Consul, Eureka, Nacos), re-mark the microservice instances in the first available zone as "healthy", and allow traffic to be redistributed to this available zone.
[0135] (7) If the test result is not passed, record the root cause of the failure, the optimization result, and the test result, and generate a fault handling document. The specific document content includes the fault description (detailed description of the fault phenomenon and the scope of influence), the root cause of the fault (clarify the fundamental cause of the fault), the optimization measures (list the implemented optimization solutions and configuration changes), the test result (record the result of the functional test and the performance metrics), and the handling suggestions (provide subsequent improvement suggestions and preventive measures).
[0136] In this embodiment, through the above solution, specifically, by monitoring the service traffic according to the service processing request, service response metrics are obtained; by querying the logs of the microservices in the first available zone, application service logs are obtained, and the application service logs include the database health status and application instance information; by performing fault detection on the service response metrics, database health status, and application instance information, a detection result is obtained. Thus, after receiving a service processing request, the available zone set is selected through a load balancer, and the selected first available zone is used to respond to the service processing request. During the processing, the microservices in the first available zone are detected in real time. In the case of detecting microservice fault information, traffic switching is performed through a switching tool to obtain a traffic switching result, which solves the problem that traffic cannot be quickly switched when a private cloud service fails and improves the efficiency of traffic switching.
[0137] Exemplarily, to help understand the implementation process of the traffic switching method based on available zones obtained by combining the above Embodiment 1, please refer to Figure 6 , Figure 6A brief process schematic diagram of a traffic switching method based on availability zones is provided. Specifically:
[0138] After service access, global load balancing is used to allocate availability zones for it, and during the processing, real-time detection of availability zones is carried out through application key metric monitoring sources, physical machine monitoring sources, database monitoring sources, and other monitoring sources. When a site anomaly is detected, specific anomaly information of the site is pushed to the panoramic observable tool for aggregation analysis to complete the diagnosis and judgment of the fault scope. When the fault scope meets the switching conditions, AZ-level switching is completed through the traffic switching tool. When the fault scope does not meet the AZ-level switching conditions, other range switching is carried out, realizing the traffic switching of the faulty microservice.
[0139] It should be noted that the above examples are only for understanding this application and do not constitute a limitation on the traffic switching method based on availability zones of this application. Based on this technical concept, more forms of simple transformations are within the protection scope of this application.
[0140] This application also provides a traffic switching device based on availability zones. Please refer to Figure 7 The device is applied to a private cloud platform. The device includes:
[0141] A receiving module 10 for receiving service processing requests;
[0142] A response module 20 for selecting a first availability zone from the availability zone set through a load balancer according to the service processing request and responding to the service processing request through the first availability zone;
[0143] A detection module 30 for detecting the overall response situation of the availability zone set to obtain a detection result;
[0144] A switching module 40 for performing traffic switching through a switching tool to obtain a traffic switching result when the detection result shows fault information.
[0145] The traffic switching device based on availability zones provided by this application adopts the traffic switching method based on availability zones in the above embodiment, and can solve the technical problem that traffic cannot be quickly switched when a private cloud service fails. Compared with the prior art, the beneficial effects of the traffic switching device based on availability zones provided by this application are the same as those of the traffic switching method based on availability zones provided in the above embodiment, and other technical features in the traffic switching device based on availability zones are the same as the features disclosed in the above embodiment method, and will not be elaborated here.
[0146] The present application provides a traffic switching device based on availability zones. The traffic switching device based on availability zones includes: at least one processor; and 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 to enable the at least one processor to execute the traffic switching method based on availability zones in the first embodiment above.
[0147] Reference is made below Figure 8 , which shows a schematic structural diagram of a traffic switching device based on availability zones suitable for implementing the embodiments of the present application. The traffic switching device based on availability zones in the embodiments of the present application may include, but is not limited to, mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Descriptions), PMPs (Portable Media Players), vehicle terminals (such as vehicle navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 8 The traffic switching device based on availability zones shown is merely an example and should not impose any limitation on the functions and scope of use of the embodiments of the present application.
[0148] As Figure 8As shown in the figure, the availability zone-based traffic switching device may include a processing device 1001 (such as a central processing unit, a graphics processing unit, etc.), which may perform various appropriate actions and processes according to the program stored in the read-only memory (ROM: Read Only Memory) 1002 or the program loaded from the storage device 1003 into the random access memory (RAM: Random Access Memory) 1004. In the RAM 1004, various programs and data required for the operation of the availability zone-based traffic switching device are also stored. The processing device 1001, the ROM 1002, and the RAM 1004 are connected to each other through a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Generally, the following systems may be connected to the I / O interface 1006: an input device 1007 including, for example, a touch screen, a touchpad, a keyboard, a mouse, an image sensor, a microphone, an accelerometer, a gyroscope, etc.; an output device 1008 including, for example, a liquid crystal display (LCD: Liquid Crystal Display), a speaker, a vibrator, etc.; a storage device 1003 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1009. The communication device 1009 may allow the availability zone-based traffic switching device to communicate with other devices wirelessly or wiredly to exchange data. Although the figure shows an availability zone-based traffic switching device having various systems, it should be understood that it is not required to implement or have all the shown systems. Instead, more or fewer systems may be implemented or had.
[0149] Specifically, according to the embodiments disclosed in the present application, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, the embodiments disclosed in the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program contains program codes for executing the methods shown in the flowcharts. In such an embodiment, the computer program may be downloaded and installed from the network through the communication device, or installed from the storage device 1003, or installed from the ROM 1002. When the computer program is executed by the processing device 1001, the above functions defined in the methods of the embodiments disclosed in the present application are executed.
[0150] The availability zone-based traffic switching device provided by the present application adopts the availability zone-based traffic switching method in the above embodiments, and can solve the technical problem that traffic switching cannot be quickly performed when a private cloud service fails. Compared with the prior art, the beneficial effects of the availability zone-based traffic switching device provided by the present application are the same as those of the availability zone-based traffic switching method provided by the above embodiments, and other technical features in the availability zone-based traffic switching device are the same as those disclosed in the method of the previous embodiment, and will not be elaborated here.
[0151] It should be understood that each part disclosed in this application can be implemented by hardware, software, firmware, or a combination thereof. In the description of the above embodiments, specific features, structures, materials, or characteristics can be combined in a suitable manner in any one or more embodiments or examples.
[0152] As described above, the above is only the specific implementation manner of this application, but the protection scope of this application is not limited thereto. Any person skilled in the art can easily think of changes or substitutions within the technical scope disclosed in this application, and all of them should be covered by the protection scope of this application. Therefore, the protection scope of this application should be subject to the protection scope of the claims.
[0153] This application provides a computer-readable storage medium having computer-readable program instructions (i.e., computer programs) stored thereon, and the computer-readable program instructions are used to execute the traffic switching method based on available zones in the above embodiments.
[0154] The computer-readable storage medium provided by this application can be, for example, a USB flash drive, but is not limited to electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or any combination of the above. More specific examples of the computer-readable storage medium may include, but are not limited to: electrical connections with one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM) or flash memory, optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the above. In this embodiment, the computer-readable storage medium can be any tangible medium that contains or stores a program, and this program can be used by or in combination with an instruction execution system, device, or device. The program code contained on the computer-readable storage medium can be transmitted by any appropriate medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.
[0155] The above computer-readable storage medium can be included in the traffic switching device based on available zones; it can also exist separately without being assembled into the traffic switching device based on available zones.
[0156] The above computer-readable storage medium carries one or more programs, which, when executed by a traffic switching device based on availability zones, cause the traffic switching device based on availability zones to: receive a service processing request; select a first availability zone from the set of availability zones through a load balancer according to the service processing request, and respond to the service processing request through the first availability zone; detect the overall response situation of the set of availability zones to obtain a detection result; and perform traffic switching through a switching tool in the case where the detection result indicates a fault message to obtain a traffic switching result.
[0157] Computer program code for performing the operations of this application may be written in one or more programming languages or combinations thereof. The programming languages include object-oriented programming languages such as Java, Smalltalk, and C++, and also include conventional procedural programming languages such as the "C" language or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, executed as a stand-alone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., by using an Internet service provider to connect through the Internet).
[0158] The flowcharts and block diagrams in the accompanying drawings illustrate the possible architectures, functions, and operations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in the flowchart or block diagram may represent a module, a program segment, or a part of code that contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the blocks may occur in a different order than that marked in the accompanying drawings. For example, two consecutive blocks shown may actually be executed substantially in parallel, and they may sometimes be executed in the reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and / or flowchart, and the combinations of blocks in the block diagram and / or flowchart, may be implemented by a dedicated hardware-based system for performing the specified functions or operations, or may be implemented by a combination of dedicated hardware and computer instructions.
[0159] The modules involved in the embodiments of the present application can be implemented in software or in hardware. In some cases, the name of the module does not constitute a limitation on the unit itself.
[0160] The readable storage medium provided by the present application is a computer-readable storage medium. The computer-readable storage medium stores computer-readable program instructions (i.e., computer programs) for executing the above-mentioned traffic switching method based on available zones, which can solve the technical problem that traffic cannot be quickly switched when a private cloud service fails. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided by the present application are the same as those of the traffic switching method based on available zones provided by the above embodiments, and will not be elaborated here.
[0161] The present application also provides a computer program product, including a computer program, and when the computer program is executed by a processor, it implements the steps of the traffic switching method based on available zones as described above.
[0162] The computer program product provided by the present application can solve the technical problem that traffic cannot be quickly switched when a private cloud service fails. Compared with the prior art, the beneficial effects of the computer program product provided by the present application are the same as those of the traffic switching method based on available zones provided by the above embodiments, and will not be elaborated here.
[0163] The above are only some embodiments of the present application, and do not limit the patent scope of the present application. Any equivalent structural transformation made by using the content of the specification and drawings of the present application under the technical concept of the present application, or any direct / indirect application in other related technical fields, is included in the patent protection scope of the present application.
Claims
1. A traffic switching method based on availability zones, characterized in that: The method is applied to a private cloud platform, and the method comprises: Receive business processing requests; According to the business processing request, select a first available zone from the available zone set through a load balancer, and respond to the business processing request through the first available zone; Detecting the overall response of the available zone set to obtain a detection result; When the detection result is fault information, flow switching is performed through a switching tool to obtain a flow switching result.
2. The method according to claim 1, characterized in that Before the step of selecting an available zone from an available zone set by a load balancer according to the business processing request to obtain a first available zone, and responding to the business processing request by the first available zone, the method further includes: Receive business registration requests from the business platform; Perform microservice deployment and availability zone deployment according to the business registration request to obtain a microservice application instance; Register the microservice application instance to the microservice registration center to obtain a microservice registration result.
3. The method according to claim 2, characterized in that The step of selecting an available zone from an available zone set by a load balancer according to the business processing request to obtain a first available zone, and responding to the business processing request by the first available zone comprises: Parsing the business processing request to obtain a request source address; According to the request source address, health detection is performed on the available zone set through the microservice registration center to obtain delay information and load information of several available zones in the available zone set; According to the delay information and the load information, the load balancer selects an available zone from the available zone set to obtain a first available zone, and routes the service processing request to the first available zone; The business processing request is responded to through the first available zone.
4. The method according to claim 1, characterized in that The step of detecting the overall response of the available zone set to obtain the detection result comprises: Performing business flow monitoring according to the business processing request to obtain a business response indicator; Perform a log query on the microservice in the first available zone to obtain an application service log, where the application service log includes a database health status and application instance information; Fault detection is performed on the business response indicator, database health status, and application instance information to obtain a detection result.
5. The method according to claim 2, characterized in that The switching tool includes a control layer and a resource layer. When the detection result is fault information, the flow switching is performed by the switching tool, and the step of obtaining the flow switching result includes: Analyze the microservice fault information through the resource layer to obtain the north-south traffic and the east-west traffic of the microservice; According to the north-south traffic, a resource scheduling analysis is performed on the available zone set through a load balancer to obtain a scheduling analysis result; Based on the scheduling analysis result, the north-south traffic is switched to the second available zone through the control layer to obtain a north-south traffic switching result; According to the east-west traffic, query the microservice registration center to obtain microservice call information; Based on the microservice call information, the east-west traffic is switched to the third available zone through the control layer to obtain an east-west traffic switching result; The east-west traffic switching result and the north-south traffic switching result are summarized to obtain a traffic switching result.
6. The method according to claim 5, characterized in that After the step of performing flow switching by a switching tool to obtain a flow switching result when the detection result is fault information, the method further includes: Analyze the fault information to obtain fault logs, fault data and fault indicators; Obtaining the root cause of the fault by performing aggregate analysis on the fault log, fault data and fault indicators; Based on the root cause of the fault, the microservice in the first availability zone is configured and optimized to obtain an optimization result; According to the optimization result, a functional test is performed on the first available zone by using an automated testing tool to obtain a test result; If the test result is that the test passes, the use permission of the first availability zone is restored through the microservice registration center; If the test result is that the test fails, a fault handling document is generated based on the root cause of the fault, the optimization result and the test result.
7. A flow switching device based on an availability zone, characterized in that: The device is applied to a private cloud platform, and the device includes: A receiving module, used for receiving a business processing request; A response module, configured to select an available zone from an available zone set through a load balancer according to the business processing request to obtain a first available zone, and respond to the business processing request through the first available zone; A detection module, used to detect the overall response of the available zone set and obtain a detection result; The switching module is used to perform flow switching through a switching tool to obtain a flow switching result when the detection result is fault information.
8. A traffic switching device based on an availability zone, characterized in that: The device comprises: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of the traffic switching method based on the availability zone as described in any one of claims 1 to 6.
9. A storage medium, characterized in that: The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the traffic switching method based on the availability zone are implemented as described in any one of claims 1 to 6.
10. A computer program product, characterized in that The computer program product comprises a computer program, and when the computer program is executed by a processor, the steps of the traffic switching method based on the availability zone are implemented as described in any one of claims 1 to 6.