Method and apparatus for controlling packet forwarding

By controlling the outgoing interface scheduling of message forwarding nodes in a time-sensitive network and utilizing time slot hysteresis technology, the clock synchronization problem is solved, resource reuse rate is improved, and network transmission efficiency is enhanced.

CN122093339APending Publication Date: 2026-05-26HUAWEI TECH CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
HUAWEI TECH CO LTD
Filing Date
2024-11-26
Publication Date
2026-05-26

AI Technical Summary

Technical Problem

In time-sensitive networks, clock synchronization between message forwarding nodes is difficult to achieve, leading to misalignment of time slots, resulting in wasted bandwidth resources and low forwarding efficiency.

Method used

By controlling the outgoing interface scheduling of message forwarding nodes, the second stream is allowed to contend for idle resources after the first stream's forwarding time slot. By utilizing time slot delay technology, the second stream is ensured to arrive in time and occupy unused transmission resources, thereby improving resource reuse rate.

Benefits of technology

This effectively improves the utilization rate of sending resources at the outgoing interface of the message forwarding node, reduces bandwidth waste, and enhances network transmission efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122093339A_ABST
    Figure CN122093339A_ABST
Patent Text Reader

Abstract

This application discloses a message forwarding control method and apparatus, belonging to the field of communication technology. The method is applied to message forwarding nodes in a communication network that forward first and second flows of messages through the same outgoing interface. The method includes: in a first time slot starting at a first time point, allowing the scheduling of messages to be forwarded in the first flow to the outgoing interface; in a first time period starting at the first time point and ending at a second time point, ceasing the scheduling of messages to be forwarded in the second flow to the outgoing interface; the duration of the first time period is shorter than the duration of the first time slot; and from the second time point onwards, allowing the scheduling of messages in the second flow to the outgoing interface. Through this method, when messages in the first flow fail to arrive at the message forwarding node on time, causing the first time slot to be idle, the second flow can contend for the idle time slot to forward messages, thus improving the statistical reuse rate of the message forwarding node's outgoing interface transmission resources.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of communication technology, and in particular to a control method and apparatus for message forwarding. Background Technology

[0002] When transmitting data over a network, such as when transmitting information technology (IT) and / or operational technology (OT) business data in a network based on the Ethernet communication standard, the demand for high reliability, low latency, and low jitter in data transmission is becoming increasingly prominent. Time-sensitive networks (TSNs) with deterministic data transmission capabilities can ensure the real-time performance and reliability of data transmission within the network; that is, TSNs can meet the stringent performance requirements of data transmission. Deterministic data transmission capability refers to the fact that the latency of data transmission is deterministic or bounded.

[0003] Currently, in TSN, based on clock synchronization of packet forwarding nodes, available bandwidth needs to be allocated to traffic with different latency requirements through time slot orchestration. To avoid interference when traffic with different latency requirements forwards packets in their respective forwarding time slots, the TSN standard introduces a gate control list (GCL) mechanism, which sets a basic principle: traffic requiring bounded latency and traffic without bounded latency requirements time-division multiplex the outgoing interface of the packet forwarding node for packet forwarding. That is, when traffic requiring bounded latency is forwarded through the outgoing interface of the packet forwarding node, traffic without bounded latency requirements is stopped from being scheduled to that outgoing interface.

[0004] However, perfect clock synchronization between packet forwarding nodes is difficult to achieve. Clock errors can easily lead to misalignment of time slots between packet forwarding nodes. In this case, packets that do not arrive at the packet forwarding node on time will miss their pre-arranged forwarding time slots, resulting in those time slots being idle and wasting bandwidth resources. Summary of the Invention

[0005] This application provides a control method and apparatus for message forwarding, which can improve the statistical reuse rate of the outgoing interface sending resources of message forwarding nodes. The technical solution provided by this application is as follows.

[0006] Firstly, this application provides a message forwarding control method, applied to a message forwarding node in a communication network that forwards a first stream and a second stream of messages through the same outgoing interface. The method includes: in a first time slot starting at a first time point, allowing the scheduling of messages to be forwarded in the first stream to the outgoing interface; stopping the scheduling of messages to be forwarded in the second stream to the outgoing interface in a first time period starting at the first time point and ending at a second time point; and allowing the scheduling of messages in the second stream to the outgoing interface starting from the second time point. Wherein, the first time slot is a time slot used for forwarding messages in the first stream, and the duration of the first time period is shorter than the duration of the first time slot.

[0007] This method delays the forwarding time slots of the second flow (i.e., the time slots used to forward packets in the second flow) by a first duration relative to the forwarding time slots of the first flow (i.e., the time slots used to forward packets in the first flow). As a result, when packets from the first flow do not arrive at the packet forwarding node on time, causing the first time slot to be idle, the forwarding time slots of the second flow arrive in time. Consequently, the second flow can contend for the idle outgoing interface sending resources to forward packets, thus improving the statistical reuse rate of the outgoing interface sending resources of the packet forwarding node.

[0008] In one possible design, the first flow requires a defined range of transmission delay, the second flow does not require a defined range of transmission delay, and the aforementioned outgoing interface is also used to forward a third flow, which does not require a defined range of transmission delay, and the priority of forwarding the third flow is lower than that of forwarding the second flow. The method further includes: during a second time period starting at a first time and ending at a third time, ceasing the scheduling of packets to be forwarded in the third flow to the outgoing interface; and allowing the scheduling of packets to be forwarded in the third flow to the outgoing interface starting from the third time. The duration of the second time period is shorter than the duration of the first time slot, and the duration of the second time period is longer than the duration of the first time period.

[0009] With this possible design, relative to the moment the door of the first stream's queue opens, the door of the second stream's queue opens with a first delay, while the door of the third stream's queue opens with a second delay. Since the second delay is longer than the first, the door of the third stream's queue opens later than the door of the second stream's queue. That is, for the second stream that arrives at the packet forwarding node in a timely manner, this possible design can guarantee that the second stream receives transmission resources before the third stream. In other words, by controlling the duration of the first and second time periods, the priority of the second and third streams in contending for transmission resources can be controlled.

[0010] In another possible design, after allowing the scheduling of the second stream of packets to the outgoing interface to begin from the second moment, the above method further includes: during the process of forwarding the second packet in the second stream at the outgoing interface, if the first packet of the first stream is received, then controlling the outgoing interface to suspend forwarding the second packet and controlling the outgoing interface to forward the first packet.

[0011] In another possible design, the above method also includes: if there are no messages to be forwarded in the first stream after the outgoing interface has completed sending the first message, controlling the outgoing interface to send the unsent portion of the second message.

[0012] With these two possible designs, when a first-order message with a required transmission delay within a certain range arrives at the message forwarding node later than the specified time, and the message forwarding node's sending resources are being occupied by other traffic (such as the second message of the second-order flow), the first-order message to be forwarded (i.e., the first message) does not need to wait for the currently forwarding second message to finish forwarding before forwarding. Instead, it preempts the occupied sending resources to forward the first message immediately, thereby ensuring the transmission delay of the first-order message with a required transmission delay within a certain range.

[0013] In another possible design, the aforementioned outgoing interface is also used to forward a fourth stream, which requires a defined transmission delay range. The method further includes: stopping the scheduling of packets to be forwarded in the fourth stream to the outgoing interface in the first time slot; and allowing the scheduling of packets to be forwarded in the fourth stream to the outgoing interface in the second time slot, starting with the fourth time slot, and stopping the scheduling of packets to be forwarded in the first stream to the outgoing interface. Here, the second time slot is used for forwarding packets in the fourth stream.

[0014] In another possible design, the above method further includes: during the third time period, which starts at the fourth time point and ends at the fifth time point, stopping the scheduling of packets to be forwarded in the second stream to the outgoing interface; and allowing the scheduling of packets to be forwarded in the second stream to the outgoing interface from the fifth time point onwards. The duration of the third time period is shorter than the duration of the second time slot.

[0015] In another possible design approach, the first flow is scheduling traffic (ST), and the second flow is audio video bridging (AVB) traffic.

[0016] In yet another possible design approach, the third flow is the best effort (BE) flow.

[0017] In another possible design approach, the communication network is a TSN network.

[0018] Secondly, this application provides a message forwarding control device. This message forwarding control device is used to execute any of the methods provided in the first aspect. This application can divide the message forwarding control device into functional modules according to any of the methods provided in the first aspect. For example, each function can be divided into its own functional modules, or two or more functions can be integrated into one processing module. For example, this application can divide the message forwarding control device into a first control unit, a second control unit, etc., according to function. The descriptions of possible technical solutions and beneficial effects executed by the aforementioned functional modules can refer to the solutions provided in the first aspect and any possible design method within the first aspect, and will not be repeated here.

[0019] Thirdly, this application provides a message forwarding control device applied to a message forwarding node in a communication network that forwards a first stream and a second stream through the same outgoing interface. The message forwarding node is configured with a Group Classification Flow (GCL), which indicates the time slots for allowing the scheduling of messages of the first stream and the second stream to the outgoing interface, and indicates the time slots for stopping the scheduling of messages of the first stream and the second stream to the outgoing interface. The GCL includes a configuration where the gate state of the sending queue containing the first stream and the gate state of the sending queue containing the second stream are both open. The message forwarding control device is used to execute, based on the GCL, a control method for scheduling messages in the first stream and / or the second stream to the outgoing interface, as provided in the first aspect and any possible design of the first aspect.

[0020] In one possible design, the first flow requires a defined range of transmission delay, the second flow does not require a defined range of transmission delay, and the outgoing interface is also used to forward a third flow, which does not require a defined range of transmission delay. The outgoing interface prioritizes forwarding the third flow over forwarding the second flow. The Gateway Channel (GCL) is also used to indicate time slots that allow scheduling of the third flow to the outgoing interface, and to indicate time slots that stop scheduling the third flow to the outgoing interface. Furthermore, the GCL includes a configuration where the gate states of the first flow's transmission queue, the second flow's transmission queue, and the third flow's transmission queue are all simultaneously open, and a configuration where the gate state of the third flow's transmission queue is closed when the gate state of the second flow's transmission queue is open.

[0021] Fourthly, this application provides a message forwarding control device, which includes a memory, a network interface, and one or more processors. The one or more processors receive or transmit data through the network interface, and are configured to read program instructions stored in the memory to execute the methods provided by the first aspect and any possible design of the first aspect.

[0022] The message forwarding control device described in the second, third, or fourth aspect may be, for example, a network device with message forwarding capability, such as a switch, router, repeater, hub, bridge, or gateway, or a component within the network device, such as a single board, line card, or network card, or a chip used to implement some or all of the operations described in any of the above aspects and in any possible design.

[0023] Fifthly, this application provides a computer-readable storage medium that is a non-volatile computer-readable storage medium, the computer-readable storage medium including computer program instructions that, when executed by a processor, a computing device including a processor, or a computer system, perform the methods provided by the first aspect and any possible design of the first aspect.

[0024] In a sixth aspect, this application provides a computer program product comprising instructions that, when executed by a processor, a computing device including a processor, or a computer system, cause the processor, the computing device including a processor, or the computer system to perform the methods provided by the first aspect and any possible design of the first aspect.

