Traffic scheduling method and device, computer equipment, storage medium and program product
By dynamically adjusting the load balancing mode at the data processing unit on the sending end, the problem of load balancing in the prior art cannot avoid congestion and save resources is solved, and the bandwidth utilization rate and server resources are improved.
Patent Information
- Application Number
- CN202510826679.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-19
- Publication Date
- 2025-09-02
AI Technical Summary
Existing load balancing technologies cannot save server resources while avoiding congestion, resulting in poor network performance.
The data processing unit on the sending side analyzes the packet characteristics and the link status information feedback from the switch, dynamically adds classification marks to realize the coexistence of the current-drift and packet-by-packet modes, and adjusts the load balancing mode according to the network congestion situation.
Improve bandwidth utilization, avoid network congestion, save server resource overhead, and realize flexible load balancing.
Smart Images

Figure CN120583047A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of network resource management, and in particular to a traffic scheduling method, apparatus, computer equipment, storage medium, and program product. Background Art
[0002] Load balancing significantly impacts the effective bandwidth of a network and is the most critical issue affecting the performance of current intelligent computing network systems. There are two main types of load balancing technologies: per-flow and per-packet. Per-flow uses five-tuple equal-cost multi-paths, which is prone to hash conflicts. Per-packet load balancing can improve network utilization, but is complex to implement and is more sensitive to path latency, packet loss, and out-of-order traffic. In per-packet multi-path scenarios, congestion spreads, impacting other tasks.
[0003] Therefore, the current load balancing technology cannot save server resources while avoiding congestion, and the load balancing effect is not ideal. Summary of the Invention
[0004] Based on this, it is necessary to provide a traffic scheduling method, device, computer equipment, computer-readable storage medium and computer program product to address the above technical problems.
[0005] In a first aspect, the present application provides a traffic scheduling method, which is applied to a data processing unit at a sending end, and the method includes:
[0006] Acquiring message characteristics of a message to be sent; the message characteristics include message size, protocol type and / or service priority;
[0007] Obtain link status information fed back by the switch;
[0008] Adding a classification tag to the message based on the message characteristics and the link state information; the classification tag is one of multiple preset classification tags;
[0009] The message carrying the classification mark is sent to the switch; different classification marks are used to instruct the switch to select different load balancing modes to send the message; the different load balancing modes include at least a flow-by-flow mode and a packet-by-packet mode.
[0010] In one embodiment, the adding a classification tag to the message based on the message characteristics and the link state information includes:
[0011] In response to an increase in the network congestion level represented by the link state information, increasing the proportion of messages marked with the first classification mark based on the message characteristics;
[0012] In response to a decrease in the network congestion level represented by the link state information, reducing the proportion of messages marked with the first classification mark based on the message characteristics;
[0013] The first classification mark is used to instruct the switch to select a packet-by-packet mode to send the message.
[0014] In one embodiment, in response to an increase in the network congestion level represented by the link state information, increasing the proportion of the packets marked with the first classification mark based on the packet characteristics includes:
[0015] In response to an increase in the network congestion level represented by the link state information, the packet cutting size threshold is lowered, and a first classification mark is added to packets whose size is greater than the packet cutting size threshold.
[0016] In one embodiment, in response to a decrease in the network congestion level represented by the link state information, reducing the proportion of the packets marked with the first classification mark based on the packet characteristics includes:
[0017] In response to a decrease in the network congestion level represented by the link state information, the packet cutting size threshold is increased, and a first classification mark is added to packets whose sizes are larger than the packet cutting size threshold.
[0018] In one embodiment, the adding a classification tag to the message based on the message characteristics and the link state information further includes:
[0019] When the network congestion level represented by the link state information is lower than a first preset congestion level, adding a second classification tag to a message whose message characteristics meet a first preset condition; the first preset condition includes belonging to a target protocol type and / or belonging to a target service priority;
[0020] The second classification tag is used to instruct the switch to select a flow-by-flow mode to send the message.
[0021] In one embodiment, the adding a classification tag to the message based on the message characteristics and the link state information further includes:
[0022] When the network congestion level represented by the link state information is lower than a second preset congestion level, a third classification mark is added to a message whose message characteristics meet a second preset condition; the second preset condition includes that the message size is greater than a packet cutting size threshold and belongs to a target protocol type and / or belongs to a target service priority; and the packet cutting size threshold is negatively correlated with the network congestion level represented by the link state information;
[0023] The third classification tag is used to instruct the switch to select one of a flow-by-flow mode and a packet-by-packet mode to send the message.
[0024] In one embodiment, the method further comprises:
[0025] Determining a packet cutting coefficient based on the link state information; wherein the packet cutting coefficient is negatively correlated with the degree of network congestion represented by the link state information;
[0026] The packet cutting size threshold is determined based on the packet cutting coefficient and a preset reference packet cutting size.
[0027] In one embodiment, sending the data packet carrying the classification tag to the switch includes:
[0028] In response to an increase in the network congestion level represented by the link state information, sending the message carrying the classification tag to the switch at a first sending rate that is lower than the current sending rate;
[0029] In response to a decrease in the network congestion level represented by the link state information, the message carrying the classification tag is sent to the switch at a second sending rate that is greater than the current sending rate.
[0030] In a second aspect, the present application further provides a traffic scheduling device, which is applied to a data processing unit of a sending end, and the device includes:
[0031] A feature extraction module, configured to obtain message features of a message to be sent; the message features include message size, protocol type, and / or service priority;
[0032] Link information acquisition module, used to obtain link status information fed back by the switch;
[0033] a marking module, configured to add a classification mark to the message based on the message characteristics and the link state information; the classification mark being one of a plurality of preset classification marks;
[0034] The sending module is used to send the data packet carrying the classification mark to the switch; different classification marks are used to instruct the switch to select different load balancing modes to send the message; the different load balancing modes include at least flow-by-flow mode and packet-by-packet mode.
[0035] In a third aspect, the present application further provides a computer device comprising a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of any of the aforementioned methods when executing the computer program.
[0036] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, which implements the steps of any of the aforementioned methods when executed by a processor.
[0037] In a fifth aspect, the present application also provides a computer program product, comprising a computer program, which implements the steps of any of the aforementioned methods when executed by a processor.
[0038] In the above-mentioned traffic scheduling method, apparatus, computer device, computer-readable storage medium, and computer program product, a data processing unit at the sending end analyzes the message characteristics of the message to be sent and obtains the link status information fed back by the switch; based on the message characteristics and the link status information of the network, a corresponding classification tag is added to the message to be sent; the classification tag is one of multiple preset classification tags; a data packet carrying the classification tag is sent to the switch, and by adding different classification tags, the switch is instructed to select different load balancing modes to send the message; wherein the different load balancing modes include at least a per-flow mode and a per-packet mode. Since the data processing unit at the sending end adds analysis and judgment to the message to be sent based on the link status information of the network, and adaptively adds the corresponding classification tag, and sends the data packet carrying the classification tag to the switch, not only can the coexistence of the per-packet forwarding mode and the per-flow forwarding mode be achieved in the network, but also the marking strategy for the message can be dynamically adjusted in combination with the network congestion situation, and different load balancing modes can be used to forward the message under different network congestion situations, effectively improving bandwidth utilization, effectively avoiding network congestion, and saving server resource overhead in the network. BRIEF DESCRIPTION OF THE DRAWINGS
[0039] In order to more clearly illustrate the technical solutions in the embodiments of the present application or related technologies, the following briefly introduces the drawings required for use in the embodiments of the present application or related technical descriptions. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying any creative work.
[0040] Figure 1 This is an application environment diagram of a traffic scheduling method in one embodiment;
[0041] Figure 2 Schematic diagram of a flow chart of a traffic scheduling method in one embodiment;
[0042] Figure 3 is a schematic diagram of an intelligent scheduling engine of a data processing unit in one embodiment;
[0043] Figure 4 is a flow chart of a traffic scheduling method according to another embodiment;
[0044] Figure 5 is a structural block diagram of a traffic scheduling device in one embodiment;
[0045] Figure 6 FIG. 1 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0046] In order to make the purpose, technical solutions and advantages of this application more clear, the following further describes this application in detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.
[0047] It should be noted that the terms "first", "second", etc. used in this application may be used to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish the first element from the second element. The terms "including" and "having" used in this application and any variations thereof are intended to cover non-exclusive inclusions. The term "plurality" used in this application refers to two or more. The term "and / or" used in this application refers to one of the solutions or any combination of multiple solutions.
[0048] To ensure effective communication bandwidth, load balancing technology has been introduced in current intelligent computing networks. Load balancing means balancing and distributing the load (work tasks) across multiple operating units, such as FTP (File Transfer Protocol) servers, web servers, core enterprise application servers, and other key task servers, to collaboratively complete workloads. Load balancing is categorized into local load balancing and global load balancing (also called regional load balancing) based on the geographic structure of its application. Local load balancing targets a local server cluster, while global load balancing targets server clusters in different geographic locations and network structures. Network load balancing refers to traffic load sharing, ensuring even distribution of traffic across links, improving bandwidth utilization, and preventing congestion.
[0049] ECMP (Equal-Cost Multipath Routing) is a network environment where multiple different links exist to reach the same destination address. If traditional routing technology is used, the data packets sent to the destination address can only use one of the links, and the other links are in backup or invalid state. In addition, switching between them in a dynamic routing environment requires a certain amount of time. The equal-cost multipath routing protocol can use multiple links simultaneously in this network environment, which not only increases the transmission bandwidth, but also can back up the data transmission of the failed link without delay and packet loss.
[0050] Load balancing technology is the most critical issue affecting the performance of current intelligent computing network systems. Because the completion time of collective operation communications is determined by the completion time of the slowest node, load imbalance can reduce the effective bandwidth of conflicting flows and significantly degrade the transmission time of conflicting flows. Traditionally, there are two mainstream load balancing technologies: per-flow and per-packet. Per-flow uses five-tuple equal-cost multipath routing, distributing data flows across multiple equal-cost paths using a hashing algorithm. This is prone to hash collisions (a phenomenon in which different input data yield the same hash value after being hashed, for example, two different five-tuples are hashed and assigned to the same link). While per-packet load balancing can improve network utilization, its implementation is complex. Each packet carries an address for forwarding, requiring switches to spray multiple paths. This approach also suffers from low robustness and a limited out-of-order receive window. Therefore, per-packet load balancing is more sensitive to increased path latency, packet loss, and out-of-order routing. In addition, it is difficult to achieve the coexistence of multiple load balancing technologies in traditional intelligent computing networks, such as flow-by-flow and packet-by-packet. The end-side equipment cannot identify based on the message, and either forwards it flow-by-flow or splits it all and forwards it packet-by-packet. The two methods cannot coexist, making it difficult to avoid congestion from the root while effectively saving server processing resources.
[0051] The present application proposes an end-to-end network collaborative intelligent traffic scheduling method based on a data processing unit. On the sending end side, the data processing unit analyzes and judges the messages to be sent according to the link status information of the network, and adds corresponding classification tags to achieve the coexistence of the network packet-by-packet forwarding mode and the flow-by-flow forwarding mode. In addition, this classification tag forwarding mechanism can also dynamically adjust the message marking strategy and sending rate based on the link status information fed back by the switch, effectively improving bandwidth utilization and flexibly realizing rapid forwarding of traffic.
[0052] The traffic scheduling method provided in the embodiment of the present application can be applied to Figure 1 In the application environment shown, the transmitting-end data processing unit 100 (DPU) is communicatively connected to the local Leaf switch 200 (also referred to as the transmitting-end switch), which is in turn communicatively connected to the spine switch 300. The spine switch 300 is also communicatively connected to the remote Leaf switch 400 (also referred to as the receiving-end switch), which is in turn communicatively connected to the receiving-end data processing unit 500. The transmitting-end data processing unit 100 and the receiving-end data processing unit 500 may include a data storage system that can store messages to be sent or received messages.
[0053] Among them, the data processing unit is a new generation of processor for data-centric computing, integrating complete data center functions on a single chip. Together with the CPU (Central Processing Unit) and GPU (Graphics Processing Unit), it constitutes the three pillars of new computing. The DPU focuses on high-speed forwarding and processing of the data plane, and the CPU is responsible for logical decision-making on the control plane to offload data processing tasks from the general-purpose CPU, thereby improving network performance, reducing latency and optimizing resource utilization.
[0054] The sending end data processing unit and the receiving end data processing unit are relative based on the sending and receiving scenarios. In other sending and receiving scenarios, the sending end data processing unit and the receiving end data processing unit can also interchange roles. The sending end and the receiving end can be terminals or servers in the network.
[0055] Among them, the Leaf switches and Spine switches form a tree topology. The Spine switch is usually a core network device and is responsible for forwarding traffic across the Leaf switches. Figure 1 As shown, when the link at the receiving end is at risk of congestion, the remote Leaf switch 400 can quickly send a congestion perception message to the Leaf switch 200 at the sending end, and the Leaf switch 200 at the sending end then passes it to the sending end data processing unit 100, thereby achieving end-to-end collaboration.
[0056] In an exemplary embodiment, Figure 2 As shown, a traffic scheduling method is provided, which is applied to Figure 1 The data processing unit 100 on the sending end side is used as an example to illustrate the process, which includes the following steps S201 to S204.
[0057] Step S201: Acquire message features of a message to be sent; the message features include message size, protocol type and / or service priority.
[0058] The DPU on the sending end uses a preset artificial intelligence model to extract the message characteristics of the message to be sent in real time, such as protocol type, message size, and service priority. By identifying the message characteristics, it can determine whether the current message to be sent belongs to a real-time control flow, batch data flow, heartbeat / keep-alive flow, emergency time flow, or large message data flow. Based on the message feature identification results, different classification tags can be added to different messages.
[0059] Step S202: Acquire link status information fed back by the switch.
[0060] The link status information fed back by the switch includes the first link status information fed back by the local switch and the second link status information fed back by the remote switch. The local switch can be understood as the switch directly connected to the sender, and the remote switch can be understood as the switch indirectly connected, for example Figure 1 Leaf switch 200 is a local switch, and Leaf switch 400 is a remote switch.
[0061] The first link state information and the second link state information represent the local and remote link load conditions, respectively. In some exemplary embodiments, the link state information may include one or more of a send-receive ratio, a packet loss rate, a ratio of packets marked as lightly congested, and the number of congestion events that occurred within a preset time period.
[0062] Exemplarily, the DPU on the transmitting end side may monitor the link status information synchronized between the local switch and the remote switch through a preset perception module.
[0063] Step S203: adding a classification tag to the message to be sent based on the message characteristics of the message to be sent, the resource status information of the sender, and the link status information of the network; the classification tag is one of multiple preset classification tags.
[0064] The various preset classification marks may be numerical marks, character marks, or numerical and character combination marks, such as classification marks such as 0x1, 0x2, and 0x3.
[0065] Furthermore, the classification markings assigned to outgoing packets when the network's link state information indicates a high level of network congestion can differ from the classification markings assigned to outgoing packets when the network's link state information indicates a low level of network congestion. For example, when network congestion is high, more packets can be marked with classification markings corresponding to packet-by-packet forwarding, while when network congestion is low, fewer packets can be marked with classification markings corresponding to packet-by-packet forwarding. Dynamically adjusting the classification markings of outgoing packets in this manner allows for adaptive adaptation to network congestion.
[0066] In one embodiment, since the resource status information of the sending end can represent the resource load situation of the sending end, correspondingly, the DPU on the sending end side can also obtain the resource status information of the sending end, such as obtaining one or more of the CPU or memory utilization, link bandwidth occupancy, and queue depth of the sending end, and jointly decide on the classification tag of the message based on the resource status information of the sending end and the link status information of the network.
[0067] Step S204: Send the message carrying the classification tag to the switch; different classification tags are used to instruct the switch to select different load balancing modes to send the current message; different load balancing modes include at least a per-flow mode and a per-packet mode.
[0068] In some embodiments, each classification tag may correspond to tag description information, a switch load balancing mode, and a data processing mode of the receiving end. The correspondence between them may be pre-configured. Based on this correspondence, after the subsequent switch and the receiving end receive the message, they may quickly determine the forwarding strategy or data processing strategy of the current message according to the classification tag.
[0069] Based on the traffic scheduling method of the above embodiment, since the data processing unit on the sending end side analyzes and judges the message to be sent according to the link status information fed back by the switch, and adaptively adds the corresponding classification tag, the data packet carrying the classification tag is sent to the switch, thereby not only achieving the coexistence of the network packet-by-packet forwarding mode and the flow-by-flow forwarding mode, but also dynamically adjusting the message marking strategy in combination with the network congestion situation, using different load balancing modes to forward messages under different network congestion situations, effectively improving bandwidth utilization, effectively avoiding network congestion and saving server resource overhead in the network.
[0070] In some embodiments, the step 202 mentioned above, adding a classification tag to the message based on the message characteristics and link state information, may specifically include:
[0071] In response to an increase in the level of network congestion represented by the link status information, based on the identified message characteristics, the proportion of messages to be sent marked with the first classification mark is increased; in response to a decrease in the level of network congestion represented by the link status information of the network, based on the message characteristics, the proportion of messages to be sent marked with the first classification mark is reduced; the first classification mark is used to instruct the switch to select a packet-by-packet mode to forward the message.
[0072] In a related embodiment, when the level of network congestion represented by the link state information rises to a set congestion threshold, and the resource state information of the current sender indicates that the sender has idle resources (CPU resources or storage resources, etc.), then based on the identified message characteristics, the proportion of messages to be sent marked with the first classification mark is increased to alleviate network congestion. Correspondingly, when the level of network congestion represented by the link state information decreases to another set congestion threshold, or the resource state information of the current sender indicates that the resource occupancy rate of the sender is higher than the set threshold, then based on the identified message characteristics, the proportion of messages to be sent marked with the first classification mark is reduced to alleviate the resource overhead of the sender. In addition, when the resource occupancy rate of the sender reaches a higher level, it is also possible to stop marking the messages to be sent with the first classification mark, thereby suspending the sending of messages in packet-by-packet mode and quickly alleviating the resource overhead of the sender.
[0073] In this way, when the network congestion is high, the number of messages sent using the packet-by-packet mode increases, and when the network congestion is low, the number of messages sent using the packet-by-packet mode decreases. This can avoid network congestion while taking into account the data processing resource overhead at the sending end, and then take into account the data processing resource overhead at the receiving end.
[0074] In one embodiment, in packet-by-packet forwarding mode, large message packets can be split into independent small message packets based on a predetermined packet splitting size threshold. Specifically, when the packet size of a message exceeds the packet splitting size threshold, the message can be considered a large message and split. Therefore, the packet splitting size threshold determines which messages are likely to be split as large messages.
[0075] Based on this, in one embodiment, the aforementioned embodiment, in response to an increase in the level of network congestion represented by the link status information, increases the proportion of messages marked with the first classification mark based on message characteristics, which may specifically include: in response to an increase in the level of network congestion represented by the link status information fed back by the switch, lowers the packet cutting size threshold, and adds the first classification mark to messages whose size is greater than the packet cutting size threshold.
[0076] Correspondingly, in a related embodiment, in response to a decrease in the level of network congestion represented by the link status information, the aforementioned embodiment reduces the proportion of messages marked as the first classification mark based on message characteristics, which may specifically include: in response to a decrease in the level of network congestion represented by the link status information fed back by the switch, increasing the packet cutting size threshold, and adding the first classification mark to messages whose size is greater than the packet cutting size threshold.
[0077] Through the above embodiment, the data processing unit at the sending end can, based on the link status information fed back by the switch on the sending end side and the switch on the receiving end side, adaptively reduce the packet cutting size threshold when the congestion level represented by the link status information increases, so that more messages are identified as large message messages, thereby increasing the proportion of messages classified and marked as the first classification mark; when the congestion level represented by the link status information decreases, the packet cutting size threshold can be adaptively increased, so that fewer messages are identified as large message messages, thereby reducing the proportion of messages classified and marked as the first classification mark. By dynamically adjusting the packet cutting size threshold based on the link status information fed back by the switch, the classification mark of the message can be adapted to the current congestion situation, thereby achieving flexible scheduling of network bandwidth resources and server resources.
[0078] Based on the traffic scheduling method of the present application, it is possible to achieve the coexistence of multiple load balancing modes. Correspondingly, the data processing unit at the sending end can add different classification tags to the message to be sent based on the network situation, so that when the switch receives the message, it can select the corresponding load balancing mode to forward the message based on the classification tag carried by the message. In addition to the aforementioned addition of the first classification tag, in one embodiment, the data processing unit at the sending end can also add a second classification tag to the message based on the acquired message characteristics and the link status information fed back by the switch, specifically including: when the network congestion level represented by the link status information fed back by the switch is lower than the first preset congestion level, adding a second classification tag to the message whose message characteristics meet the first preset condition; the first preset condition includes belonging to the target protocol type and / or belonging to the target service priority; the second classification tag is used to instruct the switch to select the flow-by-flow mode to send the message.
[0079] Messages of the target protocol type and / or of the target service priority can be understood as messages not suitable for transmission using the packet-by-packet mode, or as messages that are more effectively transmitted using the flow-by-flow mode. The data processing unit at the transmitting end can, based on the extracted message features, identify whether a message to be transmitted belongs to the target protocol type and / or the target service priority. If so, a second classification tag is added to the message, so that the switch can select the flow-by-flow mode appropriate for the message to forward the message based on the second classification tag, thereby meeting the transmission timeliness or transmission reliability requirements of the specific type of message.
[0080] In another embodiment, the transmitting data processing unit may further optionally add a third classification tag to the message, the third classification tag being used to instruct the switch to select either per-flow mode or per-packet mode for message transmission. Correspondingly, the aforementioned addition of classification tags to messages based on message characteristics and link status information may further include: when the network congestion level indicated by the link status information fed back by the switch is lower than a second preset congestion level, adding the third classification tag to messages whose message characteristics meet a second preset condition; the second preset condition including the message size being greater than a packet slicing size threshold, belonging to the target protocol type, and / or belonging to the target service priority; and the packet slicing size threshold being negatively correlated with the network congestion level indicated by the link status information.
[0081] The second preset congestion level can be the same as or different from the first preset congestion level. When different, the second preset congestion level can be higher than the first preset congestion level. In this case, when the switch receives a message carrying the third classification tag, it can forward the message using a round-robin flow-by-flow mode, a packet-by-packet mode, or alternately using the flow-by-flow mode and the packet-by-packet mode. Thus, when the congestion level is low, the data processing unit on the sending end tends to add the second classification tag to the message and then forward the message using the flow-by-flow mode. When the congestion level reaches a moderate level, the data processing unit on the sending end tends to add the third classification tag to the message and then alternately use the flow-by-flow mode and the packet-by-packet mode to forward the message, thereby balancing bandwidth utilization and resource overhead on the sending end.
[0082] In the aforementioned embodiment, whether a message is a large message message is identified by using a packet cutting size threshold, wherein the packet cutting size threshold is determined in the following manner: a packet cutting coefficient is determined based on link status information fed back by the switch; the packet cutting coefficient is negatively correlated with the degree of network congestion represented by the link status information synchronized with the switch; and the packet cutting size threshold is determined based on the packet cutting coefficient and a preset reference packet cutting size.
[0083] As an example, the packet splitting factor, α, ranges from 0 to 1 and indicates the current level of packet splitting required for large messages to cope with congestion. α = 1 indicates full packet splitting (no degradation) according to the baseline; α = 0.7 indicates only 70% of the baseline splitting (a more conservative split).
[0084] Based on the packet cutting coefficient and the preset reference packet cutting size, the packet cutting size threshold may be determined in the following manner: packet cutting size threshold=α×reference packet cutting size.
[0085] The base packet size represents the packet splitting threshold when the network is uncongested or has low congestion. For example, if the base packet size is 2MB, large messages will be split only if they are ≥ 2MB. The packet splitting threshold is the packet splitting threshold adjusted based on α. For example, if α = 0.7 and the base packet size is 2MB, the packet splitting threshold is 1.4MB. Large messages ≥ 1.4MB will be split.
[0086] In one embodiment, the transmitting-end data processing unit sends the data packet carrying the classification tag to the switch, including: in response to an increase in the network congestion level represented by the link state information, sending the data packet carrying the classification tag to the switch at a first sending rate that is lower than the current sending rate; and in response to a decrease in the network congestion level represented by the link state information, sending the data packet carrying the classification tag to the switch at a second sending rate that is higher than the current sending rate.
[0087] In this way, when the network congestion is high, the sending rate of the data processing unit at the sending end can be reduced, thereby reducing the number of messages transmitted in the network and alleviating the congestion; conversely, when the network congestion is low, the sending rate of the data processing unit at the sending end can be increased, the number of messages transmitted in the network can be increased, and the network bandwidth utilization can be improved.
[0088] In some embodiments, an intelligent scheduling engine can be deployed on the data plane of the transmitting data processing unit. This intelligent scheduling engine can be a smart network card or other form factor, enabling deep integration of message processing and traffic scheduling. This allows the transmitting data processing unit to flexibly split large message packets into independent small messages, and in conjunction with the collaborative mechanism of the end-to-end network switch, obtain link congestion status feedback through a control protocol, achieving end-to-end collaborative full-link flow control.
[0089] refer to Figure 3 As shown, the intelligent scheduling engine deployed by the data processing unit at the sending end may include three parts: semantic recognition, state perception, and decision execution. Among them, semantic recognition can extract the message features of the message to be sent in real time through an AI model or a lightweight semantic feature extraction method, such as protocol type, load size, and service priority; state perception can be used to monitor the local CPU / memory utilization, the ratio of sent and received messages, the link bandwidth occupancy rate, and the link status information synchronized by the switch; decision execution can dynamically adjust the message marking strategy and execute it according to the message recognition results and the link status perception results, and support the intelligent message packet cutting ratio; in other embodiments, decision execution can also dynamically adjust the sending rate and execute it according to the message recognition results and the link status perception results. This classified forwarding mechanism effectively improves bandwidth utilization and flexibly realizes fast forwarding of traffic.
[0090] The traffic scheduling method based on the aforementioned embodiment of the present application includes, on the one hand, a congestion prevention mechanism: when there is a risk of congestion, the marking ratio and the sending rate of the message packet cutting are greatly increased to effectively prevent congestion; when the congestion risk is relieved, in order to avoid the resource loss of the DPU packet cutting on the sending side / the DPU reassembly on the receiving side, the packet cutting ratio is reduced, and congestion is dynamically avoided while also avoiding the waste of DPU resources on the end side and the increase in latency. On the other hand, the message processing method can be dynamically decided: according to different semantic categories, the messages are classified and marked, carrying different marking information, the switch selects the load sharing mode according to the message information marked by the DPU, and the receiving end DPU performs corresponding action processing according to the received message mark. As an example, the specific example diagram is shown in Table 1 below.
[0091] Table 1:
[0092]
[0093] Figure 4 FIG. 1 is a flow chart of a traffic scheduling method provided in another embodiment. Figure 4 As shown in Figure 1, the traffic scheduling method is completed by the sending end DPU, the sending end switch, the spine switch, the receiving end switch, and the receiving end DPU. The sending end DPU is deployed with a hardware-level intelligent scheduling engine (such as a smart network card, whose function definition can be referred to Figure 3 As shown in the figure, it is used to perform semantic recognition of data packets, obtain message features based on semantic recognition, and implement message classification and marking based on the message features. At the same time, the intelligent scheduling engine of the sending-end DPU can also perform a comprehensive evaluation based on the link status information synchronized by the local and remote switches, selectively classify and mark the messages to be sent, and cut large message messages into small message messages for transmission. The switch at the sending end is used to select the load balancing mode and perceive link congestion / faults based on the candidate links and the classification markings of the sending-end DPU. The switch at the receiving end is used for free forwarding or packet-by-packet load sharing based on the classification markings of the sending-end DPU. The receiving-end DPU identifies out-of-order packets and reassembles them as needed.
[0094] As a specific example, the business process of the traffic scheduling method may include:
[0095] S401: After a data packet arrives at the transmitting DPU, the DPU's scheduling engine determines the packet splitting coefficient based on the current link status and the scheduling scope. It then determines the actual packet splitting threshold and splits large messages based on the actual packet splitting threshold, adjusting the packet splitting ratio. The packet splitting coefficient and packet splitting ratio are dynamically adjustable. The transmitting DPU marks the message and sends it to the switch at the corresponding transmission rate.
[0096] S402: After receiving the message marked by the DPU at the sending end, the switch at the sending end selects a load sharing mode according to the current candidate path and the classification mark of the message by the DPU at the sending end.
[0097] S403: After the receiving end DPU receives the message carrying the classification tag through the receiving end switch, if it is a classification tag corresponding to the packet-by-packet mode, it reassembles the packets out of order as needed according to the tag information.
[0098] S404: When there is a congestion risk at the receiving end, the switch at the receiving end quickly sends a congestion awareness message to the switch at the sending end. Figure 1 shown.
[0099] S405: The switch at the sending end coordinates messages with the DPU at the sending end, and quickly transmits the congestion detection message to the DPU at the sending end.
[0100] S406: After receiving the congestion perception message, the DPU scheduling engine at the sending end recalculates based on local and feedback link status, packet sending and receiving ratio, and other information to reduce the packet splitting coefficient and increase the ratio of large message packets to small message packets. In addition, the packet sending rate can also be reduced.
[0101] As an example, link status information can specifically be the queue depth ratio synchronized by the switch. Accordingly, a packet splitting coefficient can be calculated based on the current queue depth ratio, a preset low-risk queue ratio threshold (e.g., 30%), and a preset high-risk queue ratio threshold (e.g., 70%). This packet splitting coefficient is negatively correlated with the current queue depth ratio. A higher current queue depth ratio indicates a higher level of congestion, a lower dynamically determined packet splitting coefficient, and a corresponding smaller packet splitting size threshold, resulting in a greater proportion of large message packets being split into smaller ones.
[0102] The DPU scheduling engine on the sending end can also assist in decision-making through AI models. As another example, the model input features are: (1) link status indicators: queue depth, packet loss rate, and ECN marking ratio; (2) send-receive ratio: the current send / receive rate ratio (e.g., 1.2:1); and (3) historical status: the number of congestion events in the past N seconds (e.g., the past 5 seconds). Among them, ECN is an extended function of the IP and TCP protocols. It allows the switch to send a congestion signal to the terminal (e.g., server, DPU) by marking the packet header (ECN field in the IP header) when mild congestion occurs, without having to discard the packet. After receiving the mark, the terminal (e.g., server, DPU) will actively reduce the sending rate to avoid worsening congestion. The ECN marking ratio can reflect the real-time congestion level of the link. The higher the ECN marking ratio, the more severe the congestion.
[0103] Based on this input information, the corresponding AI model auxiliary output can be found in Table 2 below.
[0104] Table 2:
[0105]
[0106] Based on this, when the link is highly congested (packet splitting coefficient α↓), the packet splitting threshold is lowered (for example, to 1.4MB), forcing more messages to be split and improving multipath utilization. When the link is less congested (packet splitting coefficient α↑), the packet splitting threshold is raised (for example, restoring it to 2MB), reducing message splitting overhead and conserving DPU reassembly resources. This avoids excessive splitting (wasting resources) or insufficient splitting (worsening congestion) caused by fixed packet splitting thresholds or fixed splitting ratios.
[0107] S407: The DPU at the transmitting end adjusts packet transmission according to the new calculation result, the number of small message packets that the large message packet is divided into increases, and the packet transmission rate decreases.
[0108] S408: The pressure on the switch at the sending end to forward packets is reduced.
[0109] S409: Correspondingly, the receiving end DPU identifies out-of-order packets and reassembles them as needed. Since a higher proportion of messages are forwarded in a packet-by-packet mode, the reassembly ratio is increased.
[0110] S410: When the congestion risk at the receiving end is relieved, the switch at the receiving end quickly sends a congestion relief message to the switch at the sending end, which then passes the message to the DPU at the sending end.
[0111] S412: The sending end DPU recalculates and adjusts the packet splitting coefficient based on the new perception information, reducing the ratio of large message packets to be split, so that fewer packets are forwarded in a packet-by-packet mode; in addition, the packet sending rate can be increased.
[0112] S413: The sending end DPU adjusts the packet sending strategy according to the new calculation result.
[0113] S414: After receiving the message carrying the classification mark, the receiving end DPU identifies the out-of-order packets and reassembles them as needed. Since a lower proportion of messages are forwarded in a packet-by-packet mode, the reassembly ratio is reduced.
[0114] It should be noted that the above steps do not have to be executed in sequence. For example, the order of steps S404 to S409 and S410 to S414 may be reversed. Accordingly, steps S410 to S414 are executed first, and then steps S404 to S409.
[0115] The traffic scheduling method of the above-described embodiment achieves intelligent traffic scheduling through end-to-end collaboration between the data processing unit (DPU). Specifically, the transmitting-end DPU intelligent network card (INIC) performs semantic recognition on data packets, deriving message features. Based on these features, it classifies and tags the packets, intelligently determining whether to use per-packet or per-flow forwarding modes (per-packet mode requires splitting large messages into independent, smaller ones). This classified forwarding mechanism effectively improves bandwidth utilization and flexibly enables fast traffic forwarding. Furthermore, through end-to-end link status awareness, the transmitting-end DPU performs comprehensive scheduling. It can also dynamically adjust the message processing mode in real time based on link status. Through end-to-network collaboration with the switch, it achieves a deep integration of message processing and traffic scheduling, fundamentally avoiding traffic congestion and achieving global dynamic load balancing.
[0116] It should be understood that, although the various steps in the flowcharts involved in the various embodiments described above are displayed in sequence according to the instructions of the arrows, these steps are not necessarily performed in sequence in the order indicated by the arrows. Unless clearly stated herein, the execution of these steps is not strictly limited in order, and these steps can be performed in other orders. Moreover, at least a portion of the steps in the flowcharts involved in the various embodiments described above may include multiple steps or multiple stages, and these steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these steps or stages is not necessarily performed in sequence, but can be performed in turn or alternately with at least a portion of the steps or stages in other steps or other steps. It is understandable that the various steps in different embodiments can be freely combined as needed, and the various non-contradictory schemes formed by the combination all fall within the scope of protection of this application.
[0117] Based on the same inventive concept, the embodiments of the present application also provide a traffic scheduling device for implementing the aforementioned traffic scheduling method. The implementation solution provided by the device is similar to the implementation solution described in the aforementioned method. Therefore, the specific limitations in one or more traffic scheduling device embodiments provided below can be found in the above-mentioned limitations on the traffic scheduling method and will not be repeated here.
[0118] In an exemplary embodiment, Figure 5 As shown, a traffic scheduling device is provided, which is applied to a data processing unit at a sending end, including:
[0119] Feature extraction module 501, used to obtain message features of the message to be sent; the message features include message size, protocol type and / or service priority;
[0120] The link information acquisition module 502 is used to obtain link status information fed back by the switch;
[0121] The marking module 503 is configured to add a classification mark to the message based on the message characteristics and the link state information; the classification mark is one of multiple preset classification marks;
[0122] The sending module 504 is used to send the data packet carrying the classification tag to the switch; different classification tags are used to instruct the switch to select different load balancing modes to send the message; the different load balancing modes include at least flow-by-flow mode and packet-by-packet mode.
[0123] The traffic scheduling device based on the above embodiment can obtain message characteristics in real time, implement message classification and marking according to the message characteristics and the link status information fed back by the switch, and support intelligent determination of packet-by-packet forwarding or flow-by-flow forwarding mode (the packet-by-packet mode requires large message packets to be divided into small message packets for transmission). This classified forwarding mechanism effectively improves bandwidth utilization and flexibly realizes rapid forwarding of traffic. Through the end-to-end network collaboration mechanism with the switch, it realizes the deep integration of message processing and traffic scheduling, fundamentally avoids traffic congestion, and realizes global dynamic load balancing.
[0124] In one embodiment, the marking module 503 may be specifically configured to increase the proportion of messages marked with the first classification mark based on the message characteristics in response to an increase in the level of network congestion represented by the link status information; and reduce the proportion of messages marked with the first classification mark based on the message characteristics in response to a decrease in the level of network congestion represented by the link status information; wherein the first classification mark is used to instruct the switch to select a packet-by-packet mode for sending the message.
[0125] In one embodiment, the marking module 503 may also be configured to add a second classification tag to a message whose message characteristics meet a first preset condition when the network congestion level represented by the link state information is lower than a first preset congestion level; the first preset condition includes belonging to a target protocol type and / or belonging to a target service priority; and the second classification tag is used to instruct the switch to select a flow-by-flow mode to send the message.
[0126] In one embodiment, the marking module 503 may also be configured to add a third classification mark to a message whose message characteristics meet a second preset condition when the network congestion level represented by the link status information is lower than a second preset congestion level; the second preset condition includes that the message size is greater than a packet cutting size threshold and belongs to a target protocol type and / or a target service priority; the packet cutting size threshold is negatively correlated with the network congestion level represented by the link status information; and the third classification mark is used to instruct the switch to select either a flow-by-flow mode or a packet-by-packet mode to send the message.
[0127] In one embodiment, the sending module 504 may be specifically configured to send the message carrying the classification tag to the switch at a first sending rate that is lower than the current sending rate in response to an increase in the network congestion level represented by the link status information; and send the message carrying the classification tag to the switch at a second sending rate that is higher than the current sending rate in response to a decrease in the network congestion level represented by the link status information.
[0128] Each module in the above-mentioned traffic scheduling device can be implemented in whole or in part through software, hardware, or a combination thereof. Each of the above-mentioned modules can be embedded in or independent of the processor in the computer device in hardware form, or can be stored in the memory of the computer device in software form, so that the processor can call and execute the corresponding operations of each of the above modules.
[0129] In an exemplary embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as shown in FIG. Figure 6 As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, abbreviated as I / O) and a communication interface. The processor, memory and input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and computer program in the non-volatile storage medium. The database of the computer device is used to store data related to data processing. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a traffic scheduling method is implemented.
[0130] Those skilled in the art will understand that Figure 6 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than shown in the figure, or combine certain components, or have a different component arrangement.
[0131] In an exemplary embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the steps of the traffic scheduling method of any of the above embodiments are implemented.
[0132] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the traffic scheduling method of any of the above embodiments are implemented.
[0133] In one embodiment, a computer program product is provided, comprising a computer program, which, when executed by a processor, implements the steps of the traffic scheduling method of any of the above embodiments.
[0134] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.
[0135] Those skilled in the art will understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. In particular, any reference to memory, database, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The databases involved in the various embodiments provided herein may include at least one of a relational database and a non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the various embodiments provided herein may be, but are not limited to, general-purpose processors, central processing units (CPUs), graphics processing units (GPUs), digital signal processors (DSPs), programmable logic devices (PLDs), quantum computing-based data processing logic devices, artificial intelligence (AI) processors, and the like.
[0136] The technical features of the above embodiments can be combined arbitrarily. In order to make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.
[0137] The above-described embodiments merely represent several implementation methods of the present application. While the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present application. It should be noted that a person of ordinary skill in the art may make various modifications and improvements without departing from the spirit of the present application, and these modifications and improvements fall within the scope of protection of the present application. Therefore, the scope of protection of the present application shall be determined by the appended claims.
Claims
1. A traffic scheduling method, characterized in that: The method applied to the data processing unit of the sending end includes: Acquiring message characteristics of a message to be sent; the message characteristics include message size, protocol type and / or service priority; Obtain link status information fed back by the switch; Adding a classification tag to the message based on the message characteristics and the link state information; the classification tag is one of multiple preset classification tags; The message carrying the classification mark is sent to the switch; different classification marks are used to instruct the switch to select different load balancing modes to send the message; the different load balancing modes include at least a flow-by-flow mode and a packet-by-packet mode.
2. The method according to claim 1, characterized in that The adding a classification tag to the message based on the message feature and the link state information includes: In response to an increase in the network congestion level represented by the link state information, increasing the proportion of messages marked with the first classification mark based on the message characteristics; In response to a decrease in the network congestion level represented by the link state information, reducing the proportion of messages marked with the first classification mark based on the message characteristics; The first classification mark is used to instruct the switch to select a packet-by-packet mode to send the message.
3. The method according to claim 2, characterized in that In response to an increase in the network congestion level represented by the link state information, increasing the proportion of the messages marked with the first classification mark based on the message characteristics includes: In response to an increase in the network congestion level represented by the link state information, the packet cutting size threshold is lowered, and a first classification mark is added to packets whose size is greater than the packet cutting size threshold.
4. The method according to claim 2, characterized in that In response to a decrease in the network congestion level represented by the link state information, reducing the proportion of the packets marked with the first classification mark based on the packet characteristics includes: In response to a decrease in the network congestion level represented by the link state information, the packet cutting size threshold is increased, and a first classification mark is added to packets whose sizes are larger than the packet cutting size threshold.
5. The method according to claim 1, characterized in that The adding a classification tag to the message based on the message feature and the link state information further includes: When the network congestion level represented by the link state information is lower than a first preset congestion level, adding a second classification tag to a message whose message characteristics meet a first preset condition; the first preset condition includes belonging to a target protocol type and / or belonging to a target service priority; The second classification tag is used to instruct the switch to select a flow-by-flow mode to send the message.
6. The method according to claim 1, characterized in that The adding a classification tag to the message based on the message feature and the link state information further includes: When the network congestion level represented by the link state information is lower than a second preset congestion level, a third classification mark is added to a message whose message characteristics meet a second preset condition; the second preset condition includes that the message size is greater than a packet cutting size threshold and belongs to a target protocol type and / or belongs to a target service priority; and the packet cutting size threshold is negatively correlated with the network congestion level represented by the link state information; The third classification tag is used to instruct the switch to select one of a flow-by-flow mode and a packet-by-packet mode to send the message.
7. The method according to claim 3, 4 or 6, characterized in that The method further comprises: Determining a packet cutting coefficient based on the link state information; wherein the packet cutting coefficient is negatively correlated with the degree of network congestion represented by the link state information; The packet cutting size threshold is determined based on the packet cutting coefficient and a preset reference packet cutting size.
8. The method according to claim 1, characterized in that The step of sending the data packet carrying the classification tag to the switch includes: In response to an increase in the network congestion level represented by the link state information, sending the message carrying the classification tag to the switch at a first sending rate that is lower than the current sending rate; In response to a decrease in the network congestion level represented by the link state information, the message carrying the classification tag is sent to the switch at a second sending rate that is greater than the current sending rate.
9. A flow scheduling device, characterized in that: A data processing unit applied to a transmitting end, the device comprising: A feature extraction module, configured to obtain message features of a message to be sent; the message features include message size, protocol type, and / or service priority; Link information acquisition module, used to obtain link status information fed back by the switch; a marking module, configured to add a classification mark to the message based on the message characteristics and the link state information; the classification mark being one of a plurality of preset classification marks; The sending module is used to send the data packet carrying the classification mark to the switch; different classification marks are used to instruct the switch to select different load balancing modes to send the message; the different load balancing modes include at least flow-by-flow mode and packet-by-packet mode.
10. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 8 are implemented.
11. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 8 are implemented.
12. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 8 are implemented.
Citation Information
Cited By
Congestion control method and device for cloud computing platform, program product and storage medium
CN121173747A