Flow control method and device, electronic device and storage medium

By determining the traffic demands of high-priority users in the network system and dynamically adjusting the traffic allocation for low-priority users using a global throttling factor, the problems of resource waste and service quality assurance for high-priority users in traditional rate limiting strategies are solved, achieving full utilization of traffic resources and a smooth transition in user experience.

CN121603448APending Publication Date: 2026-03-03HANGZHOU HIGH-TECH ZONE (BINJIANG) INSTITUTE OF BLOCKCHAIN & DATA SECURITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511896091.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-15
Publication Date
2026-03-03

AI Technical Summary

Technical Problem

Traditional rate limiting strategies cannot fully utilize network traffic resources while ensuring the quality of service for high-priority users, resulting in resource waste and a lack of guaranteed service quality for high-priority users.

Method used

By determining the traffic needs of high-priority users, allocating corresponding traffic resources, and using a global throttling factor as a dynamic adjustment coefficient, the remaining traffic is dynamically allocated to low-priority users. The global throttling factor is used to smoothly control the traffic of low-priority users, ensuring the service quality of high-priority users.

Benefits of technology

It achieves full utilization of traffic resources in the network system, ensures service quality for high-priority users, and provides a smooth service experience for low-priority users under extreme pressure, avoiding resource waste and service quality degradation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121603448A_ABST
    Figure CN121603448A_ABST
Patent Text Reader

Abstract

The invention relates to a flow control method and device, an electronic device and a storage medium, which are applied to the field of network communication, and the method comprises the following steps: in response to a received user flow request, determining a flow demand of a high-priority user in a network system; dividing the traffic corresponding to the traffic demands of the high-priority users from the total traffic of the network system, and distributing the traffic to the high-priority users; by taking the global throttling factor as a dynamic adjustment coefficient, dynamically distributing the residual flow after the network system meets the flow requirements of the high-priority users to the low-priority users; the global throttling factor is the proportion of the traffic demand of the high-priority user to the total traffic of the network system; the global throttling factor varies spatially reversely with the dynamic adjustment of the traffic allocated to the low priority users. According to the method and the device, the effect of ensuring the service quality of the high-priority users while the traffic resources in the network system are fully used is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of network communication technology, and in particular to a flow control method, apparatus, electronic device, and storage medium. Background Technology

[0002] With the improvement of network communication service quality, resource allocation for different system loads has become particularly important. How to efficiently and dynamically allocate traffic resources under varying system load conditions has become a core issue in network resource management, cloud computing, edge computing, and even 5G / 6G communication. Meanwhile, incorporating user priority into traffic resource allocation mechanisms is a key means to improve network service quality and user experience.

[0003] Traditional fixed-threshold rate limiters fail to adequately allocate idle traffic resources (such as bandwidth) to active, low-priority users when the overall system load is low, resulting in resource waste. Conversely, when the system load surges, applying a "one-size-fits-all" approach or a fixed rate-limiting strategy to all users may compromise the quality of service for high-priority users. Therefore, traditional rate-limiting strategies have significant limitations in dynamic load and multi-priority scenarios, failing to fully utilize network traffic resources while ensuring the quality of service for high-priority users.

[0004] There is currently no effective solution to the problem that traditional rate limiting strategies cannot fully utilize network traffic resources while ensuring the quality of service for high-priority users. Summary of the Invention

[0005] This embodiment provides a flow control method, apparatus, electronic device, and storage medium to address the problem that traditional flow limiting strategies cannot fully utilize the traffic resources in a network system while ensuring the quality of service for high-priority users.

[0006] Firstly, this embodiment provides a flow control method applied to a network system, the method comprising:

[0007] In response to a received user traffic request, determine the traffic demand of high-priority users in the network system;

[0008] Traffic corresponding to the traffic needs of high-priority users is allocated from the total traffic of the network system and distributed to the high-priority users.

[0009] Using a global throttling factor as a dynamic adjustment coefficient, the remaining traffic of the network system is dynamically allocated to low-priority users; the global throttling factor is the proportion of the traffic demand of high-priority users to the total traffic of the network system; the remaining traffic is the total traffic of the network system after satisfying the traffic demand of high-priority users; the smaller the global throttling factor, the greater the dynamic adjustment space for the traffic allocated to low-priority users.

[0010] In some embodiments, determining the traffic demand of high-priority users in the network system includes:

[0011] Obtain the impact magnitude corresponding to the user traffic requests of the high-priority users; the impact magnitude is determined by the current user load of the network system and the proportion of the high-priority users in the network system, representing the fluctuation range of the traffic demand of the high-priority users;

[0012] Based on the magnitude of the impact and the time allocating traffic to the high-priority users, the traffic demand of the high-priority users is determined.

[0013] In some embodiments, determining the traffic demand of the high-priority user based on the impact magnitude and the time required to allocate traffic to the high-priority user includes:

[0014] The time difference between the time of the received user traffic request from the high-priority user and the current time is used as the time for allocating traffic to the high-priority user.

[0015] Based on a preset exponential decay function, the traffic demand of the high-priority user is determined according to the time difference, the impact amplitude, and the impact decay rate of the high-priority user; the impact decay rate of the high-priority user is used to represent the strength of the network system in smoothly controlling the traffic demand of the high-priority user.