[0025] In a seventh aspect, this application provides a chip that includes a processor for running program instructions or code. The chip or a device including the chip can be used to perform methods provided by the first aspect and any possible design embodiment within the first aspect. Exemplarily, the chip further includes an input interface, an output interface, and a memory. The chip's input interface, output interface, processor, and memory are connected via internal interconnection paths. The memory in the chip stores program instructions or code executed by the processor, and the input and output interfaces are used for communication and connection between the chip and other chips or devices.

[0026] It is understood that any of the message forwarding control devices, computer-readable storage media, computer program products or chips provided above can be applied to the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can be referred to the beneficial effects in the corresponding methods, and will not be repeated here.

[0027] In this application, the names of the aforementioned message forwarding control devices, etc., do not limit the devices or functional modules themselves. In actual implementation, these devices or functional modules may appear under other names. As long as the functions of each device or functional module are similar to those in this application, they all fall within the protection scope of this application. Attached Figure Description

[0028] Figure 1This is a schematic diagram illustrating a process of packet forwarding by a packet forwarding node in a TSN.

[0029] Figure 2 This is a schematic diagram illustrating the gate state planning of queues containing traffic with different transmission performance requirements in the TSN standard.

[0030] Figure 3a This is a schematic diagram illustrating an application scenario of the method provided in the embodiments of this application;

[0031] Figure 3b This is a schematic diagram illustrating another application scenario of the method provided in the embodiments of this application;

[0032] Figure 4 This is a schematic diagram of a GCL configuration provided in an embodiment of this application;

[0033] Figure 5 This is a flowchart illustrating a message forwarding control method provided in an embodiment of this application;

[0034] Figure 6 This is a flowchart illustrating another message forwarding control method provided in an embodiment of this application;

[0035] Figure 7 This is a schematic diagram illustrating how a first message preempts the transmission resources of a second message, as provided in an embodiment of this application.

[0036] Figure 8 This is a schematic diagram of another configuration of GCL provided in an embodiment of this application;

[0037] Figure 9 This is a flowchart illustrating another message forwarding control method provided in an embodiment of this application;

[0038] Figure 10 This describes the message sending status of the message forwarding node's outgoing interface after using the method provided in the embodiments of this application;

[0039] Figure 11a This is another configuration diagram of the GCL provided in the embodiments of this application;

[0040] Figure 11b This is another configuration diagram of the GCL provided in the embodiments of this application;

[0041] Figure 12 This is a flowchart illustrating another message forwarding control method provided in an embodiment of this application;

[0042] Figure 13 This is a schematic diagram of a TSN network topology provided in an embodiment of this application;

[0043] Figure 14This is a schematic diagram of a GCL configuration provided by TSN according to an embodiment of this application;

[0044] Figure 15 This describes the utilization of the outgoing interface of the message forwarding node after configuring GCL using the methods and related technologies provided in the embodiments of this application;

[0045] Figure 16 This is a schematic diagram of the structure of a message forwarding control device provided in an embodiment of this application;

[0046] Figure 17 This is a schematic diagram of the structure of a message forwarding node provided in an embodiment of this application. Detailed Implementation

[0047] To make the objectives, technical solutions, and advantages of this application clearer, the embodiments of this application will be described in further detail below with reference to the accompanying drawings.

[0048] To facilitate understanding, the technologies and background involved in the embodiments of this application will be explained below.

[0049] 1. TSN

[0050] TSN is a communication network defined by the Institute of Electrical and Electronics Engineers (IEEE). TSN enables low latency, low jitter, and zero packet loss in data transmission, and is used to address the issue of bounded latency for some traffic types (such as latency-sensitive traffic) when a network carries a variety of traffic types. Bounded latency means that the latency has a defined range.

[0051] In one example, when both OT and IT services are carried simultaneously in a local area network based on Ethernet communication standards, the data transmission performance requirements of OT and IT services differ. For instance, IT services require greater bandwidth, while OT services demand higher real-time performance and determinism compared to IT services. In this situation, using a TSN to simultaneously carry OT and IT services can guarantee bounded latency for latency-sensitive traffic within both OT and IT services, thereby ensuring high quality of service (QoS) for latency-sensitive services.

[0052] The TSN communication protocol primarily operates at Layer 2 of the Open System Interconnection (OSI) seven-layer model: the data link layer. TSN enhances Ethernet's real-time performance by employing measures such as precise clock synchronization, bandwidth reservation, traffic shaping, frame preemption, gate control, cyclic queuing and forwarding (CQF), flow-by-flow filtering, and seamless redundancy to provide a deterministic end-to-end transmission delay. This deterministic end-to-end transmission delay is known as bounded delay. Traffic shaping measures include, but are not limited to, time-aware shapers (TAS), asynchronous traffic shaping (ATS), or committed burst size (CBS) shapers.

[0053] For message flows requiring bounded latency, such as ST traffic, it is generally necessary to pre-allocate time slots matching the transmission mode (or transmission pattern) of ST traffic through static time slot orchestration, based on node clock synchronization. The TSN then schedules and forwards ST traffic using TAS and / or CQF, combined with the time slots matching the ST traffic. This ensures that ST traffic uses conflict-free transmission resources for forwarding, achieving deterministic forwarding of ST traffic and guaranteeing bounded end-to-end latency and jitter. Scheduled traffic refers to traffic with configured transmission resources. For example, periodically transmitted traffic is generally scheduled traffic, while non-periodic transmitted traffic is generally non-scheduled traffic. A time slot is a fundamental concept in information science, specifically representing a time segment in a time-division multiplexing mode. For instance, during time slot 1 (time 1 to time 2), the network transmits the first message flow, and during time slot 2 (time 2 to time 3), the network transmits the second message flow. Time slots 1 and 2 are two time slots.

[0054] For message flows without bounded latency requirements, such as aperiodic AVB and BE traffic, since aperiodic AVB and BE traffic are unscheduled (i.e., their transmission patterns are irregular), it's impossible to allocate forwarding time slots for them through pre-arranged time slots. Therefore, they must rely on statistical multiplexing to dynamically contend for available time slots for forwarding. For example, AVB traffic can be smoothed out through traffic shaping mechanisms, combined with rate limiting to ensure the queue storing pending forwarding messages doesn't exceed its maximum depth, and contention for transmission resources (such as outgoing interface usage rights) within available time slots based on AVB traffic forwarding priority. This improves the reliability and determinism of AVB traffic forwarding. Compared to AVB traffic, BE traffic has a lower forwarding priority. Therefore, BE traffic can maximize the utilization of the forwarding node's remaining transmission resources after other traffic has been forwarded, thereby improving the statistical multiplexing rate of transmission resources.

[0055] Traffic forwarding priority indicates the level of data transmission performance required by the traffic. Generally, the higher the data transmission performance required by the traffic, the higher the priority of the traffic being forwarded; conversely, the lower the data transmission performance required by the traffic, the lower the priority of the traffic being forwarded. Traffic forwarding priority can be indicated by the traffic's priority level. For example, the higher the traffic priority, the higher the priority of the traffic; that is, high-priority traffic is forwarded first, and low-priority traffic is forwarded later. Alternatively, the higher the traffic priority, the lower the priority of the traffic being forwarded; that is, high-priority traffic is forwarded later, and low-priority traffic is forwarded first.

[0056] For simplicity, the embodiments of this application will be described below using the example that the higher the priority of traffic, the higher the required data transmission performance, and thus the higher the priority of traffic forwarding. That is, high-priority traffic is forwarded first, and low-priority traffic is forwarded later.

[0057] 2. GCL

[0058] The gate control mechanism provided by TSN, also known as TSN gating or time-based gating, controls the forwarding switches (also called "gates") of queues storing packets to be sent based on time. It should be understood that a forwarding switch is a logical switch, actually determining whether to allow packets in the queue to be forwarded to the egress interface for forwarding. For example, when the queue's gate state is "open," packets in that queue can be scheduled to the egress interface of the packet forwarding node for forwarding. When the queue's gate state is "closed," scheduling packets in that queue to the egress interface stops; that is, packets in the queue wait in the queue until the "gate" state becomes "open" before they can be scheduled to the egress interface for forwarding. Here, the opening and closing of the queue's "gate" state is generally configured by a time-based GCL. After the GCL is configured, the queue's gate state periodically repeats "open" and "close" according to the GCL configuration.

[0059] For example, for a certain egress port of a packet forwarding node, such as the first egress port, the GCL configured for the first egress port can include multiple lines, where each line includes the gate state of each queue forwarding packets through the first egress port and the effective duration (timeinterval) of the state included in this line. For example, when the first egress port is used to forward packets of sending queue 1 and sending queue 2, the configuration of the first line of the GCL configured for the first egress port includes: the gate state of sending queue 1 (e.g., "open"), the gate state of sending queue 2 (e.g., "closed"), and the effective duration of the gate state included in this line; the configuration of the second line of the GCL includes the gate state of sending queue 1 (e.g., "closed"), the gate state of sending queue 2 (e.g., "open"), and the effective duration of the gate state included in this line, and so on. In this way, GCL sets the gate state and corresponding effective duration of each queue within a supercycle (see the description below for an explanation of the supercycle, which will not be repeated here). Thus, when GCL configuration is executed cyclically according to the base time, it can achieve periodic (i.e., supercycle) control over the gate state of the sending queue.

[0060] For any queue, the time slot during which the queue's gate is "open" is the time slot during which the traffic stored in that queue is allowed to be forwarded; in this embodiment, this is denoted as the forwarding time slot. Conversely, the time slot during which the queue's gate is "closed" is the time slot during which the scheduling of messages to the outgoing interface is stopped; in this embodiment, this is denoted as the stop time slot. For traffic with bounded latency, both the forwarding time slot and the stop time slot are pre-arranged and determined.

[0061] In TSN, traffic with different transmission performance requirements is forwarded through different queues. Therefore, by controlling the gate states of different queues through GCL, forwarding control of traffic with different transmission performance requirements can be achieved. When controlling the forwarding of traffic with different transmission performance requirements through GCL, to avoid interference between traffic without bounded delay requirements and traffic requiring bounded delay, a basic principle of GCL is to plan mutually exclusive gate states for the queues containing packets to be forwarded in traffic requiring bounded delay and the queues containing packets to be forwarded in traffic without bounded delay requirements. That is, at any given time, only the queue containing packets to be forwarded in traffic requiring bounded delay (denoted as queue 1) has its gate state "open," while the gate states of all other queues (excluding queue 1) must all be "closed." This allows time-division multiplexing of the egress interface of the packet forwarding node for both latency-bounded and non-latency-bounded traffic. Specifically, when latency-bounded traffic is forwarded through the egress interface of a packet forwarding node, non-latency-bounded traffic is stopped from being scheduled to that interface. Correspondingly, while latency-bounded traffic stops being scheduled to the egress interface, the TSN allows non-latency-bounded traffic to be scheduled to that interface. Furthermore, when time slots are used to forward non-latency-bounded traffic (such as non-scheduled traffic), to support flexible bandwidth access, the TSN allows the gate state of the queue containing packets to be forwarded in non-latency-bounded traffic to be simultaneously "open." Detailed examples can be found below. Figure 2 As previously mentioned, I will not repeat myself here.

