Data stream transmission method, network device, storage medium and program product
By merging underutilized queues in network devices to form queues with higher resource allocation, the problem of underutilized traffic manager resources is solved, and the overall resource utilization and device efficiency are improved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- ZTE CORP
- Filing Date
- 2024-12-04
- Publication Date
- 2026-06-05
AI Technical Summary
In network devices, some transmission queues have low traffic demand but high rate limits, resulting in underutilization of traffic manager resources and reduced overall resource utilization.
Multiple queues with lower-than-expected transmission status are merged into a second queue with higher resource configuration parameters. The target data stream is then transmitted through this second queue, releasing underutilized resources.
It improves the utilization of traffic manager resources, simplifies queue management, and enhances the operating efficiency of network devices.
Smart Images

Figure CN122160339A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of communication technology, and in particular to a data stream transmission method, network device, storage medium, and program product. Background Technology
[0002] In network devices such as switches and routers, data flow rate limiting and scheduling rely on Traffic Manager (TM) resources. Simply limiting traffic flow without effective scheduling can lead to a waste of queue resources.
[0003] In priority scheduling, multiple queues of the same priority type typically have their own rate limits, and the issues of rate-limited packet loss and priority-based packet loss for each queue must be considered. During data stream transmission, if some queues have lower traffic demands but are still set to relatively high rate limits, this will result in underutilization of TM resources, thereby reducing overall resource utilization. Summary of the Invention
[0004] This application provides a data stream transmission method, network device, storage medium, and program product to at least solve the problem that some transmission queues cannot be fully utilized and the resource utilization of the traffic manager is low during data stream transmission.
[0005] To solve the above-mentioned technical problems, this application is implemented as follows: In a first aspect, embodiments of this application provide a data stream transmission method, comprising: merging multiple first queues into a second queue; wherein the first queue is a transmission queue in the transmission queue corresponding to the target data stream whose transmission status is lower than the expected status; the resource configuration parameters of the second queue are greater than or equal to the sum of the resource configuration parameters of the multiple first queues; and transmitting the target data stream through the second queue.
[0006] In a second aspect, embodiments of this application provide a network device, the network device including a processor and a memory, the memory storing programs or instructions that can run on the processor, the programs or instructions being executed by the processor to implement the steps of the method described in the first aspect above.
[0007] Thirdly, embodiments of this application provide a computer-readable storage medium on which a program or instructions are stored, which, when executed by a processor, implement the steps of the method described in the first aspect above.
[0008] Fourthly, embodiments of this application provide a computer program product, the computer program product including a computer program stored on a non-transitory computer-readable storage medium, the computer program including program instructions, which, when executed by a computer, cause the computer to perform the steps of the method described in the first aspect above.
[0009] In this embodiment, multiple first queues are merged into a second queue; wherein, the first queue is the transmission queue in the transmission queue corresponding to the target data stream whose transmission status is lower than the expected status; the resource configuration parameters of the second queue are greater than or equal to the sum of the resource configuration parameters of multiple first queues; the target data stream is transmitted through the second queue, so that the resources of multiple first queues whose transmission status is lower than the expected status can be released, thereby avoiding the problem of unreasonable resource allocation leading to the underutilization of the traffic manager™ resources of some queues, and improving the utilization rate of TM resources.
[0010] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and do not limit this application. Attached Figure Description
[0011] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0012] Figure 1 This paper illustrates a flowchart of a data stream transmission method provided in an embodiment of this application. Figure 2 This illustration shows another flowchart of the data stream transmission method provided in an embodiment of this application; Figure 3 This illustration shows the effect of resetting TM resources according to an embodiment of this application; Figure 4 A schematic diagram of the hardware structure of the network device provided in an embodiment of this application is shown. Detailed Implementation
[0013] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.
[0014] In network devices such as switches and routers, the rate limiting and scheduling of data flows rely on Traffic Manager (TM) resources. For example, in a network switch, data traffic is processed by multiple queues, configured as follows: Queue A: Handles voice traffic, with a bandwidth limit of 100 Mbps; Queue B: Processes video traffic, with a bandwidth limit of 200 Mbps; Queue C: Handles file transfer traffic, with a bandwidth limit of 300 Mbps.
[0015] The actual traffic requirements are as follows: Queue A has low voice traffic requirements, with an actual traffic of only 20 Mbps; Queue B has relatively stable video traffic requirements, with an actual traffic requirement of 150 Mbps; and Queue C has low file transfer traffic requirements, with an actual traffic of 50 Mbps.
[0016] The bandwidth limit values for queues A and C are set too high, while the actual traffic demand is far lower than the set limit values. As a result, the TM resources of queues A and C are not fully utilized, reducing the overall resource utilization rate.
[0017] To address the aforementioned problems in data stream transmission of network devices, this application provides a data stream transmission method. This method merges multiple first queues with low TM resource utilization into a second queue, and transmits the target data stream through the second queue. This releases the resources of the multiple first queues with low TM resource utilization, thereby solving the problem of unreasonable resource allocation leading to underutilization of the TM resources of some queues.
[0018] Please see Figure 1 , Figure 1 A flowchart illustrating a data stream transmission method provided in an embodiment of this application is shown. The execution entity of this method can be a network device or a server, wherein the network device can be such as a switch, router, etc. The server can be a standalone server or a server cluster composed of multiple servers. Furthermore, the server can be a backend server for a specific service or a backend server for a system or platform (such as a network management system, software-defined network platform, etc.). As shown in the figure, the data stream transmission method 100 may include the following steps: Step 101: Merge multiple first queues into a second queue; wherein, the first queue is the transmission queue in the transmission queue corresponding to the target data stream whose transmission status is lower than the expected status; the resource configuration parameters of the second queue are greater than or equal to the sum of the resource configuration parameters of the multiple first queues.
[0019] Here, transmission status includes data transmission rate, packet loss status, etc.; resource configuration parameters include queue length, rate limit, bandwidth, etc.
[0020] In one exemplary embodiment, network devices such as switches and routers, after receiving data packets, forward the packets to their destination address according to specified rules. Assume that the network device needs to send eight independent data streams over the network, each with a rate of 50 Mbps (megabits per second). In data transmission, there are four priorities, with two data streams under each priority. Assume priorities range from 1 to 4, with priority 1 being the highest and priority 4 the lowest, and each priority corresponding to two data streams.
[0021] Configure the Quality of Service (QoS) transmission policy for the switch or router as needed: 1. Configure 8 classes in the Policy Map (PMAP), with each class limited to 100Mbps; Create a policy mapping named Pmap test. Class 1, speed limited to 100Mbps, priority 1 Class 2, speed limited to 100Mbps, priority 1 Class 3, speed limited to 100Mbps, priority 2 Class 4, speed limited to 100Mbps, priority 2 Class 5, speed limited to 100Mbps, priority 3 Class 6, speed limited to 100Mbps, priority 3 Class 7, speed limited to 100Mbps, priority 4 Class 8, speed limited to 100Mbps, priority 4 2. Configure PMAP and bind it to interface Port1; Server-policy pmap test output Enable QoS monitoring frequency and configure the adjustment method.
[0022] Because different types of target data streams have different quality of service (QoS) requirements regarding latency sensitivity, bandwidth, and reliability, a QoS transmission strategy can be determined based on the transmission requirements of different types of target data streams. This strategy then determines multiple transmission queues corresponding to the target data streams. For example, eight data streams from eight classes can be transmitted using eight separate transmission queues. During data transmission, the tester sends eight data streams matching the eight classes, each at 50 Mbps.
[0023] The resource usage initially consists of 8 transmission queues. For example, Class 1 to Class 8 correspond to queues 1 to 8. If packet loss is found in queues 1 to 8, indicating that the data transmission rate is not meeting expectations, then queues 5, 6, 7, and 8 are merged into queue 9. Data streams from Class 5 to Class 8 are then transmitted through queue 9. The rate limit of queue 9 is greater than or equal to the sum of the rate limits of queues 5 to 8. For example, if the rate limit of queues 5 to 8 is 100Mbps, and their total rate limit is 400Mbps, then the rate limit of queue 9 can be set to 400Mbps or greater than 400Mbps, depending on the specific needs.
[0024] This effectively identifies queues that are not fully utilizing TM resources, allowing for subsequent adjustments to these queues and improving the utilization rate of TM resources.
[0025] Step 102: Transmit the target data stream through the second queue.
[0026] Continuing with the above embodiment, data streams from Class 5 to Class 8 are transmitted through queue 9. Since the rate limit of queue 9 is 400M, the traffic of Class 6 and Class 7 can each be sent to 150Mbps.
[0027] Through the above steps, the first queues with low TM resource utilization (i.e., transmission status below expectations) are merged into a second queue, and the target data stream is transmitted through the second queue. This releases the resources of the multiple first queues with below-expected transmission status, thereby solving the problem of underutilization of TM resources in some queues due to unreasonable resource allocation and improving TM resource utilization. Furthermore, merging multiple first queues with low TM resource utilization simplifies queue management of network devices and improves their operational efficiency.
[0028] In one possible implementation, the transmission status includes the data transmission rate, and the resource configuration parameters include a rate limit value; In response to the ratio of the number of target detections to the number of target detections being less than a preset ratio threshold, the transmission queue corresponding to the target data stream is determined as the first queue; wherein, the number of target detections is the number of times in the scan results of the number of target detections that the data transmission rate of the transmission queue is less than a preset rate threshold, and the preset rate threshold is determined based on the rate limit value of the transmission queue.
[0029] In an exemplary embodiment, the transmission interface corresponding to the target data stream in the network device can be scanned a number of times for target detection. For example, the physical port SG can be scanned 100 times, once per minute. For each transmission queue, in the scan results of 100 scans, the data transmission rate is determined based on the speed measurement value provided by the chip. The number of times the data transmission rate does not reach 50% of the transmission queue's rate limit is obtained. When the ratio of the number of target data transmissions to the number of target detections is less than a preset ratio threshold, the transmission queue is determined to be the first queue. The preset ratio threshold can be set according to actual needs.
[0030] This method allows for continuous tracking of the status changes of the transmission queues, dynamic understanding of the resource usage of each transmission queue, and avoidance of misjudgments caused by instantaneous status fluctuations, thereby more accurately identifying the first queue that needs to be merged.
[0031] In another possible implementation, the transmission status information also includes packet loss status; The target number is the number of times, in the result of the detection count, that the data transmission rate of the transmission queue is less than a preset rate threshold and the transmission queue is in a packet loss state.
[0032] Continuing with the above embodiment, for each transmission queue, the transmission queue in which no packet loss was found in the 100 scans and the speed measurement value provided by the chip did not reach the expected value can be identified as the first queue.
[0033] In one possible implementation, in step 101 above, the first queue is the transmission queue in the transmission queue corresponding to the target data stream whose transmission status is lower than the expected status and whose priority type is a preset type.
[0034] Continuing with the above embodiments, priorities can be divided into different priority types according to actual needs. For example, priorities 1 and 2 can be determined as high priorities, and priorities 3 and 4 as low priorities. Candidate queues with transmission status lower than expected are selected from queues 1 to 8. For example, candidate queues whose data transmission rate has not reached 50% of the rate limit in 100 scans are selected from queues 1 to 8. Then, a first queue with a preset priority type is selected from the candidate queues. For example, a queue with a low priority type is selected as the first queue. Alternatively, candidate queues with a preset priority type can be selected from queues 1 to 8, and then a first queue with a transmission status lower than expected is selected from the candidate queues. That is, the first queue is the queue corresponding to Class 5, Class 6, Class 7, and Class 8. Multiple first queues are merged into a second queue, and the transmission of Class 5, Class 6, Class 7, and Class 8 is carried out through the second queue.
[0035] It should be noted that, based on the drop priority (DP) of the first queue and the queue's drop algorithm, such as Weighted Random Early Detection (WRED), the first queue can be merged into at least one second queue. For example, if each queue has 8 DPs with WRED, and the target queue has different DPs, then a maximum of 8 first queues can be merged into one second queue.
[0036] In another exemplary embodiment, Hierarchical Quality of Service (HQoS) can be used to flexibly manage traffic of different priorities in network traffic management. A single layer of HQoS can be configured with four types. Without applying policies to high-priority types, it is found that low-priority types do not fully utilize TM resources within 100 scans. For example, if the three lowest-priority queues are each limited to 100Mbps, and the three queues combined do not utilize 300Mbps, and each queue experiences virtually no packet loss, then only one queue is needed. These queues can be merged into one, with the rate limit configured to guarantee a 300Mbps limit.
[0037] In one possible implementation, step 101 above, merging multiple first queues into a second queue, includes: A second queue for transmitting the target data stream is obtained, and the second queue is configured according to the resource configuration parameters of the plurality of first queues, wherein the resource configuration parameters of the configured second queue are greater than or equal to the sum of the resource configuration parameters of the plurality of first queues; the target data stream transmitted in the plurality of first queues is switched to the second queue, so as to merge the plurality of first queues into the second queue.
[0038] Continuing with the above embodiment, a second queue for transmitting the target data stream is obtained. For example, the second queue is queue 9. Based on the rate limit of 100Mbps for queues 5 to 8, the rate limit of queue 9 is configured to be 400Mbps.
[0039] The second queue mentioned above can be a re-requested queue, for example, re-requesting a queue 9 for the target data streams Class1 to Class8; or, the second queue can be any of the multiple first queues, for example, using queue 8 as the second queue, and configuring the rate limit of queue 8 to 400Mbps according to the rate limit values of queues 5 to 8.
[0040] In one possible implementation, after merging the multiple first queues into a second queue in step 101 above, the method further includes: Store the resource configuration parameters of the plurality of first queues in the spare resource table entry, and release the traffic manager™ resources corresponding to the plurality of first queues.
[0041] In an exemplary embodiment, a backup resource entry can be generated in advance, storing resource configuration parameters such as the rate limit value, priority, and corresponding target data stream Class5 to Class8 of queues 5 to 8 in the backup resource entry, and releasing the traffic manager™ resources corresponding to queues 5 to 8.
[0042] In this way, by storing the resource configuration parameters of multiple first queues in the spare resource table, multiple first queues can be promptly restored when data packet loss occurs in the second queue due to congestion or instability, thereby improving the reliability of data stream transmission. Furthermore, by releasing the TM resources corresponding to multiple first queues, unnecessary resource consumption can be avoided, and more processing capacity can be provided for other queues or traffic during peak traffic periods or when a large number of queues need to be managed.
[0043] In one possible implementation, after merging the multiple first queues into a second queue in step 101 above, the method further includes: The resource configuration parameters of multiple first queues in the resource table entry corresponding to the target data stream are updated to the resource configuration parameters of the second queue, so that the target data stream can be transmitted through the second queue.
[0044] In one exemplary embodiment, after merging queues 5 to 8 into queue 9, the rate limit values, priorities, and Class 5 to Class 8 resource configuration parameters corresponding to queues 5 to 8 in the resource table entries of the target data stream are updated to the rate limit values, priorities, and Class 5 to Class 8 resource configuration parameters corresponding to queue 9. The network device transmits the target data stream according to the updated resource table entries.
[0045] In one possible implementation, such as Figure 2 As shown, in step 102 above, after transmitting the target data stream through the second queue, the method further includes: Step 103: Monitor the transmission status of the second queue.
[0046] In one exemplary embodiment, the packet loss statistics of three different DPs in the second queue can be viewed, and the data transmission rate of the second queue can be monitored. The transmission status of the second queue can be determined based on the packet loss status and the data transmission rate. Here, the dp field of the WRED of the second queue can be reused for packet statistics to determine whether packet loss has occurred.
[0047] Step 104: In response to the transmission status of the second queue being lower than the expected status, the second queue is restored to the plurality of first queues.
[0048] Continuing with the above embodiments, in the scanning results of 100 scans, the number of packet losses in the second queue can be obtained by performing packet loss statistics on three different DPs of the second queue. If the number of packet losses in the second queue reaches a preset threshold, the second queue can be restored into multiple first queues. Alternatively, in the scanning results of 100 scans, the number of times the data transmission rate of the second queue is less than 50% of the rate limit can be counted. If the number of times reaches a preset threshold, the second queue can be restored into multiple first queues.
[0049] Step 105: Transmit the target data stream through the plurality of first queues.
[0050] Continuing with the above embodiment, queues 5 to 8 are merged into one queue for transmission. When the queue experiences a specified number of packet losses, or when the data transmission rate reaches 50% of the speed limit a preset threshold number of times, the queue is restored to its previous state before merging, i.e., Class 5 to Class 8 transmission is performed through queues 5 to 8.
[0051] By following the steps above, we can get as close as possible to the maximum utilization state of the TM, improve the utilization rate of TM resources, and avoid data packet loss caused by congestion or instability, thereby improving the reliability of data stream transmission.
[0052] In one possible implementation, step 104 above, restoring the second queue back into the plurality of first queues, includes: Based on the resource configuration parameters of the multiple first queues, TM resources corresponding to the multiple first queues are generated; wherein, the resource configuration parameters of the multiple first queues are stored in the spare resource table after the multiple first queues are merged into the second queue; based on the TM resources corresponding to the multiple first queues, the second queue is restored back into the multiple first queues.
[0053] This method can avoid traffic interruptions or packet loss caused by insufficient resource preparation, ensuring a safe switching of data streams.
[0054] In one possible implementation, before merging the multiple first queues into a second queue in step 101 above, the method further includes: During the monitoring period, the transmission interface corresponding to the target data stream is scanned a number of times according to the preset scanning parameters; based on the scanning results of the number of target detections, multiple first queues in the transmission queue of the transmission interface are determined.
[0055] In one exemplary embodiment, within a monitoring period, the transmission interface corresponding to the target data stream is scanned multiple times, for example, 100 times, using pre-set scanning parameters such as scan time, number of scans, and scan priority. Based on the transmission status of each transmission queue obtained from the 100 scans, the first queue with the lowest TM resource utilization is determined. For example, in 100 checks at once per minute, statistical analysis of the forwarded data in the transmission queues reveals that no packet loss was found in any queue and the speed measurement value provided by the chip did not reach 50% of the transmission queue's speed limit. This quantifies the TM resource utilization of the transmission queues, thus identifying the first queue with the lowest TM resource utilization. The scanning parameters can be set as follows: Set scan time: milliseconds, seconds, minutes; Set the number of scans: 1 to 200; Configure the scanning interface: physical port, SG port, etc.; Set change rules: all priorities, low, medium, medium-high, high; Set change rules: 1%-100% of the speed limit value.
[0056] This method allows for continuous tracking of the status changes of the transmission queues, dynamic understanding of the TM resource usage of each transmission queue, and avoidance of misjudgments caused by instantaneous status fluctuations, thereby more accurately identifying the first transmission queue with the lowest TM resource usage.
[0057] In one exemplary embodiment, such as Figure 3 As shown, in network devices such as switches or routers, when forwarding packets, command configuration is performed to obtain corresponding resource table entries. For example, the QoS transmission policy of the network device is set, configuring 8 classes, the corresponding transmission queue for each class, and the rate limit value for each transmission queue. The packet and command configuration are then sent to the forwarding plane. The forwarding plane obtains transmission queues through command parsing, TM chip settings, Ternary Content Addressable Memory (TCAM) settings, interface table settings, and TM scan settings. HQoS is enabled in the interface table, and the TCAM obtains the transmission queues. Simultaneously, according to the TM scan settings, the transmission queues are scanned multiple times to identify several first queues with low TM resource utilization. When a queue switching setting is found, the multiple first queues are merged into a second queue, and the TM resources of the second queue are reset, updating the resource table entries. The queue switching setting includes merging multiple first queues into a second queue as described above, and restoring the second queue to multiple first queues when the transmission status of the second queue is lower than expected.
[0058] This application provides a data stream transmission method that merges multiple first queues into a second queue. The first queues are transmission queues whose transmission status is lower than expected for the target data stream. The resource configuration parameters of the second queue are greater than or equal to the sum of the resource configuration parameters of the multiple first queues. The target data stream is transmitted through the second queue. The transmission status of the second queue is monitored. In response to the second queue's transmission status being lower than expected, the second queue is restored to multiple first queues. The target data stream is then transmitted through the multiple first queues. By dynamically adjusting the queue merging and restoration strategy, the maximum utilization of the TM (Transmission Management System) can be approached as closely as possible, improving TM resource utilization. Furthermore, this method only requires TM check configuration and QoS configuration, along with auxiliary software adjustments, to achieve maximum utilization of QoS TM resources carried by network devices such as switches or routers. It does not require adding new external devices such as transmission hardware chips, resulting in a significant improvement in both the cost and performance of network devices.
[0059] Figure 4This diagram illustrates the hardware structure of the network device provided in the embodiments of this application. Referring to the diagram, at the hardware level, the network device 400 includes a processor 410, and optionally includes an internal bus 420, a network interface 430, and a memory 440. The memory 440 may include RAM 441, such as high-speed random-access memory (RAM), and may also include non-volatile memory 442, such as at least one disk storage device. Of course, the network device 400 may also include other hardware required for other services.
[0060] The processor 410, network interface 430, and memory can be interconnected via an internal bus 420. This internal bus 420 can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. The bus can be categorized as an address bus, data bus, control bus, etc. For ease of illustration, only a single bidirectional arrow is used in this diagram, but this does not imply that there is only one bus or one type of bus.
[0061] Memory 440 stores programs. Specifically, the program may include program code, which includes computer operation instructions. Memory 440 may include main memory 441 and non-volatile memory 442, and provides instructions and data to processor 410.
[0062] Processor 410 reads the corresponding computer program from non-volatile memory 442 into memory and then runs it, forming a device for locating the target user at the logical level. Processor 410 executes the program stored in memory and specifically performs the following: Figure 1 or Figure 2 The methods disclosed in the embodiments shown achieve the functions and beneficial effects of the methods described in the preceding method embodiments, and will not be repeated here.
[0063] The above is as stated in this application. Figure 1 or Figure 2The methods disclosed in the illustrated embodiments can be applied to or implemented by processor 410. Processor 410 may be an integrated circuit chip with signal processing capabilities. During implementation, each step of the above method can be completed by integrated logic circuits in the hardware or by instructions in software form within processor 410. Processor 410 can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the methods disclosed in the embodiments of this application can be directly embodied in the execution of a hardware decoding processor, or executed by a combination of hardware and software modules in the decoding processor. The software module can reside in a mature storage medium in the field, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, or registers. This storage medium is located in memory, and the processor reads information from the memory and, in conjunction with its hardware, completes the steps of the above method.
[0064] The computer device can also execute the methods described in the preceding method embodiments and achieve the functions and beneficial effects of the methods described in the preceding method embodiments, which will not be repeated here.
[0065] Of course, in addition to software implementation, the network device 400 of this application does not exclude other implementation methods, such as logic devices or a combination of hardware and software, etc. In other words, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.
[0066] This application also proposes a computer-readable storage medium that stores one or more programs, which, when executed by a network device including multiple applications, cause the network device to perform... Figure 1 or Figure 2 The methods disclosed in the embodiments shown achieve the functions and beneficial effects of the methods described in the preceding method embodiments, and will not be repeated here.
[0067] The computer-readable storage medium mentioned above includes read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk, etc.
[0068] Furthermore, embodiments of this application also provide a computer program product, the computer program product including a computer program stored on a non-transitory computer-readable storage medium, the computer program including program instructions, which, when executed by a computer, implement the following process: Figure 1 or Figure 2 The methods disclosed in the embodiments shown achieve the functions and beneficial effects of the methods described in the preceding method embodiments, and will not be repeated here.
[0069] The embodiments of this application can be applied to various network device collaboration or interconnection scenarios, including: collaboration and interconnection between mobile phones and laptops / tablets; collaboration and interconnection between mobile terminals and smart TVs / monitors; collaboration and interconnection between mobile phones or tablets and in-vehicle entertainment systems; collaboration and interconnection between mobile terminals and smart conferencing systems, etc. This satisfies users' diverse needs in smart home, smart office, and smart travel scenarios.
[0070] In summary, the above description is merely a preferred embodiment of this application and does not limit the scope of protection of this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application.
[0071] The systems, devices, modules, or units described in the above embodiments can be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, a computer can be, for example, a personal computer, laptop computer, cellular phone, camera phone, smartphone, personal digital assistant, media player, navigation device, email device, game console, tablet computer, wearable device, or any combination of these devices.
[0072] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information by any method or technology. Information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can store information accessible to a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0073] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0074] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, the system embodiments are basically similar to the method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions in the method embodiments.
Claims
1. A data stream transmission method, characterized in that, include: Multiple first queues are merged into a second queue; wherein, the first queue is the transmission queue in the transmission queue corresponding to the target data stream whose transmission status is lower than the expected status; the resource configuration parameters of the second queue are greater than or equal to the sum of the resource configuration parameters of the multiple first queues; The target data stream is transmitted through the second queue.
2. The method according to claim 1, characterized in that, The transmission status includes the data transmission rate, and the resource configuration parameters include the rate limit value; In response to the ratio of the number of target detections to the number of target detections being less than a preset ratio threshold, the transmission queue corresponding to the target data stream is determined as the first queue; wherein, the number of target detections is the number of times in the scan results of the number of target detections that the data transmission rate of the transmission queue is less than a preset rate threshold, and the preset rate threshold is determined based on the rate limit value of the transmission queue.
3. The method according to claim 2, characterized in that, The transmission status information also includes packet loss status; The target number is the number of times, in the result of the detection count, that the data transmission rate of the transmission queue is less than a preset rate threshold and the transmission queue is in a packet loss state.
4. The method according to any one of claims 1 to 3, characterized in that, The first queue is the transmission queue corresponding to the target data stream whose transmission status is lower than expected and whose priority type is a preset type.
5. The method according to claim 1, characterized in that, The step of merging multiple first queues into a second queue includes: A second queue for transmitting the target data stream is obtained, and the second queue is configured according to the resource configuration parameters of a plurality of first queues, wherein the resource configuration parameters of the configured second queue are greater than or equal to the sum of the resource configuration parameters of the plurality of first queues; The target data stream transmitted in the plurality of first queues is switched to the second queue, so as to merge the plurality of first queues into the second queue.
6. The method according to claim 5, characterized in that, The second queue is a re-application queue; or, the second queue is any one of the plurality of first queues.
7. The method according to claim 1, characterized in that, After merging the multiple first queues into a second queue, the process further includes: Store the resource configuration parameters of the plurality of first queues in the spare resource table entry, and release the traffic manager™ resources corresponding to the plurality of first queues.
8. The method according to claim 1, characterized in that, After merging the multiple first queues into a second queue, the process further includes: The resource configuration parameters of multiple first queues in the resource table entry corresponding to the target data stream are updated to the resource configuration parameters of the second queue, so that the target data stream can be transmitted through the second queue.
9. The method according to claim 1, characterized in that, After transmitting the target data stream through the second queue, the method further includes: Monitor the transmission status of the second queue; In response to the transmission status of the second queue being lower than the expected status, the second queue is restored to the plurality of first queues; The target data stream is transmitted through the plurality of first queues.
10. The method according to claim 9, characterized in that, The step of restoring the second queue back into the plurality of first queues includes: Based on the resource configuration parameters of multiple first queues, TM resources corresponding to the multiple first queues are generated; wherein, the resource configuration parameters of the multiple first queues are stored in the spare resource table after the multiple first queues are merged into the second queue; Based on the TM resources corresponding to the plurality of first queues, the second queue is restored to the plurality of first queues.
11. The method according to any one of claims 1 to 10, characterized in that, Before merging the multiple first queues into a second queue, the method further includes: During the monitoring period, the target data stream corresponding to the transmission interface is scanned a number of times according to the preset scanning parameters; Based on the scanning results of the target detection count, multiple first queues are determined in the transmission queue of the transmission interface.
12. A network device, characterized in that, The network device includes a processor and a memory, the memory storing programs or instructions that can run on the processor, the programs or instructions being executed by the processor to implement the steps of the method as described in any one of claims 1 to 11.
13. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a program or instructions that, when executed by a processor, implement the steps of the method as described in any one of claims 1 to 11.
14. A computer program product, characterized in that, The computer program product includes a computer program stored on a non-transitory computer-readable storage medium, the computer program including program instructions that, when executed by a computer, cause the computer to perform the steps of the method as described in any one of claims 1 to 11.