[0016] In some embodiments, the method further includes:

[0017] Calculate the ratio of the traffic demand of the high-priority users to the total traffic of the network system to obtain the traffic demand percentage;

[0018] The global throttling factor is obtained by normalizing the proportion of traffic demand.

[0019] In some embodiments, the step of dynamically allocating the remaining traffic of the network system to low-priority users using a global throttling factor as a dynamic adjustment coefficient includes:

[0020] Based on the elastic space permission ratio, the elastic traffic allocated to the low-priority user is determined; the elastic space permission ratio is used to characterize the current range of traffic allocated to the low-priority user, and the larger the global throttling factor, the smaller the elastic space permission ratio.

[0021] Based on the elastic traffic, the real-time traffic limit allocated to the low-priority user is determined;

[0022] Based on the real-time traffic limit, the remaining traffic of the network system is dynamically allocated to low-priority users.

[0023] In some embodiments, determining the elastic traffic allocated to the low-priority user based on the elastic space permission ratio includes:

[0024] The difference between the preset upper limit of traffic for the low-priority user and the preset lower limit of traffic for the low-priority user is determined.

[0025] The product of the traffic difference and the elastic space allowance ratio is used to determine the elastic traffic allocated to the low-priority user.

[0026] In some embodiments, determining the real-time traffic cap allocated to the low-priority user based on the elastic traffic includes:

[0027] The sum of the preset lower limit of traffic and the elastic traffic is used as the upper limit of real-time traffic allocated to the low-priority user.

[0028] Secondly, this embodiment provides a flow control device, which includes: a response module, a processing module, and a flow control module;

[0029] The response module is used to respond to received user traffic requests and determine the traffic needs of high-priority users in the network system.

[0030] The processing module is used to allocate traffic from the total traffic of the network system to meet the traffic demand of the high-priority user and distribute it to the high-priority user.

[0031] The flow control module is used to dynamically allocate the remaining traffic of the network system to low-priority users using a global throttling factor as a dynamic adjustment coefficient. The global throttling factor is the proportion of the traffic demand of the high-priority users to the total traffic of the network system. The remaining traffic is the total traffic of the network system after satisfying the traffic demand of the high-priority users. The smaller the global throttling factor, the greater the dynamic adjustment space for the traffic allocated to the low-priority users.

[0032] Thirdly, this embodiment provides an electronic device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the flow control method described in the first aspect above.

[0033] Fourthly, this embodiment provides a storage medium storing a computer program that, when executed by a processor, implements the flow control method described in the first aspect above.

[0034] Compared with related technologies, the traffic control method, apparatus, electronic device, and storage medium provided in this embodiment, upon receiving user traffic requests from users of different priorities, first determines the traffic resources in the network system that need to be pre-allocated to high-priority users; then, based on the proportion of traffic resources pre-allocated to high-priority users to the total traffic, it determines the global throttling factor of the current network system. Using the global throttling factor, it dynamically allocates the remaining traffic (excluding the traffic allocated to high-priority users) to low-priority users. By determining the global throttling factor based on the traffic demands of high-priority users, it smoothly manages the traffic of low-priority users, ensuring full utilization of the remaining traffic resources in the network system while prioritizing the traffic demands of high-priority users. This improves the user experience for high-priority users while ensuring service for low-priority users under extreme pressure, thus solving the problem that traditional rate limiting strategies cannot fully utilize network system traffic resources while guaranteeing the service quality for high-priority users.

[0035] Details of one or more embodiments of this application are set forth in the following drawings and description to make other features, objects and advantages of this application more readily apparent. Attached Figure Description

[0036] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:

[0037] Figure 1 This is a hardware structure block diagram of the terminal for the flow control method provided in the embodiments of this application;

[0038] Figure 2 This is a flowchart of the flow control method provided in the embodiments of this application;

[0039] Figure 3 This is a schematic diagram of a user access network system provided in an embodiment of this application;

[0040] Figure 4 This is an architecture diagram of the network system provided in this specific embodiment;

[0041] Figure 5 This is a flowchart of the adaptive shock and dynamic throttling factor update flow control method in this specific embodiment;

[0042] Figure 6 This is a structural block diagram of the flow control device provided in the embodiments of this application. Detailed Implementation

[0043] To better understand the purpose, technical solution, and advantages of this application, the application is described and illustrated below in conjunction with the accompanying drawings and embodiments.

[0044] Unless otherwise defined, the technical or scientific terms used in this application shall have the general meaning understood by one of ordinary skill in the art to which this application pertains. Words such as “a,” “an,” “an,” “the,” “the,” and “these” used in this application do not indicate quantitative limitation and may be singular or plural. The terms “comprising,” “including,” “having,” and any variations thereof used in this application are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or device that comprises a series of steps or modules (units) is not limited to the listed steps or modules (units) but may include steps or modules (units) not listed, or may include other steps or modules (units) inherent to these processes, methods, products, or devices. Words such as “connected,” “linked,” and “coupled” used in this application are not limited to physical or mechanical connections but may include electrical connections, whether direct or indirect. “Multiple” used in this application refers to two or more. “And / or” describes the relationship between related objects, indicating that three relationships may exist; for example, “A and / or B” can represent: A alone, A and B simultaneously, and B alone. Normally, the character " / " indicates that the objects before and after it are in an "or" relationship. The terms "first," "second," "third," etc., used in this application are merely to distinguish similar objects and do not represent a specific order of objects.