[0062] It should be noted that the "queue" mentioned in the embodiments of this application refers to a queue used to store packets to be forwarded in the packet stream, and will not be described again hereafter.

[0063] 3. Media Access Control (MAC) Frame Preemption Technology

[0064] MAC frame preemption technology based on the IEEE 802.3br protocol ensures real-time transmission of preempted traffic by implementing frame preemption at the MAC layer. Typically, traffic subject to frame preemption is traffic with high transmission performance requirements, such as traffic demanding high QoS levels.

[0065] In practice, MAC frame preemption technology is typically implemented through two modules designed for the outgoing interface of a packet forwarding node. These two modules are a preemptible MAC (pMAC) module and an express MAC (eMAC) module. A packet scheduled to the eMAC module can preempt the transmission resources of a packet scheduled to the pMAC module. This causes packets being forwarded in the pMAC module to enter a waiting mode until the packets in the eMAC module have finished forwarding. Only then can the forwarding of packets not yet completed in the pMAC module resume, thus ensuring the latency of traffic scheduled to the eMAC module. Therefore, packet forwarding nodes generally schedule low-priority packets to the pMAC module and high-priority packets to the eMAC module, allowing high-priority packets to preempt the transmission resources of low-priority packets to ensure their own latency.

[0066] refer to Figure 1 , Figure 1 This diagram illustrates a process where a packet forwarding node in a TSN forwards packets. For example... Figure 1 As shown, for any packet forwarding node in a TSN, such as packet forwarding node 100, packet forwarding node 100 includes n ingress interfaces, namely ingress interface 101 to ingress interface 10n, where n is an integer greater than 1. Packet forwarding node 100 receives packet streams sent by other nodes (such as end-side nodes connected to packet forwarding node 100 or other forwarding nodes in the TSN) through the n ingress interfaces, and selects an appropriate egress interface for the received packet stream through the switching fabric. For example, packet forwarding node 100 selects an egress interface through the switching fabric... Figure 1The ST, AVB, and BE traffic shown are selected for outgoing interface 102. Then, the packet forwarding node 100 uses a classifier to classify the packet flows determined to be forwarded through outgoing interface 102. Based on the classification results, traffic with different priorities is sent to queues configured for outgoing interface 102 with corresponding priorities. For example, ST traffic, which requires bounded latency, has the highest priority, so it is sent to queue 1, which has the highest priority. AVB and BE traffic, which do not require bounded latency, have lower priorities, and AVB traffic has a higher priority than BE traffic. Therefore, the packet forwarding node 100 sends AVB traffic to queue 7, which has the second lowest priority, and BE traffic to queue 8, which has the lowest priority. In this way, through the pre-configured GCL-planned gating time, the "doors" of each queue can be opened or closed, thereby scheduling packets in the queues to outgoing interface 102 for forwarding in the forwarding time slots corresponding to each traffic, and stopping the scheduling of packets in the queues to outgoing interface 102 in the stop time slots corresponding to each traffic.

