Method and device for controlling data transmission, equipment and storage medium
By detecting congestion events and early warning events in the data network, and adjusting the data transmission speed of the data transmission equipment according to the detection results, the problem of network congestion in high-speed network scenarios is solved and the data transmission efficiency is improved.
Patent Information
- Application Number
- CN202411472239.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-21
- Publication Date
- 2025-01-24
AI Technical Summary
The prior art cannot effectively solve the problem of network congestion when facing high-speed network scenarios, resulting in a decrease in data transmission speed and network efficiency.
By testing whether a congestion or early warning incident occurs in the data network, the data transmission speed of the data transmission device is adjusted to alleviate or avoid congestion. Specific methods include detecting congestion and early warning events within the first predetermined period, and adjust the data transmission speed according to the test results.
The data transmission speed is flexibly adjusted when the congestion or early warning is detected, effectively relieved or avoids network congestion, thereby improving the efficiency of data transmission.
Smart Images

Figure CN119363848A_ABST
Abstract
Description
Technical Field
[0001] Example embodiments of the present disclosure generally relate to the field of computer technology, and more particularly, to methods, devices, apparatuses, and computer-readable storage media for controlling data transmission. Background Art
[0002] A data network is a network system that allows devices (such as computers, mobile phones, servers, etc.) to communicate with each other and share data. It connects multiple nodes together through various transmission media (such as cables, optical fibers, radio waves, etc.) to transfer data between different devices. With its efficiency, flexibility and robustness, data networks have become the core of modern communication technology and support digital communications around the world. Data networks are widely used in the Internet, corporate intranets, the Internet of Things and other fields, supporting various functions such as file sharing, multimedia streaming and cloud computing services.
[0003] Network congestion may occur when the transmission of data packets in the network reaches or exceeds the limit of the network bandwidth. In this case, data packets may be lost, resulting in increased network latency, decreased network throughput and reduced network efficiency. Summary of the invention
[0004] In a first aspect of the present disclosure, a method for controlling data transmission is provided. The method comprises: detecting at least one of a congestion event and a warning event associated with a data transmission device in a data network within a first predetermined period of time, wherein the warning event is related to the amount of data sent by the data transmission device; and adjusting the data transmission speed of the data transmission device based on the detection result.
[0005] In a second aspect of the present disclosure, a device for controlling data transmission is provided. The device includes: a detection module configured to detect at least one of a congestion event and a warning event associated with a data transmission device in a data network within a first predetermined period of time, wherein the warning event is related to the amount of data sent by the data transmission device; and an adjustment module configured to adjust the data transmission speed of the data transmission device based on the detection result.
[0006] In a third aspect of the present disclosure, an electronic device is provided. The device includes at least one processing unit; and at least one memory, the at least one memory is coupled to the at least one processing unit and stores instructions for execution by the at least one processing unit. When the instructions are executed by the at least one processing unit, the device executes the method of the first aspect.
[0007] In a fourth aspect of the present disclosure, a computer-readable storage medium is provided, wherein a computer program is stored on the medium, and when the computer program is executed by a processor, the method of the first aspect is implemented.
[0008] It should be understood that the content described in this section is not intended to limit the key features or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. In the accompanying drawings, the same or similar reference numerals represent the same or similar elements, wherein:
[0010] Figure 1A A schematic diagram of an example data network environment is shown;
[0011] Figure 1B A schematic diagram showing a congestion notification mechanism is shown;
[0012] Figure 2 A schematic diagram showing a controller controlling data transmission of a data transmission device according to some embodiments of the present disclosure is shown;
[0013] Figure 3 A schematic diagram showing an example control module of an example controller for controlling data transmission according to some embodiments of the present disclosure;
[0014] Figure 4 A flow chart showing a method for increasing the data transmission speed of a data transmission device according to some embodiments of the present disclosure is shown;
[0015] Figure 5 A flow chart showing a method of reducing the data transmission speed of a data transmission device according to some embodiments of the present disclosure;
[0016] Figure 6 A flowchart showing a method for reducing the data transmission speed of a data transmission device according to other embodiments of the present disclosure is shown;
[0017] Figure 7 A flow chart showing a method for adjusting the data transmission speed of a data transmission device according to some embodiments of the present disclosure is shown;
[0018] Figure 8 A flow chart of a method for controlling data transmission according to some embodiments of the present disclosure is shown;
[0019] Fig. 9 A block diagram showing an apparatus for controlling data transmission according to some embodiments of the present disclosure; and
[0020] Fig.10 A block diagram of an electronic device is shown in which one or more embodiments of the present disclosure may be implemented. DETAILED DESCRIPTION
[0021] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments set forth herein. On the contrary, these embodiments are provided to provide a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.
[0022] In the description of the embodiments of the present disclosure, the term "including" and similar terms should be understood as open inclusion, that is, "including but not limited to". The term "based on" should be understood as "based at least in part on". The term "one embodiment" or "the embodiment" should be understood as "at least one embodiment". The term "some embodiments" should be understood as "at least some embodiments". Other explicit and implicit definitions may also be included below.
[0023] Herein, unless explicitly stated, executing a step “in response to A” does not mean executing the step immediately after “A” but may include one or more intermediate steps.
[0024] It is understandable that the data involved in this technical solution (including but not limited to the data itself, the acquisition or use of the data) shall comply with the requirements of relevant laws, regulations and relevant provisions.
[0025] As used herein, the term “remote direct memory access” (RDMA) is a network communication technology that allows a computer to directly access the memory of another computer over a network without the intervention of an operating system or the use of CPU resources.
[0026] In a data network environment, when the data traffic in the data network exceeds the processing capacity of the network devices in the data network, the packet loss rate will increase, the transmission delay will increase, and the data transmission speed will decrease, that is, congestion has occurred in the network. When congestion occurs in the network, it is usually necessary to reduce the data transmission speed in the network to alleviate the congestion. In addition, when the congestion in the network is alleviated, it is necessary to increase the data transmission speed in the network to improve the data transmission efficiency.
[0027] Conventional congestion control methods are mainly used for scenarios with low rates and large delays, and cannot meet the demands of high throughput and low delay in high-speed network scenarios. For example, in the transmission control protocol (TCP) scenario, the commonly used congestion control method usually uses packet loss as a congestion signal and cannot quickly respond to congestion events in the data network. In addition, other congestion control methods usually have high requirements for equipment and cannot be applied to equipment with simple structure or low performance.
[0028] For the convenience of explanation, the following Figure 1A The data network environment 100A in FIG. 1 is used as an example for discussion. Specifically, Figure 1A A schematic diagram of an example data network environment 100A is shown. In the example data environment 100A, data transmission devices 112 and 114 can transmit data to a data transmission device 116 via a switch 120. In addition, the data transmission device 116 can transmit data and / or send information to the data transmission device 112 and the data transmission device 114. As shown, the data transmission devices 112, 114, and 116 are associated with controllers 102, 104, and 106, respectively. The controllers 102, 104, and 106 can be used to control the data transmission and / or information transmission of the corresponding data transmission devices 112, 114, and 116.
[0029] In some cases, data transmission devices 112, 114, and 116 may be implemented as or included in a server. Controllers 102, 104, and 106 may be implemented as or included in a network card of a server, such as a remote direct memory access network interface card (RDMA network interface card, RNIC). In some examples, the controller and the corresponding data transmission device may be implemented or included in the same device. For example, controller 102 and data transmission device 112 may be different modules in the same device or implemented as functions of the same device.
[0030] In such Figure 1A In the data network environment 100A shown, for example, when the data transmission devices 112 and 114 simultaneously send a large amount of data, the amount of data received at the switch 120 may be greater than its processing capacity, which will cause congestion in the network. In addition, when the amount of data received by the data transmission device 116 is greater than its processing capacity, congestion will occur in the network.
[0031] In this case, to relieve congestion in the data network environment 100A, the controllers 102 and 104 may respectively reduce the data transmission speeds of the data transmission devices 112 and 114. Additionally, when the congestion is relieved, the controllers 102 and 104 may respectively increase the data transmission speeds of the data transmission devices 112 and 114 to improve data transmission efficiency.
[0032] Generally, windows can be used to control the data transmission speed of data transmission devices. For example, the sender sends data to the receiver, and the receiver returns an acknowledgment message (ACK) after receiving the data message. There is a window on the data to be sent by the sender. When the previously sent data is confirmed (that is, when the sender receives ACK), the window "slides" backward to cover the data that has not yet been sent, and the sliding step depends on the amount of data confirmed by the ACK. The data in the window becomes the data that can be sent at present, and the sender can then send new data. When the next ACK returns, the window can slide backward again, and then continue to send new data. Therefore, based on the window limit, ACK is the trigger for data transmission. This behavior is called ACK-clocking, that is, ACK is like a clock beat, and every time it comes, it can trigger data transmission once. The amount of new data triggered by ACK depends on the amount of data confirmed by ACK, so the data transmission speed can be controlled by controlling the size of the window.
[0033] In the conventional scheme, when a congestion notification packet (CNP) is received, each CNP may cause the window size to be reduced by a fixed value. This method cannot be used when the window is small, otherwise the window will be reduced to zero.
[0034] In addition, in conventional methods of reducing data transmission speed, when congestion occurs in the data network environment, the speed reduction interval is usually related to the data transmission time. When the network is congested, the relevant data transmission time may increase rapidly as the amount of data in the network changes. Therefore, the control device in the network needs to wait for a considerable time after detecting congestion before reducing the data transmission speed in the network. In a highly loaded network, this will result in congestion not being relieved in time, resulting in more data packet loss and higher latency.
[0035] Conventional solutions also include algorithms based on fixed time interval speed regulation. Since speed regulation is performed at fixed time intervals, if the network conditions change dramatically between two intervals, the algorithm cannot respond in time, which may cause network congestion or waste of resources. In addition, fixed time interval speed regulation cannot be dynamically adjusted according to the current network conditions. It may be too conservative during high traffic periods, wasting bandwidth, and too aggressive during low traffic periods, increasing the risk of congestion.
[0036] Some conventional data transmission control schemes also include control methods based on the current data transmission speed. For example, during data transmission, the data transmission rate of the sender is flexibly adjusted according to the real-time status of the network (such as bandwidth, delay, packet loss rate, etc.) to ensure that it does not exceed the maximum capacity that the network can bear, thereby avoiding congestion. This method does not require waiting for the data packet to be transmitted back to the sender. However, the control method based on data transmission speed cannot slow down the data transmission speed as quickly as the window-based algorithm when facing congestion. In the case of congestion, a large amount of data will continue to be sent to the already congested network in a short period of time, further exacerbating the congestion.
[0037] In addition, explicit congestion notification is also used to control congestion occurring in data networks. Figure 1B A schematic diagram 100B of an explicit congestion notification mechanism is shown. Explicit congestion notification (ECN) is a network congestion management mechanism that allows network devices to notify senders of network congestion without dropping data packets. By setting a specific ECN mark in the packet header, the sender can adjust its data transmission speed to alleviate network congestion.
[0038] For example, when network congestion occurs, Figure 1B As shown in FIG. 1 , data packets 130 and 132 in the data packet queue are marked as data packets with an ECN mark. When the receiver receives a data packet with an ECN mark, the receiver can notify the sender of the occurrence of congestion through an ACK. When the sender receives an ACK with an ECN notification, it can confirm that congestion has occurred and reduce its data transmission speed. For example, Figure 1B When the receiver in receives data packet 130, the number of data packets with congestion marking does not reach the ECN threshold. The receiver may not notify the sender of congestion. When the receiver receives data packet 132, the number of data packets with congestion marking exceeds the ECN threshold. The receiver notifies the sender of congestion. The sender confirms and relieves the congestion by reducing its data transmission speed.
[0039] The embodiments of the present disclosure propose a scheme for controlling data transmission. In this scheme, it is possible to detect whether a congestion event occurs in a data network or a warning event that a data transmission device sends too much data, resulting in a possible congestion in the data network, and the data transmission speed of the data transmission device can be adjusted according to whether a congestion event or a warning event is detected in the data network. In this way, the data transmission speed of the data transmission device can be flexibly and effectively adjusted, thereby improving the data transmission efficiency of the data transmission device.
[0040] The following will be combined Figure 2-Figure 8 A scheme for controlling data transmission according to some embodiments of the present disclosure is described. Figure 2 FIG. 2 is a schematic diagram 200 showing a controller controlling data transmission of a data transmission device according to some embodiments of the present disclosure. Figure 2 As shown, the controller 220 is associated with the data transmission device 210. Specifically, the controller 220 can control the data transmission speed of the data transmission device 210. In addition, the controller 220 can also control the data transmission device 210 to send messages to other devices in the data network.
[0041] In some implementations, the data transmission device 210 may be implemented as a server, and the controller 220 may be implemented in a network card (eg, RNIC) of the server. For example, there may be multiple data transmission devices, and these data transmission devices may perform data transmission with each other through a switch.
[0042] It should be understood that the controller 220 and the data transmission device 210 may be integrated together, that is, implemented on the same physical device. As an alternative, the controller 220 and the data transmission device 210 may also be devices independent of each other, and the embodiments of the present disclosure are not limited to this. In some example embodiments, the controller 220 and the data transmission device 210 are the same device, may be a part of the data transmission device 210, or may be another device independent of the data transmission device 210.
[0043] In the method for controlling data transmission according to an embodiment of the present disclosure, the controller 220 detects at least one of a congestion event and a warning event associated with a data transmission device 220 in a data network within a first predetermined period of time. Specifically, the warning event is related to the amount of data sent by the data transmission device. The controller 220 adjusts the data transmission speed of the data transmission device 210 based on the detection result. Additionally, the first predetermined period of time includes a round-trip delay of the data transmission device.
[0044] In some embodiments, if the controller 220 does not detect a congestion event within the first predetermined period, the controller 220 may increase the data transmission speed of the data transmission device 210. Specifically, the controller 220 may increase the data transmission speed by a predetermined amount at the end of the first predetermined period. For example, if the controller 220 does not detect a congestion event within the first predetermined period, the data transmission speed of the data transmission device 210 may be reduced, for example, by the following formula:
[0045] R'=R + α, (1)
[0046] Wherein R is the current data transmission speed, α is the speed increment, and R' is the updated data transmission speed. α may be predefined or determined based on the data transmission speed R.
[0047] In addition, if the controller 220 detects a congestion event or a warning event within the first predetermined period, the controller 220 may reduce the data transmission speed of the data transmission device 210. In this case, the controller 220 may reduce the data transmission speed to a predetermined ratio of the data transmission speed or to a predetermined value, wherein the predetermined ratio is greater than 0 and less than 1. For example, if the controller 220 detects a congestion event or a warning event within the first predetermined period, such as within the round-trip time (RTT), the data transmission speed of the data transmission device 210 may be updated as follows, for example, by the following formula:
[0048] R'=βR, (2)
[0049] Where R is the current data transmission speed, β is the speed reduction coefficient, R' is the updated (i.e., reduced) data transmission speed, and 1>β>0. β may be predefined or determined based on the data transmission speed R. In addition, for congestion events or warning events, β may be different values.
[0050] Specifically, if the controller 220 detects a congestion event, the controller 220 may reduce the data transmission speed by multiplying the data transmission speed by a first coefficient. Alternatively, if the controller 220 detects a warning event, the controller 220 may reduce the data transmission speed by multiplying the data transmission speed by a second coefficient. The first coefficient β1 and the second coefficient β2 may be the same or different.
[0051] In some embodiments, the first coefficient β1 may be a larger value in the interval (0,1), such as 0.95 to 0.99. This will allow the controller 220 to flexibly adjust the data transmission speed of the data transmission device 210. The second coefficient β2 may be a smaller value in the interval (0,1), such as 0.1 to 0.5. This will allow the controller 220 to efficiently adjust the data transmission speed of the data transmission device 210. In addition, the first coefficient β1 and the second coefficient β2 may also be dynamically configured according to the data transmission speed. The first coefficient β1 and the second coefficient β2 may be configured in any or all possible ways that can implement the embodiments of the present disclosure, and the embodiments of the present disclosure do not impose any restrictions on this.
[0052] It should be understood that the examples of the methods for adjusting the data transmission speed described in the present disclosure are for illustrative purposes only and are not intended to limit the embodiments of the present disclosure in any way. The methods for adjusting the data transmission speed can be configured to implement any or all of the techniques of the embodiments of the present disclosure, and the embodiments of the present disclosure do not impose any limitations on this.
[0053] In some implementations, if the controller 220 does not receive the congestion prompt information within the first predetermined period, the controller 220 may determine that no congestion event is detected within the first predetermined period. Additionally, if the controller 220 receives the congestion prompt information within the first predetermined period, the controller 220 may determine that a congestion event is detected within the first predetermined period. Specifically, the congestion prompt information may include a congestion prompt data packet or a data packet with a congestion mark.
[0054] In some embodiments, the switch in the data network environment has an ECN marking function, which can mark the ECN field of the data packets exceeding a certain threshold in the data packet queue to reflect the congestion of the queue. In this case, the controller 220 has the ECN parsing and CNP message generation functions. When the receiving end receives a data packet with an ECN mark, a CNP message can be sent to the sending end. The controller 220 of the data transmission device 210 at the sending end receives the CNP message to determine that a congestion event is detected.
[0055] In addition, if the controller 220 does not receive a CNP message within the current RTT and the data transmission device 210 does not receive a data packet with an ECN mark or a congestion warning data packet, the controller 220 determines that no congestion event is detected.
[0056] Additionally, if the controller 220 determines that the amount of data sent by the data transmission device 210 within the first predetermined period is greater than the data amount threshold, the controller 220 may determine that a warning event is detected within the first predetermined period. Specifically, the data amount threshold may correspond to the maximum amount of data that the data transmission device is allowed to transmit. In some embodiments, in order to avoid the deterioration of congestion caused by untimely feedback of congestion signals, the controller 220 may limit the total amount of data that the data transmission device 210 can send within each RTT. In this case, the controller 220 has RTT measurement and sent data amount statistics functions.
[0057] Specifically, the controller 220 may determine the data volume threshold based on the current data propagation speed of the data transmission device 210 and the reference period. The controller 220 may determine the amount of data transmitted by the data transmission device 210 in the first predetermined period as the amount of data transmitted. Additionally, the reference period may correspond to the minimum value of a plurality of round trip delays of the data transmission device 210 in the second predetermined period.
[0058] In some implementations, the controller 220 may determine the data volume threshold according to formula (3):
[0059] S max =R·RTT min , (3)
[0060] Where S max is the data volume threshold, R is the current data transmission speed of the data transmission device 210, and RTT min is the reference period. Reference period RTT min The controller 220 measures multiple RTTs of the data transmission device 210 within the second predetermined period and takes the minimum RTT therefrom. The second predetermined period may be predefined or determined based on the data transmission speed or RTT of the data transmission device 210. For example, the second predetermined period may include at least M RTTs, where M is a predefined integer. max Indicates the maximum amount of data allowed to be sent by the data transmission device 210 within the second predetermined period of time.
[0061] In addition, the controller 220 can also count the amount of data S transmitted by the statistical transmission device 210 within the current RTT. now When the controller 220 determines S now >S max, the controller 220 may determine that a warning event is detected within the first predetermined period. In other words, if the amount of data transmitted by the data transmission device 210 within the current RTT is greater than the maximum amount of data allowed to be sent by the data transmission device 210 within the recent period, the amount of data transmitted by the data transmission device 210 is likely to be greater than the processing capacity of the data network, and congestion will soon occur. Therefore, the controller 220 determines that a warning event is detected.
[0062] In this way, the method for controlling data transmission according to the exemplary embodiment of the present disclosure can flexibly and efficiently adjust the data transmission speed of the data transmission device based on congestion events and warnings associated with the data transmission equipment in the data network, thereby improving the data transmission efficiency of the data network.
[0063] Reference below Figure 3 An example control module 300 of an example controller for controlling data transmission according to some embodiments of the present disclosure is described. It should be understood that the example control module 300 may be included in, for example Figure 2 In the controller 220 shown in .
[0064] like Figure 3 As shown, the control module 300 includes a transmit pipeline (TX pipe) 310, a receive pipeline (RX pipe) 320, and a speed control function module 330. In some embodiments, the transmit pipeline 310 can send burst information to the speed control function module 330, and the burst information indicates the amount of data sent by the data transmission device. Specifically, the burst information can indicate the amount of data sent by the data transmission device within a certain time interval, or report once after sending a certain amount of data, and the length of the time interval can reflect the speed of data transmission.
[0065] In addition, the receiving pipeline 320 can send a CNP message and RTT information to the speed control function module 330. For example, the RTT information can include multiple RTTs of the data transmission device within a certain period of time. The CNP message can be used to determine that a congestion event is detected, and the RTT information can be used to determine that a warning event is detected. The speed control function module 330 can use the method for controlling data transmission according to an exemplary embodiment of the present disclosure to determine whether a congestion time and / or a warning event is detected based on the burst information, the CNP message and the RTT information, and update the data transmission speed of the data transmission device.
[0066] In this way, the control module 300 can determine whether the amount of data transmitted by the data transmission device is greater than the data amount threshold based on the amount of data sent, the CNP message, and the RTT information, thereby detecting whether a warning event occurs, and reducing the data transmission speed of the data transmission device in the event of a warning event. Therefore, congestion in the data network can be alleviated or avoided, thereby improving the data transmission efficiency of the data network.
[0067] The following will be combined Figure 4-Figure 6 A method for adjusting data transmission according to some embodiments of the present disclosure is described in detail. Figure 4 FIG. 4 is a flowchart of a method 400 for increasing the data transmission speed of a data transmission device according to some embodiments of the present disclosure. Figure 2 The method 400 for improving the data transmission speed is described by taking the data transmission device 210 and the controller 220 in FIG. 4 as an example.
[0068] like Figure 4 As shown, in box 402, the controller 220 can periodically trigger RTT measurement and record the measured results as the interval of the current speed increase. For example, the controller 220 can record the length of the RTT at the end of each RTT and trigger the next measurement to obtain the next RTT. In this way, the RTT will be used as the interval of the speed increase. It should be understood that the interval of the speed increase can also be predefined or determined according to the data transmission speed, etc., and the embodiments of the present disclosure are not limited to the above examples.
[0069] Next, in block 404 , the controller 220 determines that the time from the last event of increasing the data transmission speed to the current time is greater than the RTT (or greater than the interval of the increase in speed), and then the controller 220 may perform the determination in block 406 .
[0070] Specifically, at block 406, the controller 220 may determine whether a CNP event occurs within the RTT. If the controller 220 determines that the data transmission device 210 has received a CNP message or a data packet with an ECN mark within the last speed-up interval (e.g., RTT), the speed-up process is skipped at block 410. In this case, the data transmission speed is not increased, and the data transmission device 210 still sends data at the original speed.
[0071] In contrast, if the controller 220 does not experience a CNP event during the interval in which the speed increase is determined at block 406, the data transmission speed may be increased at block 408. For example, the controller 220 may update the data transmission speed of the data transmission device 210 according to equation (1) discussed above.
[0072] Additionally, after block 408 or block 410, the controller 220 may proceed to the next RTT measurement.
[0073] In this way, the data transmission speed of the data transmission device 210 can be effectively increased without the occurrence of congestion events or warning events, thereby improving the data transmission efficiency in the data network.
[0074] Figure 5 A flowchart of a method 500 for reducing the data transmission speed of a data transmission device according to some embodiments of the present disclosure is shown. Figure 2 The method 500 for reducing the data transmission speed is described by taking the data transmission device 210 and the controller 220 in FIG. 5 as an example.
[0075] In some embodiments, Figure 5 The method 500 of reducing the data transmission speed is shown in association with an early warning event. Figure 5 As shown, in block 502, the controller 220 may determine a data volume threshold. Specifically, the controller 220 may determine the data volume threshold using the above-mentioned method for controlling data transmission according to an exemplary embodiment of the present disclosure. For example, the controller 220 measures multiple RTTs of the data transmission device 210 within a period of time and obtains the minimum value of the multiple RTTs as RTT. min , the controller 220 can determine the data volume threshold according to formula (3).
[0076] At block 504, the controller 220 may determine whether the amount of data transmitted by the data transmission device 210 within the current RTT is greater than the data amount threshold. If the controller 220 determines that the amount of data transmitted is greater than the data amount threshold, the controller 220 determines that an early warning event is detected. In this case, the controller 220 may reduce the data transmission speed of the data transmission device 210 at block 506. Alternatively or additionally, if it is determined that the amount of data transmitted is less than or equal to the data amount threshold, the controller 220 may continue to measure the amount of data transmitted by the data transmission device 210 within the current RTT.
[0077] In some embodiments, at block 506, the controller 220 may reduce the data transmission speed of the data transmission device 210 according to equation (4):
[0078]
[0079] Wherein R is the current data transmission speed, R' is the updated (reduced) data transmission speed, and N is an integer, which may be predefined or determined according to the data transmission speed.
[0080] Next, in block 508, the controller 220 may record the current time and store the current time as the deceleration time. In some embodiments, the method 500 includes a deceleration interval time. Specifically, within the deceleration interval time after the deceleration time of this deceleration, the controller 220 may not reduce the data transmission speed of the data transmission device 210 again.
[0081] At block 510, after a certain period of time, the controller 220 may restore the data transmission speed to the value before the speed reduction. For example, at the end of the current RTT, the controller 220 may increase the data transmission speed to the data transmission speed before the speed reduction.
[0082] In this way, the data transmission speed of the data transmission device 210 can be effectively reduced when a warning event is detected, which can advantageously alleviate and / or avoid congestion in the data network, thereby improving the data transmission efficiency in the data network.
[0083] Figure 6 A flowchart of a method 600 for reducing the data transmission speed of a data transmission device according to some embodiments of the present disclosure is shown. Figure 2 The method 600 for reducing the data transmission speed is described by taking the data transmission device 210 and the controller 220 in FIG.
[0084] In some embodiments, Figure 6 The method 600 of reducing the data transmission speed is shown in association with a congestion event. Figure 6 As shown, the controller 220 may detect the occurrence of a CNP event at block 602. For example, if the controller 220 detects that a CNP message or a data packet with an ECN mark is received within the current RTT, the controller 220 may determine that a CNP event occurs.
[0085] In this case, at block 604, the controller 220 reduces the data transmission speed of the data transmission device 210. In some embodiments, the controller 220 may use equation (2) to update the data transmission speed of the data transmission device 210. In some implementations, the speed reduction coefficient β in equation (2) may be predefined or determined based on the data transmission speed R. In addition, β may be a different value for a congestion event or a warning event.
[0086] Next, in block 606, the controller 220 records the current time and stores the current time as the deceleration time of this deceleration. In some embodiments, the method 600 includes a deceleration interval time. Specifically, within the deceleration interval time after the deceleration time of this deceleration, the controller 220 may not reduce the data transmission speed of the data transmission device 210 again.
[0087] In this way, the data transmission speed of the data transmission device can be flexibly and effectively reduced when a congestion event is detected, which is beneficial to alleviate congestion in the data network, thereby improving the data transmission efficiency in the data network.
[0088] Figure 7 FIG. 7 is a flowchart of a method 700 for adjusting the data transmission speed of a data transmission device according to some embodiments of the present disclosure. Figure 2 The method 700 for adjusting the data transmission speed is described by taking the data transmission device 210 and the controller 220 in FIG. 7 as an example.
[0089] like Figure 7 As shown in FIG. 7 , in block 702 , the controller 220 may control the data transmission device 210 to transmit data.
[0090] Next, at block 704, the controller 220 may determine a data volume threshold for the data transmission device 210. In some embodiments, the controller 220 may include: Figure 3 In this case, the controller 220 can use Figure 3 The speed control function module 330 determines the data volume threshold of the data transmission device 210 based on the burst information sent by the sending pipeline 310 and the RTT information sent by the receiving pipeline 320 in combination with the method described above.
[0091] Next, at block 706, the controller 220 may determine whether the amount of data transmitted by the data transmission device 210 is greater than the data amount threshold within the current RTT. If the controller 220 determines that the amount of data transmitted by the data transmission device 210 is greater than the data amount threshold, the controller 220 reduces the data transmission speed of the data transmission device 210 at block 712. And at block 710, the current time is recorded and stored as the speed reduction time of this speed reduction.
[0092] In addition, at block 708, the controller 220 may detect that a CNP event has occurred. In this case, the controller 220 reduces the data transmission speed of the data transmission device 210 at block 712. And at block 710, the current time is recorded and stored as the speed reduction time of this speed reduction.
[0093] In some embodiments, when reducing the data transmission speed in box 712, the speed reduction method for detecting the CNP event in box 708 and the speed reduction method for determining that the amount of data transmitted by the data transmission device 210 is greater than the data amount threshold in box 706 may be different.
[0094] For example, if a CNP event is detected in block 708, the controller 220 may utilize Figure 6The method 600 for reducing the data transmission speed shown in FIG. 60 reduces the data transmission speed of the data transmission device 210 at block 712. In addition, if it is determined in block 706 that the amount of data transmitted by the data transmission device 210 is greater than the data amount threshold, the controller 220 may utilize Figure 5 The illustrated method 500 of reducing a data transmission speed reduces a data transmission speed of the data transmission device 210 at block 712 .
[0095] Alternatively or additionally, in box 714, if the controller 220 determines that the time length from the last speed adjustment time (including the last time the speed reduction or speed increase occurred) to the current time is greater than the RTT, the controller 220 determines in box 716 whether a CNP event occurs within the current RTT.
[0096] In this case, if the controller 220 determines in block 716 that the data transmission device 210 has not received a CNP message or a data packet with an ECN mark within the current RTT, the controller 220 increases the data transmission speed in block 718 .
[0097] For example, the controller 220 may utilize Figure 4 The illustrated method 400 for increasing data transmission speed increases the data transmission speed of the data transmission device 210 at block 718 .
[0098] Next, at block 720 , the controller 220 may measure and record the current RTT and update the RTT in block 714 using the measured current RTT.
[0099] In this way, the controller 220 can effectively reduce the data transmission speed of the data transmission device 210 when a congestion event or a warning event is detected and increase the data transmission speed when no congestion event or a warning event occurs, thereby improving the data transmission efficiency in the data network.
[0100] Figure 8 A flow chart of a method 800 for controlling data transmission according to some embodiments of the present disclosure is shown. The method 800 for controlling data transmission may be executed by the controller 220 discussed above, for example.
[0101] like Figure 8 As shown in , method 800 starts at 810. At 810, the controller 220 detects at least one of a congestion event and a warning event associated with a data transmission device in a data network within a first predetermined period of time. The warning event is related to the amount of data sent by the data transmission device. At 820, the controller 220 adjusts the data transmission speed of the data transmission device based on the detection result.
[0102] In some exemplary embodiments, the controller 220 may adjust the data transmission speed of the data transmission device in the following manner: if no congestion event is detected within the first predetermined time period, the data transmission speed of the data transmission device is increased; and if a congestion event or a warning event is detected within the first predetermined time period, the data transmission speed of the data transmission device is reduced.
[0103] In some exemplary embodiments, the controller 220 may increase the data transmission speed of the data transmission device by increasing the data transmission speed by a predetermined amount at the time point when the first predetermined period ends.
[0104] In some exemplary embodiments, the controller 220 may reduce the data transmission speed of the data transmission device by reducing the data transmission speed to a predetermined ratio of the data transmission speed or to a predetermined value, wherein the predetermined ratio is greater than 0 and less than 1.
[0105] In some exemplary embodiments, if a congestion event is detected, the controller 220 may further reduce the data transmission speed by multiplying the data transmission speed by a first coefficient; or if a warning event is detected, the controller 220 may further reduce the data transmission speed by multiplying the data transmission speed by a second coefficient.
[0106] In some exemplary embodiments, if the congestion prompt information is not received within the first predetermined period, the controller 220 may also determine that no congestion event is detected within the first predetermined period; and if the congestion prompt information is received within the first predetermined period, the controller 220 may also determine that a congestion event is detected within the first predetermined period. The congestion prompt information includes a congestion prompt data packet or a data packet with a congestion mark.
[0107] In some exemplary embodiments, if it is determined that the amount of data sent by the data transmission device within the first predetermined period is greater than the data amount threshold, the controller 220 may also determine that a warning event is detected within the first predetermined period.
[0108] In some exemplary embodiments, the data amount threshold may correspond to a maximum amount of data that the data transmission device is allowed to transmit.
[0109] In some exemplary embodiments, the controller 220 may also determine a data volume threshold based on a current data propagation speed of the data transmission device and a reference period; and determine the amount of data transmitted by the data transmission device within a first predetermined period as the amount of data sent.
[0110] In some exemplary embodiments, the reference time period may correspond to a minimum value among a plurality of round trip delays of the data transmission device within the second predetermined time period.
[0111] In some exemplary embodiments, in method 800, the first predetermined period may include a round trip delay of the data transmission device.
[0112] Fig. 9 A block diagram of an apparatus 900 for controlling data transmission according to some embodiments of the present disclosure is shown. The apparatus 900 for controlling data transmission may be implemented as or included in the above-mentioned controller 220. Each module / component in the apparatus 900 for controlling data transmission may be implemented by hardware, software, firmware, or any combination thereof.
[0113] like Fig. 9 As shown, the device 900 for controlling data transmission includes: a detection module 910, configured to detect at least one of a congestion event and a warning event associated with a data transmission device in a data network within a first predetermined time period, the warning event being related to the amount of data sent by the data transmission device; and an adjustment module 920, configured to adjust the data transmission speed of the data transmission device based on the detection result.
[0114] In some exemplary embodiments, the adjustment module 920 can also be configured to increase the data transmission speed of the data transmission device if no congestion event is detected within the first predetermined time period; and to reduce the data transmission speed of the data transmission device if a congestion event or a warning event is detected within the first predetermined time period.
[0115] In some exemplary embodiments, the adjustment module 920 may also be configured to increase the data transmission speed by a predetermined amount at a time point when the first predetermined period ends.
[0116] In some exemplary embodiments, the adjustment module 920 may be further configured to reduce the data transmission speed to a predetermined ratio of the data transmission speed or to a predetermined value, wherein the predetermined ratio is greater than 0 and less than 1.
[0117] In some exemplary embodiments, the adjustment module 920 may also be configured to reduce the data transmission speed by multiplying the data transmission speed by a first coefficient if a congestion event is detected; and reduce the data transmission speed by multiplying the data transmission speed by a second coefficient if a warning event is detected.
[0118] In some exemplary embodiments, the detection module 910 may also be configured to determine that no congestion event has been detected within the first predetermined time period if no congestion warning information is received within the first predetermined time period; and to determine that a congestion event has been detected within the first predetermined time period if congestion warning information is received within the first predetermined time period, wherein the congestion warning information includes a congestion warning data packet or a data packet with a congestion mark.
[0119] In some exemplary embodiments, the detection module 910 may also be configured to determine that a warning event is detected within the first predetermined period if it is determined that the amount of data sent by the data transmission device within the first predetermined period is greater than a data amount threshold.
[0120] In some exemplary embodiments, the data amount threshold may correspond to a maximum amount of data that the data transmission device is allowed to transmit.
[0121] In some exemplary embodiments, the detection module 910 can also be configured to determine a data volume threshold based on the current data propagation speed of the data transmission device and a reference time period; and determine the amount of data transmitted by the data transmission device within a first predetermined time period as the amount of data sent.
[0122] In some exemplary embodiments, the reference time period may correspond to a minimum value among a plurality of round trip delays of the data transmission device within the second predetermined time period.
[0123] In some exemplary embodiments, the first predetermined period may include a round trip delay of the data transmission device.
[0124] Fig.10 FIG. 1 is a block diagram of an electronic device 1000 capable of implementing an embodiment of the present disclosure. It should be understood that Fig.10 The electronic device 1000 shown is merely exemplary and should not constitute any limitation on the functionality and scope of the embodiments described herein. Fig.10 The electronic device 1000 shown can be used to implement the method described above. Fig.10 The electronic device 1000 shown can be used to implement Figure 2 The controller 220 in the embodiment may also be used to implement Fig. 9 The device 900 for controlling data transmission in FIG.
[0125] like Fig.10 As shown, the electronic device 1000 is in the form of a general-purpose computing device. The components of the electronic device 1000 may include, but are not limited to, one or more processors or processing units 1010, a memory 1020, a storage device 1030, one or more communication units 1040, one or more input devices 1050, and one or more output devices 1060. The processing unit 1010 may be an actual or virtual processor and is capable of performing various processes according to a program stored in the memory 1020. In a multi-processor system, multiple processing units execute computer executable instructions in parallel to improve the parallel processing capability of the electronic device 1000.
[0126] The electronic device 1000 typically includes a plurality of computer storage media. Such media may be any available media accessible to the electronic device 1000, including but not limited to volatile and non-volatile media, removable and non-removable media. The memory 1020 may be a volatile memory (e.g., a register, a cache, a random access memory (RAM)), a non-volatile memory (e.g., a read-only memory (ROM), an electrically erasable programmable read-only memory (EEPROM), flash memory), or some combination thereof. The storage device 1030 may be a removable or non-removable medium, and may include a machine-readable medium, such as a flash drive, a disk, or any other medium, which may be capable of being used to store information and / or data (e.g., training data for training) and may be accessed within the electronic device 1000.
[0127] The electronic device 1000 may further include additional removable / non-removable, volatile / non-volatile storage media. Fig.10 As shown in , a disk drive for reading or writing from a removable, non-volatile disk (e.g., a "floppy disk") and an optical drive for reading or writing from a removable, non-volatile optical disk may be provided. In these cases, each drive may be connected to the bus (not shown) by one or more data media interfaces. Memory 1020 may include a computer program product 1025 having one or more program modules that are configured to perform various methods or actions of various embodiments of the present disclosure.
[0128] The communication unit 1040 implements communication with other computing devices through a communication medium. Additionally, the functions of the components of the electronic device 1000 can be implemented in a single computing cluster or multiple computing machines that can communicate through a communication connection. Therefore, the electronic device 1000 can operate in a networked environment using a logical connection with one or more other servers, a network personal computer (PC), or another network node.
[0129] The input device 1050 may be one or more input devices, such as a mouse, a keyboard, a tracking ball, etc. The output device 1060 may be one or more output devices, such as a display, a speaker, a printer, etc. The electronic device 1000 may also communicate with one or more external devices (not shown) through the communication unit 1040 as needed, such as a storage device, a display device, etc., communicate with one or more devices that allow a user to interact with the electronic device 1000, or communicate with any device that allows the electronic device 1000 to communicate with one or more other computing devices (e.g., a network card, a modem, etc.). Such communication may be performed via an input / output (I / O) interface (not shown).
[0130] According to an exemplary embodiment of the present disclosure, a computer-readable storage medium is provided, on which computer-executable instructions are stored, wherein the computer-executable instructions are executed by a processor to implement the method described above. According to an exemplary embodiment of the present disclosure, a computer program product is also provided, the computer program product is tangibly stored on a non-transitory computer-readable medium and includes computer-executable instructions, and the computer-executable instructions are executed by a processor to implement the method described above. According to an exemplary embodiment of the present disclosure, a computer program product is provided, on which a computer program is stored, and when the program is executed by a processor, the method described above is implemented.
[0131] Various aspects of the present disclosure are described herein with reference to the flowcharts and / or block diagrams of the methods, devices, equipment, and computer program products implemented according to the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer-readable program instructions.
[0132] These computer-readable program instructions can be provided to a processing unit of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processing unit of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0133] Computer-readable program instructions can be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operational steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, so that the instructions executed on the computer, other programmable data processing apparatus, or other device implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0134] The flow chart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to multiple implementations of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and a part of a module, program segment or instruction includes one or more executable instructions for realizing the logical function of the specification. In some implementations as replacements, the function marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two continuous square boxes can actually be executed substantially in parallel, and they can sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be realized by a special hardware-based system that performs the function or action of the specification, or can be realized by a combination of special hardware and computer instructions.
[0135] The above descriptions of various implementations of the present disclosure are exemplary, non-exhaustive, and not limited to the disclosed implementations. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described implementations. The selection of terms used herein is intended to best explain the principles of the implementations, practical applications, or improvements to the technology in the marketplace, or to enable other persons of ordinary skill in the art to understand the various embodiments disclosed herein.
Claims
1. A method for controlling data transmission, comprising: detecting at least one of a congestion event and a warning event associated with a data transmission device in a data network within a first predetermined period of time, wherein the warning event is related to an amount of data sent by the data transmission device; as well as Based on the detection result, the data transmission speed of the data transmission device is adjusted.
2. The method according to claim 1, wherein adjusting the data transmission speed of the data transmission device comprises: In response to not detecting a congestion event within the first predetermined period, increasing the data transmission speed of the data transmission device; as well as In response to detecting the congestion event or the warning event within the first predetermined time period, reducing the data transmission speed of the data transmission device.
3. The method according to claim 2, wherein increasing the data transmission speed of the data transmission device comprises: At a time point when the first predetermined period ends, the data transmission speed is increased by a predetermined amount.
4. The method according to claim 2, wherein reducing the data transmission speed of the data transmission device comprises: The data transmission speed is reduced to a predetermined ratio of the data transmission speed or to a predetermined value, wherein the predetermined ratio is greater than 0 and less than 1.
5. The method according to claim 2, wherein the method comprises: In response to detecting the congestion event within the first predetermined period, reducing the data transmission speed by multiplying the data transmission speed by the first coefficient; or In response to detecting the warning event within the first predetermined period, the data transmission speed is reduced by multiplying the data transmission speed by the second coefficient.
6. The method according to claim 1, further comprising: In response to not receiving congestion prompt information within the first predetermined time period, determining that the congestion event is not detected within the first predetermined time period; as well as In response to receiving congestion prompt information within the first predetermined time period, determining that the congestion event is detected within the first predetermined time period, The congestion prompt information includes a congestion prompt data packet or a data packet with a congestion mark.
7. The method according to claim 1, further comprising: In response to determining that the amount of data sent by the data transmission device within the first predetermined time period is greater than a data amount threshold, it is determined that the warning event is detected within the first predetermined time period.
8. The method according to claim 7, wherein the data amount threshold corresponds to a maximum amount of data that the data transmission device is allowed to transmit.
9. The method according to claim 7, further comprising: determining the data volume threshold based on a current data propagation speed of the data transmission device and a reference period; as well as The amount of data transmitted by the data transmission device within the first predetermined time period is determined as the amount of data sent.
10. The method according to claim 9, wherein the reference time period corresponds to a minimum value among a plurality of round trip delays of the data transmission device within a second predetermined time period.
11. The method according to any one of claims 1 to 10, wherein the first predetermined period includes a round trip delay of the data transmission device.
12. A device for controlling data transmission, comprising: a detection module configured to detect at least one of a congestion event and a warning event associated with a data transmission device in a data network within a first predetermined period of time, wherein the warning event is related to an amount of data sent by the data transmission device; as well as The adjustment module is configured to adjust the data transmission speed of the data transmission device based on the detection result.
13. An electronic device comprising at least one processing unit; and At least one memory, the at least one memory being coupled to the at least one processing unit and storing instructions for execution by the at least one processing unit, the instructions causing the device to perform the method according to any one of claims 1 to 11 when executed by the at least one processing unit.
14. A computer-readable storage medium having a computer program stored thereon, wherein the computer program implements the method according to any one of claims 1 to 11 when executed by a processor.