Flow control method, flow control device and computer-readable storage medium
By identifying mutually exclusive devices in the network topology and calculating mutual exclusion weight coefficients, the flow is dynamically adjusted, which solves the performance impact caused by the failure to consider device mutual exclusion relationships in existing flow control methods and achieves flexible flow control.
Patent Information
- Application Number
- CN202411782608.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-05
- Publication Date
- 2025-12-02
- Estimated Expiration
- 2044-12-05
AI Technical Summary
Existing flow control methods cannot take into account the mutual exclusion relationships between different devices, resulting in fixed flow control strategies and affecting device performance.
By identifying mutually exclusive devices in the network topology that have a relationship with the target communication device, calculating the mutual exclusion weight coefficient, and dynamically adjusting the traffic of mutually exclusive devices when traffic is abnormal, the target device is restored to a normal traffic state.
It implements a flexible flow control strategy, avoiding the impact on device performance caused by fixed adjustments and improving the flexibility of flow adjustment.
Smart Images

Figure CN119676158B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of flow control technology, and more specifically, to a flow control method, a flow control device, and a computer-readable storage medium. Background Technology
[0002] In existing distributed systems, there are complex device scheduling relationships. Due to bandwidth limitations, there is traffic contention between devices. Devices with superior performance or those that establish connections first will obtain more bandwidth, thereby affecting network communication for other devices. Therefore, existing technologies implement traffic control for related devices in distributed systems.
[0003] Existing traffic control strategies typically limit traffic based on the current access status of devices, preset total bandwidth or total number of connections, and stop transmission when the threshold is reached, resuming new transmission only after the current transmission ends. This strategy cannot take into account the mutual exclusion relationship between different devices, and rigid traffic control strategies may affect the performance of critical devices.
[0004] Traditional flow control methods in the aforementioned technologies often fail to consider the mutual exclusion relationships between different devices to flexibly adjust the control strategy. They only limit the flow rate through preset limiting measures, which can easily affect device performance. Currently, no effective solution has been proposed. Summary of the Invention
[0005] This invention provides a flow control method, a flow control device, and a computer-readable storage medium to at least solve the technical problem that traditional flow control methods in the related art usually cannot take into account the mutual exclusion relationship between different devices to flexibly adjust the control strategy, and only limit the flow rate through preset limiting measures, which can easily affect the performance of the devices.
[0006] According to one aspect of the present invention, a flow control method is provided, comprising: determining that a communication device in a network topology that has a mutual exclusion relationship with a target communication device is a mutually exclusive communication device that is mutually exclusive with the target communication device, wherein the target communication device is a communication device in the network topology whose importance is higher than an importance threshold, and the mutual exclusion relationship is a relationship in which the communication devices use the same communication link for data transmission, resulting in traffic contention; calculating a mutual exclusion weight coefficient of the target communication device for each mutually exclusive communication device, wherein the mutual exclusion weight coefficient refers to the degree of communication influence of the target communication device on the mutually exclusive communication device; and, when the target communication device is in a traffic abnormal state, adjusting the traffic of each mutually exclusive communication device based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state, wherein the traffic abnormal state refers to a state in which the current traffic of the target communication device exceeds a traffic threshold, and the traffic normal state refers to a state in which the current traffic of the target communication device does not exceed the traffic threshold.
[0007] Optionally, before determining that a communication device in the network topology that has a mutual exclusion relationship with the target communication device is a mutually exclusive communication device that is mutually exclusive with the target communication device, the flow control method further includes: acquiring the communication devices that need to participate in communication in the network, the communication status of the communication devices, and the connection relationships between the communication devices; generating the network topology based on the communication devices and the connection relationships between the communication devices, wherein the network topology is used to reflect the communication status and the connection relationships of the communication devices; acquiring historical communication data of each communication device within a historical time period; evaluating the importance of each communication device based on the communication status, the connection relationships, and the historical communication data, respectively, and obtaining an evaluation result; and determining the communication device as the target communication device if the evaluation result indicates that the importance is higher than the importance threshold.
[0008] Optionally, determining that a communication device in the network topology that has a mutual exclusion relationship with the target communication device is a mutually exclusive communication device that is mutually exclusive with the target communication device includes: determining, based on the network topology, that the communication link used by the target communication device when transmitting data is a target communication link; and determining, based on the network topology, that a non-target communication device that uses the target communication link to transmit data is a mutually exclusive communication device that is mutually exclusive with the target communication device, wherein the non-target communication device is any communication device in the network topology other than the target communication device.
[0009] Optionally, calculating the mutual exclusion weight coefficient of the target communication device for each of the mutually exclusive communication devices includes: sequentially calculating the mutual exclusion weight coefficient of the target communication device for each of the mutually exclusive communication devices using a first formula, wherein the first formula is: W ij P represents the mutual exclusion weight coefficient between the target communication device i and the mutually exclusive communication device j. i B represents the communication priority of the target communication device i. i U represents the expected bandwidth of the target communication device i. j The actual bandwidth of the mutually exclusive communication device j is represented by N, the total number of the communication devices in the set of mutually exclusive communication devices is represented by k, and P represents the index of the communication device in the set of mutually exclusive communication devices. k B represents the communication priority of communication device k in the set of mutually exclusive communication devices. k U represents the expected bandwidth of communication device k in the set of mutually exclusive communication devices. k The actual bandwidth of communication device k in the set of mutually exclusive communication devices refers to the communication priority of the communication device in traffic resource allocation, the expected bandwidth refers to the bandwidth that the communication device is expected to use, and the actual bandwidth refers to the bandwidth that the communication device actually uses. The set of mutually exclusive communication devices is a set consisting of the target communication device and the mutually exclusive communication devices that are mutually exclusive with the target communication device.
[0010] Optionally, before adjusting the traffic of each of the mutually exclusive communication devices based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state, the traffic control method further includes: monitoring the traffic of the target communication device and obtaining monitoring results; determining the current traffic of the target communication device based on the monitoring results, wherein the current traffic refers to the amount of data transmitted by the target communication device per unit time; determining whether the current traffic exceeds the traffic threshold and obtaining a determination result; if the determination result indicates that the traffic threshold exceeds the traffic threshold, determining that the target communication device is in the abnormal traffic state; if the determination result indicates that the traffic threshold does not exceed the traffic threshold, determining that the target communication device is in the normal traffic state.
[0011] Optionally, when the target communication device is in an abnormal traffic state, adjusting the traffic of each of the mutually exclusive communication devices based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state includes: determining that the difference between the current traffic of the target communication device and the traffic threshold is the target traffic required for the target communication device to recover from the abnormal traffic state to the normal traffic state; determining the traffic adjustment ratio of each of the mutually exclusive communication devices according to the target traffic and the value of the mutual exclusion weight coefficient; and adjusting the traffic of the mutually exclusive communication devices according to the traffic adjustment ratio to restore the target communication device to a normal traffic state.
[0012] Optionally, when the target communication device is in an abnormal traffic state, adjusting the traffic of each of the mutually exclusive communication devices based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state includes: sorting the mutually exclusive communication devices in descending order according to the value of the mutual exclusion weight coefficient to obtain a sorting result; determining the mutually exclusive communication devices whose mutual exclusion weight coefficient is not less than a weight threshold as target mutually exclusive communication devices; adjusting the traffic of the target mutually exclusive communication devices and obtaining the current state of the target communication devices; if the current state is still in the abnormal traffic state, adjusting the traffic of the mutually exclusive communication devices other than the target mutually exclusive communication device in sequence according to the sorting result until the target communication device is restored to the normal traffic state.
[0013] According to another aspect of the present invention, a flow control device is also provided, comprising: a first determining unit, configured to determine that a communication device in a network topology that has a mutual exclusion relationship with a target communication device is a mutually exclusive communication device that is mutually exclusive with the target communication device, wherein the target communication device is a communication device in the network topology whose importance is higher than an importance threshold, and the mutual exclusion relationship is a relationship in which the communication devices use the same communication link for data transmission, resulting in traffic contention; a calculating unit, configured to calculate a mutual exclusion weight coefficient of the target communication device for each mutually exclusive communication device, wherein the mutual exclusion weight coefficient refers to the degree of communication influence of the target communication device on the mutually exclusive communication device; and an adjusting unit, configured to adjust the traffic of each mutually exclusive communication device based on the mutual exclusion weight coefficient when the target communication device is in a traffic abnormal state, so as to restore the target communication device to a normal traffic state, wherein the traffic abnormal state refers to the state in which the current traffic of the target communication device exceeds a traffic threshold, and the traffic normal state refers to the state in which the current traffic of the target communication device does not exceed the traffic threshold.
[0014] Optionally, the flow control device further includes: a first acquisition unit, configured to acquire, before determining that a communication device in the network topology that has a mutual exclusion relationship with a target communication device is a mutually exclusive communication device mutually exclusive with the target communication device, the communication devices that need to participate in communication, the communication status of the communication devices, and the connection relationships between the communication devices; a generation unit, configured to generate the network topology based on the communication devices and the connection relationships between the communication devices, wherein the network topology is used to reflect the communication status and the connection relationships of each communication device; a second acquisition unit, configured to acquire historical communication data of each communication device within a historical time period; a third acquisition unit, configured to evaluate the importance of each communication device based on the communication status, the connection relationships, and the historical communication data, and obtain an evaluation result; and a second determination unit, configured to determine the communication device as the target communication device if the evaluation result indicates that the importance is higher than the importance threshold.
[0015] Optionally, the first determining unit includes: a first determining module, configured to determine, based on the network topology, that the communication link used by the target communication device for data transmission is a target communication link; and a second determining module, configured to determine, based on the network topology, that a non-target communication device using the target communication link for data transmission is a mutually exclusive communication device that is mutually exclusive with the target communication device, wherein the non-target communication device is any communication device in the network topology other than the target communication device.
[0016] Optionally, the calculation unit includes: a calculation module, configured to sequentially calculate the mutual exclusion weight coefficient of the target communication device for each of the mutually exclusive communication devices using a first formula, wherein the first formula is: W ij P represents the mutual exclusion weight coefficient between the target communication device i and the mutually exclusive communication device j. i B represents the communication priority of the target communication device i. i U represents the expected bandwidth of the target communication device i. j The actual bandwidth of the mutually exclusive communication device j is represented by N, the total number of the communication devices in the set of mutually exclusive communication devices is represented by k, and P represents the index of the communication device in the set of mutually exclusive communication devices. k B represents the communication priority of communication device k in the set of mutually exclusive communication devices. k U represents the expected bandwidth of communication device k in the set of mutually exclusive communication devices. kThe actual bandwidth of communication device k in the set of mutually exclusive communication devices refers to the communication priority of the communication device in traffic resource allocation, the expected bandwidth refers to the bandwidth that the communication device is expected to use, and the actual bandwidth refers to the bandwidth that the communication device actually uses. The set of mutually exclusive communication devices is a set consisting of the target communication device and the mutually exclusive communication devices that are mutually exclusive with the target communication device.
[0017] Optionally, the flow control device further includes: a fourth acquisition unit, configured to monitor the flow of the target communication device and obtain a monitoring result before adjusting the flow of each of the mutually exclusive communication devices based on the mutual exclusion weight coefficient to restore the target communication device to a normal flow state; a third determination unit, configured to determine the current flow of the target communication device based on the monitoring result, wherein the current flow refers to the amount of data transmitted by the target communication device per unit time; a fifth acquisition unit, configured to determine whether the current flow exceeds the flow threshold and obtain a determination result; a fourth determination unit, configured to determine that the target communication device is in the abnormal flow state if the determination result indicates that the flow threshold exceeds the flow threshold; and a fifth determination unit, configured to determine that the target communication device is in the normal flow state if the determination result indicates that the flow threshold does not exceed the flow threshold.
[0018] Optionally, the adjustment unit includes: a third determining module, configured to determine that the difference between the current traffic of the target communication device and the traffic threshold is the target traffic required for the target communication device to recover from the abnormal traffic state to the normal traffic state; a fourth determining module, configured to determine the traffic adjustment ratio of each of the mutually exclusive communication devices based on the target traffic and the value of the mutual exclusion weight coefficient; and a first adjusting module, configured to adjust the traffic of the mutually exclusive communication devices according to the traffic adjustment ratio, so that the target communication device recovers to the normal traffic state.
[0019] Optionally, the adjustment unit includes: a first acquisition module, configured to sort the mutually exclusive communication devices in descending order according to the value of the mutual exclusion weight coefficient to obtain a sorting result; a fifth determination module, configured to determine the mutually exclusive communication devices whose mutual exclusion weight coefficient is not less than a weight threshold as target mutually exclusive communication devices; a second acquisition module, configured to adjust the traffic of the target mutually exclusive communication device and then acquire the current state of the target communication device; and a second adjustment module, configured to, if the current state is still in the abnormal traffic state, adjust the traffic of the mutually exclusive communication devices other than the target mutually exclusive communication device according to the sorting result until the target communication device returns to the normal traffic state.
[0020] According to another aspect of the present invention, a flow control system is also provided, which uses any of the flow control methods described above.
[0021] According to another aspect of the present invention, a computer-readable storage medium is also provided, the computer-readable storage medium including a stored program, wherein the program executes any of the flow control methods described above.
[0022] According to another aspect of the present invention, a processor is also provided, the processor being configured to run a program, wherein the program, when running, executes any of the flow control methods described above.
[0023] According to another aspect of the present invention, a computer program product is also provided, including computer instructions that, when executed by a processor, perform any of the flow control methods described above.
[0024] In this embodiment of the invention, communication devices in the network topology that have a mutual exclusion relationship with the target communication device are identified as mutually exclusive communication devices that are mutually exclusive with the target communication device. The target communication device is defined as a communication device in the network topology whose importance exceeds a certain threshold. The mutual exclusion relationship is a relationship where communication devices use the same communication link for data transmission, resulting in traffic contention. A mutual exclusion weight coefficient is calculated for each mutually exclusive communication device, where the mutual exclusion weight coefficient indicates the degree of communication influence of the target communication device on the mutually exclusive communication device. When the target communication device is in an abnormal traffic state, the traffic of each mutually exclusive communication device is adjusted based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state. An abnormal traffic state refers to a state where the current traffic of the target communication device exceeds a traffic threshold, and a normal traffic state refers to a state where the current traffic of the target communication device does not exceed a traffic threshold. The above technical solution achieves the goal of adjusting the traffic flow of other devices by analyzing the mutual exclusion relationship between a communication device and other devices, and adjusting the traffic flow of the communication device to restore it to a normal traffic state when the communication device is in an abnormal traffic state, based on the calculated mutual exclusion weight coefficient. This realizes the technical effect of dynamically adjusting the traffic control strategy by considering the mutual exclusion relationship between different devices, improving the flexibility of traffic adjustment, and avoiding the defects of affecting device performance due to fixed adjustment or limitation of traffic. In addition, it solves the technical problem that traditional traffic control methods in related technologies usually cannot consider the mutual exclusion relationship between different devices to flexibly adjust the control strategy, and can easily affect device performance by limiting the traffic flow by only using preset limitation measures. Attached Figure Description
[0025] The accompanying drawings, which are included to provide a further understanding of the invention and form part of this application, illustrate exemplary embodiments of the invention and, together with their description, serve to explain the invention and do not constitute an undue limitation thereof. In the drawings:
[0026] Figure 1 This is a hardware structure block diagram of a mobile terminal for a flow control method according to an embodiment of the present invention.
[0027] Figure 2 This is a flowchart of a flow control method according to an embodiment of the present invention;
[0028] Figure 3 This is a flowchart of an optional flow control method according to an embodiment of the present invention;
[0029] Figure 4 This is a schematic diagram of a flow control device according to an embodiment of the present invention. Detailed Implementation
[0030] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.
[0031] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0032] As described in the background section, traditional flow control methods in related technologies often fail to consider the mutual exclusion relationships between different devices to flexibly adjust the control strategy. They only limit the flow rate through preset limiting measures, which can easily affect device performance. To address the above shortcomings, embodiments of the present invention provide a flow control method, a flow control device, and a computer-readable storage medium.
[0033] The technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.
[0034] The methods and embodiments provided in this invention can be executed on a mobile terminal, a computer terminal, or a similar computing device. Taking running on a mobile terminal as an example, Figure 1 This is a hardware structure block diagram of a mobile terminal for a flow control method according to an embodiment of the present invention. Figure 1 As shown, a mobile terminal may include one or more ( Figure 1 Only one is shown in the diagram. A processor 102 (which may include, but is not limited to, a microprocessor MCU or a programmable logic device FPGA, etc.) and a memory 104 for storing data are also shown. The mobile terminal may further include a transmission device 106 for communication functions and an input / output device 108. Those skilled in the art will understand that... Figure 1 The structure shown is for illustrative purposes only and does not limit the structure of the mobile terminal described above. For example, the mobile terminal may also include components that are more... Figure 1 The more or fewer components shown, or having the same Figure 1 The different configurations shown.
[0035] The memory 104 can be used to store computer programs, such as application software programs and modules, like the computer program corresponding to the flow control method in this embodiment of the invention. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, thereby implementing the above-described method. The memory 104 may include high-speed random access memory and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include memory remotely located relative to the processor 102, and these remote memories can be connected to the mobile terminal via a network. Examples of the aforementioned networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof. The transmission device 106 is used to receive or send data via a network. Specific examples of the aforementioned networks may include wireless networks provided by the mobile terminal's communication provider. In one example, the transmission device 106 includes a Network Interface Controller (NIC), which can be connected to other network devices via a base station to communicate with the Internet. In one example, the transmission device 106 may be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.
[0036] According to an embodiment of the present invention, a method embodiment of a flow control method is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.
[0037] Figure 2 This is a flowchart of a flow control method according to an embodiment of the present invention, such as... Figure 2 As shown, the method includes the following steps:
[0038] Step S202: Determine the communication devices in the network topology that have a mutual exclusion relationship with the target communication device as mutually exclusive communication devices that are mutually exclusive with the target communication device. The target communication device is a communication device in the network topology whose importance is higher than the importance threshold. The mutual exclusion relationship is a relationship in which the communication devices use the same communication link for data transmission, resulting in traffic contention.
[0039] In this embodiment, communication devices that have a mutual exclusion relationship with the target communication device can be identified based on the connection relationships between communication devices in the network topology. The target communication device can actually be any communication device in the network topology; however, some communication devices may have a lower probability of experiencing traffic anomalies. To improve analysis efficiency, key devices that are more prone to traffic anomalies and have mutual exclusion relationships with many other communication devices can be selected as the target communication device for analysis.
[0040] According to the above embodiments of the present invention, before step S202, that is, before determining that the communication devices in the network topology that have a mutual exclusion relationship with the target communication device are mutually exclusive communication devices that are mutually exclusive with the target communication device, the flow control method further includes: acquiring the communication devices that need to participate in communication in the network, the communication status of the communication devices, and the connection relationship between each communication device; generating a network topology based on the communication devices and the connection relationship between each communication device, wherein the network topology is used to reflect the communication status and connection relationship of each communication device; acquiring historical communication data of each communication device within a historical time period; evaluating the importance of each communication device based on the communication status, connection relationship, and historical communication data, and obtaining an evaluation result; and determining the communication device as the target communication device when the evaluation result indicates that the importance is higher than the importance threshold.
[0041] The following is combined Figure 3 The embodiments of the present invention will be described in detail below. Figure 3 This is a flowchart of an optional flow control method according to an embodiment of the present invention.
[0042] like Figure 3As shown, a network topology can be generated based on the connection relationships between communication devices. These connection relationships can include, but are not limited to, wireless network connections via routers, wireless network connections via Bluetooth, wired connections, etc. The network topology can clearly define the communication methods, communication links, and link types used between communication devices.
[0043] Additionally, the importance of each communication device can be assessed based on its historical communication data to determine whether it is necessary to target it for traffic anomaly analysis. Assuming communication device A is chosen as the target for traffic control and adjustment, the following conditions or considerations are typically taken into account: 1) Criticality: Device A is often a critical device playing a vital role in the network, meaning its normal operation has a significant impact on the functionality, performance, and stability of the entire system. For example, device A might be a data processing center, server, gateway, or other core component; its traffic anomalies could lead to service interruptions or quality degradation, affecting user experience or business operations. 2) Severity of Traffic Anomalies: If device A experiences a surge in traffic... If the traffic of device A drops to a level exceeding the normal range, causing its bandwidth consumption to significantly impact the performance of other devices or the entire network, then device A becomes the focus of attention; 3) Mutual exclusion: Device A has a mutual exclusion relationship with other devices in the network, meaning they may share the same network resources or links. When changes in device A's traffic may affect devices that are mutually exclusive with it, device A becomes the priority in traffic control strategies; 4) Priority: In some cases, device A may have a higher priority than other devices. This priority may be based on the device's function, the urgency of the service, or user-defined rules. In the event of abnormal traffic, prioritizing the normal operation of device A may require adjusting the traffic of other devices.
[0044] According to the above embodiments of the present invention, in step S202, determining that a communication device in the network topology that has a mutual exclusion relationship with the target communication device is a mutually exclusive communication device that is mutually exclusive with the target communication device includes: determining, according to the network topology, that the communication link used by the target communication device when transmitting data is the target communication link; and determining, according to the network topology, that a non-target communication device that uses the target communication link to transmit data is a mutually exclusive communication device that is mutually exclusive with the target communication device, wherein the non-target communication device is a communication device in the network topology other than the target communication device.
[0045] Specifically, the communication links used by the target communication device can be determined based on the network topology. Other communication devices on these links are then considered mutually exclusive communication devices, potentially competing for bandwidth with the target communication link. For example, if device A and device B belong to the same communication link and use the same communication method to connect to the server, an increase in traffic to service B will affect the available bandwidth of service A. Figure 3 As shown, the target communication device and these mutually exclusive communication devices that are mutually exclusive with the target communication device can also be combined into a set of mutually exclusive communication devices.
[0046] It should be noted that in the embodiments provided by the present invention, only the mutual exclusion relationship between the target communication device and each mutually exclusive communication device is analyzed, and the mutual exclusion relationship between each mutually exclusive device is not considered for the time being.
[0047] Step S204: Calculate the mutual exclusion weight coefficient of the target communication device for each mutually exclusive communication device, where the mutual exclusion weight coefficient refers to the degree of communication influence of the target communication device on the mutually exclusive communication devices.
[0048] In this embodiment, the mutual exclusion weight coefficient between the target communication device and each mutually exclusive communication device can be calculated to provide reference data for adjusting the traffic of each device when the target communication device is in an abnormal traffic state.
[0049] It should be noted that the mutual exclusion weight coefficient here actually refers to the degree of mutual communication influence between the two communication devices. That is, the degree of communication influence of the target communication device on the mutually exclusive communication device can be considered to be approximately the same as the degree of communication influence of the mutually exclusive communication device on the target communication device.
[0050] According to the above embodiments of the present invention, in step S204, calculating the mutual exclusion weight coefficient of the target communication device to each mutually exclusive communication device includes: sequentially calculating the mutual exclusion weight coefficient of the target communication device to each mutually exclusive communication device using a first formula, wherein the first formula is: W ij P represents the mutual exclusion weight coefficient between target communication device i and mutually exclusive communication device j. i B represents the communication priority of the target communication device i. i U represents the expected bandwidth of the target communication device i. j Let N represent the actual bandwidth of the mutually exclusive communication device j, N represent the total number of communication devices in the set of mutually exclusive communication devices, k represent the index of the communication device in the set of mutually exclusive communication devices, and P represent the actual bandwidth of the mutually exclusive communication device j. k B represents the communication priority of communication device k in a set of mutually exclusive communication devices. k U represents the expected bandwidth of communication device k in a set of mutually exclusive communication devices. kThe actual bandwidth of communication device k in the set of mutually exclusive communication devices is represented by , communication priority refers to the priority of communication devices in traffic resource allocation, expected bandwidth refers to the bandwidth that the communication device is expected to use, and actual bandwidth refers to the bandwidth that the communication device actually uses. The set of mutually exclusive communication devices is a set consisting of the target communication device and mutually exclusive communication devices that are mutually exclusive with the target communication device.
[0051] Specifically, the mutual exclusion weight coefficient can be calculated based on factors such as historical data, service priority, and link bandwidth. Service priority can be represented using the weight coefficient of each communication device. For example, if device A has a higher service priority than device B, then device A's weight coefficient may be larger. The formula can be used based on these factors: Calculate the mutual exclusion weight coefficient of the target communication device for each mutually exclusive communication device, where W ij P represents the mutual exclusion weight coefficient between target communication device i and mutually exclusive communication device j. i B represents the communication priority of the target communication device i. i U represents the expected bandwidth of the target communication device i. j Let N represent the actual bandwidth of the mutually exclusive communication device j, N represent the total number of communication devices in the set of mutually exclusive communication devices, k represent the index of the communication device in the set of mutually exclusive communication devices, and P represent the actual bandwidth of the mutually exclusive communication device j. k B represents the communication priority of communication device k in a set of mutually exclusive communication devices. k U represents the expected bandwidth of communication device k in a set of mutually exclusive communication devices. k The actual bandwidth of communication device k in the set of mutually exclusive communication devices is represented by , communication priority refers to the priority of communication devices in traffic resource allocation, expected bandwidth refers to the bandwidth that the communication device is expected to use, and actual bandwidth refers to the bandwidth that the communication device actually uses.
[0052] Step S206: When the target communication device is in an abnormal traffic state, the traffic of each mutually exclusive communication device is adjusted based on the mutual exclusion weight coefficient so that the target communication device can be restored to a normal traffic state. Here, the abnormal traffic state refers to the state in which the current traffic of the target communication device exceeds the traffic threshold, and the normal traffic state refers to the state in which the current traffic of the target communication device does not exceed the traffic threshold.
[0053] As above Figure 3 As shown, when the target communication device is in an abnormal traffic state, the traffic of each communication device can be adjusted based on the mutual exclusion weight coefficients obtained in the above steps to restore it to a normal traffic state.
[0054] According to the above embodiments of the present invention, before step S206, that is, before adjusting the traffic of each mutually exclusive communication device based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state, the traffic control method further includes: monitoring the traffic of the target communication device and obtaining monitoring results; determining the current traffic of the target communication device based on the monitoring results, wherein the current traffic refers to the amount of data transmitted by the target communication device per unit time; determining whether the current traffic exceeds a traffic threshold and obtaining a judgment result; if the judgment result indicates that the traffic threshold exceeds the traffic threshold, determining that the target communication device is in an abnormal traffic state; if the judgment result indicates that the traffic threshold does not exceed the traffic threshold, determining that the target communication device is in a normal traffic state.
[0055] In this embodiment, before adjusting the traffic of each mutually exclusive communication device based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state, the traffic of the target communication device must first be monitored, and the monitoring results are used to determine whether the target communication device is currently in an abnormal traffic state. Specifically, during the traffic monitoring process, the current traffic of the target communication device can be obtained in real time, that is, the amount of data transmitted by the target communication device per unit time, and compared with a traffic threshold. If the current traffic of the target communication device does not exceed the traffic threshold, the target communication device is considered to be in a normal traffic state; if the current traffic of the target communication device exceeds the traffic threshold, the target communication device is considered to be in an abnormal traffic state.
[0056] In a specific embodiment of the present invention, when the target communication device is in an abnormal traffic state, the traffic of each mutually exclusive communication device is adjusted based on a mutual exclusion weight coefficient to restore the target communication device to a normal traffic state. This includes: determining that the difference between the current traffic of the target communication device and a traffic threshold is the target traffic required for the target communication device to recover from the abnormal traffic state to the normal traffic state; determining the traffic adjustment ratio of each mutually exclusive communication device according to the target traffic and the value of the mutual exclusion weight coefficient; and adjusting the traffic of the mutually exclusive communication devices according to the traffic adjustment ratio to restore the target communication device to a normal traffic state.
[0057] Specifically, the target traffic required for the target communication device to recover from an abnormal traffic state to a normal traffic state can be determined first based on the difference between the current traffic and the traffic threshold of the target communication device. Then, the traffic adjustment ratio of each mutually exclusive communication device can be determined based on the target traffic and the values of each mutual exclusion weight coefficient. That is, the target traffic is provided by each mutually exclusive communication device proportionally and evenly according to the values of the mutual exclusion weight coefficients to meet the traffic demand of the target communication device and restore it to a normal traffic state. It should be noted that the larger the mutual exclusion weight coefficient, the greater the degree of communication influence between the corresponding mutually exclusive communication device and the target communication device, and the higher its traffic adjustment ratio. The specific proportion of traffic adjustment for each mutually exclusive communication device is not elaborated here.
[0058] In another specific embodiment of the present invention, when the target communication device is in an abnormal traffic state, the traffic of each mutually exclusive communication device is adjusted based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state. This includes: sorting the mutually exclusive communication devices in descending order according to the value of the mutual exclusion weight coefficient to obtain a sorting result; determining the mutually exclusive communication devices whose mutual exclusion weight coefficient is not less than the weight threshold as the target mutually exclusive communication devices; adjusting the traffic of the target mutually exclusive communication devices and obtaining the current state of the target communication devices; if the current state is still in an abnormal traffic state, adjusting the traffic of the mutually exclusive communication devices other than the target mutually exclusive communication devices in turn according to the sorting result until the target communication device is restored to a normal traffic state.
[0059] Specifically, in order to adjust the traffic of as few mutually exclusive communication devices as possible and to restore the target communication device to a normal traffic state as quickly as possible, some mutually exclusive communication devices with mutual exclusion weight coefficients higher than a certain weight threshold can be selected first. Their traffic can be adjusted while affecting the normal traffic usage of these devices. If the traffic demand of the target communication device still cannot be met after adjustment (i.e., the target communication device is still in an abnormal traffic state after adjustment), the traffic of the remaining mutually exclusive communication devices can be adjusted in descending order of mutual exclusion weight coefficients. The traffic status of the target communication device can be obtained in real time. Once the traffic returns to a normal state, the remaining mutually exclusive communication devices will no longer be adjusted.
[0060] It should be noted that before adjusting the traffic of each mutually exclusive communication device to restore the target communication device to a normal traffic state using the method provided in the above embodiments of the present invention, the traffic of the target communication device can be adjusted first. For example, by reducing the data transmission rate of the target communication device, suspending non-critical data transmission, or reconfiguring its communication priority, the source of the traffic anomaly can be directly controlled. If adjusting the traffic of the target communication device alone cannot effectively alleviate the impact of its traffic anomaly, or in order to protect the normal service and critical functions of the target communication device, the traffic of the mutually exclusive communication devices can be further adjusted according to the mutual exclusion weight coefficient. This is to ensure that the target communication device can obtain sufficient resources while minimizing the impact on other devices, thereby achieving reasonable resource allocation and optimization of overall network performance.
[0061] Additionally, if adjusting the traffic of the target communication device and each mutually exclusive communication device using the above methods still fails to restore the target communication device to a normal traffic state, the following methods can be tried to solve the problem: 1) Increase bandwidth resources: Check whether the bandwidth of the communication link used by the target communication device has reached its limit. If possible, try to increase the bandwidth of the link, such as by upgrading network hardware or optimizing the network architecture to provide more network resources to the target communication device; 2) Optimize network path: Analyze the communication path of the target communication device to see if it is possible to change the data transmission path through rerouting or load balancing technology, thereby avoiding bottlenecks or busy links and improving the traffic processing capacity of the target communication device; 3) Traffic priority rescheduling: If the priority setting of the target communication device is insufficient, consider increasing its priority to give it higher weight in resource allocation. This may mean lowering the priority of other devices or services to ensure the target communication device has sufficient resources; 4) Device resource upgrade: Consider whether the target communication device itself may have resource bottlenecks, such as insufficient CPU, memory, or storage resources. If the target communication device's resources are the reason it cannot process traffic normally, it may be necessary to upgrade the hardware or optimize the software; 5) Troubleshooting and repair: Check for potential technical faults in the target communication device or network, such as hardware failures, software bugs, or configuration errors. Timely repair of these problems may naturally improve the traffic status of the target communication device; 6) Application-level optimization: If the traffic problem of the target communication device is caused by the application running on it, optimization can be performed at the application level, such as adjusting the application's resource consumption strategy, optimizing data processing algorithms, or reducing unnecessary data transmission; 7) Implement more precise traffic control: Develop more complex traffic control algorithms that can more accurately identify and respond to the traffic demand of the target communication device. For example, introduce machine learning-based predictive models to dynamically predict the traffic demand of the target communication device and make adjustments in advance.
[0062] As described above, the technical solution provided by the embodiments of the present invention can identify communication devices in the network topology that have a mutual exclusion relationship with the target communication device as mutually exclusive communication devices. The target communication device is a communication device in the network topology whose importance is higher than an importance threshold. The mutual exclusion relationship is a relationship where communication devices use the same communication link for data transmission, resulting in traffic contention. The mutual exclusion weight coefficient of the target communication device to each mutually exclusive communication device is calculated, where the mutual exclusion weight coefficient indicates the degree of communication influence of the target communication device on the mutually exclusive communication device. When the target communication device is in an abnormal traffic state, the traffic of each mutually exclusive communication device is adjusted based on the mutual exclusion weight coefficient. This method aims to restore the target communication device to a normal traffic state. An abnormal traffic state refers to a situation where the current traffic of the target communication device exceeds a traffic threshold, while a normal traffic state refers to a situation where the current traffic of the target communication device does not exceed the traffic threshold. This achieves the goal of adjusting the traffic of other devices by analyzing the mutual exclusion relationships between a particular communication device and other devices, and by using the calculated mutual exclusion weight coefficients when the target communication device is in an abnormal traffic state. This realizes the technical effect of dynamically adjusting the traffic control strategy by considering the mutual exclusion relationships between different devices, improving the flexibility of traffic adjustment, and avoiding the defects of affecting device performance due to fixed traffic adjustments or limits.
[0063] Therefore, the technical solution provided by the above embodiments of the present invention solves the technical problem that traditional flow control methods in the related art usually cannot take into account the mutual exclusion relationship between different devices to flexibly adjust the control strategy, and only limit the flow rate through preset limiting measures, which easily affects the performance of the device.
[0064] It should be noted that, for the sake of simplicity, the foregoing method embodiments are all described as a series of actions. However, those skilled in the art should understand that this application is not limited to the described order of actions, as some steps may be performed in other orders or simultaneously according to this application. Furthermore, those skilled in the art should also understand that the embodiments described in the specification are preferred embodiments, and the actions and modules involved are not necessarily essential to this application.
[0065] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods according to the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of this application.
[0066] According to embodiments of the present invention, a flow control device for implementing the above-described flow control method is also provided. Figure 4 This is a schematic diagram of a flow control device according to an embodiment of the present invention, such as... Figure 4 As shown, the device includes: a first determining unit 41, a calculating unit 43, and an adjusting unit 45. The flow control device will now be described in detail.
[0067] The first determining unit 41 is used to determine that communication devices in the network topology that have a mutual exclusion relationship with the target communication device are mutually exclusive communication devices that are mutually exclusive with the target communication device. The target communication device is a communication device in the network topology whose importance is higher than the importance threshold, and the mutual exclusion relationship is a relationship in which the communication devices use the same communication link to transmit data, resulting in traffic competition.
[0068] The calculation unit 43 is used to calculate the mutual exclusion weight coefficient of the target communication device to each mutually exclusive communication device, wherein the mutual exclusion weight coefficient refers to the degree of communication influence of the target communication device on the mutually exclusive communication devices.
[0069] The adjustment unit 45 is used to adjust the traffic of each mutually exclusive communication device based on the mutual exclusion weight coefficient when the target communication device is in an abnormal traffic state, so as to restore the target communication device to a normal traffic state. The abnormal traffic state refers to the state in which the current traffic of the target communication device exceeds the traffic threshold, and the normal traffic state refers to the state in which the current traffic of the target communication device does not exceed the traffic threshold.
[0070] It should be noted that the first determining unit 41, the calculation unit 43 and the adjustment unit 45 mentioned above correspond to steps S202 to S206 in the above embodiments. The three units and the corresponding steps implement the same instances and application scenarios, but are not limited to the content disclosed in the above embodiments.
[0071] As can be seen from the above, in the scheme described in the above embodiments of the present invention, the first determining unit can be used to determine the communication devices in the network topology that have a mutual exclusion relationship with the target communication device as mutually exclusive communication devices that are mutually exclusive with the target communication device. The target communication device is a communication device in the network topology whose importance is higher than an importance threshold, and the mutual exclusion relationship is a relationship where communication devices use the same communication link for data transmission, resulting in traffic contention. Then, the calculation unit calculates the mutual exclusion weight coefficient of the target communication device for each mutually exclusive communication device, where the mutual exclusion weight coefficient refers to the degree of communication influence of the target communication device on the mutually exclusive communication devices. Finally, the adjustment unit adjusts the mutual exclusion weight coefficient of each mutually exclusive communication device when the target communication device is in an abnormal traffic state. The device's traffic is adjusted to restore the target communication device to a normal traffic state. An abnormal traffic state refers to the target communication device's current traffic exceeding a traffic threshold, while a normal traffic state refers to the target communication device's current traffic not exceeding a traffic threshold. This achieves the goal of adjusting the traffic of other devices when the target communication device is in an abnormal traffic state by analyzing the mutual exclusion relationships between a particular communication device and other devices, and by using the calculated mutual exclusion weight coefficients. This realizes the technical effect of dynamically adjusting the traffic control strategy by considering the mutual exclusion relationships between different devices, improving the flexibility of traffic adjustment, and avoiding the defects of affecting device performance due to fixed traffic adjustments or limits.
[0072] Therefore, the technical solution provided by the above embodiments of the present invention solves the technical problem that traditional flow control methods in the related art usually cannot take into account the mutual exclusion relationship between different devices to flexibly adjust the control strategy, and only limit the flow rate through preset limiting measures, which easily affects the performance of the device.
[0073] Optionally, the flow control device further includes: a first acquisition unit, configured to acquire, before determining that a communication device in the network topology that has a mutual exclusion relationship with the target communication device is a mutually exclusive communication device mutually exclusive with the target communication device, the communication devices that need to participate in communication, the communication status of the communication devices, and the connection relationships between the communication devices; a generation unit, configured to generate a network topology based on the communication devices and the connection relationships between the communication devices, wherein the network topology is used to reflect the communication status and connection relationships of each communication device; a second acquisition unit, configured to acquire historical communication data of each communication device within a historical time period; a third acquisition unit, configured to evaluate the importance of each communication device based on the communication status, connection relationships, and historical communication data, and obtain an evaluation result; and a second determination unit, configured to determine the communication device as the target communication device if the evaluation result indicates that the importance is higher than the importance threshold.
[0074] Optionally, the first determining unit includes: a first determining module, configured to determine, based on the network topology, that the communication link used by the target communication device for data transmission is the target communication link; and a second determining module, configured to determine, based on the network topology, that a non-target communication device using the target communication link for data transmission is a mutually exclusive communication device that is mutually exclusive with the target communication device, wherein the non-target communication device is a communication device in the network topology other than the target communication device.
[0075] Optionally, the calculation unit includes: a calculation module, configured to sequentially calculate the mutual exclusion weight coefficient of the target communication device for each mutually exclusive communication device using a first formula, wherein the first formula is: W ij P represents the mutual exclusion weight coefficient between target communication device i and mutually exclusive communication device j. i B represents the communication priority of the target communication device i. i U represents the expected bandwidth of the target communication device i. j Let N represent the actual bandwidth of the mutually exclusive communication device j, N represent the total number of communication devices in the set of mutually exclusive communication devices, k represent the index of the communication device in the set of mutually exclusive communication devices, and P represent the actual bandwidth of the mutually exclusive communication device j. k B represents the communication priority of communication device k in a set of mutually exclusive communication devices. k U represents the expected bandwidth of communication device k in a set of mutually exclusive communication devices. k The actual bandwidth of communication device k in the set of mutually exclusive communication devices is represented by , communication priority refers to the priority of communication devices in traffic resource allocation, expected bandwidth refers to the bandwidth that the communication device is expected to use, and actual bandwidth refers to the bandwidth that the communication device actually uses. The set of mutually exclusive communication devices is a set consisting of the target communication device and mutually exclusive communication devices that are mutually exclusive with the target communication device.
[0076] Optionally, the flow control device further includes: a fourth acquisition unit, used to monitor the flow of the target communication device and obtain monitoring results before adjusting the flow of each mutually exclusive communication device based on the mutual exclusion weight coefficient to restore the target communication device to a normal flow state; a third determination unit, used to determine the current flow of the target communication device based on the monitoring results, wherein the current flow refers to the amount of data transmitted by the target communication device per unit time; a fifth acquisition unit, used to determine whether the current flow exceeds the flow threshold and obtain a determination result; a fourth determination unit, used to determine that the target communication device is in an abnormal flow state if the determination result indicates that the flow threshold exceeds the flow threshold; and a fifth determination unit, used to determine that the target communication device is in a normal flow state if the determination result indicates that the flow threshold does not exceed the flow threshold.
[0077] Optionally, the adjustment unit includes: a third determining module, used to determine that the difference between the current traffic of the target communication device and the traffic threshold is the target traffic required for the target communication device to recover from an abnormal traffic state to a normal traffic state; a fourth determining module, used to determine the traffic adjustment ratio of each mutually exclusive communication device based on the target traffic and the value of the mutual exclusion weight coefficient; and a first adjusting module, used to adjust the traffic of the mutually exclusive communication devices according to the traffic adjustment ratio so that the target communication device recovers to a normal traffic state.
[0078] Optionally, the adjustment unit includes: a first acquisition module, used to sort the mutually exclusive communication devices in descending order according to the value of their mutual exclusion weight coefficients to obtain a sorting result; a fifth determination module, used to determine the mutually exclusive communication devices whose mutual exclusion weight coefficients are not less than a weight threshold as target mutually exclusive communication devices; a second acquisition module, used to adjust the traffic of the target mutually exclusive communication devices and then acquire the current state of the target communication devices; and a second adjustment module, used to adjust the traffic of the mutually exclusive communication devices other than the target mutually exclusive communication device in sequence according to the sorting result if the current state is still in an abnormal traffic state, until the target communication device returns to a normal traffic state.
[0079] According to another aspect of the present invention, a flow control system is also provided, which uses any of the flow control methods described above.
[0080] According to another aspect of the present invention, a computer-readable storage medium is also provided, the computer-readable storage medium including a stored program, wherein the program executes any of the above-described flow control methods.
[0081] Optionally, in this embodiment, the computer-readable storage medium may be located in any computer terminal in a group of computer terminals in a computer network, or in any communication device in a group of communication devices.
[0082] Optionally, in this embodiment, the computer-readable storage medium is configured to store program code for performing the following steps: determining communication devices in the network topology that have a mutual exclusion relationship with the target communication device as mutually exclusive communication devices, wherein the target communication device is a communication device in the network topology whose importance is higher than an importance threshold, and the mutual exclusion relationship is a relationship in which the communication devices use the same communication link for data transmission, resulting in traffic contention; calculating the mutual exclusion weight coefficient of the target communication device for each mutually exclusive communication device, wherein the mutual exclusion weight coefficient refers to the degree of communication influence of the target communication device on the mutually exclusive communication device; and adjusting the traffic of each mutually exclusive communication device based on the mutual exclusion weight coefficient when the target communication device is in an abnormal traffic state, so as to restore the target communication device to a normal traffic state, wherein the abnormal traffic state refers to the state in which the current traffic of the target communication device exceeds the traffic threshold, and the normal traffic state refers to the state in which the current traffic of the target communication device does not exceed the traffic threshold.
[0083] Optionally, in this embodiment, the computer-readable storage medium is configured to store program code for performing the following steps: obtaining communication devices that need to participate in communication in the network, the communication status of the communication devices, and the connection relationships between the communication devices; generating a network topology based on the communication devices and the connection relationships between them, wherein the network topology is used to reflect the communication status and connection relationships of each communication device; obtaining historical communication data of each communication device within a historical time period; evaluating the importance of each communication device based on the communication status, connection relationships, and historical communication data, and obtaining an evaluation result; and determining the communication device as the target communication device if the evaluation result indicates that the importance is higher than the importance threshold.
[0084] Optionally, in this embodiment, the computer-readable storage medium is configured to store program code for performing the following steps: determining, based on the network topology, that the communication link used by the target communication device for data transmission is the target communication link; determining, based on the network topology, that a non-target communication device using the target communication link for data transmission is a mutually exclusive communication device that is mutually exclusive with the target communication device, wherein the non-target communication device is a communication device in the network topology other than the target communication device.
[0085] Optionally, in this embodiment, the computer-readable storage medium is configured to store program code for performing the following steps: calculating the mutual exclusion weight coefficient of the target communication device for each mutually exclusive communication device sequentially using a first formula, wherein the first formula is: W ij P represents the mutual exclusion weight coefficient between target communication device i and mutually exclusive communication device j. i B represents the communication priority of the target communication device i. i U represents the expected bandwidth of the target communication device i.j Let N represent the actual bandwidth of the mutually exclusive communication device j, N represent the total number of communication devices in the set of mutually exclusive communication devices, k represent the index of the communication device in the set of mutually exclusive communication devices, and P represent the actual bandwidth of the mutually exclusive communication device j. k B represents the communication priority of communication device k in a set of mutually exclusive communication devices. k U represents the expected bandwidth of communication device k in a set of mutually exclusive communication devices. k The actual bandwidth of communication device k in the set of mutually exclusive communication devices is represented by , communication priority refers to the priority of communication devices in traffic resource allocation, expected bandwidth refers to the bandwidth that the communication device is expected to use, and actual bandwidth refers to the bandwidth that the communication device actually uses. The set of mutually exclusive communication devices is a set consisting of the target communication device and mutually exclusive communication devices that are mutually exclusive with the target communication device.
[0086] Optionally, in this embodiment, the computer-readable storage medium is configured to store program code for performing the following steps: monitoring the traffic of the target communication device and obtaining monitoring results; determining the current traffic of the target communication device based on the monitoring results, wherein the current traffic refers to the amount of data transmitted by the target communication device per unit time; determining whether the current traffic exceeds a traffic threshold and obtaining a judgment result; if the judgment result indicates that the traffic threshold exceeds the traffic threshold, determining that the target communication device is in an abnormal traffic state; if the judgment result indicates that the traffic threshold does not exceed the traffic threshold, determining that the target communication device is in a normal traffic state.
[0087] Optionally, in this embodiment, the computer-readable storage medium is configured to store program code for performing the following steps: determining the difference between the current traffic of the target communication device and the traffic threshold as the target traffic required for the target communication device to recover from an abnormal traffic state to a normal traffic state; determining the traffic adjustment ratio for each mutually exclusive communication device based on the target traffic and the value of the mutual exclusion weight coefficient; and adjusting the traffic of the mutually exclusive communication devices according to the traffic adjustment ratio so that the target communication device recovers to a normal traffic state.
[0088] Optionally, in this embodiment, the computer-readable storage medium is configured to store program code for performing the following steps: sorting the mutually exclusive communication devices in descending order according to the value of their mutual exclusion weight coefficients to obtain a sorting result; determining the mutually exclusive communication devices whose mutual exclusion weight coefficients are not less than a weight threshold as target mutually exclusive communication devices; adjusting the traffic of the target mutually exclusive communication devices and obtaining the current state of the target communication devices; if the current state is still in an abnormal traffic state, adjusting the traffic of the mutually exclusive communication devices other than the target mutually exclusive communication devices in turn according to the sorting result until the target communication device returns to a normal traffic state.
[0089] According to another aspect of the present invention, a processor is also provided, which is used to run a program, wherein the program executes any of the above-described flow control methods during runtime.
[0090] According to another aspect of the present invention, a computer program product is also provided, including computer instructions that, when executed by a processor, perform any of the above-described flow control methods.
[0091] The sequence numbers of the above embodiments of the present invention are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0092] In the above embodiments of the present invention, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0093] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units can be a logical functional division, and in actual implementation, there may be other division methods. For instance, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the displayed or discussed mutual coupling, direct coupling, or communication connection may be through some interfaces; the indirect coupling or communication connection between units or modules may be electrical or other forms.
[0094] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0095] Furthermore, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0096] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, read-only memory (ROM), random access memory (RAM), portable hard drives, magnetic disks, or optical disks.
[0097] The above description is only a preferred embodiment of the present invention. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A flow control method, characterized in that, include: The communication devices in the network topology that have a mutual exclusion relationship with the target communication device are identified as mutually exclusive communication devices that are mutually exclusive with the target communication device. The target communication device is the communication device in the network topology whose importance is higher than the importance threshold. The mutual exclusion relationship is a relationship in which the communication devices use the same communication link for data transmission, resulting in traffic contention. Calculate the mutual exclusion weight coefficient of the target communication device for each of the mutually exclusive communication devices, wherein the mutual exclusion weight coefficient refers to the degree of communication influence of the target communication device on the mutually exclusive communication devices; When the target communication device is in an abnormal traffic state, the traffic of each mutually exclusive communication device is adjusted based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state. The abnormal traffic state refers to the target communication device's current traffic exceeding a traffic threshold, while the normal traffic state refers to the target communication device's current traffic not exceeding the traffic threshold. Calculating the mutual exclusion weight coefficient of the target communication device for each of the mutually exclusive communication devices includes: sequentially calculating the mutual exclusion weight coefficient of the target communication device for each of the mutually exclusive communication devices using a first formula, wherein the first formula is: , This represents the mutual exclusion weight coefficient between the target communication device i and the mutually exclusive communication device j. This indicates the communication priority of the target communication device i. This represents the expected bandwidth of the target communication device i. Let N represent the actual bandwidth of the mutually exclusive communication device j, N represent the total number of the communication devices in the set of mutually exclusive communication devices, and k represent the index of the communication device in the set of mutually exclusive communication devices. This represents the communication priority of communication device k in the set of mutually exclusive communication devices. This represents the expected bandwidth of communication device k in the set of mutually exclusive communication devices. The actual bandwidth of communication device k in the set of mutually exclusive communication devices refers to the communication priority of the communication device in traffic resource allocation, the expected bandwidth refers to the bandwidth that the communication device is expected to use, and the actual bandwidth refers to the bandwidth that the communication device actually uses. The set of mutually exclusive communication devices is a set consisting of the target communication device and the mutually exclusive communication devices that are mutually exclusive with the target communication device.
2. The flow control method according to claim 1, characterized in that, Before determining that the communication device in the network topology that has a mutual exclusion relationship with the target communication device is a mutually exclusive communication device that is mutually exclusive with the target communication device, the method further includes: Obtain the communication devices that need to participate in communication in the network, the communication status of the communication devices, and the connection relationships between the communication devices; The network topology is generated based on the communication devices and the connection relationships between them, wherein the network topology is used to reflect the communication status and connection relationships of each of the communication devices; Obtain historical communication data of each of the aforementioned communication devices within a historical time period; The importance of each communication device is evaluated based on the communication status, the connection relationship, and the historical communication data to obtain the evaluation result. If the evaluation result indicates that the importance level is higher than the importance level threshold, the communication device is determined to be the target communication device.
3. The flow control method according to claim 1, characterized in that, The communication devices in the network topology that have a mutual exclusion relationship with the target communication device are identified as mutually exclusive communication devices that are mutually exclusive with the target communication device, including: Based on the network topology, the communication link used by the target communication device when transmitting data is determined to be the target communication link; Based on the network topology, a non-target communication device that uses the target communication link for data transmission is identified as a mutually exclusive communication device that is mutually exclusive with the target communication device, wherein the non-target communication device is any communication device in the network topology other than the target communication device.
4. The flow control method according to claim 1, characterized in that, Before adjusting the traffic of each of the mutually exclusive communication devices based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state, the method further includes: Traffic monitoring is performed on the target communication device to obtain monitoring results; The current traffic of the target communication device is determined based on the monitoring results, wherein the current traffic refers to the amount of data transmitted by the target communication device per unit time. Determine whether the current traffic exceeds the traffic threshold, and obtain the determination result; If the determination result indicates that the traffic threshold exceeds the traffic threshold, it is determined that the target communication device is in the abnormal traffic state; If the determination result indicates that the traffic threshold has not been exceeded, the target communication device is determined to be in the normal traffic state.
5. The flow control method according to claim 1, characterized in that, When the target communication device is in an abnormal traffic state, the traffic of each mutually exclusive communication device is adjusted based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state, including: The difference between the current traffic of the target communication device and the traffic threshold is determined to be the target traffic required for the target communication device to recover from the abnormal traffic state to the normal traffic state. The traffic adjustment ratio for each of the mutually exclusive communication devices is determined based on the target traffic and the value of the mutual exclusion weight coefficient. The traffic of the mutually exclusive communication device is adjusted according to the traffic adjustment ratio so that the target communication device is restored to a normal traffic state.
6. The flow control method according to claim 1, characterized in that, When the target communication device is in an abnormal traffic state, the traffic of each mutually exclusive communication device is adjusted based on the mutual exclusion weight coefficient to restore the target communication device to a normal traffic state, including: The mutually exclusive communication devices are sorted in descending order according to the values of the mutual exclusion weight coefficients to obtain the sorting result; The mutual exclusion communication devices whose mutual exclusion weight coefficient is not less than the weight threshold are identified as target mutual exclusion communication devices. After adjusting the traffic of the target mutually exclusive communication device, the current state of the target communication device is obtained; If the current state is still in the abnormal traffic state, the traffic of the mutual exclusive communication devices other than the target mutual exclusive communication device is adjusted in turn according to the sorting result until the target communication device is restored to the normal traffic state.
7. A flow control device, characterized in that, include: The first determining unit is used to determine that the communication device in the network topology that has a mutual exclusion relationship with the target communication device is a mutually exclusive communication device that is mutually exclusive with the target communication device, wherein the target communication device is the communication device in the network topology whose importance is higher than an importance threshold, and the mutual exclusion relationship is a relationship in which the communication devices use the same communication link for data transmission, resulting in traffic contention. A calculation unit is used to calculate the mutual exclusion weight coefficient of the target communication device for each of the mutually exclusive communication devices, wherein the mutual exclusion weight coefficient refers to the degree of communication influence of the target communication device on the mutually exclusive communication devices; The adjustment unit is configured to adjust the traffic of each mutually exclusive communication device based on the mutual exclusion weight coefficient when the target communication device is in an abnormal traffic state, so as to restore the target communication device to a normal traffic state. The abnormal traffic state refers to a state where the current traffic of the target communication device exceeds a traffic threshold, and the normal traffic state refers to a state where the current traffic of the target communication device does not exceed the traffic threshold. The calculation unit includes: a calculation module, used to sequentially calculate the mutual exclusion weight coefficient of the target communication device for each of the mutually exclusive communication devices using a first formula, wherein the first formula is: , This represents the mutual exclusion weight coefficient between the target communication device i and the mutually exclusive communication device j. This indicates the communication priority of the target communication device i. This represents the expected bandwidth of the target communication device i. Let N represent the actual bandwidth of the mutually exclusive communication device j, N represent the total number of the communication devices in the set of mutually exclusive communication devices, and k represent the index of the communication device in the set of mutually exclusive communication devices. This represents the communication priority of communication device k in the set of mutually exclusive communication devices. This represents the expected bandwidth of communication device k in the set of mutually exclusive communication devices. The actual bandwidth of communication device k in the set of mutually exclusive communication devices refers to the communication priority of the communication device in traffic resource allocation, the expected bandwidth refers to the bandwidth that the communication device is expected to use, and the actual bandwidth refers to the bandwidth that the communication device actually uses. The set of mutually exclusive communication devices is a set consisting of the target communication device and the mutually exclusive communication devices that are mutually exclusive with the target communication device.
8. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a stored program, wherein the program performs the flow control method according to any one of claims 1 to 6.
9. A computer program product comprising computer instructions, characterized in that, When the computer instructions are executed by the processor, the flow control method according to any one of claims 1 to 6 is performed.
Citation Information
Patent Citations
SDN (Software Defined Network) load balancing dual-weight switch migration method and system based on prediction
CN114338537A
Method and device for preventing application program from executing abnormal operation
CN118260093A