[0067] As an example, refer to Figure 2 , Figure 2 This diagram illustrates the gate state planning for queues containing traffic with different transmission performance requirements in the TSN standard. (Example:) Figure 2 As shown, based on the ST traffic transmission mode, time slots matching the ST traffic transmission mode can be pre-allocated for ST traffic using a static time slot arrangement method: in the forwarding time slot of duration L1 (such as... Figure 2 Within time slots 1 and 3 shown, packets awaiting forwarding that are scheduled to the outgoing interface for ST traffic are allowed, and a stop time slot with a duration of L2, starting at the end of the forwarding time slot, is provided (e.g., ...). Figure 2 During time slots 2 and 4, it is not allowed to schedule ST traffic packets to the outgoing interface for forwarding. Then, a time slot with a duration of L1, starting from the end time of the stop time slot, is used as the forwarding time slot for ST traffic, and this process is repeated. Based on this, the GCL configures the gate state of the queue containing ST traffic during the forwarding time slot to "open" and the gate state of the queue containing ST traffic during the stop time slot to "closed". Here, L1 and L2 are positive numbers. This embodiment of the application does not limit the specific values ​​of L1 and L2; L1 and L2 can be the same or different.

[0068] To prevent AVB and BE traffic from interfering with the forwarding of ST traffic, the GCL configures the gate state of the queues containing AVB and BE traffic to "off" in the forwarding slots of ST traffic. For example, in slots 1 and 3, packet forwarding nodes are not allowed to schedule packets to be forwarded in AVB and BE traffic to the outgoing interface. Figure 1The gate states of each queue are as follows: the gate state of the queue containing ST traffic is "open," and the gate state of the other queues is "closed." That is, time slots 1 and 3, which serve as the forwarding time slots for ST traffic, are the stop time slots for AVB and BE traffic. This satisfies the criterion mentioned above that at any given time, only the queue containing traffic requiring bounded delay has its gate state "open," while the gate states of all other queues must be "closed," thus guaranteeing the transmission delay of traffic requiring bounded delay.

[0069] Correspondingly, in the ST traffic stop time slot, the GCL configures the gate state of the queues containing AVB and BE traffic to "open," meaning that in time slots 2 and 4, packet forwarding nodes are allowed to schedule packets to be forwarded from AVB and BE traffic to the outgoing interface. In other words, time slots 2 and 4, which are the ST traffic stop time slots, are the forwarding time slots for AVB and BE traffic. In this case, packet forwarding nodes can schedule packets to be forwarded from AVB and BE traffic to the outgoing interface 102 in time slots 2 and 4 according to a preset scheduling strategy. In one example, the scheduling strategy could be priority scheduling, round-robin scheduling, etc., and is not limited to these.

[0070] See also Figure 2 When the GCL configured as described above is applied to the packet forwarding node 100, the packet forwarding behavior of the outgoing interface 102, which is used to forward ST traffic, AVB traffic, and BE traffic, is as follows: When an ST traffic packet arrives at queue 1 at or before the start of time slot 1, the packet forwarding node 100 forwards the ST traffic packet in queue 1 of the outgoing interface 102 in time slot 1, and stops forwarding the ST traffic packet in queue 1 of the outgoing interface 102 at the end of time slot 1; when an AVB traffic packet arrives at queue 7 and a BE traffic packet arrives at queue 8 at or before the start of time slot 2, the packet forwarding node 100 forwards the ST traffic packet in queue 7 of the outgoing interface 102 in time slot 1, and stops forwarding the ST traffic packet in queue 8 of the outgoing interface 102 in time slot 1. The strategy is to schedule according to priority. In this case, AVB traffic packets in queue 7 can compete for the transmission resources of the outgoing interface 102 in time slot 2 for forwarding. At the beginning of time slot 3, ST traffic packets fail to arrive in queue 1 on time, and ST traffic packets only arrive in queue 1 when half of time slot 3 has elapsed. At this time, if the packet forwarding node 100 determines that the size of the packet currently arriving in queue 1 can be transmitted in the remaining time of time slot 3, it will schedule the packet for forwarding. Subsequently, at the beginning of time slot 4, if the packet forwarding node 100 determines that all AVB traffic packets in queue 7 have been forwarded, it will schedule the BE traffic packets in queue 8 for forwarding.

[0071] It is understandable that a continuous period of time, including at least one forwarding slot and at least one stopping slot for each flow forwarded through the same outgoing interface, and which repeats repeatedly, can be denoted as a hypercycle or macrocycle. For example Figure 2 As shown, time slot 1 and time slot 2 form a supercycle, and time slot 3 and time slot 4 form a supercycle.

[0072] See also Figure 1 The message forwarding node 100 is also configured with a frame preemption module, which includes an eMAC module, a pMAC module, and a MAC merging sublayer module. Thus, messages from high-priority queues are scheduled to the eMAC module for forwarding, while messages from low-priority queues are scheduled to the pMAC module. This allows messages from high-priority queues to preempt the transmission resources available when the pMAC module forwards messages from low-priority queues, thereby ensuring the transmission latency of traffic in high-priority queues. The MAC merging sublayer module manages and coordinates the transmission of messages forwarded by the eMAC module and those forwarded by the pMAC module. The MAC merging sublayer module ensures that messages forwarded by the eMAC module have priority during transmission, meaning that messages forwarded by the eMAC module are transmitted before those forwarded by the pMAC module, thus achieving the effect of frame preemption.

[0073] In related technologies, when the message forwarding node 100 controls the queue containing ST traffic to enter the forwarding time slot via GCL, the scheduling of AVB traffic and BE traffic in the queues stops at the outgoing interface. However, at this time, there may be AVB traffic or BE traffic being forwarded at the outgoing interface. Therefore, when the queue containing ST traffic enters the forwarding time slot and begins scheduling packets to be forwarded at the outgoing interface, there may still be AVB traffic or BE traffic being forwarded at the outgoing interface. In this case, the frame preemption module can ensure that after the queue containing ST traffic enters the forwarding time slot and begins scheduling packets to be forwarded at the outgoing interface, it immediately preempts the transmission resources of the still forwarding AVB traffic or BE traffic, thus guaranteeing the transmission delay of ST traffic.

[0074] Currently, achieving perfect clock synchronization between message forwarding nodes is difficult. Clock errors can easily lead to misalignment of time slots between message forwarding nodes. As a result, messages that do not arrive at the message forwarding node on time will miss their pre-arranged forwarding time slots, causing those time slots to become idle and resulting in a waste of bandwidth resources.

[0075] For example Figure 2 As shown, in time slot 3, the packets of ST traffic arrive in queue 1 when half of time slot 3 has elapsed, resulting in the outgoing interface being idle for the first half of time slot 3. Furthermore, due to the restrictions of the "basic principle" mentioned above, traffic that does not require bounded delay (such as AVB traffic or BE traffic) cannot contend for the outgoing interface to forward packets when the outgoing interface is idle in time slot 3, thus wasting the outgoing interface's sending resources.

[0076] In other examples, after the message forwarding node completes the forwarding of the received ST traffic in time slot 1, there is a period of inactivity at the end of time slot 1. This is because, in practice, to ensure the real-time forwarding of asynchronous traffic such as alarms (e.g., emergency braking messages in OT services), these asynchronous traffic are generally scheduled to be forwarded in the highest priority queue. To avoid these asynchronous traffic interfering with the scheduling of traffic in low-priority queues, a certain margin of time slots is generally added when planning forwarding time slots for traffic requiring bounded latency. That is, the forwarding time slots planned for traffic requiring bounded latency include: time slots for forwarding this traffic and time slots for forwarding asynchronous traffic with real-time requirements. However, these asynchronous traffic are generally intermittent traffic, so the time slots reserved for asynchronous traffic in the forwarding time slots planned for traffic requiring bounded latency are mostly idle. However, due to the limitations of the "basic principles" mentioned above, traffic that does not require bounded latency (such as AVB traffic or BE traffic) cannot compete for the time slots reserved for asynchronous traffic, which also leads to a waste of outgoing interface transmission resources.

[0077] To reduce the waste of transmission resources, embodiments of this application provide a message forwarding control method. This method is applied to a communication network (such as a TSN), which includes message forwarding nodes that forward first and second flows of messages through the same outgoing interface. The method controls the gate state of the queue containing the second flow to "closed" starting from the beginning of the first flow's forwarding time slot (i.e., the first time slot), and controls the gate state of the queue containing the second flow to "open" after a period shorter than the first time slot (i.e., the first duration). That is, during a first time period starting from the first time slot and lasting the first duration, scheduling of second flow messages to the outgoing interface is stopped, and scheduling of second flow messages to the outgoing interface is allowed starting from the end of the first time period (i.e., the second time slot). In this way, the forwarding time slot of the second flow is delayed by the first flow for a certain duration. Therefore, when the first flow's packets do not arrive at the packet forwarding node on time, causing the first time slot to be idle, the forwarding time slot of the second flow arrives in time. Thus, the second flow can compete for the idle outgoing interface sending resources to forward packets, which can improve the statistical reuse rate of the outgoing interface sending resources of the packet forwarding node.

[0078] refer to Figure 3a , Figure 3a A schematic diagram illustrating an application scenario of the method provided in an embodiment of this application is shown. For example... Figure 3aAs shown, this application scenario includes any message forwarding node in a communication network (such as a TSN). The message forwarding node receives multiple message streams with different transmission performance requirements, including but not limited to ST traffic, AVB traffic, and BE traffic as described above. The message forwarding node includes at least one outgoing interface, and this at least one outgoing interface includes an interface for forwarding at least two of the aforementioned multiple message streams. The at least two message streams have different transmission performance requirements. The at least two message streams include a first stream requiring bounded latency, and a second stream that does not require bounded latency. In one example, the first stream is an ST stream, and the second stream is either an AVB stream or a BE stream.

[0079] For example, a packet forwarding node can be implemented as a network device with packet forwarding capabilities, such as a switch, router, repeater, hub, bridge, or gateway, or as a functional module with packet forwarding capabilities within a network device. The switch can be a physical switch or a virtual switch; there is no limitation on this.

[0080] It should be understood that when in Figure 3a When the method provided in the embodiments of this application is applied to the message forwarding node shown, the statistical reuse rate of the message forwarding node's sending resources can be improved.

[0081] refer to Figure 3b , Figure 3b This diagram illustrates another application scenario of the method provided in the embodiments of this application. For example... Figure 3b As shown, the source end (including but not limited to) Figure 3b The source terminals 311, 312, and 313 shown are accessing the destination terminal (including but not limited to...) Figure 3b When destinations 321 and 322 are shown, messages can be sent to the destination through at least one message forwarding node (such as message forwarding node 331 and message forwarding node 332). Any one or each of these at least one message forwarding nodes can improve the statistical reuse rate of the outgoing interface sending resources by executing the method provided in the embodiments of this application.

[0082] It should also be understood that the above content is an exemplary description of the application scenarios of the message forwarding control method provided in the embodiments of this application, and does not constitute a limitation on the application scenarios of the method. As those skilled in the art know, as business needs change, its application scenarios can be adjusted according to application needs, and the embodiments of this application do not list them one by one.

[0083] This application also provides a message forwarding control device, which is applied to a message forwarding node in a communication network (such as a TSN) and is used to execute the method provided in this application to improve the statistical reuse rate of the message forwarding node's transmission resources. A detailed description of the message forwarding node can be found in Figure 3 (for simplicity, [the text is incomplete and likely refers to a different document or diagram]. Figure 3a and Figure 3b The relevant descriptions (referred to as Figure 3) will not be repeated here.

[0084] For example, the control device for message forwarding can be implemented through a message forwarding node or a functional module (such as a network interface card) in a message forwarding node, without limitation.

[0085] The message forwarding control method provided in the embodiments of this application is described below with reference to the accompanying drawings.

[0086] First, considering the application scenario shown in Figure 3, when the packet forwarding node shown in Figure 3 includes an outgoing interface for forwarding the first and second flows, and the first flow requires bounded latency while the second flow does not, then before executing the method provided in this application embodiment, it is necessary to statically configure the GCL for the packet forwarding node based on time slot orchestration. The packet forwarding node can configure the GCL locally, or it can receive the GCL configured by the network management system / network controller; there are no limitations on this.

[0087] In this embodiment, the GCL instruction configured for the packet forwarding node is as follows: within each supercycle, the time slot pre-arranged for forwarding packets in the first flow (i.e., the forwarding time slot) is the first time slot. That is, the first time slot allows the scheduling of packets to be forwarded in the first flow to the outgoing interface. During the first time period, which starts at a first time and ends at a second time, the scheduling of packets to be forwarded in the second flow to the outgoing interface is stopped. From the second time, the scheduling of packets in the second flow to the outgoing interface is allowed. The duration of the first time period (i.e., the first duration) is less than the duration of the first time slot. In one example, the first duration is generally determined empirically, for example, set to range from a few microseconds (μs) to several hundred microseconds. That is, as... Figure 4 As shown, within one supercycle, the gate state of the queue containing the first flow is "open" in the first time slot, and the gate state of the queue containing the second flow is "closed" in the first time period of the first duration, and remains "open" in the remaining time period of the first time slot excluding the first time period, and also in the stop time slot of the first flow. That is, the GCL configured for the packet forwarding node in this embodiment includes a configuration where the gate states of both the queue containing the first flow and the queue containing the second flow are simultaneously "open". Furthermore, the gate state of the queue containing the first flow is "closed" in the stop time slot of the first flow, meaning that scheduling of first-flow packets to the outgoing interface is stopped during the stop time slot.

[0088] It can be seen that, on the one hand, within the first-order forwarding time slot (first time slot), the gate state of the queue containing the second-order flow is not "closed" for the entire first time slot (e.g., ...). Figure 2 The gate state of the queue containing the AVB traffic shown is "closed" during the first time slot of the first time slot, and "open" during the remaining time slots of the first time slot. Figure 4 The GCL configuration shown ensures that when the first-flow packet arrives at the packet forwarding node on time, the first flow receives priority over the second flow for forwarding. Furthermore, if the first-flow packet fails to arrive on time, resulting in an idle first time slot, the second flow can use the outgoing interface to forward packets during the remaining time slot outside the first time period, thus avoiding the first time slot being wasted. On the other hand, when the packet forwarding node does not receive any asynchronous traffic with the highest priority, such as alarms, scheduled for forwarding in the queue of the first flow in the first time slot, it indicates that the time slot reserved for asynchronous traffic such as alarms in the first time slot is idle. Therefore, the second flow can also use the outgoing interface to forward packets in this reserved time slot, further avoiding the first time slot being wasted and thus improving the statistical reuse rate of outgoing interface sending resources. On another note, Figure 4 The GCL configuration shown can also be understood as follows: relative to the moment the door of the queue containing the first flow opens, the "door" of the queue containing the second flow opens with a delay of a first duration. Therefore, when arranging forwarding slots for the first and second flows using an algorithm to find the optimal solution based on information such as the delay requirements of the first and second flows, it is not necessary to use the relevant information of the second flow as input. This is because the second flow can be directly set based on the delay settings of the forwarding slots of the first flow, which avoids the situation where there is no solution when finding the optimal solution due to too much input information.

[0089] based on Figure 4 The GCL configuration shown is for reference. Figure 5 , Figure 5 A flowchart illustrating a message forwarding control method provided in an embodiment of this application is shown. Optionally, this method is applied to the application scenario shown in Figure 3. Taking the message forwarding control device implemented by a message forwarding node as an example, for message forwarding nodes in a communication network (such as TSN) that forward the first and second flows through the same outgoing interface, such as... Figure 5 As shown, the method includes steps 101 to 103.

[0090] Step 101: In the first time slot, starting from the first time moment, the packet forwarding node is allowed to schedule packets to be forwarded in the first flow to the outgoing interface of the packet forwarding node. The first time slot is a time slot pre-arranged for forwarding packets in the first flow.

[0091] In this step, the packet forwarding node opens the "door" of the queue containing the first flow at the first moment through the pre-configured GCL control, thereby allowing the packets in the queue to be scheduled to the outgoing interface for forwarding.

[0092] Optionally, the message forwarding node is configured with Figure 1 When the frame preemption module is activated, the packet forwarding node, after opening the "door" to the queue containing the first stream at the first moment through the pre-configured GCL control, allows packets in that queue to be sent to the eMAC module in the frame preemption module for forwarding. In this way, if the pMAC module in the frame preemption module currently has a packet being forwarded, the eMAC module can preempt the transmission resources of that packet to send the first stream packet. The detailed process is not elaborated further.

[0093] Step 102: During the first time period, which starts at the first time and ends at the second time, the message forwarding node stops scheduling messages to be forwarded in the second stream to the outgoing interface. The duration of the first time period (i.e., the first duration) is less than the duration of the first time slot.

[0094] In this step, the packet forwarding node closes the "door" of the queue containing the second stream at the first moment through the pre-configured GCL control, thereby stopping the scheduling of packets in the queue to the outgoing interface for forwarding.

[0095] Step 103: Starting from the second moment, the message forwarding node allows the scheduling of the second stream of messages to the outgoing interface.

[0096] In this step, the packet forwarding node opens the "door" of the queue containing the second flow at the second moment through the pre-configured GCL control, thereby enabling the scheduling of packets in the queue to the outgoing interface for forwarding.

[0097] In this scenario, if there are no packets to be forwarded in the first flow by the second time slot, meaning the queue for storing packets to be forwarded in the first flow is empty by the second time slot, it indicates that the packets in the first flow have not arrived at the forwarding node on time, and therefore the first time slot is temporarily idle. In this case, starting from the second time slot, if the queue for storing packets to be forwarded in the second flow contains packets, the forwarding node allows the forwarding node to forward packets from the queue containing the second flow scheduled at the outgoing interface. Compared to the "basic principle" applied in the related technologies described above, the method provided in this application embodiment can avoid wasting the sending resources of the outgoing interface during idle forwarding time slots (such as the first time slot) in the first flow, thus improving the statistical reuse rate of the sending resources of the forwarding node.

[0098] In some embodiments, after the message forwarding node executes steps 101 to 103, if the first flow has no messages to be sent as of the second time interval, and the second flow has messages to be forwarded as of the second time interval, then the second flow uses the outgoing interface of the message forwarding node for message forwarding starting from the second time interval. In this case, if the message forwarding node completes the reception of the message to be forwarded in the first flow (denoted as the first message) after the second time interval but before the end of the first time slot, that is, before the end of the first time slot, the queue used to store the messages to be forwarded in the first flow includes the first message to be forwarded. To address this situation, embodiments of this application provide another message forwarding control method that can guarantee the transmission delay of the first flow in this case.

[0099] refer to Figure 6 , Figure 6 A flowchart illustrating another message forwarding control method provided in this application embodiment is shown. Optionally, this method is applied to the application scenario shown in Figure 3. Taking the message forwarding control device implemented by a message forwarding node as an example, for message forwarding nodes in a communication network (such as TSN) that forward the first and second flows through the same outgoing interface, after executing steps 101 to 103, that is, after the message forwarding node allows the scheduling of the second flow of messages to the outgoing interface from the second time point, it also executes... Figure 6 Steps 201 to 202 are shown.

[0100] Step 201: During the process of forwarding the second message in the second stream at the outgoing interface of the message forwarding node, if there is a first message to be forwarded in the first stream, the message forwarding node controls the outgoing interface to suspend the transmission of the second message and controls the outgoing interface to forward the first message.

[0101] The second message is a message to be forwarded from the queue of the second flow to the outgoing interface during the idle period after the second time slot in the first time slot.

[0102] In other words, during this step, when the message forwarding node schedules and forwards the second message to the outgoing interface during the first time slot, it receives the first message to be forwarded in the first stream. Since it is in the first time slot at this time, the message forwarding node is allowed to schedule the first message to be forwarded in the first stream to the outgoing interface, thus scheduling the first message to the outgoing interface immediately after receiving it. At this time, the outgoing interface is being used to forward the second message of the second stream. Therefore, the message forwarding node can preempt the transmission resources for the first message and forward it through the frame preemption module. That is, the message forwarding node controls the outgoing interface to pause the transmission of the second message and controls the outgoing interface to forward the first message. For example, the message forwarding node sends the first message to be forwarded in the first stream to the eMAC module of the frame preemption module, and preempts the transmission resources of the second message scheduled to the pMAC module through the eMAC module for forwarding. The detailed implementation process is not described here.

[0103] Understandably, when a message forwarding node preempts a frame for the first message, it needs to first determine whether the remaining time in the first time slot is sufficient to transmit the first message. If it determines that the remaining time in the first time slot is sufficient to complete the transmission of the first message, then it will preempt the frame for the first message. Conversely, if the message forwarding node determines that the remaining time in the first time slot is insufficient to complete the transmission of the first message, it will control the first message to wait in the queue corresponding to the first flow until the next forwarding time slot arrives before scheduling and forwarding it.

[0104] Step 202: After the outgoing interface of the message forwarding node completes the transmission of the first message, if there are no messages to be sent in the first stream, the message forwarding node controls the outgoing interface to send the unsent portion of the second message.

[0105] In this step, after the message forwarding node preempts the transmission resources of the outgoing interface for the first message through the frame preemption module, it forwards the first message through that outgoing interface. If the message forwarding node completes the transmission of the first message through that outgoing interface, the first time slot has not ended, and there are currently no messages to be transmitted in the first flow, the message forwarding node controls that outgoing interface to continue transmitting the untransmitted portion of the second message. In actual implementation, after determining that the messages in the eMAC module (including the first message) have been transmitted through the outgoing interface, the message forwarding node controls the second message in the pMAC module to continue forwarding the untransmitted portion of the message when the transmission resources were preempted through that outgoing interface. The detailed process is not described here.

[0106] Through steps 201 to 202, when the first-order message with bounded latency arrives at the message forwarding node later than the specified time, and the sending resources of the message forwarding node are occupied by other traffic, the first-order message to be forwarded does not need to wait for the currently forwarded message to be forwarded to be completed before forwarding. Instead, it preempts the occupied sending resources to forward the first-order message to be forwarded immediately, thereby ensuring the transmission latency of the first-order message with bounded latency.

[0107] Combination Figure 4 ,refer to Figure 7 , Figure 7 This diagram illustrates a scenario where a first message preempts the transmission resources of a second message. For example... Figure 7 As shown, up to the second time point (t2), there are no packets to be forwarded in the first stream, but there are packets to be forwarded in the second stream. Therefore, starting from the second time point, the packet forwarding node schedules the second packet to the outgoing interface and forwards it. During the forwarding of the second packet at the outgoing interface, the packet forwarding node receives the first packet from the first stream. Therefore, the packet forwarding node schedules the first packet to the outgoing interface to preempt the sending resources of the second packet to forward the first packet, and also continues to forward the portion of the second packet that was not yet sent after the first packet was sent. It can be seen that... Figure 7 The second message shown was forwarded in two segments.

[0108] In some other embodiments, in conjunction with the application scenario shown in Figure 3, when a certain outgoing interface of the packet forwarding node shown in Figure 3 is used not only for forwarding the first and second flows, but also for forwarding a third flow that does not require bounded latency, and the priority of this outgoing interface in forwarding the third flow is lower than the priority in forwarding the second flow, that is, the priority of the third flow is lower than the priority of the second flow, in this case, before executing the method provided in the embodiments of this application, the GCL configured for the packet forwarding node based on the time slot orchestration method includes, in addition to, the first flow. Figure 4 In addition to the configuration shown, GCL also instructs that: within each supercycle, during the second time period starting at the first time slot and ending at the third time slot (denoted as t3), scheduling packets to be forwarded in the third flow to the outgoing interface should be stopped; and starting from the third time slot, scheduling packets in the third flow to the outgoing interface is permitted. The duration of the second time period (denoted as the second duration) is less than the duration of the first time slot, and the second duration is greater than the first duration. In one example, the second duration is generally determined empirically, for example, set to range from a few microseconds to several hundred microseconds. That is, combined with... Figure 4 ,like Figure 8As shown, within one supercycle, the gate state of the queue containing the first flow is "open" in the first time slot, the gate state of the queue containing the second flow is "closed" in the first time period, and remains "open" for the remaining time period excluding the first time period and the stop time slot of the first flow. The gate state of the queue containing the third flow is "closed" in the second time period, and remains "open" for the remaining time period excluding the second time period and the stop time slot of the first flow. That is, the GCL configured for the packet forwarding node in this embodiment includes configurations where the gate states of the queues containing the first flow, the second flow, and the third flow are all simultaneously open, and configurations where the gate state of the queue containing the second flow is "open" and the gate state of the queue containing the third flow is "closed". Furthermore, the gate state of the queue containing the first flow is "closed" during the stop time slot of the first flow, meaning that scheduling of first-flow packets to the outgoing interface is stopped during the stop time slot.

[0109] The beneficial effects of this GCL configuration can be seen in the above text. Figure 4 The beneficial effects of the GCL configuration shown will not be elaborated further.

[0110] It should be noted that, by Figure 8 As shown in the GCL configuration, relative to the moment the door of the queue containing the first flow opens, the door of the queue containing the second flow opens with a delay of the first duration, and the door of the queue containing the third flow opens with a delay of the second duration. Since the second duration is longer than the first duration, the door of the queue containing the third flow opens later than the door of the queue containing the second flow. That is, for the second flow that arrives at the packet forwarding node in a timely manner, this embodiment can guarantee that the second flow obtains transmission resources before the third flow. In other words, by controlling the duration of the first and second time periods, the priority of the second and third flows in contending for transmission resources can be controlled.

[0111] based on Figure 8 The GCL configuration shown is for reference. Figure 9 , Figure 9 This document illustrates a flowchart of another message forwarding control method provided in an embodiment of this application. Optionally, this method is applied to the application scenario shown in Figure 3. Taking the message forwarding control device implemented by a message forwarding node as an example, for a communication network (such as a TSN) including message forwarding nodes that forward the first, second, and third flows through the same outgoing interface, where the priority of the second flow is higher than that of the third flow, after executing steps 101 to 103, this method executes... Figure 9 Steps 104 to 105 are shown.

[0112] Step 104: During the second time period, which starts at the first time slot and ends at the third time slot, the message forwarding node stops scheduling messages to be forwarded in the third stream to the outgoing interface of the message forwarding node. The duration of the second time period is less than the duration of the first time slot, and the duration of the second time period is greater than the duration of the first time slot.

[0113] Understandably, if the priority of the second stream is lower than that of the third stream, then the duration of the first time slot will be longer than that of the second time slot.

[0114] In this step, the packet forwarding node closes the "door" of the queue containing the third stream at the first moment through the pre-configured GCL control, thereby stopping the scheduling of packets in the queue to the outgoing interface for forwarding.

[0115] Step 105: Starting from the third moment, the message forwarding node is allowed to schedule messages to be forwarded in the third stream to the above-mentioned outgoing interface.

[0116] In this step, the packet forwarding node opens the "door" of the queue containing the third flow at the third moment through the pre-configured GCL control, thereby enabling the scheduling of packets in the queue to the outgoing interface for forwarding.

[0117] In this scenario, if neither the first nor the second flow has any packets to be forwarded by the third time interval, it indicates that the queues in the packet forwarding nodes used to store packets to be forwarded from the first and second flows are empty by the third time interval. At this point, starting from the third time interval, if the queue used to store packets to be forwarded from the third flow contains packets, the packet forwarding node allows the packet forwarding node to forward the packets in the queue of the third flow scheduled at the outgoing interface. Compared to the "basic principle" applied in the related technologies described above, the method provided in this application embodiment can avoid wasting the sending resources of the outgoing interface during the idle forwarding time slots of the first flow (such as the first time slot), thus improving the statistical reuse rate of the sending resources of the packet forwarding node. Furthermore, for the second flow that arrives at the packet forwarding node in a timely manner, this method can ensure that the second flow obtains sending resources before the third flow. In other words, by controlling the duration of the first and second time intervals, the priority of the second and third flows in competing for sending resources can be controlled.

[0118] Taking the first stream as ST traffic, the second stream as AVB traffic, and the third stream as BE traffic as an example, combined with... Figure 2 The message sending status of the outgoing interface is shown below. Figure 8 The GCL configuration shown is as follows: Figure 10 As shown, Figure 10 This illustrates the packet transmission status of the packet forwarding node's outgoing interface after employing the method described in the embodiments of this application. Combined with... Figure 2 ,like Figure 10 As shown, located Figure 10 During the idle period in the first forwarding slot (slot 1) of the ST traffic, since the queue gates for both AVB and BE traffic are "open," and AVB traffic has a higher priority than BE traffic, the packet forwarding node schedules AVB traffic packets to the outgoing interface during this idle period in slot 1 to avoid wasting time slots. Furthermore, when the packet forwarding node finishes forwarding the AVB traffic packets to be forwarded, and the time remaining between the start of the next forwarding slot (slot 3) of the ST traffic and the start of the slot is sufficient to forward one or more packets to be forwarded from the BE traffic, the packet forwarding node then forwards that single packet from the BE traffic. Later, in slot 3, because the ST traffic arrives late, the "door" of the BE traffic queue opens at the second time interval from the start of slot 3, allowing the packet forwarding node to schedule BE traffic packets to the outgoing interface for reuse. Figure 2 The idle time period in time slot 3 is shown. It can be seen that the method in this application can improve the statistical reuse rate of the outgoing interface.

[0119] After the message forwarding node executes steps 101 to 105, if the first and second flows have no messages to be sent by the third time interval, and the third flow has messages to be forwarded by the third time interval, then the third flow will use the message forwarding node's outgoing interface to forward messages starting from the third time interval. In this case, if the message forwarding node completes the reception of the message to be forwarded in the first flow (denoted as the first message) after the third time interval and before the end of the first time slot, that is, before the end of the first time slot, the queue used to store the messages to be forwarded in the first flow includes the first message to be forwarded. To address this situation, the embodiments of this application can be implemented as described above. Figure 6 The method described guarantees first-class transmission latency.

[0120] In some other embodiments, in conjunction with the application scenario shown in Figure 3, when a certain outgoing interface of the packet forwarding node shown in Figure 3 is used not only to forward the first and second flows, but also to forward a fourth flow requiring bounded latency, in this case, before executing the method provided in the embodiments of this application, the GCL configured for the packet forwarding node based on the time slot orchestration method includes, in addition to, the fourth flow requiring bounded latency. Figure 4In addition to the configuration shown, GCL also instructs that: in the first time slot within each supercycle, scheduling packets to be forwarded in the fourth flow to the outgoing interface is stopped; and in the second time slot starting at the fourth time, scheduling packets to be forwarded in the fourth flow to the outgoing interface is allowed, while scheduling packets to be forwarded in the first flow to the outgoing interface is stopped in the second time slot. Furthermore, in the third time period starting at the fourth time and ending at the fifth time, scheduling packets to be forwarded in the second flow to the aforementioned outgoing interface is stopped. The duration of the third time period (denoted as the third duration) is shorter than the duration of the second time slot. That is, as... Figure 11a As shown, within one supercycle, the gate state of the queue containing the first flow is "open" in the first time slot and "closed" in the second time slot. The gate state of the queue containing the fourth flow is "closed" in the first time slot and "open" in the second time slot. This satisfies the "basic principle" mentioned above, that at any given time, only the queue containing traffic with bounded latency has its gate state "open," thus ensuring the deterministic latency of the first and fourth flows. Furthermore, the gate state of the queue containing the second flow is "closed" in the first and third time slots, and "open" for the remaining time slots within one supercycle, excluding the first and third time slots. That is, the GCL configured for the packet forwarding node in this embodiment includes a configuration where the gate states of the queue containing the fourth flow and the queue containing the second flow are simultaneously "open." Figure 11a The beneficial effects of the GCL configuration shown above can be seen in the text above. Figure 4 The beneficial effects of the GCL configuration shown will not be elaborated further.

[0121] Combination Figure 11a ,like Figure 11b As shown, the gate state of the queue containing the third flow is "closed" during the second and fourth time periods, and "open" for the remaining time periods excluding the second and fourth time periods within a supercycle. Furthermore, for the first and second time periods starting at the same time, the second time period ends later than the first time period; and for the third and fourth time periods starting at the same time, the fourth time period ends later than the third time period. That is, the GCL configured for the packet forwarding node in this embodiment includes configurations where the gate states of the queue containing the fourth flow, the queue containing the second flow, and the queue containing the third flow are all simultaneously "open," and configurations where the gate state of the queue containing the third flow is "closed" when the gate state of the queue containing the second flow is "open." Figure 11b The beneficial effects of the GCL configuration shown above can be seen in the text above. Figure 8 The beneficial effects of the GCL configuration shown will not be elaborated further.

[0122] based on Figure 11a The GCL configuration shown is for reference. Figure 12 , Figure 12This diagram illustrates a flowchart of another message forwarding control method provided in an embodiment of this application. Optionally, this method is applied to the application scenario shown in Figure 3. Taking the message forwarding control device implemented by a message forwarding node as an example, for a message forwarding node in a communication network (such as a TSN) that forwards the first, second, and fourth flows through the same outgoing interface, after executing steps 101 to 103, this method executes... Figure 12 Steps 106 to 108 are shown.

[0123] Step 106: The packet forwarding node stops scheduling packets to be forwarded in the fourth flow to the outgoing interface in the first time slot, and allows scheduling packets to be forwarded in the fourth flow to the outgoing interface in the second time slot starting from the fourth time slot, and stops scheduling packets to be forwarded in the first flow to the outgoing interface in the second time slot.

[0124] The second time slot is a time slot pre-arranged for the fourth stream to transmit messages in the fourth stream.

[0125] In one example, when the time-bounded packet flow for forwarding through the aforementioned outgoing interface only includes the first and second flows, the fourth time slot is the end time of the first time slot, i.e., the first and second time slots are as follows: Figure 11a The adjacent time periods are shown.

[0126] In another example, when the time-bounded packet flow forwarded by the aforementioned outgoing interface includes not only the first and second flows but also other time-bounded packet flows, such as the fifth flow, then the fourth time slot can be the end time of the first time slot. In this case, the first and second time slots are as follows: Figure 11a The adjacent time periods are shown. Of course, the fourth time point may not be the end time of the first time slot. In this case, there is a forwarding time slot for the fifth stream between the first and second time slots, and the first and second time slots are the stop time slots for the fifth stream.

[0127] Step 107: During the third time period, which starts at the fourth time and ends at the fifth time, the message forwarding node stops scheduling messages to be forwarded in the second stream to the above-mentioned outgoing interface. The duration of the third time period is less than the duration of the second time slot.

[0128] In this step, the packet forwarding node closes the "gate" of the queue containing the second stream at the fourth moment through the pre-configured GCL control, thereby stopping the scheduling of packets in the queue to the outgoing interface for forwarding.

[0129] The duration of the third time period can be equal to or unequal to the duration of the first time period mentioned above; there is no limitation on this.

[0130] Step 108: Starting from the fifth moment, the message forwarding node is allowed to schedule messages to be forwarded in the second stream to the above-mentioned outgoing interface.

[0131] In this step, the packet forwarding node opens the "door" of the queue containing the second stream at the fifth moment through the pre-configured GCL control, thereby enabling the scheduling of packets in the queue to the outgoing interface for forwarding.

[0132] In this case, if there are no packets to be forwarded in the fourth flow by the fifth time slot, meaning the queue for storing packets to be forwarded in the fourth flow is empty by the fifth time slot, it indicates that the packets of the fourth flow have not arrived at the message forwarding node on time, and therefore the second time slot is temporarily idle. In this situation, starting from the fifth time slot, if the queue for storing packets to be forwarded in the second flow contains packets, the message forwarding node is allowed to schedule packets from the queue containing the second flow to the outgoing interface and forward them. Compared to the "basic principle" applied in the related technologies described above, the method provided in this application embodiment can avoid wasting the sending resources of the outgoing interface in the idle forwarding time slots of the fourth flow (such as the second time slot), thus improving the statistical reuse rate of the sending resources of the message forwarding node.

[0133] Understandably, in Figure 12 In the method described, if the outgoing interface of the packet forwarding node used for forwarding the first, second, and fourth flows is also used for forwarding the third flow, then the packet forwarding node can combine... Figure 12 and Figure 9 The method described above indicates the priority of the second and third flows by setting different stop time slots (such as the first time slot and the third time slot corresponding to the second flow, and the second time slot corresponding to the third flow) to ensure that high-priority traffic gets transmission resources before low-priority traffic.

[0134] It's understandable, as stated above. Figure 4 , Figure 8 And Figure 11 (including) Figure 11a and Figure 11b The GCL configuration shown can be used as a control policy, pre-determined by the controller / device / equipment of the communication network (such as TSN), and sent to the relevant packet forwarding nodes in the TSN. In response, the packet forwarding nodes receive the control policy and, according to the instructions of the control policy, schedule packets to be forwarded in different flows to the outgoing interface in different time slots, for example, by executing the methods described in the above embodiments based on the control policy.

[0135] To enhance understanding of the methods described in the embodiments of this application, further explanation is provided below with specific examples.

[0136] Taking the communication network TSN as an example, refer to Figure 13The network topology of TSN 1300 is as follows: Figure 13 As shown, the TSN1300 has a link bandwidth of 100 megabits per second (Mbps) and a transmission latency of 1 μs. Figure 13 As shown, TSN 1300 includes three service sources: source node 1, source node 2, and source node 3. Flow 1 from source node 1 is ST traffic with bounded latency requirements, flow 2 from source node 2 is AVB traffic without bounded latency requirements, and flow 3 from source node 3 is BE traffic without bounded latency requirements. AVB traffic has a higher priority than BE traffic.

[0137] Table 1 shows the traffic types, packet sizes, and packet transmission intervals for Flow 1, Flow 2, and Flow 3. The packet transmission intervals include the packet transmission intervals used to configure the GCL and the actual packet transmission intervals at the source. Specifically, the packet transmission intervals used to configure the GCL are the same as those used to configure the forwarding and stop slots in the GCL, while the actual packet transmission intervals at the source are the intervals set to simulate situations where packets fail to arrive at the packet forwarding node within the specified time.

[0138] Table 1

[0139]

[0140] In this case, the GCL configuration pre-determined for TSN 1300 for flows 1, 2, and 3 in this embodiment is a timeout duration of 200μs. Of this, 100μs is used as the forwarding time slot for ST traffic, and the remaining time slots are shared by AVB and BE traffic, i.e., the stop time slots for ST traffic. Thus, if... Figure 14 As shown, Figure 14 (a) shows the GCL configuration based on related technologies: the gate state of the queue containing ST traffic is "off" for the first 100 μs of the 200 μs time period and "on" for the last 100 μs of the 200 μs time period; and the gate states of the queue containing AVB traffic and the queue containing BE traffic are "on" for the first 100 μs of the 200 μs time period and "off" for the last 100 μs of the 200 μs time period. Figure 14(b) shows the GCL configuration based on the scheme of this application: the gate state of the queue containing ST traffic is "off" for the first 100μs of the 200μs supercycle period and "on" for the last 100μs of the 200μs supercycle period; the gate state of the queue containing AVB traffic is "off" for the first T1 period of the last 100μs of the 200μs supercycle period and "on" for the rest of the 200μs supercycle period; and the gate state of the queue containing BE traffic is "off" for the first T2 period of the last 100μs of the 200μs supercycle period and "on" for the rest of the 200μs supercycle period, and the duration of T2 is longer than the duration of T1.

[0141] based on Figure 14 Table 2 shows the results after a simulation experiment lasting 10 milliseconds (ms) using the GCL configuration described above. Figure 14 The table shows the outgoing interface utilization rate after configuring the GCL based on related technologies and the scheme of this application embodiment. When the simulated packet forwarding node performs packet forwarding based on the GCL configured in this application embodiment, no frame preemption module is configured. As can be seen from Table 2, compared with related technologies, using the scheme described in this application embodiment, and without enabling frame preemption, the utilization rate of the outgoing interfaces used for forwarding flows 1 to 3 increases from 68.3% to 92.7%.

[0142] Table 2

[0143] plan Outgoing interface utilization Related technologies 68.3% This application 92.7%

[0144] in addition, Figure 15 It shows the use of Figure 14 The utilization of the GCL back-out interface configured based on related technologies and the embodiments of this application, such as... Figure 15 As shown, compared with the GCL configured based on related technologies, when the outgoing interface of the packet forwarding node performs packet scheduling control based on the GCL configured in this application embodiment, the idle part in the forwarding time slot of ST traffic is contended by AVB traffic and BE traffic. That is, when the outgoing interface of the forwarding node controls packet scheduling based on the GCL configured in this application embodiment, it has a higher statistical reuse rate.

[0145] In addition, Table 3 shows the usage Figure 14 The end-to-end delay statistics of flows 1 to 3 are statistically analyzed after configuring the GCL based on related technologies and the scheme of the embodiments of this application. As can be seen from Table 3, compared with related technologies, after adopting the scheme provided by the embodiments of this application, the end-to-end average delay, end-to-end delay standard deviation, and delay jitter of flows 2 and 3 are optimized while ensuring the stability of the bounded delay of flow 1.

[0146] Table 3

[0147]

[0148] The above mainly describes the solution provided by the embodiments of this application from a methodological perspective.

[0149] To achieve the above functions, refer to Figure 16 , Figure 16 This diagram illustrates the structure of a message forwarding control device according to an embodiment of this application. The message forwarding control device 1600 is applied in a communication network to a message forwarding node that forwards first and second streams of messages through the same outgoing interface, and is used to execute the message forwarding control method described above, for example, to execute... Figure 5 , Figure 6 , Figure 9 or Figure 12 The method shown. The message forwarding control device 1600 may include a first control unit 1601.

[0150] The first control unit 1601 is configured to: allow the scheduling of packets to be forwarded in the first flow to the outgoing interface in a first time slot starting at a first time point; stop scheduling packets to be forwarded in the second flow to the outgoing interface in a first time period starting at the first time point and ending at a second time point; and allow the scheduling of packets in the second flow to the outgoing interface starting at the second time point. The first time slot is used for forwarding packets in the first flow, and the duration of the first time period is shorter than the duration of the first time slot.

[0151] As an example, combined Figure 5 The first control unit 1601 can be used to execute steps 101 to 103.

[0152] Optionally, the first flow requires a transmission delay within a defined range, the second flow does not require a transmission delay within a defined range, and the outgoing interface is also used to forward a third flow, which does not require a transmission delay within a defined range, and the priority of forwarding the third flow by the outgoing interface is lower than the priority of forwarding the second flow. The first control unit 1601 is further configured to: during a second time period starting at a first time and ending at a third time, stop scheduling packets to be forwarded in the third flow to the outgoing interface; and allow scheduling packets to be forwarded in the third flow to the outgoing interface starting at the third time. The duration of the second time period is shorter than the duration of the first time slot, and the duration of the second time period is longer than the duration of the first time period.

[0153] As an example, combined Figure 9 The first control unit 1601 can be used to execute steps 104 to 105.

[0154] Optionally, after allowing the scheduling of the second stream of messages to the outgoing interface to begin from the second moment, the message forwarding control device 1600 further includes: a second control unit 1602, which, during the process of forwarding the second message in the second stream at the outgoing interface, if the first message of the first stream is received, controls the outgoing interface to suspend forwarding the second message and controls the outgoing interface to forward the first message.

[0155] As an example, combined Figure 6 The second control unit 1602 can be used to perform step 201.

[0156] Optionally, the second control unit 1602 is further configured to: control the outgoing interface to send the unsent portion of the second message when there are no messages to be forwarded in the first stream after the outgoing interface has completed sending the first message.

[0157] As an example, combined Figure 6 The second control unit 1602 can be used to perform step 202.

[0158] Optionally, the outgoing interface is also used to forward a fourth stream, which requires a transmission delay within a defined range. The first control unit 1601 is further configured to: stop scheduling packets to be forwarded in the fourth stream to the outgoing interface in the first time slot; and in the second time slot, which begins at the fourth time slot, allow scheduling packets to be forwarded in the fourth stream to the outgoing interface, and stop scheduling packets to be forwarded in the first stream to the outgoing interface. The second time slot is used for forwarding packets in the fourth stream.

[0159] As an example, combined Figure 12 The first control unit 1601 can be used to execute step 106.

[0160] Optionally, the first control unit 1601 is further configured to: stop scheduling packets to be forwarded in the second stream to the outgoing interface during the third time period, which starts at the fourth time and ends at the fifth time; and allow scheduling packets to be forwarded in the second stream to the outgoing interface starting from the fifth time. The duration of the third time period is shorter than the duration of the second time slot.

[0161] As an example, combined Figure 12 The first control unit 1601 can be used to execute steps 107 to 108.

[0162] Optionally, the first stream is ST traffic and the second stream is AVB traffic.

[0163] Optionally, the third stream is BE flow.

[0164] Alternatively, the communication network is a TSN network.

[0165] For a detailed description of the above-mentioned optional methods, please refer to the foregoing method embodiments, which will not be repeated here. Furthermore, the explanation of any of the message forwarding control devices 1600 provided above, as well as the description of their beneficial effects, can be found in the corresponding method embodiments described above, and will not be repeated here.

[0166] This application embodiment also provides a message forwarding control device. The message forwarding control device is applied to a message forwarding node in a communication network that forwards a first stream and a second stream through the same outgoing interface. The message forwarding node is configured with a Gateway Classifier (GCL). The GCL is used to indicate time slots that allow scheduling of the first and second streams of messages to the aforementioned outgoing interface, and to indicate time slots that stop scheduling the first and second streams of messages to the outgoing interface. The GCL includes a configuration where the gate states of the sending queue containing the first stream and the sending queue containing the second stream are both open. The message forwarding control device is used to execute, based on the GCL, the control method described above for scheduling messages from the first stream and / or the second stream to the outgoing interface.

[0167] Optionally, the first flow requires a defined range of transmission delay, while the second flow does not. The aforementioned outgoing interface is also used to forward a third flow, which does not require a defined range of transmission delay, and the priority of forwarding the third flow by the outgoing interface is lower than that of forwarding the second flow. The GCL is also used to indicate the time slots for scheduling packets of the third flow to the outgoing interface, and to indicate the time slots for stopping scheduling packets of the third flow to the outgoing interface. Furthermore, the GCL includes a configuration where the gate state of the sending queue containing the first flow, the gate state of the sending queue containing the second flow, and the gate state of the sending queue containing the third flow are all open, and a configuration where the gate state of the sending queue containing the third flow is closed when the gate state of the sending queue containing the second flow is open.

[0168] Those skilled in the art will readily recognize that, based on the units and algorithm steps described in conjunction with the embodiments disclosed herein, this application can be implemented in hardware or a combination of hardware and computer software. Whether a function is implemented in hardware or by computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0169] It should be noted that, Figure 16 The module / unit division shown is illustrative and represents only one logical functional division; in actual implementation, other division methods are possible. For example, two or more functions can be integrated into a single processing module. The functions implemented by the integrated modules described above can be implemented either in hardware or as software functional modules.

