A scheduling system and method for a time-sensitive service cache queue
By adopting the structure of the first-level cache queue and the second-level cache queue in the time-sensitive service cache queue scheduling system, combining the time slot negotiation and frame preemption mechanism, the problem of TT flow queue resource exclusiveness and gate control complexity is solved, and efficient Bandwidth utilization and low-cost transmission real-time.
Patent Information
- Application Number
- CN202211581874.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-09
- Publication Date
- 2024-12-20
- Estimated Expiration
- 2042-12-09
AI Technical Summary
The exclusive use of TT flow queue resources for time-sensitive services in the prior art leads to waste of gated resources and control complexity, and the gated negotiation mechanism is too complex and the deployment cost is high.
The scheduling system adopts the first-level cache queue and the second-level cache queue, binds each TT stream queue and transmission time slot through the time slot negotiation mechanism, and independently schedules the TT stream and non-TT stream queues using a static gating list and a differential service scheduler. , combined with the frame preemption mechanism, the message of the TT stream queue is sent first.
It realizes efficient independent scheduling of TT stream queues, avoids resource waste, simplifies the gated negotiation mechanism, reduces deployment costs, and improves bandwidth utilization and transmission real-time.
Smart Images

Figure CN115883483B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of communication technology, and in particular to a scheduling system and method for a time-sensitive service cache queue. Background Art
[0002] With the widespread application of communication technology, the demand for time-sensitive services such as industrial automation control and autonomous driving is increasing. Since the establishment of the IEEE TSN working group in 2012, a series of protocol clusters have been released to expand the Ethernet specification in terms of time synchronization, resource management, delay control, and security management to meet the requirements of time-sensitive services for transmission delay and jitter. Among them, the gating mechanism defined by 802.1qbv divides the cache queue of the Ethernet port into a time-triggered (TT) flow queue and a non-TT flow queue, and configures a gating list on the Ethernet port to control the queue to periodically open and close the sending function of the TT flow queue, thereby realizing deterministic scheduling of the TT flow queue in the device. When a TT flow service is transmitted through the network, each device on the transmission path needs to cache the TT flow queue and set a suitable gating list to accurately control the gate opening time of each TT flow queue to achieve low-latency and low-jitter transmission of the service on each device. In addition, in traditional Ethernet, if a low-priority message (for example, a non-TT flow queue) is being transmitted, a high-priority message (for example, a TT flow queue) needs to wait for the low-priority message to be transmitted before it can start transmitting. On a low-speed interface, this will cause large jitter. The frame preemption mechanism specified by 802.1qbu allows the TT flow queue to preempt the channel being used by the non-TT flow queue, reducing the transmission jitter of the TT flow queue.
[0003] However, there are still some problems with the existing solutions: On the one hand, the traditional solution requires that when the gate of the TT flow queue is opened, the TT service monopolizes the interface bandwidth resources, and in order to solve the problem of burst traffic before the gate is closed, a certain amount of bandwidth resources are usually reserved for each gate, which leads to a waste of bandwidth resources. On the other hand, the traditional solution calculates the gating list of each node in the transmission path for each flow. When a device has many TT flows with different requirements, it is necessary to comprehensively calculate the requirements of all flows to form a gating list that meets all business requirements, resulting in the gating list being difficult to obtain a suitable solution, and the gating list is also too complicated. This work usually requires centralized server calculation, and the deployment cost is high.
[0004] In view of this, how to overcome the defects of the existing technology and solve the problem of gating resource waste and complex control caused by the existing TT flow queue resource monopoly is a problem to be solved in the field of this technology. Summary of the invention
[0005] In view of the above defects or improvement requirements of the prior art, the present invention solves the problem of TT service resource monopoly in the existing scheduling scheme.
[0006] The embodiment of the present invention adopts the following technical solution:
[0007] In a first aspect, the present invention provides a scheduling system for a time-sensitive service cache queue, specifically comprising: a first-level cache queue, a first-level scheduler, a second-level cache queue and a MAC, specifically: the first-level cache queue includes at least two first-level TT flow queues and at least one first-level non-TT flow queue, each first-level TT flow queue is bound to a transmission time slot; the first-level scheduler includes a deterministic delay scheduler and at least one differential service scheduler, the deterministic delay scheduler includes a static gating list, the static gating list schedules the first-level TT flow queue according to a time slot negotiation mechanism, and the differential service scheduler controls the transmission rate of the first-level non-TT flow queue according to the flow control information of the second-level non-TT flow queue; the second-level cache queue includes a second-level TT flow queue and a second-level non-TT flow queue, the second-level TT flow queue and the second-level non-TT flow queue cache messages received from the first-level TT flow queue and the first-level non-TT flow queue respectively, and when the second-level TT flow queue is not empty, the second-level TT flow queue initiates a message transmission request to the MAC; the MAC is a MAC with a frame preemption function, and the messages in the second-level TT flow queue are preferentially sent based on the frame preemption mechanism of the MAC.
[0008] Preferably, each first-level TT flow queue is bound to a transmission time slot, specifically including: measuring the transmission delay between adjacent devices according to the time slot information transmitted by the time slot negotiation message, calculating the transmission time slot of the message in the device according to the transmission delay and the transmission time slot of the upstream node, and each service corresponds to a transmission time slot; the static gating list divides a cycle into several time slots according to the transmission time slot of each service, there is no time interval between the time slots, and each time slot corresponds to a first-level TT flow queue; binding the service corresponding to each time slot to the first-level TT flow queue controlled by the time slot, and the first-level TT flow queue is used to cache the messages of the corresponding service.
[0009] Preferably, the transmission delay between adjacent devices is measured based on the time slot information transmitted by the time slot negotiation message, specifically including: the time slot negotiation message is injected into the packet processing chip through the control plane at the first node of the transmission path in the sending direction, extracted to the control plane through the packet processing chip at the intermediate node and the tail node in the receiving direction, and injected into the packet processing chip again after processing, the time slot negotiation message contains the forwarding information required for forwarding the actual business, as well as the timestamp when the message is injected and the time slot information of the message sent by this station, and the negotiation message length is the maximum message length set for the business.
[0010] Preferably, the differential service scheduler controls the transmission rate of the primary non-TT flow queue according to the flow control information of the secondary non-TT flow queue, and further includes:
[0011] The secondary non-TT flow queue sends flow control information to the differential service scheduler based on the queue length. When the differential service scheduler receives the flow control information sent by the secondary non-TT flow queue, it stops scheduling the messages in the primary non-TT flow queue.
[0012] When the length of the secondary non-TT flow queue decreases below the queue configuration threshold, the secondary non-TT flow queue stops sending flow control information to the differential service scheduler, and the differential service scheduler resumes scheduling the messages in the primary non-TT flow queue.
[0013] Preferably, the MAC-based frame preemption mechanism gives priority to sending messages in the secondary TT flow queue, specifically including: when MAC is transmitting messages in the secondary non-TT flow queue, if the secondary TT flow queue requests to send a message, MAC gives up the channel after transmitting a message with a packet length that is an integer multiple of 64 bytes, and instead schedules the message in the secondary TT flow queue.
[0014] On the other hand, the present invention provides a scheduling method for a time-sensitive service cache queue, specifically: using the scheduling system for the time-sensitive service cache queue provided by the first aspect to schedule the cache queue, specifically including: determining the time slot used by each first-level TT flow queue according to the time slot negotiation mechanism, scheduling the first-level TT flow queue according to the static gating list, and the first-level TT flow queue sending a message to the second-level TT flow queue at the maximum rate of the interface according to the scheduling; scheduling the first-level non-TT flow queue according to the differentiated service model, and terminating the scheduling when the second-level non-TT flow queue is congested; when the second-level TT flow queue is not empty, the second-level TT flow queue initiates a message transmission request to the MAC, and when the second-level TT flow queue is empty, the second-level non-TT flow queue initiates a message transmission request to the MAC, and after obtaining the transmission permission, each queue transmits the message through the mac at the maximum rate of the interface.
[0015] Preferably, for the first node of the transmission path, each first-level TT flow queue is bound to a transmission time slot, specifically including: the control plane constructs a time slot negotiation message for each deterministic delay service, the control plane queries the service configuration, and determines the output interface of the time slot negotiation message; based on the principle of traffic balance, a first-level TT flow queue whose remaining bandwidth meets the demand is selected from all first-level TT flow queues included in the service message output interface as the first-level TT flow queue that carries the current service; the control plane binds the selected first-level TT flow queue to the current service, and sends a configuration to control the service to enter the first-level TT flow queue.
[0016] Preferably, for the first node of the transmission path, the time slot used by each first-level TT flow queue is determined according to the time slot negotiation mechanism, specifically including: the control plane fills the service demand, the transmission time slot allocated by this node and the gating list configuration information into the time slot negotiation message; the control plane injects the time slot negotiation message into the TT flow queue of the packet processing chip, and updates the timestamp of the injected time slot negotiation message; when the transmission time slot of the selected first-level TT flow queue arrives, the service message is scheduled to be forwarded to the second-level TT flow queue of the downstream node.
[0017] Preferably, for the intermediate nodes and tail nodes of the transmission path, the time slot used by each first-level TT flow queue is determined according to the time slot negotiation mechanism, specifically including: the packet processing chip receives the time slot negotiation message, updates the time slot negotiation message reception timestamp, identifies the time slot negotiation message type, and then extracts the time slot negotiation message to the control unit; completes the routing calculation according to the packet header information of the time slot negotiation message, and obtains the time slot negotiation message output interface; calculates the transmission delay, calculates the time slot that meets the requirements according to the information carried by the time slot negotiation message and the gating list configuration of the port, and sends down the relevant configuration to bind the service to the first-level TT flow queue corresponding to the time slot.
[0018] Preferably, for the intermediate nodes and tail nodes of the transmission path, the time slot used by each first-level TT flow queue is determined according to the time slot negotiation mechanism, specifically including: injecting the service message into the first-level TT flow queue bound to the service to wait for scheduling, updating the message injection time, the allocated time slot and the time slot table parameters of this device; when the transmission time slot time of the bound first-level TT flow queue is reached, the service message is scheduled to be forwarded to the downstream node.
[0019] Compared with the prior art, the beneficial effects of the embodiments of the present invention are: independently scheduling the TT flow queue and non-TT flow queue of the service, and solving the problem of bandwidth resource waste caused by deterministic services through the flow control mechanism of non-TT flows in the egress queue; binding the TT flow queue with the transmission time slot of each service by configuring a static gating list for each port, determining the queues and transmission time slots required for forwarding services on different devices based on path detection and delay measurement on the transmission equipment, and solving the problem of overly complex gating negotiation mechanism and high deployment cost. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments of the present invention. Obviously, the drawings described below are only some embodiments of the present invention, and for ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0021] Figure 1 A schematic diagram of a scheduling system architecture for a time-sensitive service cache queue provided by an embodiment of the present invention;
[0022] Figure 2 The diagram is a schematic diagram of the scheduling process of the first-level TT flow queue;
[0023] Figure 3 This is a schematic diagram of the timeslot negotiation message format;
[0024] Figure 4 A flow chart of a method for caching a time-sensitive service queue provided by an embodiment of the present invention;
[0025] Figure 5 A flow chart of another method for caching a time-sensitive service queue provided by an embodiment of the present invention;
[0026] Figure 6 A flow chart of another method for caching a time-sensitive service queue provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0027] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0028] The present invention is an architecture of a specific functional system, so the specific embodiments mainly illustrate the functional logical relationship between the various structural modules, and do not limit the specific software and hardware implementation methods.
[0029] In addition, the technical features involved in the various embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other. The present invention will be described in detail below with reference to the accompanying drawings and embodiments.
[0030] Embodiment 1:
[0031] The scheduling system provided in this embodiment relates to the field of deterministic networks, and specifically, is a scheduling system model based on gating technology in a deterministic network, and a gating negotiation mechanism required for implementing deterministic scheduling based on this model.
[0032] like Figure 1 As shown, the basic architecture of the scheduling system model of the time-sensitive service cache queue provided by the embodiment of the present invention is shown. The system includes a first-level cache queue, a first-level scheduler, a second-level cache queue and a media access control layer (Media Access Control, abbreviated as MAC).
[0033] The first-level cache queue includes at least two first-level TT flow queues and at least one first-level non-TT flow queue, and each first-level TT flow queue is bound to a transmission time slot. In this embodiment, the TT flow messages and non-TT flow messages in the service message are scheduled separately and independently, and the first-level cache queue is used for classification cache before scheduling, which includes a first-level TT flow queue and a first-level non-TT flow queue. The first-level TT flow queue is used to carry deterministic delay services (TT services). Each port of the network transmission path includes several first-level TT flow queues. The first-level TT flow queue does not occupy the queue of the traditional differential service, but is scheduled using a static gated array. The first-level non-TT flow queue is used to carry services other than the deterministic delay service. Each port includes at least one first-level non-TT flow queue. In actual implementation, the traditional Ethernet differential service model generally uses 8 queues. Since the first-level TT flow queue in the method of the present invention does not occupy the queue of the traditional differential service, all 8 differential service queues can be used as first-level non-TT flow queues.
[0034] The first-level scheduler includes a deterministic delay scheduler and at least one differential service scheduler. The deterministic delay scheduler includes a static gating list. The static gating list schedules the first-level TT flow queue according to the time slot negotiation mechanism. The differential service scheduler controls the transmission rate of the first-level non-TT flow queue according to the flow control information of the second-level non-TT flow queue. In the method of this embodiment, the static gating list periodically turns on the gating switch of each first-level TT flow queue in turn according to the transmission time slot bound to each first-level TT flow queue to realize the scheduling of the first-level TT flow queue. The specific time slot negotiation mechanism implementation method is described later. On the other hand, the differential service scheduler is used to implement the scheduling of the first-level non-TT queue. The differential service scheduler can realize the use requirements of the scheduling algorithms such as strict priority (SP), weighted fair queue (WFQ), and hierarchical scheduling required by the differential service model, and meet the different scheduling needs of the first-level non-TT flow queue. The two schedulers in the first-level scheduler work independently, and the maximum available bandwidth of each scheduler is the maximum bandwidth of the interface. Furthermore, in order to avoid congestion of the secondary cache queue, the differential service scheduler receives flow control information of the secondary cache queue to control the transmission rate of the primary non-TT flow queue.
[0035] The secondary cache queue includes a secondary TT flow queue and a secondary non-TT flow queue. The secondary TT flow queue and the secondary non-TT flow queue cache the messages received from the primary TT flow queue and the primary non-TT flow queue respectively. When the secondary TT flow queue is not empty, the secondary TT flow queue initiates a message transmission request to the MAC; when the secondary TT flow queue is empty, the secondary non-TT flow queue initiates a message transmission request to the MAC. Corresponding to the primary cache queue, the secondary cache queue includes a secondary TT flow queue and a secondary non-TT flow queue. The secondary TT flow queue is used to cache all messages received from the primary TT flow queue, and the secondary non-TT flow queue is used to buffer messages received from all primary non-TT flow queues. When the secondary TT flow queue is not empty, a message transmission request can be initiated to the MAC to ensure the real-time transmission of the TT message. When the secondary TT flow queue is empty, the secondary non-TT flow queue can initiate a message transmission request to the MAC to avoid preempting the sending resources of the TT message. The secondary non-TT flow queue can transmit flow control information to the differential service scheduler in the primary scheduler based on the queue length. When the queue length is too long, the transmission of the primary non-TT flow message is suspended to avoid packet loss caused by cache fullness.
[0036] The MAC is a MAC with a frame preemption function. Based on the MAC frame preemption mechanism, the messages in the secondary TT flow queue are sent preferentially. The MAC with a frame preemption mechanism can pause in the middle of sending non-TT messages and give priority to sending TT messages, further improving the real-time performance of TT message sending. Specifically, the MAC can use the MAC with a frame preemption function specified in 802.1qbu.
[0037] In this embodiment, the first-level TT flow queue is scheduled based on the time slot negotiation mechanism of the above system, the transmission time slot information is transmitted between adjacent devices through the time slot negotiation message, and the transmission delay between adjacent devices is measured. The transmission time slot of each TT flow service in the local device is calculated based on the transmitted time slot information and the measured transmission delay, and the service is bound to the relevant TT flow queue of the determined time slot, so as to realize the binding of the TT flow of each device on the transmission path with the optimal transmission time slot.
[0038] like Figure 2 As shown in the figure, the scheduling process of the first-level TT flow queue is as follows: the transmission delay between adjacent devices is measured according to the time slot information transmitted by the time slot negotiation message, and the transmission time slot of the service in the device is calculated according to the transmission delay and the transmission time slot of the upstream node. Each service corresponds to a transmission time slot. The static gating list divides a cycle into several time slots according to the transmission time slot of each service. There is no time interval between the time slots, and each time slot corresponds to a first-level TT flow queue; the service corresponding to each time slot is bound to the first-level TT flow queue controlled by the time slot, and the first-level TT flow queue is used to cache the message of the corresponding service.
[0039] Among them, the time slot negotiation message is injected into the packet processing chip through the control plane at the first node in the sending direction, extracted to the control plane through the packet processing chip at the intermediate node and the tail node in the receiving direction, and injected into the packet processing chip again after processing. The time slot negotiation message contains the forwarding information required to forward the actual business, as well as the timestamp when the message is injected and the time slot information of the message sent by this station. The negotiation message length is the maximum message length set for the business.
[0040] The specific format of the time slot negotiation message is as follows: Figure 3 As shown, the key fields have the following meanings:
[0041] REQ_BANDWIDTH: Requested bandwidth, filled in by the source node.
[0042] REQ_MAX_DELAY: The maximum forwarding delay of a single node requested.
[0043] MAX_PKT_SIZE: Maximum length of a service message.
[0044] RX_TIME: The receiving timestamp of this node, in us.
[0045] INJECT_TIME: The timestamp when the control plane injects the timeslot negotiation message into the packet processing chip, in us.
[0046] TSID: carries the sending time slot ID used by the previous node when receiving the time slot negotiation message, and updates the sending start time slot allocated by this node when sending the time slot negotiation message.
[0047] TS_LEN: carries the time slot length of the previous node when receiving the time slot negotiation message, and is updated to the time slot length of this node when sending the time slot negotiation message.
[0048] TS_NUM: Carries the number of time slots per cycle of the previous node when receiving the time slot negotiation message, and is updated to the time slot number configuration of this node when sending the time slot negotiation message.
[0049] The method for measuring the transmission delay between adjacent devices is as follows: the downstream device in the adjacent device calculates the time required from the upstream device transmission gate opening time to the downstream device completing the message reception by receiving the injection time information, the sending time slot information and the timestamp information when the device receives the message carried in the time slot negotiation message, and uses this time as the transmission delay between adjacent devices. The calculation principle is as follows:
[0050] The duration of each time slot of the previous node is t1 = TS_LEN.
[0051] The duration of the previous node gating cycle T1 = TS_LEN*TS_NUM.
[0052] The actual sending time TX_TIME of the previous station message.
[0053] if(INJECT_TIME MOD T1>t1*TX_TSID) / / If the injection time information INJECT_TIME exceeds the message sending time slot of this cycle, wait for the time slot corresponding to the first-level TT queue in the next cycle to send the message.
[0054] TX_TIME=((INJECT_TIME / T1)+1)*T1+TX_TSID*t1 / / Calculate the message sending time. Since the message needs to be sent in the next cycle, the number of time slots needs to be increased by one cycle.
[0055] else
[0056] TX_TIME=(INJECT_TIME / T1)*T1+TX_TSID*t1 / / Calculate the message sending time. The message is sent normally in this cycle and the number of time slots does not need to be increased.
[0057] Delay T_DELAY = RX_TIME - TX_TIME, that is, the difference between the arrival time and the sending time.
[0058] The method for calculating the transmission time slot of the device is: through the transmission time slot information carried by the time slot negotiation message and the measured transmission delay, the time for the message to be transmitted in the device is calculated as the transmission time slot in the device itself. In this embodiment, in order to improve the transmission efficiency, the time slot with the shortest waiting time and bandwidth that meets the requirements is selected in the device to be bound to the first-level TT flow queue of the corresponding service. The calculation principle is as follows:
[0059] The duration t2=LS_LEN' of each time slot of this node is the LS_LEN of the receiving node.
[0060] The first available time slot id of this node = ((TSID*t1+T_DELAY) / t2) mod TS_NUM', which is the LS_NUM' of the receiving node.
[0061] Starting from the first available time slot id, find the time slot that meets the delay and bandwidth requirements.
[0062] According to the above specific calculation results, the time slot negotiation message can be used to obtain the transmission time slot of each service, and each first-level TT flow queue can be bound to each time slot, so as to use the static gating array to schedule the first-level TT flow queue according to the time slot negotiation mechanism. At the same time, by transmitting time slot information between nodes and measuring transmission delay, the optimal transmission time slot of this node can also be calculated.
[0063] The second-level cache queue includes a second-level TT flow queue and a second-level non-TT flow queue, which are used to cache the messages received from the first-level TT flow queue and the non-TT flow queue respectively. Through the scheduling of the first-level scheduler, all messages in the first-level TT flow queue are scheduled to the second-level TT flow queue, and all messages in the first-level non-TT flow queue are scheduled to the second-level non-TT flow queue.
[0064] In order to ensure the real-time transmission of TT messages, the scheduling in the secondary TT flow queue does not wait, and the secondary TT flow queue can initiate a message transmission request to the MAC when it is not empty. At the same time, the secondary non-TT flow queue needs to give up the transmission resources of the MAC, so it can only initiate a message transmission request to the MAC when the secondary TT flow queue is empty. After obtaining the transmission permission, the secondary TT flow queue and the secondary non-TT flow queue have both transmitted messages through the MAC at the maximum interface rate.
[0065] Furthermore, since the messages in the secondary non-TT flow queue need to wait, in order to avoid congestion in the secondary non-TT flow queue, it is also necessary to adjust the scheduling of the primary TT flow queue through the flow control information of the secondary TT flow queue. The secondary non-TT flow queue sends flow control information to the differential service scheduler based on the queue length. When the differential service scheduler receives the flow control information sent by the secondary non-TT flow queue, it stops scheduling the messages in the primary non-TT flow queue. When the length of the secondary non-TT flow queue drops below the queue configuration threshold, the secondary non-TT flow queue stops sending flow control information to the differential service scheduler, and the differential service scheduler resumes scheduling the messages in the primary non-TT flow queue.
[0066] Through the above method, the scheduling of the secondary cache queue can be completed, and the priority sending of TT messages can be achieved.
[0067] In order to further improve the real-time performance of TT message transmission, a MAC with a frame preemption mechanism is used in the system provided in this embodiment. When the secondary TT flow queue has a message to be transmitted, it is transmitted first, but at this time, when the MAC is transmitting a message in the secondary non-TT flow queue, based on the MAC frame preemption mechanism, the secondary TT flow queue can preempt the physical channel of the MAC to transmit the message first. When the MAC is transmitting a message in the secondary non-TT flow queue, if the secondary TT flow queue requests to send a message, the MAC gives up the channel after transmitting a message with a packet length of an integer multiple of 64 bytes, and instead schedules the message in the secondary TT flow queue.
[0068] The scheduling system of the time-sensitive service cache queue provided in this embodiment caches TT messages and non-TT messages into different queues for scheduling, so that the TT flow queue uses the interface bandwidth on demand with high priority, and the differential service of the non-TT flow maximizes the use of the remaining bandwidth through the flow control mechanism of the secondary cache queue, without the need for resource reservation, high interface bandwidth utilization, and flexible service bandwidth division. The time slot negotiation mechanism is used to implement a static gating list and delay measurement mechanism to achieve the negotiation of the optimal transmission time slot of each device on the transmission path for the TT flow, which is simple to implement and does not require the deployment of a centralized controller.
[0069] Embodiment 2:
[0070] Based on the scheduling system for a time-sensitive service cache queue provided in Example 1, this embodiment further provides a scheduling method for a time-sensitive service cache queue.
[0071] like Figure 4 As shown, scheduling can be accomplished using the following steps.
[0072] Step 101: The time slot used by each primary TT flow queue is determined according to the time slot negotiation mechanism, and the primary TT flow queue is scheduled according to the static gating list. The primary TT flow queue sends a message to the secondary TT flow queue at the maximum rate of the interface according to the scheduling.
[0073] The first-level TT flow queue is used to carry deterministic delay services. Each port of the network transmission path contains no less than 2 first-level TT flow queues, and each first-level TT flow queue is bound to the transmission time slot corresponding to a service. The number of TT flow queues and the number of services may be a one-to-many relationship. Multiple services can reuse the same TT flow queue, and different services correspond to different time slots in the TT flow queue. In this embodiment, the optimal transmission time slot of each service is calculated by transmitting time slot information between nodes and measuring transmission delay, and the service and time slot are bound. In the method provided in this embodiment, a time slot negotiation mechanism is used to determine the optimal time slot for each service, and the service is configured to enter the queue bound to the time slot. The specific time slot negotiation mechanism is described in detail later.
[0074] The first-level TT flow queue is scheduled by the deterministic delay scheduler in the first-level scheduler. The deterministic delay scheduler contains a static gating list. Through the static gating list, it polls according to the time period to turn on and off the gating switch of each TT flow queue in turn. The static gating list divides a cycle into several time slots. The number of time slots is the same as the number of first-level TT flow queues on the port. There is no time interval between time slots. Each time slot is bound to a first-level TT flow queue. When the time slot time is reached, the first-level TT flow queue opens the transmission gate, and when the time slot time ends, the queue closes the transmission gate.
[0075] All first-level TT flow queues have the same priority. The control plane of the first node of the transmission path selects a TT flow queue for each flow to forward based on the principle of traffic balancing. The intermediate nodes and the tail node select the optimal queue for each flow based on the transmission delay and the remaining bandwidth of each queue. Each first-level TT flow queue sends messages to the second-level TT flow queue at the maximum rate of the interface when the transmission gate is opened. The theoretical rate at which each queue can carry services is: the maximum rate of the port / the number of first-level TT flow queues.
[0076] Furthermore, in order to ensure the real-time transmission of TT messages, messages can be sent when there are messages in the first-level TT flow queue and the transmission gate state of the queue is open, regardless of whether the remaining time is sufficient to send the message. This will cause a delay in the start of sending messages in the next first-level TT flow queue, and the theoretical delay time is no greater than "message length / port maximum rate". When planning services, some bandwidth can be reserved for each queue to prevent such situations from affecting the transmission gate opening time of all subsequent queues, and the impact range is controlled to the next adjacent time slot.
[0077] Furthermore, the deterministic delay scheduler can also schedule the messages in the first-level TT flow queue based on credit. In each time slot, the deterministic delay scheduler generates a specified number of credits. In specific implementation, the credits can be generated and issued in the form of tokens. When the first-level TT flow queue needs to transmit a message, it first determines whether the remaining credits are sufficient to send the message. If so, the message is sent. Otherwise, it waits for the credits to be sufficient before sending the message, so as to avoid a queue over-sending messages in the current time slot and affecting the message sending in the next time slot.
[0078] Step 102: Schedule the first-level non-TT flow queue according to the differentiated service model, and stop scheduling when the second-level non-TT flow queue is congested.
[0079] The first-level non-TT flow queue is used to carry other services except deterministic delay services. In order to improve the utilization of the differential service queue in the existing Ethernet differential service model, in actual implementation, each network port contains 8 first-level non-TT flow queues, and sends messages to the second-level non-TT flow queue at the rate specified by the first-level scheduler according to the differential service model.
[0080] The first-level non-TT flow queue is scheduled by the differential service scheduler in the first-level scheduler, which can realize the requirements of SP, WFQ, RR, hierarchical scheduling, etc. required by the differential service model. Furthermore, multiple differential schedulers can be used in combination to realize applications such as hierarchical scheduling.
[0081] In this embodiment, the first-level scheduler uses two different schedulers to independently schedule the first-level TT flow queue and the first-level non-TT flow queue. The deterministic service scheduler and the differential service scheduler can simultaneously schedule the message from the first-level queue to the second-level queue at their respective designed scheduling rates. Therefore, when the first-level cache queue over-issues traffic, it may cause congestion in the second-level cache queue. In order to ensure that the messages in the first-level TT flow queue are sent in time, the second-level non-TT flow queue generates flow control information according to the congestion situation, and controls the differential service scheduler to stop scheduling the first-level non-TT flow service. The differential service scheduler receives the flow control information of the second-level queue and controls the transmission rate of the non-TT flow queue. Specifically: when the second-level non-TT flow queue sends the flow control information to the differential service scheduler, the differential service scheduler stops scheduling the messages in the first-level non-TT flow queue; when the length of the second-level non-TT flow queue is reduced to below the queue configuration threshold, the second-level non-TT flow queue stops sending flow control information to the differential service scheduler, and the differential service scheduler resumes scheduling the messages in the first-level non-TT flow queue.
[0082] In a specific implementation, the differential service scheduler can configure the maximum available bandwidth for non-TT flow message transmission as needed.
[0083] Step 103: When the secondary TT flow queue is not empty, the secondary TT flow queue and the secondary non-TT flow queue initiate a message transmission request to the MAC. After obtaining the transmission permission, each queue transmits the message through the MAC at the maximum rate of the interface.
[0084] The secondary cache queue includes a secondary TT flow queue and a secondary non-TT flow queue, which are used to cache messages received from the primary TT flow queue and the non-TT flow queue respectively.
[0085] When the secondary TT flow queue is not empty, it can initiate a message transmission request to MAC. When the secondary TT flow queue is empty, the secondary non-TT flow queue can initiate a message transmission request to MAC. After obtaining transmission permission, both queues transmit messages through MAC at the maximum interface rate.
[0086] When the secondary TT flow queue has a message to be transmitted, the message will be transmitted first. If the MAC is transmitting a message in the secondary differential queue at this time, based on the MAC frame preemption mechanism, the secondary TT flow queue can preempt the physical channel to transmit the message first.
[0087] The MAC used in this embodiment is a MAC with frame preemption function specified in 802.1qbu. When the MAC is transmitting non-TT flow services, if the TT flow queue requests to send a message, the MAC gives up the channel after transmitting a message with a packet length of an integer multiple of 64 bytes and schedules the TT flow service instead.
[0088] Through steps 101 to 103, the system in Example 1 can be used to implement independent scheduling of TT flows and non-TT flows, and ensure the real-time transmission of TT messages. In a specific implementation, two schedulers in the first-level scheduler independently schedule TT flows and non-TT flows, the maximum available bandwidth of each scheduler is the maximum bandwidth of the interface, and MAC is forwarded independently of the first-level scheduler. Therefore, the execution order of steps 101 and 103 does not need to be fixed, and can be executed synchronously.
[0089] In step 101, the time slot negotiation mechanism based on the scheduling system provided in Example 1 is used to schedule the first-level TT flow queue, and the transmission time slot information is transmitted between adjacent devices on the transmission path through the time slot negotiation message. Based on the transmission delay measured by the transmitted time slot information and the transmission time slot of each service in the device is calculated, each service is bound to the first-level TT flow queue controlled by its corresponding time slot, and finally the binding of the TT flow of each device on the transmission path with the optimal transmission time slot is realized.
[0090] like Figure 5 As shown, for the first node of the transmission path, the optimal time slot selection of the first-level TT flow queue, as well as the corresponding time slot binding and scheduling can be completed through the time slot negotiation mechanism described in the following steps.
[0091] Step 201: The control plane constructs a time slot negotiation message for each deterministic delay service, and the control plane queries the service configuration to determine the outbound interface of the time slot negotiation message.
[0092] Step 202: Based on the principle of traffic balance, a first-level TT flow queue whose remaining bandwidth meets the demand is selected from all the first-level TT flow queues included in the service message outbound interface as the first-level TT flow queue that carries the service.
[0093] Step 203: The control plane binds the selected first-level TT flow queue to the service, and sends a configuration to control the service to enter the first-level TT flow queue.
[0094] In order to control the used bandwidth value, the control plane also needs to subtract the bandwidth requested by the new service from the remaining bandwidth of the selected first-level TT flow queue.
[0095] Step 204: The control plane fills the service requirements, the transmission time slot allocated by the node and the gating list configuration information into the time slot negotiation message. Specifically, the control plane needs to fill the service requirements (REQ_BANDWIDTH, REQ_MAX_DELAY, MAX_PKT_SIZE), the transmission time slot allocated by the node (TSID) and the gating list configuration information (TS_LEN, TS_NUM) into the corresponding fields of the time slot negotiation message.
[0096] Step 205: The control plane injects the time slot negotiation message into the TT flow queue of the packet processing chip, and updates the timestamp (INJECT_TIME) of the injected time slot negotiation message.
[0097] Step 206: When the transmission time slot of the first-level TT flow queue arrives, the service message is scheduled to be forwarded to the second-level TT flow queue of the downstream node.
[0098] Through step 201 to step 206, the binding of the service and the time slot is completed, and the deterministic scheduling of the service is realized.
[0099] like Figure 6 As shown, the binding of services and time slots is completed for the intermediate nodes and tail nodes of the transmission path, realizing deterministic scheduling of services.
[0100] Step 301: The packet processing chip receives a time slot negotiation message, updates a time slot negotiation message receiving timestamp (RX_TIME), identifies the time slot negotiation message type, and extracts the time slot negotiation message to a control unit.
[0101] Step 302: Complete routing calculation according to the header information of the time slot negotiation message, and obtain the time slot negotiation message outbound interface.
[0102] Step 303: Calculate the transmission delay, calculate the time slot that meets the requirements according to the information carried in the time slot negotiation message and the gating list configuration of the egress port, and issue relevant configuration to bind the service to the first-level TT flow queue corresponding to the time slot.
[0103] Step 305: inject the service message into the first-level TT flow queue bound to the service to wait for scheduling, and update the message injection time (INJECT_TIME), the allocated time slot (TSID) and the time slot table parameters of the device.
[0104] Step 306: When the transmission time slot of the bound first-level TT flow queue is reached, the service message is scheduled to be forwarded to the second-level TT flow queue of the downstream node.
[0105] Through step 301 to step 306, the binding of the service and the time slot is completed, and the deterministic scheduling of the service is realized.
[0106] It can be seen from the above steps that, through the scheduling system of the time-sensitive service cache queue provided in Example 1, the TT message corresponding to each service can be independently scheduled through the first-level TT flow queue bound to each service, thereby avoiding the problem of TT service resource monopoly.
[0107] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A scheduling system for a time-sensitive service cache queue, characterized in that: Including the first-level cache queue, the first-level scheduler, the second-level cache queue and MAC, specifically: The first-level cache queue includes at least two first-level TT flow queues and at least one first-level non-TT flow queue, and each first-level TT flow queue is bound to a transmission time slot; The first-level scheduler includes a deterministic delay scheduler and at least one differential service scheduler, the deterministic delay scheduler includes a static gating list, the static gating list schedules the first-level TT flow queue according to the time slot negotiation mechanism, and the differential service scheduler controls the transmission rate of the first-level non-TT flow queue according to the flow control information of the second-level non-TT flow queue; The secondary cache queue includes a secondary TT flow queue and a secondary non-TT flow queue. The secondary TT flow queue and the secondary non-TT flow queue cache messages received from the primary TT flow queue and the primary non-TT flow queue respectively. When the secondary TT flow queue is not empty, the secondary TT flow queue initiates a message transmission request to the MAC. The MAC is a MAC with a frame preemption function, and the messages in the secondary TT flow queue are preferentially sent based on the MAC frame preemption mechanism.
2. The scheduling system for time-sensitive service cache queue according to claim 1, characterized in that: Each level TT flow queue is bound to a transmission time slot, specifically including: The transmission delay between adjacent devices is measured based on the time slot information transmitted by the time slot negotiation message. The transmission time slot of the message in the local device is calculated based on the transmission delay and the transmission time slot of the upstream node. Each service corresponds to a transmission time slot. The static gating list divides a cycle into several time slots according to the transmission time slot of each service. There is no time interval between the time slots, and each time slot corresponds to a first-level TT flow queue; The service corresponding to each time slot is bound to the first-level TT flow queue controlled by the time slot, and the first-level TT flow queue is used to cache the messages of the corresponding service.
3. The scheduling system for time-sensitive service cache queue according to claim 2, characterized in that: Measuring the transmission delay between adjacent devices according to the time slot information transmitted by the time slot negotiation message specifically includes: The time slot negotiation message is injected into the packet processing chip through the control plane at the first node of the transmission path in the sending direction, extracted to the control plane through the packet processing chip at the intermediate node and the tail node in the receiving direction, and injected into the packet processing chip again after processing. The time slot negotiation message contains the forwarding information required for forwarding the actual business, as well as the timestamp when the message is injected and the time slot information of the message sent by this station. The negotiated message length is the maximum message length set for the business.
4. The scheduling system for time-sensitive service cache queue according to claim 1, characterized in that: The differential service scheduler controls the transmission rate of the primary non-TT flow queue according to the flow control information of the secondary non-TT flow queue, and further includes: The secondary non-TT flow queue sends flow control information to the differential service scheduler based on the queue length. When the differential service scheduler receives the flow control information sent by the secondary non-TT flow queue, it stops scheduling the messages in the primary non-TT flow queue. When the length of the secondary non-TT flow queue decreases below the queue configuration threshold, the secondary non-TT flow queue stops sending flow control information to the differential service scheduler, and the differential service scheduler resumes scheduling the messages in the primary non-TT flow queue.
5. The scheduling system for time-sensitive service cache queue according to claim 1, characterized in that: The MAC-based frame preemption mechanism preferentially sends the messages in the secondary TT flow queue, specifically including: When MAC is transmitting messages in the secondary non-TT flow queue, if the secondary TT flow queue requests to send a message, MAC will give up the channel after transmitting a message with a packet length that is an integer multiple of 64 bytes and instead schedule the message in the secondary TT flow queue.
6. A scheduling method for a time-sensitive service cache queue, characterized in that: The scheduling system of the time-sensitive service cache queue according to any one of claims 1 to 5 is used to schedule the cache queue, specifically comprising: The time slot used by each first-level TT flow queue is determined according to the time slot negotiation mechanism, and the first-level TT flow queue is scheduled according to the static gating list. The first-level TT flow queue sends packets to the second-level TT flow queue at the maximum rate of the interface according to the scheduling; Schedule the first-level non-TT flow queue according to the differentiated service model, and stop scheduling when the second-level non-TT flow queue is congested; When the secondary TT flow queue is not empty, the secondary TT flow queue initiates a message transmission request to the MAC. When the secondary TT flow queue is empty, the secondary non-TT flow queue initiates a message transmission request to the MAC. After obtaining the transmission permission, each queue transmits the message through the MAC at the maximum rate of the interface.
7. The method for scheduling a time-sensitive service cache queue according to claim 6, characterized in that: For the first node of the transmission path, each first-level TT flow queue is bound to a transmission time slot, specifically including: The control plane constructs a time slot negotiation message for each deterministic delay service, queries the service configuration, and determines the outbound interface of the time slot negotiation message; Based on the principle of traffic balancing, a first-level TT flow queue with a remaining bandwidth that meets the demand is selected from all the first-level TT flow queues included in the service packet outbound interface as the first-level TT flow queue that carries this service; The control plane binds the selected first-level TT flow queue to the service and sends a configuration to control the service to enter the first-level TT flow queue.
8. The method for scheduling a time-sensitive service cache queue according to claim 6, characterized in that: For the first node of the transmission path, determining the time slot used by each first-level TT flow queue according to the time slot negotiation mechanism specifically includes: The control plane fills the service requirements, the transmission time slot allocated by the node, and the gating list configuration information into the time slot negotiation message; The control plane injects the time slot negotiation message into the TT flow queue of the packet processing chip and updates the timestamp of the injected time slot negotiation message at the same time; When the transmission time slot of the selected first-level TT flow queue arrives, the service message is scheduled to be forwarded to the second-level TT flow queue of the downstream node.
9. The method for scheduling a time-sensitive service cache queue according to claim 6, characterized in that: For the intermediate node and the tail node of the transmission path, determining the time slot used by each first-level TT flow queue according to the time slot negotiation mechanism specifically includes: The packet processing chip receives the time slot negotiation message, updates the time slot negotiation message receiving timestamp, identifies the time slot negotiation message type, and extracts the time slot negotiation message to the control unit; Complete the routing calculation according to the header information of the time slot negotiation message and obtain the outgoing interface of the time slot negotiation message; Calculate the transmission delay, calculate the time slot that meets the requirements based on the information carried in the time slot negotiation message and the port's gating list configuration, and send relevant configurations to bind the service to the first-level TT flow queue corresponding to the time slot.
10. The method for scheduling a time-sensitive service cache queue according to claim 6, characterized in that: For the intermediate node and the tail node of the transmission path, determining the time slot used by each first-level TT flow queue according to the time slot negotiation mechanism specifically includes: Inject the service message into the first-level TT flow queue bound to the service to wait for scheduling, and update the message injection time, the allocated time slot and the time slot table parameters of this device; When the transmission time slot of the bound first-level TT flow queue is reached, the service message is scheduled to be forwarded to the downstream node.
Citation Information
Patent Citations
Time-aware shaper hierarchical cross flow scheduling system and method for mobile forward transmission network
CN112260957A
Method for managing and scheduling time-sensitive network queue in wired and wireless integrated spacecraft
CN114615211A