[0045] The method embodiments provided in this example can be executed on a terminal, computer, or similar computing device. For example, it can run on a terminal. Figure 1 This is a hardware structure block diagram of the terminal for the flow control method provided in this application embodiment. For example... Figure 1 As shown, a terminal may include one or more ( Figure 1Only one is shown in the diagram. A processor 102 and a memory 104 for storing data are also included. The processor 102 may be, but is not limited to, a microprocessor (MCU) or a programmable logic device (FPGA). The terminal may also include a transmission device 106 for communication functions and an input / output device 108. Those skilled in the art will understand that… Figure 1 The structure shown is for illustrative purposes only and does not limit the structure of the terminal described above. For example, the terminal may also include components that are larger than... Figure 1 The more or fewer components shown, or having the same Figure 1 The different configurations shown are illustrated.

[0046] The memory 104 can be used to store computer programs, such as application software programs and modules, like the computer program corresponding to the flow control method in this embodiment. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, thereby implementing the above-described method. The memory 104 may include high-speed random access memory and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include memory remotely located relative to the processor 102, and these remote memories can be connected to the terminal via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.

[0047] The transmission device 106 is used to receive or send data via a network. This network includes a wireless network provided by the terminal's communication provider. In one example, the transmission device 106 includes a Network Interface Controller (NIC), which can connect to other network devices via a base station to communicate with the Internet. In another example, the transmission device 106 can be a Radio Frequency (RF) module used for wireless communication with the Internet.

[0048] Current traffic control strategies in network systems suffer from several problems, including resource waste and poor user experience due to static rate limiting, quality of service (QoS) assurance issues for multiple user levels, smooth transitions during traffic surges, and environmental adaptability and system scalability issues.

[0049] Among them, the problems of resource waste and poor experience of static rate limiting are reflected in the following aspects: Traditional fixed threshold rate limiters cannot fully allocate idle traffic resources (such as bandwidth) to active low-priority users when the total network system load is low, resulting in resource waste; while when the network system load suddenly increases, "one-size-fits-all" or rate limiting according to fixed policies for all users may result in the inability to guarantee the quality of service (QoS) of high-priority users.

[0050] The issue of quality of service (QoS) assurance for multiple user tiers is reflected in how to dynamically reserve sufficient traffic quotas for high-tier users to cope with their sudden demands in a system with multiple user tiers (e.g., paid premium users and free regular users), while fairly and efficiently allocating these resources to lower-tier users when high-tier users have no demand.

[0051] The issue of smoothing out traffic surges manifests in the fact that when high-priority, high-traffic users suddenly enter the system, existing technologies often abruptly and drastically cut off or severely restrict traffic to low-priority users, leading to a sharp decline in user experience. Therefore, a mechanism is needed to smoothly redistribute resources based on the intensity of the surge and smoothly return resources to lower-priority users after the surge ends.

[0052] The issues of environmental adaptability and system scalability are manifested in the fact that the parameters of traditional rate limiting strategies rarely change once configured, thus failing to adapt to dynamic changes in user composition. Furthermore, proactively updating flow control configurations for a massive number of users incurs significant system overhead and latency.

[0053] To address the aforementioned traffic control issues, a counter algorithm using either a fixed or sliding window was implemented to limit the total number of traffic requests within a fixed or sliding time window. However, this method suffers from a criticality problem, potentially leading to traffic spikes exceeding the threshold within a short period at the window boundary. It also fails to effectively handle traffic spikes and offers limited support for user priorities.

[0054] To address the issue of the calculator algorithm's inability to effectively handle traffic spikes, a token bucket / leaky bucket algorithm is also implemented. The token bucket / leaky bucket algorithm adds tokens (or processes requests) to the bucket at a constant rate, smoothing out the traffic flow. However, the token generation rate and bucket capacity are typically statically configured. This results in insufficient flexibility, failing to adjust the token distribution strategy based on the real-time load of the entire system and the dynamic behavior of users with different priorities. When high-level users require significant resources, the system cannot dynamically reduce the amount of tokens issued to low-level users, and vice versa.

[0055] To address the limited support for user priorities, a priority queue method was implemented. This involves placing requests from different users into queues of different priorities, with the system processing requests from the higher-priority queues first. However, this mechanism primarily addresses the order of processing, rather than the dynamic allocation of traffic quotas. If the high-priority queue remains continuously busy, the low-priority queues may become overloaded. It does not provide a mechanism to dynamically adjust the traffic limit for low-priority users based on the "impact intensity" of high-priority users.

[0056] Therefore, existing traffic limiting schemes cannot guarantee the quality of service for high-priority users while fully utilizing traffic resources in the network system. Based on this, this application provides a proactive and smooth traffic control method that takes into account multiple priority users. Instead of allocating a passively changing "remaining traffic pool" for low-priority users, it directly updates and applies a global, dynamic "system throttling factor" to the flow control calculation logic for each low-priority user.

[0057] This embodiment provides a flow control method. Figure 2 This is a flowchart of the flow control method provided in the embodiments of this application, such as... Figure 2 As shown, the process includes the following steps:

[0058] Step S210: In response to the received user traffic request, determine the traffic demand of high-priority users in the network system.

[0059] in, Figure 3 This is a schematic diagram of a user access network system provided in an embodiment of this application. (Reference) Figure 3 The network system has a traffic resource pool. When a user accesses the network system, the network system receives the user's traffic request and needs to allocate the required traffic to the user according to the current user's traffic request. In this process, users are divided into high-priority users and low-priority users. First, based on the user traffic request of high-priority users, the current traffic demand of high-priority users is determined. That is, according to the priority order, the required traffic demand is pre-allocated to high-priority users first, so as to reserve sufficient traffic quota for high-priority users to cope with their sudden demand.

[0060] It should be noted that the user levels here do not actually include only high-priority and low-priority users, but can accept multiple levels of users. By iterating and comparing across these multiple levels, users are sorted, and adjacent levels are then classified as relatively high-priority and low-priority users. In another preferred embodiment, a priority-based traffic threshold can be set. The traffic demand corresponding to a user's traffic request is compared with the priority-based traffic threshold. Users exceeding the priority-based traffic threshold are identified as high-priority users, and users not exceeding the threshold are identified as low-priority users. There can be multiple priority-based traffic thresholds.

[0061] Step S220: Allocate traffic from the total traffic of the network system that meets the traffic needs of high-priority users to the high-priority users.

[0062] After determining the traffic needs of high-priority users, the processor allocates traffic from the traffic pool in the network system to meet the traffic needs of high-priority users, thereby reserving sufficient traffic quotas for high-priority users to cope with their sudden needs.

[0063] Step S230: Using the global throttling factor as a dynamic adjustment coefficient, the remaining traffic of the network system is dynamically allocated to low-priority users.

[0064] The global throttling factor is the proportion of traffic demand from high-priority users to the total traffic of the network system; the remaining traffic is the total traffic of the network system after satisfying the traffic demand of high-priority users; the smaller the global throttling factor, the greater the dynamic adjustment space for traffic allocated to low-priority users.

[0065] After determining the traffic demand corresponding to high-priority users, it is necessary to determine the remaining traffic in the network system's traffic pool after the traffic allocated to high-priority users. This remaining traffic can be used as the rated upper limit of traffic allocated to low-priority users, and the remaining traffic is dynamically determined based on the traffic demand of high-priority users.

[0066] After determining the remaining traffic that can be allocated to low-priority users in the current network system, a global throttling factor is determined based on the remaining traffic in the current network system to dynamically determine the real-time and accurate traffic limit for low-priority users under the current user traffic demand.

[0067] Furthermore, the global throttling factor is determined based on the proportion of high-priority users' traffic demands to the total network system traffic.

[0068] This involves calculating the ratio of traffic demand from high-priority users to the total network traffic, thus obtaining the traffic demand share. This share is then normalized to obtain a percentage of the total traffic demand. The difference between this percentage and 100% is used to determine the global throttling factor. This global throttling factor characterizes the proportion of traffic allocated to high-priority users in the current network system. A lower proportion allocated to high-priority users indicates greater dynamic adjustment space for traffic allocated to low-priority users. Therefore, a smaller global throttling factor results in greater dynamic adjustment space for traffic allocated to low-priority users; conversely, a larger global throttling factor results in less dynamic adjustment space for traffic allocated to low-priority users.

[0069] Through the above steps, when receiving traffic requests from users of different priorities, the system first determines the traffic resources that need to be pre-allocated to high-priority users. Then, based on the proportion of traffic resources pre-allocated to high-priority users to the total traffic, a global throttling factor is determined for the current network system. Using this global throttling factor, the remaining traffic (excluding that allocated to high-priority users) is dynamically allocated to low-priority users. By determining the global throttling factor based on the traffic demands of high-priority users, the system smoothly manages the traffic of low-priority users. This ensures that the remaining traffic resources in the network system are fully utilized, while prioritizing the traffic demands of high-priority users. This improves the user experience for high-priority users while ensuring service quality for low-priority users under extreme pressure, thus addressing the problem that traditional rate limiting strategies cannot fully utilize network traffic resources while guaranteeing service quality for high-priority users.

[0070] In some embodiments, step S210 determines the traffic demand of high-priority users in the network system, including steps S211 to S212.

[0071] Step S211: Obtain the impact magnitude corresponding to the user traffic requests of high-priority users; the impact magnitude is determined by the current user load of the network system and the proportion of high-priority users in the network system, representing the fluctuation range of the traffic demand of high-priority users.

[0072] After obtaining the user traffic requests from high-priority users, it is necessary to determine the impact magnitude corresponding to the traffic required by the current high-priority users.

[0073] Specifically, after the network system receives a user's traffic request, it first needs to determine the number of users currently initiating the request and, based on this number, determine the current user load of the network system. Simultaneously, it also needs to determine the proportion of high-priority users among those currently initiating traffic requests. Subsequently, using an adaptive impact attenuation model, based on the current user load of the network system, the proportion of high-priority users, and the preset adaptive gain coefficient and the basic impact magnitude for high-priority users in the model, the impact magnitude corresponding to the current high-priority user's traffic request is determined.

[0074] When the current network system receives traffic requests from high-priority users, it indicates that a traffic surge is about to occur in the network system. Therefore, it is necessary to dynamically and adaptively "attenuate" the traffic demands of high-priority users based on an adaptive surge attenuation model in order to maintain the overall stability of the network system.

[0075] Step S212: Based on the impact magnitude and the time allocating traffic to high-priority users, determine the traffic demand of high-priority users.

[0076] The process of determining the traffic demand of high-priority users based on the impact magnitude and the time for allocating traffic to them includes: using the time difference between the time of receiving a traffic request from a high-priority user and the current time as the time for allocating traffic to the high-priority user; determining the traffic demand of high-priority users based on a preset exponential decay function, according to the time difference, the impact magnitude, and the impact decay rate of high-priority users; and using the impact decay rate of high-priority users to represent the strength of the network system's smooth control over the traffic demand of high-priority users.

[0077] After determining the impact magnitude of the current high-priority users, the impact magnitude is used as the amplitude based on the pre-set exponential decay function. The traffic demand of high-priority users is calculated according to the time for traffic allocation to high-priority users in the current network system and the impact decay rate of high-priority users.

[0078] The above method can proactively and smoothly reduce the traffic demand of high-priority users, solving the problem in existing technologies where when high-priority, high-traffic users suddenly enter the system, the traffic of low-priority users is instantly and abruptly cut off or significantly restricted, leading to a precipitous drop in user experience. It is beneficial to smoothly redistribute resources according to the impact intensity of high-priority users, thus solving the problem of smooth transition of traffic impact.

[0079] In some embodiments, step S230 uses a global throttling factor as a dynamic adjustment coefficient to dynamically allocate the remaining traffic of the network system to low-priority users, including steps S231 to S232.

[0080] Step S231: Determine the elastic traffic allocated to low-priority users based on the elastic space permission ratio; the elastic space permission ratio is used to characterize the current range of traffic allocated to low-priority users. The larger the global throttling factor, the smaller the elastic space permission ratio.

[0081] Specifically, the difference between the preset upper limit and the preset lower limit of traffic for low-priority users is determined; the preset upper limit of traffic can be a preset value or determined based on the remaining traffic; the product of the traffic difference and the allowable proportion of elastic space is determined as the elastic traffic allocated to low-priority users.

[0082] After determining the global throttling factor based on the traffic demands of high-priority users in the current network system, it is necessary to determine, based on the global throttling factor, the elastic proportion range of traffic that can be allocated to low-priority users relative to the total traffic in the network system. Then, within the elastic proportion range, corresponding elastic traffic is allocated to low-priority users so that the traffic limit of low-priority users can be smoothly compressed / increased without interfering with the traffic control of high-priority users.

[0083] Furthermore, the network system defines preset lower and upper limits for traffic for low-priority users. Here, the preset upper limit for traffic for low-priority users is determined based on the remaining traffic in the network system, which is the ideal value under a relaxed environment.

[0084] Step S232: Based on elastic traffic, determine the real-time traffic limit allocated to low-priority users; according to the real-time traffic limit, dynamically allocate the remaining traffic of the network system to low-priority users. Further, the sum of the preset traffic lower limit and elastic traffic is used as the real-time traffic limit allocated to low-priority users.

[0085] After determining the available elastic traffic, the sum of the preset lower limit and the elastic traffic is used as the real-time upper limit for allocating traffic to low-priority users in the current network system. Subsequently, based on the real-time upper limit, the remaining traffic in the network system is allocated to low-priority users. This achieves full utilization of network traffic resources while ensuring the service quality for high-priority users, and provides a smooth transition for the traffic needs of low-priority users, customizing different elastic spaces for different user levels.

[0086] The present embodiment will be described and explained below through specific examples.

[0087] Traffic control in a network system is essentially a problem of traffic resource allocation; maximizing the overall satisfaction of all users is the ultimate goal. This specific embodiment uses a "proportional fairness" model as the system's optimization objective, and its utility function is defined as:

[0088] ;

[0089] Furthermore, the constraint that the total resources cannot exceed the total capacity of the network system can be expressed by the formula:

[0090] ;

[0091] Where k is the user level, It's weight. It refers to the number of active users in the network system. Let A be the average traffic limit allocated to users of this level, and A be the total system capacity. Solving this optimization problem using the Lagrange multiplier method yields the following characteristics of the optimal solution: ,in, It is the "price" of a unit of resource. This means that in an ideal static system, resources should be allocated according to weight proportions.

[0092] However, in real-world systems, especially for high-priority users with high-quality requirements, their needs are sudden and must be met first, and cannot be simply allocated proportionally to other user levels. Therefore, this specific embodiment adopts an approximate solution approach to handle this dynamic nature.

[0093] Figure 4 This is an architecture diagram of the network system provided in this specific embodiment. (Reference) Figure 4 The network system includes a central control plane and a data plane (flow actuator). The central control plane comprises an event monitor, a system status monitor, a parameter adaptive optimizer, and an impact calculator. These components work together to calculate the total impact R1(t) corresponding to the current high-priority user traffic requests, i.e., the traffic demand in the aforementioned embodiment. This means that the traffic of high-priority users is not prioritized. Instead of treating it as a variable to be optimized, its demand is viewed as a dynamic reservation of system resources, a hard constraint that must be prioritized. The total amount of this dynamic reservation is precisely the total impact R1(t) calculated through the "adaptive impact attenuation model". R1(t) accurately describes the reasonable occupation of system resources by all high-priority users at the current moment.

[0094] The central control plane in the network system also includes a throttling factor generator, a core component of the network system. It receives the total impact amount R1(t) sent by the impact calculator and calculates the global system throttling factor S(t) according to the formula below, i.e., the global throttling factor in the aforementioned embodiment. After satisfying the needs of high-priority users, the behavior of low-priority users is adjusted through a global throttling factor, rather than simply allocating "remaining resources."

[0095] The central control plane also includes a dynamic configuration center, such as Redis or ZooKeeper, used to store and broadcast the global system throttling factor S(t). The data plane (flow executor) is equipped with flow control logic points and a lazy update mechanism; the flow control logic points obtain the latest global throttling factor S(t) from the dynamic configuration center in real time, and then, combined with the user's default configuration, dynamically calculate the real-time, precise flow limit for low-priority users using the flow control method described in the above embodiments.

[0096] Through a lazy update model of "centralized computing broadcasting and edge real-time applications," the system achieves extremely high scalability. The central controller only needs to maintain a single global throttling factor, avoiding the overhead and complexity of actively pushing configurations to a massive number of clients. Traffic execution points only obtain the latest factor when processing requests, ensuring the real-time performance and low latency of the policy.

[0097] Figure 5 This is a flowchart of the adaptive shock and dynamic throttling factor update flow control method in this specific embodiment, as shown below. Figure 5 As shown, the method includes the following steps:

[0098] Step S510: Determine the global throttling factor based on user traffic demand.

[0099] Specifically, the total system capacity of the network system is set to A. When a user traffic request is received, it is processed through... Figure 4 The components such as the event monitor, system status monitor, parameter adaptive optimizer, and impact calculator in the network system calculate the total impact R1(t) corresponding to the user traffic requests of the current high-priority users based on the current user load of the network system and the proportion of low-priority users in the network system. The total demand (dynamic reservation) of high-priority users is then set as R1(t).

[0100] The global throttling factor can then be calculated. The global throttling factor is the proportion of traffic demand from high-priority users to the total network system capacity; that is, the proportion of "throttling" achieved by the system to ensure high-priority service. Global Throttling Factor It can be represented as:

[0101] ;

[0102] To ensure this global throttling factor The stability of the global throttling factor is crucial; its proportion cannot exceed 100%. Normalization and amplitude limiting are applied; expressed by the formula:

[0103] ;

[0104] in, This global throttling factor quantifies the system's load pressure. When the global throttling factor is 0, it means that the current network system has no high-priority user traffic demand pressure and is in a completely relaxed state; when the global throttling factor is 1, it means that the current network system's traffic resources have been completely occupied by high-priority users, and it is in a peak pressure state.

[0105] Step S520: Determine the real-time upper limit for low-priority users.

[0106] Specifically, the global throttling factor is a control indicator that directly reflects the "stress level" of the system, and its goal is to proactively update the flow control logic for low-priority users. Additionally, upper and lower bounds are defined for the behavior of low-priority users, representing the default flow limit under relaxed conditions. This represents the minimum basic guarantee limit under extreme pressure. The default traffic limit here is the same as the traffic limit preset for low-priority users in the aforementioned embodiments, and the basic guarantee lower limit here is the same as the traffic lower limit preset for low-priority users in the aforementioned embodiments.

[0107] Set the default traffic limit and the lower limit of basic protection The difference between As the current low-priority users, the elastic traffic space can be allocated and controlled by the network system. At the same time, the proportion of this elastic traffic space that is allowed to occupy is determined by the global throttling factor, i.e., the elastic space permission ratio.

[0108] For example, when the network system has no high-priority user traffic demand, the global throttling factor is 0, and the elastic space allowance ratio is... At this point, low-priority users can obtain the full elasticity; when the traffic demand pressure of high-priority users in the network system is... At that time, the allowable ratio of flexible space is Therefore, at any time t, the elastic traffic available to low-priority users can be expressed as: .

[0109] Adding the calculated elastic flow rate to the constant baseline guarantee yields the final real-time flow rate ceiling. This can be expressed as a formula:

[0110] ;

[0111] in, This indicates the default traffic limit for low-priority users and This indicates the minimum basic guarantee for low-priority users; This represents the global throttling factor.

[0112] In a preferred embodiment, the network system sequentially receives user traffic requests from two high-priority users (VIP users) and two low-priority users (free users).

[0113] Given a total network traffic A of 10000 RPS, the baseline impact magnitude for VIP users in the adaptive attenuation model is... 500 RPS; adaptive gain coefficient of 2000; user surge attenuation rate b1 for VIP users is 0.1; default traffic limit for free users. 100 RPS, minimum basic guarantee It is 5 RPS.

[0114] In the initial state, i.e., during time period T0, only free users Free_A and Free_B are active in the system. At this time, the central control plane calculates the total surge volume, i.e., the traffic demand, for high-priority users. At this time, the global throttling factor Free user Free_A initiates a user traffic request, and its real-time traffic limit is calculated to be:

[0115] .

[0116] During time period T1, the first VIP user (VIP_A) connects to the network system. At this time, VIP_A initiates a high-traffic task, triggering event 1. The total load on the network system at this time is: Free user ratio: .

[0117] Subsequently, the parameter adaptive optimizer calculates the initial impact magnitude for event 1:

[0118] .

[0119] The impact calculator calculates the total impact amount:

[0120] .

[0121] The central control plane updates the global throttling factor S(T1):

[0122] S(T1)=860 / 10000=0.086.

[0123] When a regular user Free_B initiates a request, its flow control logic obtains the global throttling factor S(T1) = 0.086 and calculates the real-time traffic limit for the regular user Free_B:

[0124] .

[0125] At this point, the limit for free users was lowered for the first time.

[0126] During time period T2, a second VIP user (VIP_B) connects to the network system. At this time, VIP_B initiates a high-traffic task, triggering event 2. When T2 = T1 + 5 seconds, the network system load further increases. The total load on the network system at this point is: Free user ratio: .

[0127] First, the impact calculator uses a preset exponential decay function. Update the decayed impact of event 1:

[0128] ;

[0129] Subsequently, the parameter adaptive optimizer calculates the independent impact magnitude for the new event 2:

[0130] ;

[0131] At this point, the total impact in the system This is a superposition of event 1 and event 2:

[0132] ;

[0133] Subsequently, the central control plane updates the throttling factor. :

[0134] .

[0135] Free_A initiates another request, and its flow control logic obtains S(T2)=0.16616 to calculate the real-time traffic limit for ordinary user Free_A:

[0136] .

[0137] It can be seen that free users are subject to further throttling due to the increase in VIP users.

[0138] During time interval T3, T3 = T2 + 10 seconds = T1 + 15 seconds, assuming no user triggers a new event. The impact calculator uses a preset exponential decay function. Update the decayed impact of events 1 and 2. and :

[0139] ;

[0140] .

[0141] At this point, the total impact decreases accordingly: .

[0142] The central control plane updates the throttling factor S(T3) = 611.3 / 10000 = 0.06113.

[0143] If a regular user Free_B initiates a request, its flow control logic obtains S(T3) = 0.06113, and the upper limit smoothly increases, resulting in the real-time traffic limit. for:

[0144] .

[0145] By employing the above method, a global "throttling factor" is used to proactively and directly update the flow control formula affecting each user, providing precise control over the user experience. By adjusting the default upper limit and the basic lower limit, different "elasticity spaces" can be customized for users of different levels, ensuring a high-quality user experience while also guaranteeing that low-quality users can still receive dignified, non-zero service under extreme pressure.

[0146] It should be noted that the steps shown in the above process or in the flowcharts in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions.

[0147] This embodiment also provides a flow control device for implementing the above embodiments and preferred embodiments; details already described will not be repeated. The terms "module," "unit," "subunit," etc., used below refer to combinations of software and / or hardware that implement a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.

[0148] Figure 6 This is a structural block diagram of the flow control device provided in the embodiments of this application, such as... Figure 6 As shown, the device includes a response module 10, a processing module 20, and a flow control module 30.

[0149] The response module 10 is used to respond to received user traffic requests and determine the traffic needs of high-priority users in the network system.

[0150] The processing module 20 is used to allocate traffic from the total traffic of the network system to meet the traffic needs of high-priority users and distribute it to high-priority users.

[0151] The flow control module 30 is used to dynamically allocate the remaining traffic of the network system to low-priority users using a global throttling factor as a dynamic adjustment coefficient. The global throttling factor is the proportion of the traffic demand of high-priority users to the total traffic of the network system. The remaining traffic is the total traffic of the network system after satisfying the traffic demand of high-priority users. The smaller the global throttling factor, the greater the dynamic adjustment space for the traffic allocated to low-priority users.

[0152] It should be noted that the above modules can be functional modules or program modules, and can be implemented through software or hardware. For modules implemented through hardware, the above modules can reside in the same processor; or the above modules can be located in different processors in any combination.

[0153] This embodiment also provides an electronic device including a memory and a processor, the memory storing a computer program and the processor being configured to run the computer program to perform the steps in any of the above method embodiments.

[0154] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor and the input / output device is connected to the processor.

[0155] Optionally, in this embodiment, the processor can be configured to perform the following steps via a computer program:

[0156] S1, in response to a received user traffic request, determines the traffic needs of high-priority users in the network system.

[0157] S2 allocates traffic from the total network traffic to meet the traffic needs of high-priority users and distributes it to them.

[0158] S3 uses a global throttling factor as a dynamic adjustment coefficient to dynamically allocate the remaining traffic of the network system to low-priority users. The global throttling factor is the proportion of the traffic demand of high-priority users to the total traffic of the network system. The remaining traffic is the total traffic of the network system after satisfying the traffic demand of high-priority users. The smaller the global throttling factor, the greater the dynamic adjustment space for the traffic allocated to low-priority users.

[0159] It should be noted that the specific examples in this embodiment can refer to the examples described in the above embodiments and optional implementations, and will not be repeated in this embodiment.

[0160] Furthermore, in conjunction with the flow control methods provided in the above embodiments, this embodiment can also provide a storage medium for implementation. The storage medium stores a computer program; when executed by a processor, the computer program implements any of the flow control methods described in the above embodiments.

[0161] It should be understood that the specific embodiments described herein are merely illustrative of the application and not intended to limit it. All other embodiments derived by those skilled in the art based on the embodiments provided in this application without inventive effort are within the scope of protection of this application.

[0162] Obviously, the accompanying drawings are merely some examples or embodiments of this application. Those skilled in the art can apply this application to other similar situations based on these drawings without any creative effort. Furthermore, it is understood that although the work done in this development process may be complex and lengthy, for those skilled in the art, certain design, manufacturing, or production modifications made based on the technical content disclosed in this application are merely conventional technical means and should not be considered as insufficient disclosure of this application.

[0163] The term "embodiment" in this application refers to a specific feature, structure, or characteristic described in connection with an embodiment that may be included in at least one embodiment of this application. The appearance of this phrase in various places in the specification does not necessarily imply the same embodiment, nor does it imply that it is mutually exclusive with or independent of other embodiments. It will be clearly or implicitly understood by those skilled in the art that the embodiments described in this application may be combined with other embodiments without conflict.

[0164] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of patent protection. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the appended claims.

Claims

1. A flow control method, characterized in that, The method is applied to a network system, and the method includes: In response to a received user traffic request, determine the traffic demand of high-priority users in the network system; Traffic corresponding to the traffic needs of high-priority users is allocated from the total traffic of the network system and distributed to the high-priority users. Using a global throttling factor as a dynamic adjustment coefficient, the remaining traffic of the network system is dynamically allocated to low-priority users; the global throttling factor is the proportion of the traffic demand of high-priority users to the total traffic of the network system; the remaining traffic is the total traffic of the network system after satisfying the traffic demand of high-priority users; the smaller the global throttling factor, the greater the dynamic adjustment space for the traffic allocated to low-priority users.

2. The flow control method according to claim 1, characterized in that, Determining the traffic demand of high-priority users in the network system includes: Obtain the impact magnitude corresponding to the user traffic requests of the high-priority users; the impact magnitude is determined by the current user load of the network system and the proportion of the high-priority users in the network system, representing the fluctuation range of the traffic demand of the high-priority users; Based on the magnitude of the impact and the time allocating traffic to the high-priority users, the traffic demand of the high-priority users is determined.

3. The flow control method according to claim 2, characterized in that, The process of determining the traffic demand of high-priority users based on the impact magnitude and the time allocating traffic to them includes: The time difference between the time of the received user traffic request from the high-priority user and the current time is used as the time for allocating traffic to the high-priority user. Based on a preset exponential decay function, the traffic demand of the high-priority user is determined according to the time difference, the impact amplitude, and the impact decay rate of the high-priority user; the impact decay rate of the high-priority user is used to represent the strength of the network system in smoothly controlling the traffic demand of the high-priority user.

4. The flow control method according to any one of claims 1 to 3, characterized in that, The method further includes: Calculate the ratio of the traffic demand of the high-priority users to the total traffic of the network system to obtain the traffic demand percentage; The global throttling factor is obtained by normalizing the proportion of traffic demand.

5. The flow control method according to claim 4, characterized in that, The method of dynamically allocating the remaining traffic of the network system to low-priority users using a global throttling factor as a dynamic adjustment coefficient includes: Based on the elastic space permission ratio, the elastic traffic allocated to the low-priority users is determined; the elastic space permission ratio is used to characterize the current range of traffic allocated to the low-priority users; the larger the global throttling factor, the smaller the elastic space permission ratio. Based on the elastic traffic, the real-time traffic limit allocated to the low-priority user is determined; Based on the real-time traffic limit, the remaining traffic of the network system is dynamically allocated to low-priority users.

6. The flow control method according to claim 5, characterized in that, The step of determining the elastic traffic allocated to the low-priority users based on the elastic space permission ratio includes: The difference between the preset upper limit of traffic for the low-priority user and the preset lower limit of traffic for the low-priority user is determined. The product of the traffic difference and the elastic space allowance ratio is used to determine the elastic traffic allocated to the low-priority user.

7. The flow control method according to claim 6, characterized in that, The determination of the real-time traffic limit allocated to the low-priority user based on the elastic traffic includes: The sum of the lower limit of traffic and the elastic traffic is used as the upper limit of real-time traffic allocated to the low-priority user.

8. A flow control device, characterized in that, The device includes: a response module, a processing module, and a flow control module; The response module is used to respond to received user traffic requests and determine the traffic needs of high-priority users in the network system. The processing module is used to allocate traffic from the total traffic of the network system to meet the traffic demand of the high-priority user and distribute it to the high-priority user. The flow control module is used to dynamically allocate the remaining traffic of the network system to low-priority users using a global throttling factor as a dynamic adjustment coefficient. The global throttling factor is the proportion of the traffic demand of the high-priority users to the total traffic of the network system. The remaining traffic is the total traffic of the network system after satisfying the traffic demand of the high-priority users. The smaller the global throttling factor, the greater the dynamic adjustment space for the traffic allocated to the low-priority users.

9. An electronic device comprising a memory and a processor, characterized in that, The memory stores a computer program, and the processor is configured to run the computer program to perform the flow control method according to any one of claims 1 to 7.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the flow control method according to any one of claims 1 to 7.