[0170] This application provides a message forwarding node that implements some or all of the functions of the method provided in this application. For example, the message forwarding node is equipped with the message forwarding control device described above and is used to execute some or all of the functions of the method provided in this application.

[0171] refer to Figure 17 , Figure 17 This is a schematic diagram of the structure of a message forwarding node provided in an embodiment of this application. For example... Figure 17 As shown, the message forwarding node 1700 includes a processor 1701, a memory 1702, a network interface 1703, and a bus 1704. The processor 1701, memory 1702, and network interface 1703 are interconnected via the bus 1704. The message forwarding node 1700 also includes an input / output interface 1705, which is interconnected with the processor 1701, memory 1702, and network interface 1703 via the bus 1704.

[0172] Processor 1701 may include a general-purpose processor and / or a dedicated hardware chip. A general-purpose processor may include a central processing unit (CPU), a microprocessor, or a graphics processing unit (GPU). The CPU may be, for example, a single-core processor or a multi-core processor. A dedicated hardware chip is a high-performance processing hardware module. Dedicated hardware chips include at least one of the following: digital signal processing (DSP), data processing unit (DPU), application-specific integrated circuit (ASIC), field-programmable gate array (FPGA), other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, neural processing unit (NPU), tensor processing unit (TPU), artificial intelligence chip, or network processor (NP). Processor 1701 may also be an integrated circuit chip with signal processing capabilities. In the implementation process, some or all of the functions of the method provided in the embodiments of this application can be accomplished by the integrated logic circuit of the hardware in the processor 1701 or by instructions in the form of software.

