Traffic management method and device, equipment and storage medium
By acquiring the current feature vector of the business system, and using reinforcement learning algorithms based on the policy knowledge base and digital twin model, the target traffic governance strategy is determined and filtered, solving the real-time and accuracy problems of traffic governance in microservice architecture, and realizing adaptive intelligent decision-making and strategy optimization.
Patent Information
- Application Number
- CN202511662501.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-13
- Publication Date
- 2026-02-10
AI Technical Summary
Existing technologies cannot respond in real time to dynamically changing business scenarios in traffic governance of microservice architectures. They rely on manual intervention for adjustment, and monitoring with fixed time windows results in second-level delays in anomaly detection and recovery, which cannot meet the needs of scenarios with high real-time requirements.
By acquiring the current feature vector of the business system, candidate traffic governance strategies are determined based on the policy knowledge base. Reinforcement learning algorithms are used to conduct simulation tests in the digital twin model to determine the confidence score and select the target traffic governance strategy for traffic governance, thereby achieving adaptive intelligent decision-making.
It improves the accuracy and real-time performance of traffic management, can adaptively identify various business scenarios, quantify the reliability of strategies, solve the business risks brought about by traditional trial-and-error adjustments, and realize the transformation from manual preset to automatic adaptation.
Smart Images

Figure CN121509340A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a traffic management method, apparatus, device, and storage medium. Background Technology
[0002] Traditional monolithic architectures are no longer sufficient to meet the ever-growing and diverse access demands. Microservice architectures, by breaking down a single application into numerous microservices based on various needs, offer a solution. Each microservice can be load-balanced and elastically scaled, allowing it to flexibly handle traffic demands across different scenarios. Therefore, enterprises are increasingly building their applications based on microservice architectures, which offer greater flexibility in system resource scheduling. Furthermore, effective traffic management within microservice architectures has become a hot research topic.
[0003] In existing technologies, traffic governance in microservice architectures typically employs statically configured service meshes (e.g., Istio) and time-window-based monitoring mechanisms. Staticly configured service meshes rely on manually preset rules for traffic management, including fixed load balancing strategies (e.g., round-robin, weighted) and manually defined routing rules. Time-window-based monitoring mechanisms use fixed data collection intervals (e.g., 1 minute) to acquire system metrics and trigger alarms or circuit breakers based on thresholds.
[0004] However, static configurations cannot respond in real time to dynamically changing business scenarios (such as sudden traffic surges and promotional activities), requiring manual intervention for adjustments. Monitoring within a fixed time window results in second-level delays in anomaly detection and recovery, which cannot meet the needs of scenarios with high real-time requirements. Summary of the Invention
[0005] This application provides a traffic management method, apparatus, device, and storage medium to improve the accuracy and real-time performance of traffic management and effectively address various business scenarios.
[0006] In a first aspect, embodiments of this application provide a traffic management method, the method comprising: Obtain the current feature vector of the business system. The current feature vector includes features in multiple dimensions, including business scenario type, service level, and expected traffic pattern. Service level represents the importance level of different services. Based on the policy knowledge base, each candidate traffic governance policy that matches the current feature vector is determined. The policy knowledge base is used to store each historical feature vector and the traffic governance policies associated with each historical feature vector. Simulation tests are conducted on each candidate traffic management strategy to determine the confidence score of each candidate strategy. From the candidate strategies, the target traffic management strategy that meets the pre-set confidence conditions is selected, and the target traffic management strategy is adopted for traffic management.
[0007] In one optional embodiment, obtaining the current feature vector of the business system includes: Obtain multi-dimensional data sources corresponding to the business system. These multi-dimensional data sources include: business logs, call chain records, and monitoring metrics. The current feature vector is obtained by semantic parsing based on multi-dimensional data sources.
[0008] In one optional embodiment, based on a policy knowledge base, each candidate traffic governance policy that matches the current feature vector is determined, including: The strategy knowledge base is queried to identify historical feature vectors of each target that meet the similarity condition with the current feature vector, and the traffic governance strategies associated with each historical feature vector of the target are used as candidate traffic governance strategies.
[0009] In one optional embodiment, simulation tests are performed on each candidate traffic management strategy to determine the confidence score of each candidate traffic management strategy, including: Build a digital twin model based on actual operational data from the production environment; In the digital twin model, reinforcement learning algorithms are used to simulate and test each candidate traffic governance strategy, and an execution evaluation report for each candidate traffic governance strategy is obtained. The execution evaluation report includes: governance success rate, hardware resource consumption, and business impact. Based on the implementation evaluation reports of each candidate traffic governance strategy, a confidence score for each candidate traffic governance strategy is determined.
[0010] In an optional embodiment, the method further includes: When the confidence scores of each candidate traffic management strategy do not meet the preset confidence conditions, the adjustable parameters of each candidate traffic management strategy are adjusted to obtain new candidate traffic management strategies, and these new candidate traffic management strategies are added to the existing candidate traffic management strategies.
[0011] In one optional embodiment, traffic governance is performed using a targeted traffic governance strategy, including: A target traffic management strategy is adopted to manage the traffic of the corresponding business to be managed in the business layer. A target traffic management strategy is adopted to manage the traffic of the corresponding services to be managed in the service layer. A target traffic management strategy is adopted to manage the traffic of the corresponding hardware resources to be managed in the infrastructure layer.
[0012] In an optional embodiment, after performing traffic governance using a target traffic governance strategy, the method further includes: Establish a relationship between the current feature vector and the target traffic governance strategy, and store the relationship in the strategy knowledge base.
[0013] Secondly, embodiments of this application also provide a traffic management device, the device comprising: The acquisition module is used to acquire the current feature vector of the business system. The current feature vector includes features in multiple dimensions, including business scenario type, service level, and expected traffic pattern. The service level represents the importance level of different services. The first processing module is used to determine each candidate traffic governance strategy that matches the current feature vector based on the strategy knowledge base, wherein the strategy knowledge base is used to store each historical feature vector and the traffic governance strategy associated with each historical feature vector; The second processing module is used to perform simulation tests on each candidate traffic management strategy, determine the confidence score of each candidate traffic management strategy, select the target traffic management strategy whose confidence score meets the preset confidence conditions from each candidate traffic management strategy, and use the target traffic management strategy to perform traffic management.
[0014] In an optional embodiment, when obtaining the current feature vector of the business system, the acquisition module is further configured to: Obtain multi-dimensional data sources corresponding to the business system. These multi-dimensional data sources include: business logs, call chain records, and monitoring metrics. The current feature vector is obtained by semantic parsing based on multi-dimensional data sources.
[0015] In an optional embodiment, when determining each candidate traffic governance strategy that matches the current feature vector based on the policy knowledge base, the first processing module is further configured to: The strategy knowledge base is queried to identify historical feature vectors of each target that meet the similarity condition with the current feature vector, and the traffic governance strategies associated with each historical feature vector of the target are used as candidate traffic governance strategies.
[0016] In an optional embodiment, when performing simulation tests on each candidate traffic management strategy and determining the confidence score of each candidate traffic management strategy, the second processing module is further configured to: Build a digital twin model based on actual operational data from the production environment; In the digital twin model, reinforcement learning algorithms are used to simulate and test each candidate traffic governance strategy, and an execution evaluation report for each candidate traffic governance strategy is obtained. The execution evaluation report includes: governance success rate, hardware resource consumption, and business impact. Based on the implementation evaluation reports of each candidate traffic governance strategy, a confidence score for each candidate traffic governance strategy is determined.
[0017] In an optional embodiment, the second processing module is further configured to: When the confidence scores of each candidate traffic management strategy do not meet the preset confidence conditions, the adjustable parameters of each candidate traffic management strategy are adjusted to obtain new candidate traffic management strategies, and these new candidate traffic management strategies are added to the existing candidate traffic management strategies.
[0018] In an optional embodiment, when using a target traffic management strategy for traffic management, the second processing module is further configured to: A target traffic management strategy is adopted to manage the traffic of the corresponding business to be managed in the business layer. A target traffic management strategy is adopted to manage the traffic of the corresponding services to be managed in the service layer. A target traffic management strategy is adopted to manage the traffic of the corresponding hardware resources to be managed in the infrastructure layer.
[0019] In an optional embodiment, after performing traffic governance using a target traffic governance strategy, the second processing module is further configured to: Establish a relationship between the current feature vector and the target traffic governance strategy, and store the relationship in the strategy knowledge base.
[0020] Thirdly, embodiments of this application also provide an electronic device, including: Processor; and Stored program memory, The program includes instructions that, when executed by the processor, cause the processor to perform the traffic governance method as described in the first aspect.
[0021] Fourthly, embodiments of this application also provide a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to cause a computer to perform the traffic management method as described in the first aspect.
[0022] Fifthly, this application provides a computer program product that, when invoked by a computer, causes the computer to execute the traffic management method steps described in the first aspect.
[0023] The beneficial effects of this application are as follows: In the traffic governance method provided in this application embodiment, the current feature vector of the business system is obtained. Then, based on a strategy knowledge base, candidate traffic governance strategies matching the current feature vector are determined. The strategy knowledge base stores historical feature vectors and their associated traffic governance strategies. Finally, simulation tests are performed on each candidate traffic governance strategy to determine its confidence score. From these strategies, a target traffic governance strategy whose confidence score meets pre-set confidence conditions is selected, and traffic governance is performed using the target strategy. This breaks through the reliance on manual rules in existing technologies, achieving intelligent traffic governance. It can adaptively identify various business scenarios, obtain the current feature vector, which not only reflects the current system state but also includes predictions of future business trends, providing forward-looking guidance for strategy formulation. It determines the target traffic governance strategy corresponding to the current feature vector, realizing a shift from manual pre-setting to automatic adaptation, effectively addressing sudden traffic surges and complex business scenarios. Furthermore, simulation tests on each candidate traffic governance strategy determine its confidence score, quantifying strategy reliability and resolving the business risks associated with traditional trial-and-error adjustments. Therefore, it improves the accuracy and real-time performance of traffic governance under the microservice architecture, effectively addressing various business scenarios.
[0024] Furthermore, other features and advantages of this application will be set forth in the following description and will be apparent in part from the description, or may be learned by practicing the application. The objectives and other advantages of this application may be realized and obtained by means of the structures particularly pointed out in the written description, claims, and drawings. Attached Figure Description
[0025] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described herein are used to provide a further understanding of this application, constitute a part of this application, and do not constitute an improper limitation of this application. In the accompanying drawings: Figure 1 This is a schematic diagram of an optional system architecture applicable to the embodiments of this application; Figure 2 A schematic diagram illustrating the implementation process of a traffic management method provided in this application embodiment; Figure 3 A logical schematic diagram for obtaining the current feature vector provided in an embodiment of this application; Figure 4 A logical diagram illustrating an embodiment of this application for obtaining a target traffic management strategy; Figure 5 A logical diagram illustrating a multi-level collaborative traffic governance approach provided in this application embodiment; Figure 6 This is a schematic diagram of the structure of a flow management device provided in an embodiment of this application; Figure 7 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0026] Embodiments of this application will now be described in more detail with reference to the accompanying drawings. While some embodiments of this application are shown in the drawings, it should be understood that this application can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of this application. It should be understood that the drawings and embodiments of this application are for illustrative purposes only and are not intended to limit the scope of protection of this application.
[0027] It should be understood that the steps described in the method embodiments of this application may be performed in different orders and / or in parallel. Furthermore, the method embodiments may include additional steps and / or omit the steps shown. The scope of this application is not limited in this respect.
[0028] The term "comprising" and its variations as used herein are open-ended, meaning "including but not limited to". The term "based on" means "at least partially based on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Definitions of other terms will be given in the following description. It should be noted that the concepts of "first", "second", etc., mentioned in this application are used only to distinguish different devices, modules, or units, and are not intended to limit the order of functions performed by these devices, modules, or units or their interdependencies.
[0029] It should be noted that the terms "a" and "a plurality of" used in this application are illustrative rather than restrictive, and those skilled in the art should understand that, unless otherwise expressly indicated in the context, they should be understood as "one or more".
[0030] The names of the messages or information exchanged between multiple devices in the embodiments of this application are for illustrative purposes only and are not intended to limit the scope of these messages or information.
[0031] The following explanations of some terms used in the embodiments of this application are provided to facilitate understanding by those skilled in the art.
[0032] (1) Microservice architecture: an architectural style that breaks down a monolithic application into multiple independently deployed small services, each of which runs an independent process and interacts with each other through a lightweight communication mechanism.
[0033] (2) Service Mesh: The infrastructure layer used to manage communication between microservices, and implements service discovery, load balancing and traffic control through the Sidecar proxy (e.g., Istio).
[0034] (3) Extended Berkeley Packet Filter (eBPF): A Linux kernel-level technology that enables network packet filtering and performance monitoring without modifying the kernel, and is used for fast circuit breaking.
[0035] (4) Wasm: A lightweight binary instruction format that supports dynamic compilation of traffic management strategies, enabling flexible loading and hot updates of strategies.
[0036] (5) Service Level Objective (SLO): such as "99% of requests have a latency of ≤100ms", which is used to trigger traffic management strategies such as intelligent degradation.
[0037] Based on the above explanations of terms and related terminology, the design concept of the embodiments of this application will be briefly introduced below: Traditional monolithic architectures are no longer sufficient to meet the ever-growing and diverse access demands. Due to the flexibility of microservice architectures, the overall application can be broken down into several microservices based on various needs. Each microservice can be load-balanced and elastically scaled, allowing it to flexibly handle traffic access demands in different scenarios. Therefore, enterprises are increasingly building their applications based on microservice architectures, which offer more flexible system resource scheduling. Meanwhile, how to implement traffic governance within microservice architectures has become a hot research topic.
[0038] In existing technologies, traffic governance in microservice architectures typically employs statically configured service meshes (e.g., Istio) and time-window-based monitoring mechanisms. Staticly configured service meshes rely on manually preset rules for traffic management, including fixed load balancing strategies (e.g., round-robin, weighted) and manually defined routing rules. Time-window-based monitoring mechanisms use fixed collection intervals (e.g., 1 minute) to acquire system metrics (e.g., queries per second (QPS) and latency), triggering alarms or circuit breakers based on thresholds. Furthermore, they employ a single-dimensional governance strategy (considering only basic performance metrics for traffic control decisions) and decentralized rule management (different teams independently configure and manage their own governance rules, lacking a global coordination mechanism).
[0039] However, static configurations cannot respond in real time to dynamically changing business scenarios (such as sudden traffic surges and promotional activities), requiring manual intervention for adjustments; monitoring with fixed time windows results in second-level delays in anomaly detection and recovery, which cannot meet the needs of scenarios with high real-time requirements; decisions based solely on basic performance indicators lack an understanding of business semantics, resulting in critical business operations not receiving accurate protection; and decentralized rule management is prone to policy overriding or conflicts, affecting system stability and service quality, especially in cross-team collaboration scenarios.
[0040] In view of this, this application provides a traffic governance method, which may specifically include: obtaining the current feature vector of a business system, the current feature vector including features of multiple dimensions, the multiple dimensions including: business scenario type, service level, and expected traffic pattern, the service level representing: the importance level of different services; then, based on a policy knowledge base, determining each candidate traffic governance strategy that matches the current feature vector, wherein the policy knowledge base is used to store each historical feature vector and the traffic governance strategies associated with each historical feature vector; then, performing simulation tests on each candidate traffic governance strategy to determine the confidence score of each candidate traffic governance strategy; then, selecting a target traffic governance strategy from each candidate traffic governance strategy whose confidence score meets a preset confidence condition; and finally, using the target traffic governance strategy for traffic governance.
[0041] By employing the above approach, we break through the reliance of existing technologies on manual rules, achieving intelligent traffic governance. This approach adaptively identifies various business scenarios, obtains current feature vectors that reflect not only the current system state but also predictions of future business trends, providing forward-looking guidance for strategy formulation. It determines the target traffic governance strategy corresponding to the current feature vector, realizing a shift from manual pre-setting to automatic adaptation, effectively handling sudden traffic surges and complex business scenarios. Furthermore, simulation tests are conducted on each candidate traffic governance strategy to determine its confidence score, quantifying strategy reliability and resolving the business risks associated with traditional trial-and-error adjustments. Therefore, this improves the accuracy and real-time performance of traffic governance in a microservice architecture, effectively addressing various business scenarios.
[0042] In particular, the preferred embodiments of this application will be described below with reference to the accompanying drawings. It should be understood that the preferred embodiments described herein are for illustration and explanation only and are not intended to limit this application. Furthermore, the embodiments of this application and the features in the embodiments can be combined with each other without conflict.
[0043] See Figure 1The diagram illustrates an optional system architecture applicable to an embodiment of this application. This system architecture may include: terminal devices (101a, 101b) and server 102. The terminal devices (101a, 101b) and server 102 can interact via a communication network. The communication network may employ wireless communication or wired communication methods. For example, the terminal devices (101a, 101b) can access the network and communicate with server 102 via cellular mobile communication technology. This cellular mobile communication technology may include, for example, 5G (5th generation mobile networks) or next-generation mobile communication technology. Optionally, the terminal devices (101a, 101b) can access the network and communicate with server 102 via short-range wireless communication. This short-range wireless communication method may include, for example, wireless fidelity (Wi-Fi) technology.
[0044] This application embodiment does not impose any limitation on the number of communication devices involved in the above system architecture. For example, the above system architecture may include more terminal devices, or it may include fewer terminal devices, or it may also include other network devices. Figure 1 As shown, only terminal devices (101a, 101b) and server 102 are described as examples. The following is a brief introduction to the above communication devices and their respective functions.
[0045] A terminal device (101a, 101b) is a device that can provide voice and / or data connectivity to a user, and may be a device that supports wired and / or wireless connections.
[0046] For example, terminal devices (101a, 101b) may include, but are not limited to: mobile phones, tablets, laptops, handheld computers, mobile internet devices (MID), wearable devices, virtual reality (VR) devices, augmented reality (AR) devices, wireless terminal devices in industrial control, wireless terminal devices in autonomous driving, wireless terminal devices in smart grids, wireless terminal devices in transportation safety, wireless terminal devices in smart cities, or wireless terminal devices in smart homes, etc.
[0047] In addition, the terminal devices (101a, 101b) may have related clients installed. The client may be software, such as an application (APP), browser, short video software, or webpage, mini-program, etc. It should be noted that the terminal devices (101a, 101b) in this application embodiment may be traffic management related clients.
[0048] Server 102 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms.
[0049] The traffic management method provided by the exemplary embodiments of this application will be described below in conjunction with the above system architecture and with reference to the accompanying drawings. It should be noted that the above system architecture is only shown to facilitate understanding of the spirit and principles of this application, and the embodiments of this application are not limited in any way in this respect.
[0050] See Figure 2 The diagram shown illustrates the implementation flow of a traffic management method provided in this application embodiment. Taking a server as an example, the specific implementation flow of this method is as follows: S20: Obtain the current feature vector of the business system.
[0051] The current feature vector includes features in multiple dimensions, including business scenario type, service level, and expected traffic pattern. Service level represents the importance level of different services under the current business scenario type, and expected traffic pattern represents the future traffic distribution characteristics of each service. Business scenario type includes, but is not limited to, e-commerce promotion activities, peak financial transactions, VIP user requests, etc.
[0052] Optionally, in this application embodiment, a possible implementation is provided for obtaining the current feature vector of the business system, specifically by performing the following operations: S200: Obtain multi-dimensional data sources corresponding to the business system.
[0053] The multi-dimensional data sources include: business logs, call chain records, and monitoring metrics. Business logs are log files generated during application runtime, recording information such as user transactions, API calls, and system exceptions. Call chain records are records that trace the flow path of requests between different microservices in a distributed system, including context labels, timestamps, and dependency information. Monitoring metrics include: QPS, latency, etc.
[0054] In this embodiment of the application, the multi-dimensional data source generated by the business system is connected.
[0055] S201: Perform semantic parsing based on multi-dimensional data sources to obtain the current feature vector.
[0056] Semantic parsing can be achieved using Natural Language Processing (NLP) technology.
[0057] In this embodiment of the application, semantic parsing is performed on scenario keywords (such as "flash sale" and "payment") in the business log text, and context tags (such as user level and business type) in the call chain record are combined to construct a business scenario profile. Based on the business scenario profile, a structured current feature vector is generated.
[0058] In this way, based on multi-dimensional data sources, the current business scenario can be accurately identified.
[0059] The current feature vector contains three core dimensions: business scenario type, service level, and expected traffic pattern. For example, the current feature vector is <major promotional event, core payment service, expected peak traffic>.
[0060] In this way, the current feature vector not only reflects the current system state, but also includes predictions of future business trends, providing forward-looking guidance for strategy formulation. The current feature vector will be updated in real time as business changes occur, ensuring the timeliness of traffic governance strategies.
[0061] Based on the above embodiments, see Figure 3 The diagram illustrates the logic for obtaining the current feature vector in this embodiment. A business-semantic traffic feature extraction engine is used to acquire the current feature vector. This engine automatically identifies business scenarios and generates the current feature vector through deep analysis of multi-dimensional data sources. It then establishes a correlation between the current feature vector and the target traffic governance strategy, storing this correlation in a strategy knowledge base. This business-semantic traffic feature extraction engine overcomes the limitations of traditional traffic management that relies solely on basic indicators, achieving an upgrade from a technology-driven to a business-semantic-driven governance model, providing accurate decision-making basis for subsequent intelligent scheduling.
[0062] S21: Based on the policy knowledge base, determine each candidate traffic governance policy that matches the current feature vector.
[0063] The strategy knowledge base is used to store each historical feature vector and the traffic governance strategies associated with each historical feature vector.
[0064] In this embodiment of the application, the strategy knowledge base is queried to determine each target historical feature vector whose similarity with the current feature vector meets the similarity condition, and the traffic governance strategy associated with each target historical feature vector is used as each candidate traffic governance strategy.
[0065] The similarity between historical feature vectors and current feature vectors can be cosine similarity, or it can be similarity such as Euclidean distance. This embodiment does not impose any restrictions on this. Each target historical feature vector that satisfies the similarity condition can be a target historical feature vector with a similarity greater than a similarity threshold, or it can be the top N target historical feature vectors sorted from high to low similarity, where N is an integer greater than 1. This embodiment does not impose any restrictions on this.
[0066] In addition, it is worth noting that multiple historical feature vectors in the policy knowledge base of this application embodiment can be associated with the same traffic governance policy. That is, a traffic governance policy is associated with at least one historical feature vector.
[0067] S22: Conduct simulation tests on each candidate traffic management strategy, determine the confidence score of each candidate traffic management strategy, and select the target traffic management strategy from the candidate traffic management strategies whose confidence scores meet the preset confidence conditions, and adopt the target traffic management strategy for traffic management.
[0068] Optionally, in this embodiment of the application, a possible implementation is provided for simulating and testing each candidate traffic management strategy to determine the confidence score of each candidate traffic management strategy, specifically by performing the following operations: S220: Build a digital twin model based on actual operational data from the production environment.
[0069] In this embodiment, actual operational data from the production environment (including traffic characteristics, service call relationships, and resource usage data) is collected to construct a high-fidelity digital twin model. This digital twin model not only reproduces the topology and dependencies of the real environment but also simulates various abnormal scenarios (such as sudden traffic spikes and node failures). Through a dynamic learning mechanism, the digital twin model continuously tracks changes in the production environment, maintaining synchronous evolution between the virtual and real worlds, providing a reliable foundation for strategy simulation.
[0070] S221: In the digital twin model, reinforcement learning algorithms are used to simulate and test each candidate traffic governance strategy, and an execution evaluation report for each candidate traffic governance strategy is obtained.
[0071] The implementation assessment report includes: governance success rate, hardware resource consumption, and business impact. The governance success rate can be determined based on the number of successful transactions for each service. Hardware resources include, but are not limited to, CPU, memory, and network resources. The business impact can be determined based on business influencing factors, including, but not limited to, business order volume and business access volume.
[0072] In this embodiment of the application, reinforcement learning algorithms (such as DRL algorithm) are used to simulate and test each candidate strategy in the digital twin model, simulate the performance of the governance strategy under different load conditions, predict the cascading effects that may be caused by the execution of the governance strategy, and obtain the execution evaluation report of each candidate traffic governance strategy.
[0073] In this way, by conducting simulations, an execution evaluation report can be obtained, which can intuitively demonstrate the advantages and disadvantages of traffic management strategies and avoid the risk of directly applying unverified traffic management strategies to the production environment.
[0074] S222: Based on the respective implementation evaluation reports of each candidate traffic governance strategy, determine the confidence score of each candidate traffic governance strategy.
[0075] In this embodiment of the application, the following operations are performed for each candidate traffic governance strategy: the governance success rate, hardware resource consumption and business impact included in the execution evaluation report of a candidate traffic governance strategy are weighted and summed to obtain a confidence score for the candidate traffic governance strategy.
[0076] In this embodiment, a target traffic governance strategy that meets the preset confidence score is selected from the candidate traffic governance strategies. The target traffic governance strategy that meets the preset confidence score can be the traffic governance strategy with the highest confidence score, or it can be the traffic governance strategy with a confidence score greater than the score threshold and the highest confidence score. This embodiment does not impose any restrictions on this.
[0077] Optionally, when the confidence scores of all candidate traffic governance strategies do not meet the preset confidence conditions, the adjustable parameters of each candidate traffic governance strategy are adjusted to obtain new candidate traffic governance strategies, which are then added to the existing candidate traffic governance strategies. After adding the new candidate traffic governance strategies, simulation tests are performed on each new candidate traffic governance strategy to select the target traffic governance strategy. That is, in the digital twin model, reinforcement learning algorithms are used to simulate and test each new candidate traffic governance strategy, obtaining an execution evaluation report for each new candidate traffic governance strategy. Based on the execution evaluation reports of each new candidate traffic governance strategy, the confidence score of each new candidate traffic governance strategy is determined, and the target traffic governance strategy whose confidence score meets the preset confidence conditions is selected from the new candidate traffic governance strategies.
[0078] In this way, the adjustable parameters of the governance strategy can be iteratively optimized until a stable solution is obtained. This data-driven optimization approach ensures both the scientific validity of the strategy and adaptability to constantly changing business needs.
[0079] Based on the above embodiments, see Figure 4 The diagram illustrates the logic of obtaining the target traffic governance strategy in this embodiment. A traffic governance digital twin simulation system is used to acquire the target traffic governance strategy. This system constructs a virtual mirror of the real traffic environment to pre-verify and optimize the traffic governance strategy. The system employs a closed-loop mechanism of "simulation-verification-optimization," transforming traditional trial-and-error strategy deployment into data-driven scientific decision-making, significantly improving the security and effectiveness of traffic governance.
[0080] In this embodiment of the application, after obtaining the target traffic management strategy, the target process management strategy is deployed to the production environment, and traffic management is performed using the target traffic management strategy.
[0081] In this embodiment, a three-tiered design—infrastructure layer, service layer, and business layer—achieves comprehensive traffic control from hardware resources to business logic, breaking through the traditional single-layer governance model. This allows for precise control based on the specific needs of different layers, maximizing business value while ensuring system stability. Specifically, a target traffic governance strategy is adopted to manage the traffic of the corresponding business to be governed in the business layer; the target traffic governance strategy is also adopted to manage the traffic of the corresponding services to be governed in the service layer; and the target traffic governance strategy is adopted to manage the traffic of the corresponding hardware resources to be governed in the infrastructure layer. Here, the services to be governed are those supporting the business to be governed, and the hardware resources to be governed are those supporting the services to be governed (e.g., servers). For example, if the business to be governed is a payment business, then the services to be governed include: payment services, risk control services, user services, account services, order services, etc.
[0082] In this embodiment, at the business level, scenario-based routing corresponding to the business scenario is implemented based on the target traffic governance strategy. For example, VIP user requests are directed to a dedicated service cluster, or dedicated bandwidth is allocated to payment services during promotional periods. This achieves a qualitative leap from technical availability to business optimization, enabling traffic management to truly serve business objectives.
[0083] In this embodiment, at the service level, the SLO (Service Level Agreement) achievement status is continuously tracked through dynamically loaded policy plugins (e.g., the Wasm plugin). When the service metrics of the service to be governed fluctuate, the service-layer policies in the target traffic governance strategy (e.g., intelligent degradation policies) are automatically triggered, such as temporarily shutting down non-core functions or enabling backup service nodes. This level of regulation considers both technical requirements and the dependencies between services, ensuring the continuous availability of critical service links.
[0084] In this embodiment, at the infrastructure level, kernel-level technologies (such as eBPF) are used to monitor the basic metrics of the hardware resources to be managed, such as CPU, memory, and network, in real time. When the basic metrics of the hardware resources are detected to reach a critical threshold, a millisecond-level circuit breaker mechanism is immediately triggered. For example, low-priority requests are quickly dropped when the CPU is overloaded. This low-level fast response characteristic provides the first line of defense for the system, effectively preventing global failures caused by the exhaustion of hardware resources.
[0085] Based on the above embodiments, see Figure 5 The diagram shown illustrates the logic of multi-level collaborative traffic governance in this embodiment. The infrastructure layer implements millisecond-level circuit breaking through eBPF, the service layer dynamically executes SLO policies based on the Wasm plugin, and the business layer implements scenario-based routing through the Sidecar proxy. This layered collaborative mechanism overcomes the limitations of single-layer scheduling in existing technologies, achieving full-stack adaptive control from hardware resources to business logic.
[0086] Furthermore, in this embodiment of the application, after traffic governance is performed using the target traffic governance strategy, the current feature vector and the target traffic governance strategy are associated, and the association is stored in the strategy knowledge base.
[0087] In this embodiment, if the target traffic management strategy is already stored in the strategy knowledge base, a new association relationship is added to the target traffic management strategy in the strategy knowledge base. The association relationship is the relationship between the current feature vector and the target traffic management strategy. At this time, the target traffic management strategy is associated with more than one feature vector (i.e., the current feature vector and at least one historical feature vector). If the target traffic management strategy is not stored in the strategy knowledge base, a new target traffic management strategy is added to the strategy knowledge base, and an association relationship is established between the current feature vector and the target traffic management strategy. This association relationship is stored. At this time, the target traffic management strategy is associated with only one feature vector (i.e., the current feature vector).
[0088] In this way, the strategy knowledge base supports continuous self-optimization, and updates the strategy knowledge base through feedback mechanisms to achieve iterative improvement of governance capabilities.
[0089] Furthermore, based on the same technical concept, embodiments of this application provide a traffic management device for implementing the above-described method flow of embodiments of this application. For example, see [link to relevant documentation]. Figure 6 As shown, the traffic management device 600 may include: an acquisition module 601, a first processing module 602, and a second processing module 603.
[0090] The acquisition module 601 is used to acquire the current feature vector of the business system. The current feature vector includes features in multiple dimensions, including business scenario type, service level, and expected traffic pattern. The service level represents the importance level of different services. The first processing module 602 is used to determine each candidate traffic governance strategy that matches the current feature vector based on the strategy knowledge base, wherein the strategy knowledge base is used to store each historical feature vector and the traffic governance strategy associated with each historical feature vector; The second processing module 603 is used to perform simulation tests on each candidate traffic management strategy, determine the confidence score of each candidate traffic management strategy, select the target traffic management strategy whose confidence score meets the preset confidence conditions from each candidate traffic management strategy, and use the target traffic management strategy to perform traffic management.
[0091] In an optional embodiment, when obtaining the current feature vector of the business system, the acquisition module 601 is further configured to: Obtain multi-dimensional data sources corresponding to the business system. These multi-dimensional data sources include: business logs, call chain records, and monitoring metrics. The current feature vector is obtained by semantic parsing based on multi-dimensional data sources.
[0092] In an optional embodiment, when determining each candidate traffic governance strategy matching the current feature vector based on the policy knowledge base, the first processing module 602 is further configured to: The strategy knowledge base is queried to identify historical feature vectors of each target that meet the similarity condition with the current feature vector, and the traffic governance strategies associated with each historical feature vector of the target are used as candidate traffic governance strategies.
[0093] In an optional embodiment, when performing simulation tests on each candidate traffic management strategy and determining the confidence score of each candidate traffic management strategy, the second processing module 603 is further configured to: Build a digital twin model based on actual operational data from the production environment; In the digital twin model, reinforcement learning algorithms are used to simulate and test each candidate traffic governance strategy, and an execution evaluation report for each candidate traffic governance strategy is obtained. The execution evaluation report includes: governance success rate, hardware resource consumption, and business impact. Based on the implementation evaluation reports of each candidate traffic governance strategy, a confidence score for each candidate traffic governance strategy is determined.
[0094] In an optional embodiment, the second processing module 603 is further configured to: When the confidence scores of each candidate traffic management strategy do not meet the preset confidence conditions, the adjustable parameters of each candidate traffic management strategy are adjusted to obtain new candidate traffic management strategies, and these new candidate traffic management strategies are added to the existing candidate traffic management strategies.
[0095] In an optional embodiment, when using a target traffic management strategy for traffic management, the second processing module 603 is further configured to: A target traffic management strategy is adopted to manage the traffic of the corresponding business to be managed in the business layer. A target traffic management strategy is adopted to manage the traffic of the corresponding services to be managed in the service layer. A target traffic management strategy is adopted to manage the traffic of the corresponding hardware resources to be managed in the infrastructure layer.
[0096] In an optional embodiment, after performing traffic management using a target traffic management strategy, the second processing module 603 is further configured to: Establish a relationship between the current feature vector and the target traffic governance strategy, and store the relationship in the strategy knowledge base.
[0097] Based on the description of the method and apparatus embodiments above, an exemplary embodiment of the present invention also provides an electronic device, including: at least one processor; and a memory communicatively connected to the at least one processor. The memory stores a computer program executable by the at least one processor, which, when executed by the at least one processor, causes the electronic device to perform the method according to an embodiment of the present invention.
[0098] This application also provides a non-transitory computer-readable storage medium storing a computer program, wherein the computer program, when executed by a computer's processor, is used to cause the computer to perform a method according to an embodiment of this application.
[0099] This application also provides a computer program product, including a computer program, wherein the computer program, when executed by a computer's processor, is used to cause the computer to perform a method according to an embodiment of this application.
[0100] See Figure 7 The diagram shown below illustrates the structure of an electronic device 700 that can serve as a server or client in this application, and is an example of a hardware device that can be applied to various aspects of this application. The electronic device is intended to represent various forms of digital electronic computer devices, 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 processors, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the application described and / or claimed herein.
[0101] like Figure 7 As shown, the electronic device 700 includes a computing unit 701, which can perform various appropriate actions and processes based on a computer program stored in a read-only memory (ROM) 702 or a computer program loaded from a storage unit 708 into a random access memory (RAM) 703. The RAM 703 may also store various programs and data required for the operation of the device 700. The computing unit 701, ROM 702, and RAM 703 are interconnected via a bus 704. An input / output (I / O) interface 705 is also connected to the bus 704.
[0102] Multiple components in electronic device 700 are connected to I / O interface 705, including: input unit 706, output unit 707, storage unit 708, and communication unit 709. Input unit 706 can be any type of device capable of inputting information to electronic device 700. Input unit 706 can receive input digital or character information and generate key signal inputs related to user settings and / or function control of electronic device. Output unit 707 can be any type of device capable of presenting information and may include, but is not limited to, a display, speaker, video / audio output terminal, vibrator, and / or printer. Storage unit 708 may include, but is not limited to, disk and optical disk. Communication unit 709 allows electronic device 700 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks, and may include, but is not limited to, modems, network cards, infrared communication devices, wireless communication transceivers and / or chipsets, such as Bluetooth devices, WiFi devices, worldwide interoperability for microwave access (WiMax) devices, cellular communication devices, and / or the like.
[0103] The computing unit 701 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 701 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 701 performs the various methods and processes described above. For example, in some embodiments, the above-described traffic governance methods can be implemented as computer software programs tangibly contained in a machine-readable medium, such as storage unit 708. In some embodiments, part or all of the computer program can be loaded and / or installed on the electronic device 700 via ROM 702 and / or communication unit 709. In some embodiments, the computing unit 701 can be configured to perform the above-described traffic governance methods by any other suitable means (e.g., by means of firmware).
[0104] The program code used to implement the methods of this application may be written in any combination of one or more programming languages. This program code may be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing device, such that when executed by the processor or controller, the functions / operations specified in the flowcharts and / or block diagrams are implemented. The program code may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.
[0105] In the context of this application, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, RAM, ROM, erasable programmable read-only memory (EPROM) or flash memory, optical fibers, compact disc read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0106] As used in this application, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, device, and / or apparatus (e.g., disk, optical disk, memory, programmable logic device, PLD) used to provide machine instructions and / or data to a programmable processor, including machine-readable media that receive machine instructions as machine-readable signals. The term "machine-readable signal" refers to any signal used to provide machine instructions and / or data to a programmable processor.
[0107] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device for displaying information to the user (e.g., a cathode ray tube (CRT) or liquid crystal display (LCD) monitor); and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the computer. Other types of devices can also be used to provide interaction with the user; for example, 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 sound input, voice input, or tactile input).
[0108] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or computing systems that include middleware components (e.g., application servers), or computing systems that include frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), and the Internet.
[0109] Computer systems can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. Client-server relationships are created by computer programs running on the respective computers and having a client-server relationship with each other.
[0110] Furthermore, it should be understood that the above-disclosed embodiments are merely preferred embodiments of this application and should not be construed as limiting the scope of the invention. Therefore, any equivalent variations made in accordance with the claims of this invention are still within the scope of this application.
Claims
1. A traffic management method, characterized in that, include: Obtain the current feature vector of the business system. The current feature vector includes features in multiple dimensions, including business scenario type, service level, and expected traffic pattern. The service level represents the importance level of different services. Based on the policy knowledge base, each candidate traffic governance policy that matches the current feature vector is determined, wherein the policy knowledge base is used to store each historical feature vector and the traffic governance policy associated with each historical feature vector; Simulation tests are performed on each candidate traffic management strategy to determine the confidence score of each candidate traffic management strategy. From the candidate traffic management strategies, a target traffic management strategy that meets the preset confidence conditions is selected, and the target traffic management strategy is used for traffic management.
2. The method as described in claim 1, characterized in that, The acquisition of the current feature vector of the business system includes: Obtain the multi-dimensional data source corresponding to the business system, including: business logs, call chain records, and monitoring metrics; The current feature vector is obtained by performing semantic parsing based on the multi-dimensional data source.
3. The method as described in claim 1, characterized in that, The step of determining each candidate traffic governance strategy that matches the current feature vector based on the policy knowledge base includes: The strategy knowledge base is queried to determine each target historical feature vector whose similarity to the current feature vector meets the similarity condition, and the traffic governance strategy associated with each target historical feature vector is taken as the candidate traffic governance strategy.
4. The method as described in claim 1, characterized in that, The step of performing simulation tests on each candidate traffic management strategy and determining the confidence score of each candidate traffic management strategy includes: Build a digital twin model based on actual operational data from the production environment; In the digital twin model, reinforcement learning algorithms are used to simulate and test each candidate traffic governance strategy to obtain an execution evaluation report for each candidate traffic governance strategy. The execution evaluation report includes: governance success rate, hardware resource consumption, and degree of business impact. Based on the respective implementation evaluation reports of each candidate traffic governance strategy, a confidence score for each candidate traffic governance strategy is determined.
5. The method as described in claim 4, characterized in that, The method further includes: When the confidence scores of each candidate traffic management strategy do not meet the preset confidence conditions, the adjustable parameters of each candidate traffic management strategy are adjusted to obtain each new candidate traffic management strategy, and each new candidate traffic management strategy is added to the candidate traffic management strategy.
6. The method as described in claim 1, characterized in that, The traffic management using the target traffic management strategy includes: The target traffic management strategy is used to perform traffic management on the corresponding services to be managed in the business layer. The target traffic management strategy is used to perform traffic management on the corresponding services to be managed in the service layer. The target traffic management strategy is adopted to perform traffic management on the corresponding hardware resources to be managed in the infrastructure layer.
7. The method as described in claim 1, characterized in that, After implementing traffic management using the target traffic management strategy, the process further includes: Establish a relationship between the current feature vector and the target traffic governance strategy, and store the relationship in the strategy knowledge base.
8. A flow control device, characterized in that, include: The acquisition module is used to acquire the current feature vector of the business system. The current feature vector includes features in multiple dimensions, including business scenario type, service level, and expected traffic pattern. The service level represents the importance level of different services. The first processing module is used to determine each candidate traffic governance strategy that matches the current feature vector based on the strategy knowledge base, wherein the strategy knowledge base is used to store each historical feature vector and the traffic governance strategy associated with each historical feature vector; The second processing module is used to perform simulation tests on each candidate traffic management strategy, determine the confidence score of each candidate traffic management strategy, select the target traffic management strategy whose confidence score meets the preset confidence conditions from each candidate traffic management strategy, and use the target traffic management strategy to perform traffic management.
9. An electronic device, comprising: processor; as well as Stored program memory, The program includes instructions that, when executed by the processor, cause the processor to perform the method as described in any one of claims 1-7.
10. A non-transitory computer-readable storage medium storing computer instructions, wherein, The computer instructions are used to cause the computer to perform the method according to any one of claims 1-7.