[0173] Memory 1702 is used to store computer programs, including operating system 1702a and executable code (i.e., program instructions) 1702b. Memory 1702 is, for example, read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), flash memory, or other types of static storage devices capable of storing static information and instructions; it is also such as static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), and synchronous linked dynamic random access memory (SDRAM). DRAM (SLDRAM) or other types of dynamic storage devices capable of storing information and instructions, such as read-only optical discs or other optical disc storage, optical disc storage (including compressed optical discs, laser discs, optical discs, digital universal optical discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium capable of carrying or storing desired executable code in the form of instructions or data structures and accessible by a computer, but not limited thereto. For example, memory 1702 is used to store GCL, etc. Memory 1702 may exist independently and be connected to processor 1701 via bus 1704. Alternatively, memory 1702 and processor 1701 may be integrated together. Memory 1702 can store executable code. When the executable code stored in memory 1702 is executed by processor 1701, processor 1701 performs some or all of the functions of the method provided in the embodiments of this application. Please refer to the relevant descriptions in the foregoing embodiments for the implementation of the processor 1701 executing this process. Memory 1702 may also include software modules and data required by other running processes, such as operating systems.

[0174] Network interface 1703 uses transceiver modules, such as, but not limited to, transceivers, to enable communication with other devices or communication networks. For example, network interface 1703 can be any one or any combination of the following devices: network interfaces (such as Ethernet interfaces), wireless network cards, and other devices with network access capabilities. Network interface 1703 includes a receiving unit for receiving data / messages and a sending unit for sending data / messages.

[0175] Bus 1704 can be any type of communication bus used to interconnect internal devices (e.g., memory 1702, processor 1701, network interface 1703) of message forwarding node 1700. For example, a system bus. This embodiment illustrates the interconnection of the aforementioned devices within message forwarding node 1700 via bus 1704. Optionally, the aforementioned devices within message forwarding node 1700 can also communicate with each other using other connection methods besides bus 1704; for example, the aforementioned devices within message forwarding node 1700 can be interconnected via internal logic interfaces.

[0176] Input / output interface 1705 is used to realize human-computer interaction between the user and message forwarding node 1700. For example, it enables text or voice interaction between the user and message forwarding node 1700. Input / output interface 1705 includes an input interface for the user to input information to message forwarding node 1700, and an output interface for message forwarding node 1700 to output information to the user. As an example, the input interface includes, but is not limited to, a touchscreen, keyboard, mouse, or microphone, and the output interface includes, but is not limited to, a display screen, speaker, etc. The touchscreen, keyboard, or mouse is used to input text / image information, the microphone is used to input voice information, the display screen is used to output text / image information, and the speaker is used to output voice information.

[0177] As an example, message forwarding node 1700 can receive user-inputted GCLs through the input interface in input / output interface 1705.

[0178] It should be noted that the aforementioned devices can be disposed on separate chips, or at least partially or entirely on the same chip. Whether to dispose of the devices independently on different chips or integrate them on one or more chips often depends on the needs of the product design. This application does not limit the specific implementation of the aforementioned devices. Furthermore, the descriptions of the processes corresponding to the various figures above each have their own emphasis; for parts of a process not described in detail in one figure, please refer to the relevant descriptions of other processes.

[0179] In the above embodiments, implementation can be achieved, in whole or in part, through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented, in whole or in part, as a computer program product. The computer program product providing the program development platform includes one or more computer instructions. When these computer program instructions are loaded and executed on the message forwarding node 1700, they implement, in whole or in part, some or all of the functions of the methods provided in the embodiments of this application.

[0180] Furthermore, computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, computer instructions can be transmitted from one website, computer, server, or data center to another via wired (e.g., coaxial cable, fiber optic, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium stores computer program instructions that provide a program development platform.

[0181] As an example, combined Figure 16 The functions implemented by the first control unit 1601 and the second control unit 1602 in the message forwarding control device 1600 can be achieved through... Figure 17 Processor 1701 in the middle executes Figure 17 The program code is implemented in memory 1702.

[0182] This application also provides a computer-readable storage medium, which is a non-volatile computer-readable storage medium. The computer-readable storage medium includes computer program instructions. When the computer program instructions are executed by a processor, a computing device including the processor, or a computer system, the processor, the computing device including the processor, or the computer system performs the message forwarding control method provided in this application.

[0183] This application also provides a computer program product containing instructions that, when executed by a processor, a computing device including a processor, or a computer system, cause the processor, the computing device including a processor, or the computer system to implement the message forwarding control method provided in this application.

[0184] A computer system is a system with computational processing capabilities. A computer system generally includes a processor and memory. The processor retrieves and executes instructions stored in memory to enable the computer system to implement the message forwarding control method described above. Optionally, a computer system may also include at least one of an input interface or an output interface. The processor, memory, input interface, and output interface of the computer system are interconnected through internal connection paths.

[0185] Those skilled in the art will understand that all or part of the steps of the above embodiments can be implemented by hardware, or by a program instructing the relevant hardware to implement them. The program can be stored in a computer-readable storage medium, such as a read-only memory, a disk, or an optical disk.

[0186] It should be noted that the information (including but not limited to user device information, user personal information, etc.), data (including but not limited to data used for analysis, data stored, data displayed, etc.) and signals involved in this application are all authorized by the user or fully authorized by all parties, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions.

[0187] This application also provides a chip that includes a processor for running program instructions or code. The chip or a device containing the chip can be used to execute the message forwarding control method provided in this application. Exemplarily, the chip further includes an input interface, an output interface, and a memory. The chip's input interface, output interface, processor, and memory are connected via internal interconnection paths. The memory in the chip stores program instructions or code executed by the processor, and the input and output interfaces are used for communication between the chip and other chips or devices.

[0188] In the embodiments of this application, the terms "first," "second," and "third" are used for descriptive purposes only and should not be construed as indicating or implying relative importance. The term "at least one" refers to one or more, and the term "multiple" refers to at least two, unless otherwise expressly defined.

[0189] In this application, the term "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. Additionally, the character " / " in this document generally indicates that the preceding and following related objects have an "or" relationship.

[0190] It should be understood that the terminology used in the description of the various examples herein is for the purpose of describing particular examples only and is not intended to be limiting. As used in the description of the various examples and the appended claims, the singular forms “a” and “the” are intended to include the plural forms as well, unless the context clearly indicates otherwise.

[0191] It should be understood that determining B based on A does not mean determining B solely based on A; B can also be determined based on A and / or other information.

[0192] It should be understood that the term "comprising" (also referred to as "includes", "including", "comprises" and / or "comprising") as used in this specification specifies the presence of the stated features, integers, steps, operations, elements, and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and / or groups thereof.

[0193] It should also be understood that, in the various embodiments of this application, the sequence number of each process does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.

[0194] The above description is merely an optional embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc., made within the concept and principles of this application should be included within the protection scope of this application.

[0195] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the protection scope of the technical solutions of the embodiments of the present invention.

Claims

1. A control method of packet forwarding, characterized by, A message forwarding node for forwarding messages of a first flow and a second flow through a same outgoing interface in a communication network, the method comprising: allowing, in a first time slot starting at a first time, scheduling of messages to be forwarded of the first flow to the outgoing interface, the first time slot being a time slot for forwarding messages of the first flow; stopping, in a first time period starting at the first time and ending at a second time, scheduling of messages to be forwarded of the second flow to the outgoing interface, the first time period having a length smaller than a length of the first time slot; allowing, starting from the second time, scheduling of messages of the second flow to the outgoing interface.

2. The method of claim 1, wherein, The first flow requires a transmission delay having a determined range, the second flow does not require a transmission delay having a determined range, the outgoing interface is further used for forwarding a third flow, the third flow does not require a transmission delay having a determined range, and a priority of forwarding the third flow by the outgoing interface is lower than a priority of forwarding the second flow; the method further comprises: stopping, in a second time period starting at the first time and ending at a third time, scheduling of messages to be forwarded of the third flow to the outgoing interface, the second time period having a length smaller than the length of the first time slot and a length greater than the length of the first time period; allowing, starting from the third time, scheduling of messages to be forwarded of the third flow to the outgoing interface.

3. The method according to claim 1 or 2, characterized in that, After the allowing, starting from the second time, scheduling of messages of the second flow to the outgoing interface, the method further comprises: in a process of forwarding a second message of the second flow by the outgoing interface, if a first message of the first flow is received, controlling the outgoing interface to suspend forwarding of the second message and controlling the outgoing interface to forward the first message.

4. The method of claim 3, wherein, The method further comprises: in a case where there is no message to be forwarded of the first flow after the outgoing interface completes sending of the first message, controlling the outgoing interface to send a part of the second message which has not been sent.

5. The method according to any one of claims 1 to 4, characterized in that, The outgoing interface is further used for forwarding a fourth flow, the fourth flow requiring a transmission delay having a determined range; the method further comprises: stopping, in the first time slot, scheduling of messages to be forwarded of the fourth flow to the outgoing interface; allowing, in a second time slot starting at a fourth time, scheduling of messages to be forwarded of the fourth flow to the outgoing interface and stopping scheduling of messages to be forwarded of the first flow to the outgoing interface, the second time slot being a time slot for forwarding messages of the fourth flow.

6. The method of claim 5, wherein, The method further comprises: stopping, in a third time period starting at the fourth time and ending at a fifth time, scheduling of messages to be forwarded of the second flow to the outgoing interface, the third time period having a length smaller than a length of the second time slot; allowing, starting from the fifth time, scheduling of messages to be forwarded of the second flow to the outgoing interface.

7. The method according to any one of claims 1 to 6, characterized in that, The first flow is scheduling traffic, and the second flow is audio video bridging traffic.

8. The method of claim 2, wherein, The third flow is best effort traffic.

9. The method according to any one of claims 1 to 8, characterized in that, The communication network is a time-sensitive network.

10. A control device for packet forwarding, characterized by, An apparatus for forwarding packets in a communication network that forwards the first and second streams of data through the same outgoing interface; the apparatus includes: A first control unit is configured to, in a first time slot starting at a first time point, allow scheduling of packets to be forwarded in the first stream to the outgoing interface, wherein the first time slot is a time slot used for forwarding packets in the first stream; stop scheduling of packets to be forwarded in the second stream to the outgoing interface in a first period starting at the first time point and ending at a second time point, wherein the duration of the first period is less than the duration of the first time slot; and allow scheduling of packets in the second stream to the outgoing interface starting at the second time point.

11. The apparatus of claim 10, wherein, The first stream requires a transmission delay within a defined range, the second stream does not require a transmission delay within a defined range, and the outgoing interface is also used to forward a third stream, which does not require a transmission delay within a defined range, and the outgoing interface has a lower priority for forwarding the third stream than for forwarding the second stream. The first control unit is also used for: During the second time period, which starts at the first time point and ends at the third time point, the scheduling of packets to be forwarded in the third stream to the outgoing interface is stopped. The duration of the second time period is less than the duration of the first time slot, and the duration of the second time period is greater than the duration of the first time period. Starting from the third moment, it is permitted to schedule packets to be forwarded in the third stream to the outgoing interface.

12. The apparatus of claim 10 or 11, wherein, After the message that allows scheduling of the second stream to the outgoing interface to begin from the second time point, the device further includes: The second control unit is configured to, during the process of forwarding the second message in the second stream at the outgoing interface, if a first message in the first stream is received, control the outgoing interface to pause forwarding the second message and control the outgoing interface to forward the first message.

13. The apparatus of claim 12, wherein, The second control unit is also used for: If there are no packets to be forwarded in the first stream after the first packet has been sent at the outgoing interface, the outgoing interface is controlled to send the unsent portion of the second packet.

14. The apparatus of any one of claims 10-13, wherein, The output interface is also used to forward a fourth stream, which requires a transmission delay within a defined range; the first control unit is also used to: Stop scheduling packets to be forwarded in the fourth stream to the outgoing interface during the first time slot; In the second time slot starting at the fourth time point, it is permitted to schedule packets to be forwarded in the fourth stream to the outgoing interface, and scheduling packets to be forwarded in the first stream to the outgoing interface is stopped. The second time slot is used to forward packets in the fourth stream.

15. The apparatus of claim 14, wherein, The first control unit is also used for: During the third time period, which begins at the fourth time point and ends at the fifth time point, the scheduling of packets to be forwarded in the second stream to the outgoing interface is stopped. The duration of the third time period is less than the duration of the second time slot. Starting from the fifth moment, it is permitted to schedule packets to be forwarded in the second stream to the outgoing interface.

16. The apparatus of any one of claims 10 to 15, wherein, The first flow is scheduling traffic, and the second flow is audio-video bridging traffic.

17. The apparatus of claim 11, wherein, The third flow is the best effort flow.

18. The apparatus of any one of claims 10-17, wherein, The communication network is a time-sensitive network.

19. A control device for packet forwarding, characterized by, The apparatus is applied to a packet forwarding node in a communication network that forwards a first stream and a second stream through the same outgoing interface. The packet forwarding node is configured with a gate control list, which indicates time slots that allow scheduling of packets from the first stream and the second stream to the outgoing interface, and time slots that stop scheduling packets from the first stream and the second stream to the outgoing interface. The gate control list includes a configuration where the gate state of the sending queue containing the first stream and the gate state of the sending queue containing the second stream are both open. The apparatus is used to execute, based on the gate control list, the control method described in any one of claims 1 to 9, to schedule packets from the first stream and / or the second stream to the outgoing interface.

20. The apparatus of claim 19, wherein, The first stream requires a transmission delay within a defined range, the second stream does not require a transmission delay within a defined range, and the outgoing interface is also used to forward a third stream, which does not require a transmission delay within a defined range, and the outgoing interface has a lower priority for forwarding the third stream than for forwarding the second stream. The gating list is also used to indicate time slots that allow scheduling of packets of the third stream to the outgoing interface, and to indicate time slots that stop scheduling of packets of the third stream to the outgoing interface. The gating list includes a configuration in which the gate state of the sending queue of the first stream, the gate state of the sending queue of the second stream, and the gate state of the sending queue of the third stream are all open, and a configuration in which the gate state of the sending queue of the third stream is closed when the gate state of the sending queue of the second stream is open.

21. A control device for packet forwarding, characterized by, include: The device includes a memory, a network interface, and one or more processors, the one or more processors receiving or transmitting data through the network interface, the one or more processors being configured to read program instructions stored in the memory to perform the method as described in any one of claims 1 to 9.

22. A computer program product comprising instructions, characterized in that, When the instructions are executed by the processor, the processor or a device including the processor performs the method as described in any one of claims 1 to 9.

23. A computer-readable storage medium, characterized in that, It includes computer program instructions, which, when executed by a processor, cause the processor or a device including the processor to perform the method as described in any one of claims 1 to 9.