WO2022022222A1 - 发送数据包的方法及网络设备 - Google Patents

发送数据包的方法及网络设备 Download PDF

Info

Publication number
WO2022022222A1
WO2022022222A1 PCT/CN2021/104191 CN2021104191W WO2022022222A1 WO 2022022222 A1 WO2022022222 A1 WO 2022022222A1 CN 2021104191 W CN2021104191 W CN 2021104191W WO 2022022222 A1 WO2022022222 A1 WO 2022022222A1
Authority
WO
WIPO (PCT)
Prior art keywords
time
network device
queue
data packet
target
Prior art date
Application number
PCT/CN2021/104191
Other languages
English (en)
French (fr)
Inventor
任首首
刘冰洋
孟锐
王闯
勒布德克·简-伊夫
穆罕默德·伊桑
艾法沃·阿拉丁
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP21851520.3A priority Critical patent/EP4184887A4/en
Publication of WO2022022222A1 publication Critical patent/WO2022022222A1/zh
Priority to US18/159,875 priority patent/US20230171201A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/56Queue scheduling implementing delay-aware scheduling
    • H04L47/564Attaching a deadline to packets, e.g. earliest due date first
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/62Queue scheduling characterised by scheduling criteria
    • H04L47/625Queue scheduling characterised by scheduling criteria for service slots or service orders
    • H04L47/6275Queue scheduling characterised by scheduling criteria for service slots or service orders based on priority
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/24Traffic characterised by specific attributes, e.g. priority or QoS
    • H04L47/2416Real-time traffic
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/28Flow control; Congestion control in relation to timing considerations
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/28Flow control; Congestion control in relation to timing considerations
    • H04L47/283Flow control; Congestion control in relation to timing considerations in response to processing delays, e.g. caused by jitter or round trip time [RTT]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/56Queue scheduling implementing delay-aware scheduling
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/56Queue scheduling implementing delay-aware scheduling
    • H04L47/568Calendar queues or timing rings
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/62Queue scheduling characterised by scheduling criteria
    • H04L47/622Queue service order
    • H04L47/6225Fixed service order, e.g. Round Robin
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/30Peripheral units, e.g. input or output ports
    • H04L49/3018Input queuing
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/30Peripheral units, e.g. input or output ports
    • H04L49/3027Output queuing

Definitions

  • the present application relates to the field of communication technology, and more particularly, to a method and a network device for sending data packets.
  • Deterministic delay means that the delay and jitter experienced by the data packet transmission meet the upper bound on the premise that the data packet obeys certain burstiness requirements.
  • scalable data plane deterministic packet scheduling needs to be implemented.
  • the present application provides a method and network device for sending data packets, which can ensure end-to-end deterministic delay and jitter of the network in different network scenarios.
  • a first aspect provides a method for sending data packets, characterized in that the method includes:
  • the second network device receives the data packet sent by the first network device at the first moment
  • the second network device determines a second reference time according to the time information carried by the data packet, where the second reference time is a reference time for instructing the data packet to enter a queue in the second queuing system, and the second queuing system is the second reference time.
  • the time information is used to indicate the first remaining processing time for the data packet to pass through the first network device, where the first remaining processing time is the difference between the first delay and the first processing time, and the first remaining processing time is the difference between the first delay and the first processing time.
  • a delay is a value not less than the absolute value of the difference between the first theoretical upper limit of time and the first transmission time
  • the first theoretical upper limit of time is the upper limit of the theoretical processing time from the first reference time to the second reference time
  • the first The reference time is the reference time for directing the data packet to enter the queue in the first queuing system
  • the first queuing system is the queuing system of the first network device
  • the first transmission time is the data packet being output by the first network device
  • the actual transmission time from the first output moment to the first moment, and the first processing time is the actual processing time from the first reference moment to the first output moment when the data packet is output by the first network device;
  • the second network device determines a target queue from a plurality of queues included in the second queue system according to the second reference time and adds the data packet to the target queue;
  • the second network device sends the data packet to the third network device according to the scheduling rule corresponding to the second queuing system.
  • the second network device may determine the remaining processing time of the data packet in the first network device according to the pre-defined first delay, and when the remaining processing time is greater than zero, the data packet enters the The time of a queue in the second network device (that is, an example of the target queue) is the start time, and after a period of time reaches the second reference time corresponding to the data packet, the remaining processing time is consumed in the second network device , so as to ensure the deterministic delay and jitter after the data packet is forwarded by the first network device and the second network device, and further make the flow of the data packet enter the shape of the second network device and the flow of the data packet to be The shape after the output of the second network device is the same.
  • the plurality of queues included in the second queue system corresponds to a plurality of preset times in one-to-one correspondence, and any two adjacent preset times in the plurality of preset times
  • the time difference is a first value
  • the second network device determines a target queue from a plurality of queues included in the second queue system according to the second reference time, including:
  • the second network device determines that one of the queues included in the second queue system corresponding to the first target time is the target queue, and the first target time is the second reference time and the second reference time.
  • the sum of the second value, the second value is the absolute value of the difference between the second reference time and the third time plus an integer multiple of the first value, and the second reference time and the third time do not include the Any one of a plurality of preset times, the third time is one of the plurality of preset times and the third time is greater than the second reference time, and the first target time is the plurality of preset times a moment in.
  • the second network device determines the second reference time according to the time information carried in the data packet, including:
  • the second network device determines the second reference time according to the first delay and the first processing time.
  • the second network device determines the second reference time according to the first delay and the first processing time, including:
  • the second network device determines the second reference time according to the first delay, the first reference time, the first output time when the data packet is output by the first network device, and the first time.
  • the second network device is based on the first delay, the first reference time, and the first output time at which the data packet is output by the first network device and the first moment, and determining the second reference moment includes: the second network device determining the second reference moment according to the following formula:
  • E 2 is the second reference moment, for this first moment, is the first delay, is the first output time when the data packet is output by the first network device, and E 1 is the first reference time.
  • the second network device determines the second reference time according to the first delay and the first processing time, including:
  • the second network device is based on the first delay, the first reference time, the first output time of the data packet output by the first network device, and the time after the data packet is processed by the switch fabric of the second network device. and the first time, determine the second reference time, wherein the time after the data packet is processed by the switching fabric of the second network device is less than the second reference time.
  • the second network device is based on the first delay, the first reference time, and the first output time at which the data packet is output by the first network device , the time after the data packet is processed by the switching structure of the second network device and the first time, to determine the second reference time, including: the second network device determines the second reference time according to the following formula:
  • E 2 is the second reference moment, is the moment after the data packet is processed through the switching fabric of the second network device, is the first delay, is the first output moment when the data packet is output by the first network device, E 1 is the first reference moment, for the first moment.
  • the time information includes a first time value, and the first time value is the first remaining processing time.
  • the time information includes first indication information, where the first indication information is used to indicate the first processing time.
  • the first indication information includes a second time value, and the second time value is the first processing time.
  • the first indication information includes a third time value and a fourth time value
  • the third time value is the first time that the data packet is output by the first network device.
  • An output time, the fourth time value is the first reference time.
  • the time information further includes second indication information, where the second indication information is used to indicate the first delay.
  • the second network device sends the data packet to the third network device according to a scheduling rule corresponding to the second queuing system, including:
  • the second network device determines that the target queue is the queue currently scheduled among the queues included in the second queue system, and the target queue is in an open state, and the second network device sends the data packet to the third Internet equipment.
  • the method further includes:
  • the second network device determines to close the target queue when the target queue satisfies the first preset condition.
  • the method further includes:
  • the second network device determines a second target time according to the first information, the second target time corresponds to the target queue, the second target time is the opening time corresponding to the target queue after the first target time, and the first target time
  • the second target time is greater than any one of the plurality of preset times, and the first information includes the scheduling sequence corresponding to each queue included in the second queuing system and the opening corresponding to each queue included in the second queuing system the moment;
  • the plurality of queues included in the second queuing system correspond to the plurality of preset times in one-to-one correspondence
  • the difference between any two adjacent preset times in the plurality of preset times is a first value
  • the first target time One of the queues included in the corresponding second queue system is the target queue
  • the first target time is the sum of the second reference time and a second value
  • the second value is the second reference time and the second value.
  • the absolute value of the difference between the third time and the integer multiple of the first value, the second reference time and the third time do not include any one of the plurality of preset time, and the third time is the One of a plurality of preset times and the third time is greater than the second reference time, and the first target time is one of the plurality of preset times.
  • the second network device determines that the target queue is a queue currently scheduled among multiple queues included in the second queue system, including:
  • the second network device determines that the target queue is a queue with the highest priority among multiple queues included in the second queue system, determines that the target queue is one of multiple queues included in the second queue system The queue scheduled at the current moment;
  • the method further includes:
  • the second network device sets the priority of the target queue to the queue with the lowest priority among the queues included in the second queue system, and sets the queues included in the second queue system except the target queue The priority of the queue is increased.
  • the multiple queues included in the second queue system correspond one-to-one with multiple preset scheduling sequences
  • the second network device determines that the target queue is the queue currently scheduled among the multiple queues included in the second queue system, including:
  • the second network device determines that the preset scheduling sequence corresponding to the target queue is the scheduling sequence corresponding to the queue scheduled by the second network device at the current moment according to the multiple preset scheduling sequences, the second network device determines the The target queue is the queue scheduled at the current moment among the multiple queues included in the second queue system.
  • the first preset condition includes: the target queue is an empty queue, and the opening duration of the target queue is greater than or equal to a first value, and the first value is more than The difference between any two adjacent preset times among the preset times, the preset times correspond to the queues included in the second queuing system on a one-to-one basis.
  • a second network device wherein the second network device includes:
  • a transceiver unit configured to receive a data packet sent by the first network device at the first moment
  • a processing unit configured to determine a second reference time according to the time information carried by the data packet, where the second reference time is a reference time for guiding the data packet to enter a queue in a second queuing system, and the second queuing system is the second reference time
  • the time information is used to indicate the first remaining processing time for the data packet to pass through the first network device, where the first remaining processing time is the difference between the first delay and the first processing time, and the first remaining processing time is the difference between the first delay and the first processing time.
  • a delay is a value not less than the absolute value of the difference between the first theoretical upper limit of time and the first transmission time
  • the first theoretical upper limit of time is the upper limit of the theoretical processing time from the first reference time to the second reference time
  • the first The reference time is the reference time for directing the data packet to enter the queue in the first queuing system
  • the first queuing system is the queuing system of the first network device
  • the first transmission time is the data packet being output by the first network device
  • the actual transmission time from the first output moment to the first moment, and the first processing time is the actual processing time from the first reference moment to the first output moment when the data packet is output by the first network device;
  • the processing unit is further configured to determine a target queue from a plurality of queues included in the second queue system according to the second reference time and add the data packet to the target queue;
  • the processing unit is further configured to send the data packet to the third network device according to the scheduling rule corresponding to the second queuing system.
  • the second network device may determine the remaining processing time of the data packet in the first network device according to the pre-defined first delay, and when the remaining processing time is greater than zero, the data packet enters the The time of a queue in the second network device (that is, an example of the target queue) is the start time, and after a period of time reaches the second reference time corresponding to the data packet, the remaining processing time is consumed in the second network device , so as to ensure the deterministic delay and jitter after the data packet is forwarded by the first network device and the second network device, and further make the flow of the data packet enter the shape of the second network device and the flow of the data packet to be The shape after the output of the second network device is the same.
  • the multiple queues included in the second queue system correspond one-to-one with multiple preset moments
  • the processing unit is also used to:
  • the second reference time it is determined that one of the multiple queues included in the second queuing system corresponding to the first target time is the target queue, and the first target time is the sum of the second reference time and the second value,
  • the second value is the absolute value of the difference between the second reference time and the third time plus an integer multiple of the first value, and the interval between the second reference time and the third time does not include the preset time at any time of
  • the third time is one of the plurality of preset times and the third time is greater than the second reference time
  • the first target time is one of the plurality of preset times.
  • the processing unit is further configured to:
  • the second reference time is determined according to the first time delay and the first processing time.
  • the processing unit is further configured to:
  • the second reference time is determined according to the first delay, the first reference time, the first output time when the data packet is output by the first network device, and the first time.
  • the processing unit is further configured to:
  • the second reference moment is determined according to the following formula:
  • E 2 is the second reference moment, for this first moment, is the first delay, is the first output time when the data packet is output by the first network device, and E 1 is the first reference time.
  • the processing unit is further configured to:
  • the first reference time the first output time when the data packet is output by the first network device, the time when the data packet is processed by the switch fabric of the second network device, and the first time , and determine the second reference time, wherein the time after the data packet is processed by the switching fabric of the second network device is less than the second reference time.
  • the processing unit is further configured to:
  • the second reference moment is determined according to the following formula:
  • E 2 is the second reference moment, is the moment after the data packet is processed through the switching fabric of the second network device, is the first delay, is the first output moment when the data packet is output by the first network device, E 1 is the first reference moment, for the first moment.
  • the time information includes a first time value, the first
  • the time value is the first remaining processing time.
  • the time information includes first indication information, and the first
  • An indication message is used to indicate the first processing time.
  • the first indication information includes a second time value
  • the second time value is the first processing time
  • the first indication information includes a third time value and a fourth time value
  • the third time value is the first time that the data packet is output by the first network device.
  • An output time, the fourth time value is the first reference time.
  • the time information further includes second indication information, where the second indication information is used to indicate the first delay.
  • the processing unit is further configured to:
  • the transceiver unit is further configured to: send the data packet to the third network device according to the scheduling rule corresponding to the second queuing system.
  • the processing unit is further configured to:
  • the target queue satisfies the first preset condition, it is determined to close the target queue.
  • a second target time is determined according to the first information, the second target time corresponds to the target queue, and the second target time is after the first target time
  • the opening time corresponding to the target queue, the second target time is greater than any one preset time among a plurality of preset times
  • the first information includes the scheduling sequence corresponding to each queue included in the second queuing system and the first information. The corresponding opening time of each queue included in the two-queue system;
  • the plurality of queues included in the second queuing system correspond to the plurality of preset times in one-to-one correspondence
  • the difference between any two adjacent preset times in the plurality of preset times is a first value
  • the first target time One of the queues included in the corresponding second queue system is the target queue
  • the first target time is the sum of the second reference time and a second value
  • the second value is the second reference time and the second value.
  • the absolute value of the difference between the third time and the integer multiple of the first value, the second reference time and the third time do not include any one of the plurality of preset time, and the third time is the One of a plurality of preset times and the third time is greater than the second reference time, and the first target time is one of the plurality of preset times.
  • the processing unit is further configured to:
  • the target queue is the queue with the highest priority among the multiple queues included in the second queuing system, determining that the target queue is the queue currently scheduled among the multiple queues included in the second queuing system;
  • the multiple queues included in the second queue system correspond one-to-one with multiple preset scheduling sequences
  • the processing unit is also used to:
  • the preset scheduling order corresponding to the target queue is the scheduling order corresponding to the queue scheduled by the second network device at the current moment
  • the first preset condition includes: the target queue is an empty queue, and the opening duration of the target queue is greater than or equal to a first value, and the first value is more The difference between any two adjacent preset times among the preset times, the preset times correspond to the queues included in the second queuing system on a one-to-one basis.
  • a second network device in a third aspect, includes a memory and a processor, where the memory is used to store computer-executed instructions, and the processor is used to read the computer-executed instructions stored in the memory, so that the The apparatus performs the above-mentioned first aspect and the method in any possible implementation manner of the first aspect.
  • a processor including: an input circuit, an output circuit, and a processing circuit.
  • the processing circuit is configured to receive a signal through the input circuit and transmit a signal through the output circuit, so that any aspect of the first aspect and the method of any possible implementation of the first aspect are accomplish.
  • the above-mentioned processor may be a chip system
  • the input circuit may be an input pin
  • the output circuit may be an output pin
  • the processing circuit may be a transistor, a gate circuit, a flip-flop, and various logic circuits.
  • the input signal received by the input circuit may be received and input by, for example, but not limited to, a receiver
  • the signal output by the output circuit may be, for example, but not limited to, output to and transmitted by a transmitter
  • the circuit can be the same circuit that acts as an input circuit and an output circuit at different times.
  • the embodiments of the present application do not limit the specific implementation manners of the processor and various circuits.
  • a processing apparatus including a processor and a memory.
  • the processor is configured to read computer-executable instructions stored in the memory, and can receive signals through a receiver and transmit signals through a transmitter, so as to execute the method in the first aspect and any possible implementation manner of the first aspect.
  • processors there are one or more processors and one or more memories.
  • the memory may be integrated with the processor, or the memory may be provided separately from the processor.
  • the memory can be a non-transitory memory, such as read only memory (ROM), which can be integrated with the processor on the same chip system, or can be set in different On the chip system, the embodiment of the present application does not limit the type of the memory and the setting manner of the memory and the processor.
  • ROM read only memory
  • the relevant data interaction process such as sending indication information, may be a process of outputting indication information from the processor, and receiving capability information may be a process of receiving input capability information by the processor.
  • the data output by the processing can be output to the transmitter, and the input data received by the processor can be from the receiver.
  • the transmitter and the receiver may be collectively referred to as a transceiver.
  • a computer-readable storage medium for storing a computer program, the computer program comprising computer-executable instructions for executing the method in the above-mentioned first aspect and any possible implementation manner of the above-mentioned first aspect.
  • a computer program product comprising computer-executable instructions, which, when run on a computer, cause the computer to execute the method in the above-mentioned first aspect and any possible implementation manner of the above-mentioned first aspect.
  • a chip system including at least one processor and an interface; the at least one processor is configured to call and run a computer program, so that the chip system executes the above-mentioned first aspect and the above-mentioned first aspect A method in any possible implementation of an aspect.
  • a system including the above-mentioned second network device.
  • FIG. 1 is a schematic diagram of the reasons for the formation of burst accumulation.
  • FIG. 2 is a schematic diagram of a system architecture 200 to which embodiments of the present application can be applied.
  • FIG. 3 is a schematic structural block diagram of a router capable of implementing an embodiment of the present application.
  • FIG. 4 is a schematic flowchart of a method 400 for sending a data packet provided by an embodiment of the present application.
  • FIG. 5 is a schematic diagram of a moment provided by an embodiment of the present application.
  • FIG. 6 is an encapsulation format of the time information in the header provided by the embodiment of the present application.
  • FIG. 7 is a sequence diagram of a second network device determining a second reference time on an uplink board according to an embodiment of the present application.
  • FIG. 8 is a sequence diagram of another second network device determining the second reference time on the uplink board according to an embodiment of the present application.
  • FIG. 9 is a sequence diagram of a second network device determining a second reference time on a downlink board according to an embodiment of the present application.
  • FIG. 10 is a sequence diagram of another second network device determining the second reference time on the downlink board according to the embodiment of the present application.
  • FIG. 11 is a schematic diagram of a second queue system provided by an embodiment of the present application.
  • FIG. 12 is a schematic diagram of a deterministic delay after a data packet is forwarded by a network device according to an embodiment of the present application.
  • FIG. 13 is a specific embodiment of a method for sending a data packet provided by an embodiment of the present application.
  • FIG. 14 is a schematic diagram of a deterministic delay after a data packet is forwarded by a network device according to an embodiment of the present application.
  • FIG. 15 is a functional module of a second network device provided by the implementation of this application.
  • FIG. 16 is a functional module of a network device for sending data packets provided by the implementation of this application.
  • FIG. 17 is a functional module of another network device for sending data packets provided by the implementation of this application.
  • FIG. 18 is a schematic structural diagram of a second network device 1700 provided by an embodiment of the present application.
  • FIG. 19 is a schematic diagram of a hardware structure of a second network device 2000 provided by an embodiment of the present application.
  • the network architecture and service scenarios described in the embodiments of the present application are for the purpose of illustrating the technical solutions of the embodiments of the present application more clearly, and do not constitute a limitation on the technical solutions provided by the embodiments of the present application.
  • the evolution of the architecture and the emergence of new business scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.
  • references in this specification to "one embodiment” or “some embodiments” and the like mean that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the present application.
  • appearances of the phrases “in one embodiment,” “in some embodiments,” “in other embodiments,” “in other embodiments,” etc. in various places in this specification are not necessarily All refer to the same embodiment, but mean “one or more but not all embodiments” unless specifically emphasized otherwise.
  • the terms “including”, “including”, “having” and their variants mean “including but not limited to” unless specifically emphasized otherwise.
  • At least one means one or more, and “plurality” means two or more.
  • the character “/” generally indicates that the associated objects are an “or” relationship.
  • “At least one item(s) below” or similar expressions thereof refer to any combination of these items, including any combination of single item(s) or plural items(s).
  • at least one item (a) of a, b, or c can represent: a, b, c, ab, ac, bc, or abc, where a, b, c can be single or multiple .
  • IP Internet Protocol
  • Burst accumulation is the root cause of delay uncertainty. Burst accumulation is caused by the squeezing of different packets.
  • Figure 1 shows a schematic diagram of the reasons for the formation of burst accumulation.
  • FIG. 2 shows a schematic diagram of a system architecture 200 to which embodiments of the present application can be applied.
  • the system architecture 200 may be composed of an edge network 210 , an edge network 220 and a core network 230 .
  • Edge network 220 includes user equipment 221 .
  • Core network 230 includes ingress edge device 231 , network device 232 , network device 233 , network device 234 , and egress edge device 235 .
  • the user equipment 211 may communicate with the user equipment 221 through the core network 230 .
  • the embodiments of the present application may be implemented by devices in the core network 230 .
  • it can be implemented by the ingress edge device 231 and the network device 232 , can also be implemented by the network device 231 to the network device 235 , and can also be implemented by the network device 232 to the egress edge device 235 .
  • the method for implementing the embodiments of the present application by the network device 231 to the network device 235 is used as an example for introduction.
  • the ingress edge device 231 When the ingress edge device 231 is the first network device in which the multiple flows enter the core network 230, the ingress edge device 231 may also be referred to as a first-hop network device or a first-hop network device.
  • the network device 232 is the network device of the second hop
  • the network device 233 is the network device of the third hop
  • the network device 234 is the network device of the fourth hop
  • the egress edge device 235 is the network device of the fifth hop.
  • Ingress edge device 231 may receive multiple traffic flows.
  • the ingress edge device 231 processes each of the multiple service flows in the same manner.
  • the traffic model of each service flow received by the ingress edge device 231 satisfies the following formula:
  • t is the time; A i (t) is the total data flow of the ith service flow within t time; ri is the bandwidth required by the ith service flow, and B i is the maximum burst rate of the ith service flow ; ri is the average bandwidth, which can be understood as the average speed of the i -th service flow in the statistical sense.
  • traffic flow described above may also sometimes be referred to as traffic.
  • the ingress edge device 231 may utilize existing shaping algorithms (eg, leaky bucket algorithm, token bucket algorithm, etc.). etc.) to shape the target flow, so that the shaped flow model of the target flow satisfies the above flow model.
  • existing shaping algorithms eg, leaky bucket algorithm, token bucket algorithm, etc.
  • a device capable of implementing the embodiments of the present application may be a router.
  • a device capable of implementing the embodiments of the present application may also be an ingress gateway device (eg, a switch).
  • Fig. 2 is only a schematic diagram for helping those skilled in the art to understand a system architecture of the method of the present application, rather than a limitation to the system architecture that can apply the technical solutions of the present application.
  • the system architecture 200 may include a greater number of network devices.
  • edge network 210 or edge network 220 may also include a greater number of user equipments.
  • FIG. 3 shows a schematic structural block diagram of a router capable of implementing an embodiment of the present application.
  • the router 300 includes an upstream board 301 , a switch fabric 302 and a downstream board 303 .
  • the upstream board may also be called the upstream interface board.
  • Upstream board 301 may include multiple input ports.
  • the upstream board can decapsulate the packets received by the input port, and use the forwarding table to find the output port. Once the output port is found (for ease of description, the found output port is hereinafter referred to as the target output port), the data packet is sent to the switch fabric 302 .
  • Switch fabric 302 forwards received packets to one of the destination output ports. Specifically, the switch fabric 302 forwards the received data packet to the downstream board 303 including the target output port. Downstream boards may also be referred to as downstream interface boards.
  • the lower board 303 includes a plurality of output ports. Downstream board 303 receives data packets from switch fabric 302 .
  • the downlink board can perform buffer management and encapsulation processing on the received data packet, and then send the data packet to the next-hop network device through the target output port.
  • a router may include multiple upstream boards and/or multiple downstream boards.
  • FIG. 4 is a schematic flowchart of a method 400 for sending a data packet provided by an embodiment of the present application.
  • the method 400 includes steps 410 to 440 .
  • the method 400 can be applied to the core network 230 shown in FIG. 2 , and the steps 410 to 440 will be described in detail below.
  • Step 410 the second network device receives the data packet sent by the first network device at the first moment.
  • the network device may be a switch, a router, or the like.
  • a network device may also sometimes be referred to as a network node or hop.
  • the second network device is a next-hop network device of the first network device.
  • the second network device when the first network device is the ingress edge device 231 , the second network device may be the network device 232 .
  • the second network device When the first network device is the network device 232 , the second network device may be the network device 234 .
  • the second network device When the first network device is the network device 234 , the second network device may be the egress edge device 235 .
  • the first network device may further include that the first network device receives the data packet.
  • the first network device may use an algorithm (for example, a leaky bucket algorithm) for the data packet received by the first network device
  • the service flow 1 where it belongs is shaped so that the shaped service flow 1 satisfies the following formula:
  • t is time; A 1 (t) is the total data flow of service flow 1 within t time; r 1 is the bandwidth required by service flow 1, B 1 is the maximum burst degree of service flow 1; r 1 is the average bandwidth , the average bandwidth can be understood as the average speed of service flow 1 in the statistical sense.
  • Step 420 the second network device determines the second reference time according to the time information carried in the data packet.
  • the second reference time is a reference time for instructing the data packet to enter the queue in the second queuing system
  • the second queuing system is the queuing system of the second network device.
  • the second network device may determine that the data packet should enter a certain queue in the second queue system according to the second reference time.
  • the second queue system includes a group of queues, and the group of queues includes a plurality of queues.
  • the second queuing system may also sometimes be referred to as a second queuing group.
  • the second network device may also include the priority of the services carried by each data packet and the second network device including: The business priority corresponding to the multiple queue systems is determined, and the second queue system is determined from the multiple queue systems. The business priorities corresponding to any two queue systems in the multiple queue systems are not the same, and the business priority corresponding to the second queue system A service priority in the class is the same as the priority of the service carried by the data packet.
  • the multiple queue systems may also be referred to as multiple queue groups, and each queue group may include multiple queues.
  • Each queue group can correspond to one or more service priorities.
  • the second network device includes three queue systems, namely, queue system 1, queue system 2, and queue system 3, and queue system 1 includes queue 1 (corresponding to a service priority of 1) and queue 2 (corresponding to a service priority of 1). is 2), queue system 2 includes queue 3 (corresponding to business priority 3), queue 4 (corresponding business priority is 4) and queue 5 (corresponding business priority is 5), queue system 3 includes queue 6 (the corresponding service priority is 6) and queue 7 (the corresponding service priority is 6).
  • the second network device may determine that the queue system 3 is the second queue system.
  • the time information is used to indicate the first remaining processing time of the data packet passing through the first network device, the first remaining processing time is the difference between the first delay and the first processing time, and the first delay is not A value smaller than the absolute value of the difference between the first theoretical upper limit of time and the first transmission time.
  • the first theoretical upper limit of time is the upper limit of the theoretical processing time from the first reference time to the second reference time.
  • a reference time of a queue in a queue system is the queue system of the first network device
  • the first transmission time is the actual transmission time from the first output time when the data packet is output by the first network device to the first time
  • the first processing time is the actual processing time from the first reference time to the first output time when the data packet is output by the first network device.
  • the absolute value of the difference between the first theoretical upper limit of time and the first transmission time is denoted as the first absolute value.
  • the first delay is a value not less than the first absolute value, and a value greater than or equal to the first absolute value may be arbitrarily selected as the first delay.
  • the first absolute value is 10 microseconds
  • the first delay can be set to 10 microseconds, 11 microseconds, 20 microseconds or 50 microseconds, etc.
  • the first delay is a value not less than the first absolute value, and the sum of a non-negative integer and the first absolute value may be used as the first delay.
  • the first absolute value is 10 microseconds and the non-negative integer is 1.5 microseconds
  • the first delay may be set to 11.5 microseconds.
  • the upper limit of the above-mentioned first theoretical delay is a predefined value.
  • the upper limit of the first theoretical delay may be set according to a specific network environment.
  • the upper limit of the first theoretical delay can be set to 10 microseconds.
  • the upper limit of the first theoretical delay may be set to 100 microseconds.
  • the above-mentioned first transmission time is also a fixed value.
  • the first transmission delay may be 2 microseconds.
  • the first transmission delay may be 12 microseconds.
  • the first delay is a value not less than the absolute value of the difference between the first theoretical upper limit of the theoretical time and the first transmission time. Since the first transmission time is a fixed value, the first theoretical upper limit of the delay is It is also a predefined fixed value, so the first delay is also a fixed non-negative value.
  • the first reference moment can be understood as any moment when the data packet passes through the first network device.
  • the first reference time can be defined as the time when the data packet is output by the shaping structure of the first network device.
  • the first reference time can be defined as the time when the data packet is output by the first network device.
  • the first reference time can be defined as the time when the data packet enters the first network device.
  • the first reference time is a predefined time, and the predefined time can be any time when the data packet passes through the first network device a moment.
  • the header may be a media access control (MAC) header.
  • the header may also be an IP header (eg, an IPv4 header or an IPv6 header).
  • each time described in the above method 400 refers to an accurate time value by default, and each time includes: a first time, a second time, a third time, a first reference time, a second reference time, and a third time. Reference time, first output time, preset time, etc.
  • Concepts such as the remaining processing time (eg, the first remaining processing time), the theoretical upper limit of time (eg, the first theoretical upper limit of time) described in the above method 400 refer to the difference between these precise moment values.
  • the time precision that the second network device (for example, a router) can identify and express is limited, usually 1 ns or 2 ns, and the method for sending data packets provided in this embodiment of the present application may be based on this precision.
  • the accuracy of the moment is the same as the accuracy that the second network device can identify and express.
  • the actual occurrence time of the moment may also be any time within the precision range.
  • the precision that the second network device can identify and express is 1 ns
  • the precision of the moment is also 1 ns.
  • the transmission time 1 is 1 ⁇ s1ns
  • the actual time of the transmission time 1 may be any time from 1 ⁇ s1ns to 1 ⁇ s2ns, for example, 1 ⁇ s1.1ns or 1 ⁇ s1.99ns.
  • the precision of the moment may also be a preset precision range. For example, if the preset accuracy is 10 ⁇ s, the time accuracy is also 10 ⁇ s.
  • the actual occurrence time of the moment can be any time within the precision. Based on this, if the transmission time 1 is 13 ⁇ s, the actual time of the transmission time 1 may be any time from 13 ⁇ s to 23 ⁇ s, such as 15 ⁇ s, 16 ⁇ s or 18 ⁇ s.
  • any one of the moments described in the foregoing method 400 may also be represented by a predefined number.
  • time may be divided into multiple moments according to a predefined granularity, and each moment is represented by a number.
  • 24 hours can be divided into 1440 moments with a granularity of 1 minute, and each moment is represented by an Arabic numeral number, for example, the number 0 represents 0:00 to 0:1, and the number 1 represents 0:1 to 0:02, and so on.
  • the sending time 1 is 16
  • the actual time of sending time 1 can be any time from 0:16 to 0:17, such as 0:16:08, 0:16:31, 0:16 59 seconds etc.
  • a fine-grained precision is used to express time, that is, 1 ns granularity is used as the basic granularity of time.
  • the first moment may be 13 ⁇ s 0ns or 13 ⁇ s 0.2 ns or the like.
  • coarse-grained precision is used to express time in (b) of FIG. 5 , for example, each moment value in the period from 13 ⁇ s to 23 ⁇ s can be regarded as a same value (for example, 13 ⁇ s, 13 ⁇ s, 23 ⁇ s, or any time between 13 ⁇ s and 23 ⁇ s).
  • the coarse granularity of 10us is used as the basic granularity of time and numbered in order from small to large, and the number 0 is used to represent any moment in the period from 0 ⁇ s to 10 ⁇ s,
  • the number 1 represents any moment in the period of 10 ⁇ s to 20 ⁇ s (eg, 10 ⁇ s2ns, etc.), and the number 3 represents any moment in the period of 20 ⁇ s to 30 ⁇ s (eg, 25 ⁇ s, etc.).
  • the time information may include first indication information and second indication information, where the first indication information is used to indicate the first processing time, and the second indication information is used to indicate the first delay.
  • the first indication information includes a third time value and a fourth time value, the third time value is the first output moment when the data packet is output by the first network device, and the fourth time value is the first reference moment, see the format in FIG. 6 one.
  • the second network device may acquire the first processing time by calculation according to the fourth time value and the third time value in the format one.
  • the time information may include first indication information, where the first indication information is used to indicate the first processing time.
  • the first indication information includes a third time value and a fourth time value, the third time value is the first output moment when the data packet is output by the first network device, and the fourth time value is the first reference moment, see the format in FIG. 6 two.
  • the packet in format 2 in FIG. 6 does not carry the first delay
  • the second network device may obtain the first delay in other ways.
  • the second network device may acquire the first delay by delivering the control plane signaling.
  • the time information may include first indication information and second indication information, where the first indication information is used to indicate the first processing time, and the second indication information is used to indicate the first delay.
  • the first indication information includes a second time value, and the second time value is the first processing time, see format 3 in FIG. 6 .
  • the header corresponding to format 3 can directly carry the first processing time.
  • the time information may include first indication information, where the first indication information is used to indicate the first processing time.
  • the first indication information includes a second time value, and the second time value is the first processing time, see format 4 in FIG. 6 .
  • the header in format 4 does not carry the first delay
  • the second network device can obtain the first delay in other ways.
  • the second network device may acquire the first delay by delivering the control plane signaling.
  • the time information may include a first time value, where the first time value is the first remaining processing time, see format 5 in FIG. 6 .
  • the header in format five can directly carry the first remaining processing time.
  • the second network device may determine the second reference time in the uplink board of the second network device.
  • the second network device may also determine the second reference time in the downlink board of the second network device. It should also be understood that when the second reference time is determined in the uplink board of the second network device, the second network device may determine that the data packet enters the target queue in the uplink board according to the second reference time. When the second reference time is determined in the downlink board of the second network device, the second network device may determine that the data packet enters the target queue in the downlink board according to the second reference time.
  • the second network device determining the second reference time according to the time information carried in the data packet includes: the second network device determining the second reference time according to the first delay and the first processing time.
  • determining the second reference time by the second network device according to the first delay and the first processing time includes: the second network device determines the second reference time according to the first delay, the first reference time, and the first time that the data packet is output by the first network device. Once the output time and the first time are determined, the second reference time is determined.
  • the second network device determines the second reference time according to the first delay, the first reference time, the first output time and the first time when the data packet is output by the first network device, including: the second network device according to the following formula Determine the second reference moment:
  • E 2 is the second reference moment, for the first moment, is the first delay, is the first processing time, is the first output moment when the data packet is output by the first network device, E 1 is the first reference moment, is the first remaining processing time.
  • the first reference moment can be understood as any moment when the data packet passes through the first network device.
  • the first reference time can be defined as the time when the data packet is output by the shaping structure of the first network device.
  • the first reference time can be defined as the time when the data packet is output by the first network device.
  • the first reference time can be defined as the time when the data packet enters the first network device.
  • the first reference time is a predefined time, and the predefined time can be any time when the data packet passes through the first network device a moment.
  • FIG. 7 shows a sequence diagram of the second network device determining the second reference time on the uplink board according to the embodiment of the present application.
  • the network device 232 can be understood as the second network device that receives the data packet
  • the network device 233 can be understood as the third network device that receives the data packet.
  • E1 is the reference time for guiding the data packet to enter the queue in the queue system of the network device 232, that is, the first reference time
  • E2 is the reference moment that guides the data packet to enter the queue in the queue system of the network device 233, that is, the second reference moment
  • FIG. 7 is only for illustration and does not constitute any limitation to the embodiments of the present application.
  • the network device 233 in FIG. 7 may be the network device 234 in FIG. 2 .
  • network device 233 in FIG. 7 may be egress edge device 235 in FIG. 2 .
  • FIG. 8 shows a sequence diagram of another second network device determining the second reference time at the uplink board according to the embodiment of the present application. It should be understood that each moment shown in FIG. 8 is only for illustration and does not constitute any limitation to the present application.
  • the ingress edge device 231 can be understood as the first network device (ie, the first hop device) that receives the data packet
  • the network device 232 can be understood as the second network device that receives the data packet.
  • E1 is the time when the instruction data packet is output from the shaping structure of the ingress edge device 231, that is, an example of the first reference time
  • E2 is the reference moment that guides the data packet to enter the queue in the queue system of the network device 232, that is, the second reference moment
  • the first reference time E1 can be understood as the data packet passing through the ingress Any time at the edge device 231.
  • the first reference time can be defined as the time when the data packet is output by the shaping structure of the ingress edge device 231 .
  • the first reference time can be defined as the time when the data packet is output by the ingress edge device 231 .
  • the first reference time can be defined as the time when the data packet enters the ingress edge device 231 . That is to say, the first reference time at this time is a predefined time, and the predefined time may be any time when the data packet passes through the first network device.
  • the second network device determining the second reference time according to the time information carried in the data packet includes: the second network device determining the second reference time according to the first delay and the first processing time.
  • the second network device determines the second reference time in the downlink board according to the first delay and the first processing time, including the following two methods:
  • the second network device determines the second reference time according to the first delay and the first processing time, including: the second network device determines the second reference time according to the first delay, the first reference time, and the first output of the data packet output by the first network device. time and the first time to determine the second reference time.
  • the second network device determines the second reference time according to the first delay, the first reference time, the first output time and the first time when the data packet is output by the first network device, including: the second network The device determines the second reference moment according to the following formula:
  • E 2 is the second reference moment, for the first moment, is the first delay, is the first processing time, is the first output moment when the data packet is output by the first network device, E 1 is the first reference moment, is the first remaining processing time.
  • the first reference time can be understood as any time when the data packet passes through the first network device.
  • the first reference time can be defined as the time when the data packet is output by the shaping structure of the first network device.
  • the first reference time can be defined as the time when the data packet is output by the first network device.
  • the first reference time can be defined as the time when the data packet enters the first network device. That is to say, the first reference time at this time is a predefined time, and the predefined time may be any time when the data packet passes through the first network device.
  • the method for determining the second reference time in the above method 1 is the same as the method for determining the second reference time in the uplink board by the second network device.
  • the second network device determines the second reference time according to the first delay and the first processing time, including: the second network device determines the second reference time according to the first delay, the first reference time, and the first output of the data packet output by the first network device.
  • the time, the time after the data packet is processed by the switching fabric of the second network device, and the first time determine the second reference time, wherein the time after the data packet is processed by the switch fabric of the second network device is less than the second reference time.
  • the second network device is based on the first delay, the first reference time, the first output time when the data packet is output by the first network device, the time when the data packet is processed by the switch fabric of the second network device, and At the first moment, determining the second reference moment includes: the second network device determining the second reference moment according to the following formula:
  • E 2 is the second reference moment, is the moment after the data packet is processed through the switching fabric of the second network device,
  • E 1 is the first reference moment, for the first moment.
  • the first reference time can be understood as any time when the data packet passes through the first network device.
  • the first reference time may be the time when the data packet is output by the shaping structure of the first network device.
  • the first reference time may be the time when the data packet is output by the first network device.
  • the first reference moment may be the moment when the data packet enters the first network device. That is to say, the first reference time at this time is a predefined time, and the predefined time may be any time when the data packet passes through the first network device.
  • FIG. 9 shows a sequence diagram illustrating that the second network device determines the second reference moment in the downlink board according to the embodiment of the present application.
  • the functions of each unit or structure included in FIG. 9 can be referred to in FIG. 7 .
  • the circular queue unit and the dequeue unit shown in FIG. 9 are only logical unit structures. In practical applications, the circular queue unit and the dequeue unit may be included in the same physical unit. Alternatively, the circular queue unit and the dequeue unit may respectively correspond to two physical units.
  • the network device 232 can be understood as the second network device that receives the data packet
  • the network device 233 can be understood as the third network device that receives the data packet.
  • E1 is the reference time that directs the data packet to enter the queue in the queue system of the network device 232, that is, the first reference time
  • E 2 is the reference time that directs the data packet to enter the queue in the queue system of the network device 233, that is, the second reference time
  • FIG. 9 is only for illustration and does not constitute any limitation to the embodiments of the present application.
  • the network device 233 in FIG. 9 may be the network device 234 in FIG. 2 .
  • network device 233 in FIG. 9 may be egress edge device 235 in FIG. 2 .
  • FIG. 10 shows a sequence diagram of another second network device determining the second reference moment on the downlink board according to the embodiment of the present application.
  • the functions of each unit or structure included in FIG. 10 can be referred to in FIG. 8 .
  • each moment shown in FIG. 10 is only for illustration and does not constitute any limitation to the present application.
  • the circular queue unit and the dequeue unit shown in FIG. 10 are only logical unit structures. In practical applications, the circular queue unit and the dequeue unit may be included in the same physical unit. Alternatively, the circular queue unit and the dequeue unit may respectively correspond to two physical units.
  • the ingress edge device 231 can be understood as the first network device that receives the data packet, and the ingress edge device 231 can be understood as the second network device that receives the data packet.
  • the moment when the ingress edge device 231 receives the data packet sent from the previous hop network device is the time when the data packet enters the shaping structure of the ingress edge device 231;
  • E 1 is the time when the instruction data packet is output from the shaping structure of the ingress edge device 231, that is, an example of the first reference time; is the first output moment when the data packet is output by the ingress edge device 231; is the moment when the network device 232 receives the data packet sent by the ingress edge device 231, that is, the first moment; is the time when the data packet is output by the switching structure of the network device 232;
  • E 2 is the reference time that directs the data packet to enter the queue in the queue system of the network device 232, that is, the second reference time; is the second output moment when the data packet is output by the network device 232
  • the first reference time E1 can be understood as the data packet passing through the ingress Any time at the edge device 231.
  • the first reference time can be defined as the time when the data packet is output by the shaping structure of the ingress edge device 231 .
  • the first reference time can be defined as the time when the data packet is output by the ingress edge device 231 .
  • the first reference time can be defined as the time when the data packet enters the ingress edge device 231 . That is to say, the first reference moment at this time is a predefined moment, and the predefined moment may be any moment when the data packet passes through the ingress edge device 231 .
  • Step 430 the second network device determines a target queue from the plurality of queues included in the second queue system according to the second reference time and adds the data packet to the target queue.
  • the second network device may determine that the data packet enters the target queue in the uplink board according to the second reference time.
  • the second network device may determine that the data packet enters the target queue in the downlink board according to the second reference time.
  • the plurality of queues included in the second queuing system correspond to the plurality of preset times in one-to-one correspondence, and the difference between any two adjacent preset times in the plurality of preset times is the first value, and the preset times may be It is understood as the moment when the queue is opened.
  • the first value may be a predefined value.
  • the first value may be set according to a specific application scenario or device capability.
  • the first value can be set to 10 microseconds.
  • the first value can be set to 15 microseconds.
  • FIG. 11 shows a schematic diagram of a second queue system provided by an embodiment of the present application.
  • the second queue system includes M queues, which are queue Q1, queue Q2, queue Q3, ..., queue QM, where M is a positive integer greater than 3.
  • M is a positive integer greater than 3.
  • the M queues are in one-to-one correspondence with the M preset moments.
  • the priority of queue Q1 is higher than the priority of queue Q2, the priority of queue Q2 is higher than the priority of queue Q3, and so on.
  • the time interval between any two adjacent queues from queue Q1 to queue QM is ⁇ (ie, the first value).
  • the preset time corresponding to queue Q1 is T+ ⁇
  • the preset time corresponding to queue Q2 is T+2 ⁇
  • the preset time corresponding to queue Q3 is T+3 ⁇ .
  • the preset time corresponding to the queue QM is T max .
  • the M queues may also be circular queues, and after the system time exceeds the time Tmax , the M queues continue to circulate at time intervals ⁇ .
  • the time interval between the preset time corresponding to the queue Q1 and the preset time corresponding to the queue QM is ⁇ , in other words, the preset time corresponding to the queue Q1 is T max + ⁇ .
  • the time interval between the preset time corresponding to the queue Q2 and the preset time corresponding to the queue Q1 is ⁇ , in other words, the preset time corresponding to the queue Q2 is T max +2 ⁇ , and so on.
  • the second network device determines the target queue from the plurality of queues included in the second queuing system according to the second reference time, including:
  • the second network device determines that one of the multiple queues included in the second queue system corresponding to the first target time is the target queue, and the first target time is the sum of the second reference time and the second value,
  • the second value is the absolute value of the difference between the second reference time and the third time plus an integer multiple of the first value.
  • the second reference time and the third time do not include any one of the preset time.
  • the third time is one of a plurality of preset times and the third time is greater than the second reference time, and the first target time is one of the plurality of preset times.
  • the first value is ⁇
  • the second reference time E 2 T+1.5 ⁇
  • the third time is T+2 ⁇ .
  • the second value is the absolute value of the difference between the second reference moment and the third moment plus an integer multiple of the first value.
  • the second value is the absolute value of the difference between the second reference moment and the third moment plus the first value.
  • the first value is ⁇
  • the second reference time E 2 T+1.5 ⁇ .
  • the second value is
  • the target queue is queue Q2.
  • n times the above-mentioned first value is the same value for each data packet included in the same flow received by the second network device. That is to say, n is a fixed value at this time.
  • FIG. 11 is only for illustration and does not constitute any limitation to the method for determining the target queue according to the second reference time provided in the present application.
  • the remaining processing time of the data packet passing through the previous hop of the second network device ie the first remaining processing time of the data packet passing through the first network device is consumed in the second network device.
  • the second queue system may include N first-level queues and M second-level queues, where N and M are positive integers greater than or equal to 1.
  • the N first-level queues correspond to the N first preset moments
  • the M second-level queues correspond to the M second preset moments.
  • the difference between any two adjacent first preset times is the first value
  • the difference between any two adjacent second preset times is the second value
  • the first value is smaller than the second value.
  • the priority of any first-level queue is higher than the priority of any second-level queue.
  • the second network device determines the target queue according to the second reference time, including:
  • the second network device determines that the data packet enters one of the multiple queues included in the second queuing system according to the second reference time, the N first preset times, and the M second preset times.
  • the second network device determines that the data packet can enter both one of the N first-level queues and one of the M second-level queues at a certain moment, the second network device determines that the data packet can enter either one of the N first-level queues or one of the M second-level queues The data packet enters one of the M secondary queues.
  • the second network device sends data packets to the third network device in one of the N first-level queues. That is, if the second network device determines to add the data packet to one of the M secondary queues, the second network device will also remove the data packet from the M secondary queues where the data packet is located after that. dequeues one of the queues in and adds the packet to one of the N first-level queues.
  • the method for the second network device to determine that the data packet is dequeued includes:
  • the second network device determines a method for sending data packets from one of the N first-level queues to the third network device. Specifically, the second network device may send the data packet to the third network device according to the scheduling rules corresponding to the N first-level queues.
  • the scheduling rules corresponding to the N first-level queues may be predefined scheduling rules.
  • the scheduling rules corresponding to the N first-level queues may also be scheduling rules related to queue priorities. This application does not limit this.
  • the second network device determines a method for dequeuing and enqueuing a data packet from one of the M secondary queues to one of the N primary queues. Specifically, after the secondary queue to which the data packet is added is enabled, the second network device may dequeue the data packet from the secondary queue to which the data packet is added and add it to N primary queues according to the second reference time. of a queue.
  • N first-level queues are one circular queue
  • M second-level queues are another circular queue. That is to say, the round-robin manner of the N first-level queues and the round-robin manner of the M second-level queues do not affect each other.
  • Step 440 the second network device sends the data packet to the third network device according to the scheduling rule corresponding to the second queuing system.
  • the time information includes the first processing time (see format 4 in FIG. 6 ), before step 440, it further includes:
  • the second network device updates the first processing time carried in the header of the data packet. Specifically, the first processing time carried in the header of the data packet is updated as the difference between the first output time when the data packet is output by the second network device and the second reference time.
  • Also includes:
  • the second network device updates the first output time when the data packet carried in the data packet header is output by the first network device to the second output time when the data packet is output by the second network device, and updates the first reference time carried in the data packet header Update to the second reference moment.
  • the second network device sends the data packet to the third network device according to the scheduling rule corresponding to the second queuing system, including:
  • the second network device determines that the target queue is the queue currently scheduled among the multiple queues included in the second queue system, and the target queue is in an open state, and the second network device sends the data packet to the third network device.
  • the method further includes:
  • the second network device determines to close the target queue when the target queue satisfies the first preset condition.
  • the first preset condition includes: the target queue is an empty queue, and the opening duration of the target queue is greater than or equal to a first value, the first value is the difference between any two adjacent preset moments in a plurality of preset moments, and a plurality of The preset time is in one-to-one correspondence with the multiple queues included in the second queue system.
  • the first value is a predefined value.
  • the first value may be set according to a specific application scenario or device capability. For example, the first value can be set to 10 microseconds. Alternatively, the first value can be set to 15 microseconds.
  • the second network device determines that the target queue is a queue that is currently scheduled among multiple queues included in the second queue system, including:
  • the second network device determines that the target queue is the queue with the highest priority among the queues included in the second queue system, determines that the target queue is the queue currently scheduled among the multiple queues included in the second queue system ;
  • the method further includes:
  • the second network device sets the priority of the target queue to the queue with the lowest priority among the plurality of queues included in the second queue system, and sets the priority of the queues other than the target queue among the plurality of queues included in the second queue system promote.
  • the network device schedules the queues included in the second queue system according to strict priorities. In other words, the network device schedules the queues included in the second queuing system according to the priority order. If the data packets in the queues with higher priority have not been scheduled, the network device will not start scheduling the next priority queues. packets in the queue. It should also be understood that in the event that the high priority queue is emptied but the high priority queue has not been closed, the network device may start scheduling packets in the next highest priority queue.
  • the second queue system includes three queues, namely queue 1 (priority 1), queue 2 (priority 2), and queue 3 (priority 3), where priority 1>priority 2>priority Level 3. Since queue 1 has the highest priority, the second network device may determine queue 1 as the target queue. After the second network device has completed scheduling all data packets in queue 1 and the opening duration of queue 1 satisfies the preset condition, the second network device closes queue 1, and at the same time, the second network device prioritizes queue 2 The priority is set to 1, the priority of queue 3 is set to 2, and the priority of queue 1 is set to 3. In the above data packet scheduling process, after the second network device has completed scheduling all data packets in queue 1 and queue 1 has not been closed, the second network device may start to schedule data in queue 2 Packets are scheduled.
  • the multiple queues included in the second queue system correspond to multiple preset scheduling sequences one-to-one, and the second network device determines that the target queue is the one scheduled at the current moment among the multiple queues included in the second queue system.
  • Queue including:
  • the second network device determines that the preset scheduling sequence corresponding to the target queue is the scheduling sequence corresponding to the queue scheduled by the second network device at the current moment according to the multiple preset scheduling sequences, the second network device determines that the target queue is the second queue system The queue that is scheduled at the current moment among the multiple queues included.
  • the network device can schedule the queues included in the second queuing system according to a predefined scheduling sequence, and the network device does not need to compare the priorities of each queue during the specific queue scheduling process.
  • the method further includes:
  • the second network device determines a second target time according to the first information, the second target time corresponds to the target queue, the second target time is the opening time corresponding to the target queue after the first target time, and the second target time is greater than a plurality of Any one of the preset moments, the first information includes the scheduling sequence corresponding to each queue included in the second queuing system and the opening moment corresponding to each queue included in the second queuing system;
  • the multiple queues included in the second queue system correspond one-to-one with multiple preset times, the difference between any two adjacent preset times in the multiple preset times is the first value, and the second value corresponding to the first target time
  • One of the multiple queues included in the queue system is the target queue
  • the first target time is the sum of the second reference time and the second value
  • the second value is the absolute value of the difference between the second reference time and the third time plus the third time.
  • Integer multiple of the first value, the second reference time and the third time do not include any one of the multiple preset times
  • the third time is one of the multiple preset times and the third time is greater than the second time.
  • the first target time is one of a plurality of preset times. Specifically, for the method of determining the second value and the third moment, refer to step 430, which will not be described in detail here.
  • the start time corresponding to each queue included in the second queue system may be predefined.
  • the scheduling sequence corresponding to each queue included in the second queue system may be predefined.
  • the second network device can recycle each queue included in the second queue system, thereby improving resource utilization.
  • FIG. 12 is only for illustration and does not constitute any limitation to the present application.
  • the network device included in FIG. 7 can also be used to analyze the delay after the data packet is forwarded by the first network device and the second network device.
  • the first reference time E1 can be understood as the data packet passing through the Any time when entering the edge device 231.
  • the first reference time can be defined as the time when the data packet is output by the shaping structure of the ingress edge device 231 .
  • the first reference time can be defined as the time when the data packet is output by the ingress edge device 231 .
  • the first reference time can be defined as the time when the data packet enters the ingress edge device 231 .
  • the first reference moment at this time is a predefined moment
  • the predefined moment may be any moment when the data packet passes through the ingress edge device 231 .
  • FIG. 12 only the time when the data packet is output by the ingress edge device 231 at the first reference time E1 is used as an example for description.
  • the network device 232 According to the method for sending a data packet provided by the present application, in the case where the remaining processing time of the data packet after being forwarded by the ingress edge device 231 is greater than zero, after the data packet enters the network device 232, the network device 232 according to the remaining processing time and When the network device 232 receives the data packet, it is determined that the data packet is enqueued into a queue of the network device 232 . Taking the time when the data packet enters a queue of the network device 232 as the starting time, after a period of time to the second reference time corresponding to the data packet, the remaining processing time is consumed in the network device 232 . Therefore, the deterministic delay after the data packet is forwarded by the ingress edge device 231 and the network device 232 is
  • the network device 232 uses the method for sending data packets provided by the present application to each data packet included in the received flow, it can be ensured that the flow in which the data packet is located enters the network device 232 and is output by the network device 232 in the same shape.
  • the second network device may determine the remaining processing time of the data packet in the first network device according to the maximum delay allowed to stay in the first network device for the data packet configured in advance , in the case that the remaining processing time is greater than zero, the moment when the data packet enters a queue in the second network device (that is, an example of the target queue) is the starting moment, and after a period of time, the data packet corresponding to the Until the second reference time, the remaining processing time is consumed in the second network device, so that the deterministic delay and jitter of the data packet after being forwarded by the first network device and the second network device can be guaranteed, and the data packet can be further ensured.
  • the shape of the flow in which the packet is entered into the network device is the same as the shape of the flow in which the packet is output by the network device.
  • the method for sending data packets does not require the time synchronization of each network device that forwards data packets, and does not specifically limit the link length for forwarding data packets, which can be applied to large-scale networks. , provides a deterministic end-to-end delay cap and a jitter cap.
  • FIG. 13 shows a specific embodiment of the method for sending a data packet provided by an embodiment of the present application.
  • the method includes steps 1210 to 1250, which will be described in detail below.
  • FIG. 13 is for illustration only, and does not constitute any limitation to the present application.
  • each moment shown in FIG. 14 is only for illustration, and does not constitute any limitation to the present application.
  • E 1 in FIG. 14 may also be the moment when the data packet is output by the ingress edge device 231 .
  • E 1 in FIG. 14 may also be the moment when the data packet enters the ingress edge device 231 .
  • step 1210 the ingress edge device 231 obtains the data stream 1 and performs shaping processing on the data stream 1.
  • the ingress edge device 231 can use the leaky bucket algorithm to perform shaping processing on the data stream 1, so that the shaped data stream 1 satisfies the following formula:
  • t is time; A 1 (t) is the total data flow of data stream 1 within t time; r 1 is the bandwidth required by data stream 1, B 1 is the maximum burst degree of data stream 1; r 1 is the average bandwidth , the average bandwidth can be understood as the average speed of data stream 1 in the statistical sense.
  • Step 1220 the ingress edge device 231 sends the data packet carrying the time information 1 to the network device 232 .
  • the ingress edge device 231 is also included to determine the time information 1.
  • the time information 1 is used to indicate the remaining processing time of the data packet in the ingress edge device 231 .
  • the time information 1 may include the time when the data packet is output from the shaping structure of the ingress edge device 231 and the output time when the data packet is output by the ingress edge device 231, and the time information 1 is encapsulated in the header of the data packet.
  • the reference time 1 can be used to represent the time when the data packet is output from the shaping structure of the ingress edge device 231. Since the ingress edge device 231 is the first network device (ie, the first hop device) to receive the data packet, the reference time 1 is a predefined moment.
  • the time information 1 includes E 1 and E 1 is the moment when the data packet is output from the shaping structure of the ingress edge device 231, is the output time when the data packet is output by the ingress edge device 231 .
  • Step 1230 the network device 232 determines the target queue 1 according to the time information 1 carried in the received data packet.
  • the network device 232 determines the target queue 1 according to the time information 1 carried in the received data packet, including:
  • the network device 232 determines the reference time 2 according to the time information 1 carried in the data packet; and the network device 232 determines the target queue 1 according to the reference time 2 .
  • the reference time 2 is a reference time for directing the data packet to enter the queue in the queue system of the network device 232 .
  • the delay 1 is the time between the time when the data packet is output from the shaping structure of the ingress edge device 231 to the reference time 2 (excluding the data packet The time between the time it is output by the ingress edge 231 and the time the packet is received by the network device 232).
  • the delay 1 can also be understood as, starting from the moment when the data packet is output from the shaping structure of the ingress edge device 231, after the delay 1 (excluding the time when the data packet is output by the ingress edge 231 to After the data packet is received by the network device 232 ), the data packet must be enqueued to one of the multiple queues included in the queue system of the network device 232 .
  • the delay 1 is a predefined value.
  • network device 232 may determine reference time 2 according to the following formula:
  • E 2 is the reference time 2
  • E 1 is the moment after the data packet has been processed through the switching fabric of the network device 232
  • is delay 1 is the moment when the data packet is output by the first network device
  • E 1 is the reference moment 1
  • the network device 232 can determine the target queue 1 on the downlink board of the network device 232 according to the reference time 1.
  • the specific method for determining the target queue 1 is the same as the method for determining the target queue in step 430, and details are not described here.
  • the moment when the network device 232 receives the data packet sent by the network device 231 and enters a queue (ie, target queue 1) in the network device 232 is the starting moment, and after a period of time it reaches the reference moment. 2, the remaining processing time of the data packet passing through the network device 231 is consumed in the network device 232.
  • Step 1240 the network device 232 sends the data packet carrying the time information 2 to the network device 232.
  • the network device 232 Before step 1240, the network device 232 also determines the time information 2, and updates the time information 1 carried in the data packet header to the time information 2.
  • the time information 2 may include the reference time 2 and the time when the data packet is output by the network device 232 .
  • the time information carried in the data packet is time information 2 .
  • the network device 232 may The data packet carrying the time information 2 is sent to the network device 232 .
  • step 1250 the network device 233 determines the target queue 2 according to the time information 2 carried in the received data packet.
  • the network device 233 determines the target queue 2 according to the time information 2 carried in the received data packet, including:
  • the network device 233 determines the reference time 3 according to the time information 2 carried in the data packet; and the network device 232 determines the target queue 2 according to the reference time 3 .
  • the reference time 3 is a reference time for guiding the data packet to enter the queue in the queue system of the network device 233 .
  • the network device 233 Before determining the reference time 3, it also includes that the network device 233 obtains the delay 2 through the control plane, and the delay 2 is the time between the reference time 2 and the reference time 3 (excluding the time when the data packet is output by the network device 232 to the data packet). time between moments received by network device 233).
  • the delay 2 can also be understood as, starting from the moment when the data packet enters the switching structure of the network device 232, after the delay 2 (excluding the time when the data packet is output by the network device 232 to the data packet After the packet is received by the network device 233 ), the data packet must be dispatched to one of a plurality of queues included in the queue system of the network device 233 .
  • the delay 2 is a predefined value.
  • the network device 233 may determine the reference time 3 according to the following formula:
  • E 3 is the reference time 3
  • E 2 is the reference time 2
  • E 3 is the moment after the data packet is processed through the switching fabric of the network device 233
  • E2 is the reference time 2
  • the network device 233 may determine, on the downlink board of the network device 233, one of the multiple queues of the network device 233 as the target queue 2.
  • the specific method for determining the target queue 2 is the same as the method for determining the target queue in step 430. The method is the same and will not be described in detail here.
  • the moment when the network device 233 receives the data packet sent by the network device 232 and enters a queue (ie, the target queue 2) in the network device 233 is the starting moment, and after a period of time reaches the reference moment. 3, the remaining processing time of the data packet passing through the network device 232 is consumed in the network device 233.
  • the fixed delay for forwarding the data packet is the sum of the delay 1, the delay 2, the delay 3 and the delay 4.
  • the delay 3 is the time between the data packet being received by the ingress edge device 231 and the reference time 1 (that is, the time delay in FIG. 14 ).
  • the delay 4 is the time between the reference time 3 and the time when the data packet is output by the network device 233 (ie, the time in FIG. 14 ).
  • the above delay 1, delay 2, delay 3 and delay 4 are predefined values. For example, delay 1, delay 2, delay 3, and delay 4 can all be set to 12 microseconds.
  • the method for sending data packets provided by the embodiments of the present application can ensure that the upper bound of the end-to-end delay of any flow does not exceed the sum of delay 1, delay 2, delay 3 and delay 4.
  • the method for sending a data packet provided by the embodiment of the present application can ensure the deterministic delay and jitter after the data packet is forwarded through the ingress edge device 231, the network device 232 and the network device 233, and further enables the flow of the data packet to enter the network device
  • the shape of the packet is the same as the shape of the stream in which the packet is output by the network device.
  • the method for sending data packets does not require time synchronization of each network network device that forwards data packets, and does not specifically limit the link length for forwarding data packets. In large-scale networks, it provides deterministic end-to-end latency and jitter caps.
  • each network device determines the reference time in the downlink board and determines the destination queue of the data packet into the downlink board according to the reference time as an example to introduce this.
  • the method for sending data packets provided by the application does not constitute any limitation to this application.
  • the data packet may also be forwarded through more (eg, 5 network devices or 10 network devices, etc.) or less network devices (eg, 2 network devices) and so on.
  • FIG. 15 shows the functional modules of the second network device provided by the implementation of this application.
  • the second network device may include 6 functional modules.
  • the 6 functional modules are: time information capture module (packet arrival time capture), bounded Delay module (bounded variable delay units), header update module (damper header update unit), delay equalizer module (latency equalizer), queuing subsystem (queueing subsystem) and header insertion module (damper header insertion unit).
  • Time information capture module packet arrival time capture: used to acquire the time information and reference time (eg, the first reference time or the second reference time) in the method 400 .
  • Bounded delay module used for data packet analysis, table lookup, switching network forwarding, etc. Wherein, any one of the above-mentioned processing of data packets has a predictable upper bound of the maximum delay.
  • time information capturing module and the bounded delay module are jointly used to acquire the time information and the reference time in the method 400 .
  • Header update module used to update the time information carried in the data packet (that is, the time information in the method 400).
  • Delay equalizer module used to wait a certain time for the data packet entering the network device and add the data packet to the queue of the network device. Specifically, the network device implements active waiting of data packets through a cyclic gating scheduling method. After the data packet passes through the latency equalizer, the data packet shaping can be completed.
  • Queuing subsystem used for queuing management of multiple queues included in network devices.
  • Header insertion module used to transfer the time information related to the network device (ie, the time information in the method 400 ) before the data packet is output by the network device to the next-hop network device of the network device. Insert into the header of the packet.
  • FIG. 16 shows the functional modules of the network device for sending data packets provided by the implementation of this application.
  • network device #1 As shown in FIG. 16 , three network devices are included, namely, network device #1, network device #2, and network device #3.
  • Network device #1 and network device #3 include all functional modules included in the second network device in FIG. 15 .
  • the network device #2 only includes the 4 functional modules included in the second network device in FIG. 15.
  • the 4 functional modules are the time information capture module (packet arrival time capture), bounded time Extension module (bounded variable delay units), queuing subsystem (queueing subsystem) and header insertion module (damper header insertion unit).
  • the maximum delay that a packet may experience in network device 1 is The maximum delay that a packet may experience in network device 2 is The maximum delay that a packet may experience in network device 3 is And the data packet has been marked by its previous hop device before entering the network device 1 and the remaining processing time of the data packet in the previous hop device.
  • the network device 1 processes the received data packet according to the method for sending a data packet provided in the embodiment of the present application, and the network device 1 sends the data packet to the network device 2 after a preset condition is satisfied.
  • the network device 2 After receiving the data packet sent by the network device 1, the network device 2 continues to process the data packet according to the method for sending a data packet provided by the embodiment of the present application. However, since the functional module of the network device 2 does not have a latency equalizer, the network device 2 can only forward the data packets according to the default scheduling method.
  • the data can be determined by the time information capture module (packet arrival time capture) in the network device 2
  • the processing time of the packet passing through the network device 2 (for example, the processing time may be the time between the time when the data packet enters the switching fabric of the network device 2 to the time when the data packet is output by the network device 2), and uses the header insertion module ( damper header insertion unit) inserts the processing time into the header of the data packet, and then the network device 2 sends the data packet to the network device 3 after a preset condition is met.
  • the time information carried by the data packet is used to indicate the sum of the remaining processing time of the data packet passing through network device 1 and the remaining processing time of the data packet passing through network device 2.
  • the network device 3 After receiving the data packet sent by the network device 2, the network device 3 processes the data packet in the network device 3 according to the method for sending a data packet provided by the embodiment of the present application according to the time information carried by the data packet.
  • the time that the data packet actively waits in the network device 3 includes the sum of the remaining processing time of the data packet passing through the network device 1 and the remaining processing time of the data packet passing through the network device 2 .
  • the function of actively waiting for data packets can be implemented in some network devices (network device #1 and network device #3), and the ability to obtain time information can be implemented on all network devices, thereby ensuring end-to-end determination. latency and jitter.
  • FIG. 17 shows the functional modules of the network device for sending data packets provided by the implementation of this application.
  • network device #1 As shown in FIG. 17 , three network devices are included, namely, network device #1, network device #2, and network device #3.
  • Network device #1 and network device #3 include all functional modules included in the second network device in FIG. 15 .
  • Network device #2 only includes two functional modules included in the second network device in Figure 15. According to the order in which each module processes data packets, the two functional modules are bounded variable delay modules and queuing sub-modules in turn. System (queueing subsystem).
  • the maximum delay that a packet may experience in network device 1 is The maximum delay that a packet may experience in network device 2 is The maximum delay that a packet may experience in network device 3 is And before the data packet enters the network device 1, the remaining processing time of the data packet in the previous hop device has been marked by its previous hop device.
  • the network device 1 processes the received data packet according to the method for sending a data packet provided in the embodiment of the present application, and the network device 1 sends the data packet to the network device 2 after a preset condition is satisfied.
  • the network device 2 After receiving the data packet sent by the network device 1, the network device 2 schedules the data packet according to a method predefined in the network device 2.
  • the time information carried by the data packet is used to indicate the remaining processing time of the data packet passing through the network device 1 .
  • the network device 3 After receiving the data packet sent by the network device 2, the network device 3 processes the data packet in the network device 3 according to the method for sending a data packet provided by the embodiment of the present application according to the time information carried by the data packet.
  • the time that the data packet actively waits in the network device 3 is the remaining processing time of the data packet passing through the network device 1 .
  • the traffic shape of any flow after it leaves the "latency equalization" module of the network device 1 can be determined, which is exactly the same as the traffic shape when the arbitrary flow enters the network device 1 . Since we also know the traffic characteristics of all flows passing through network device 1 and network device 2, we can know the specific shape of the arbitrary flow after passing through the queuing subsystem of network device 1 and after passing through network device 2, so It is also possible to calculate an upper bound on the worst delay of the arbitrary flow on the network device 3 .
  • the function of actively waiting for data packets and the ability to obtain time information can be implemented in some network devices (network device #1 and network device #3), thereby ensuring end-to-end deterministic delay and jitter.
  • the shape of a stream after passing through the latency equalizer of the network device 3 is compared with the shape of the stream after passing through the latency equalizer of the network device 1, and the burst degree changes. big.
  • the upper bound of the delay of the data packet passing through the network device 3 becomes larger, so that the upper limit of the end-to-end delay and the upper limit of the jitter become larger.
  • FIG. 18 shows a schematic structural diagram of a second network device 1700 provided by an embodiment of the present application.
  • the second network device 1700 includes: a transceiver unit 1710 and a processing unit 1720 .
  • the transceiver unit 1710 and the processing unit 1720 communicate with each other through an internal connection path to transmit control and/or data signals.
  • a transceiver unit 1710 configured to receive a data packet sent by the first network device at the first moment
  • the processing unit 1720 is configured to determine a second reference time according to the time information carried by the data packet, where the second reference time is a reference time for instructing the data packet to enter the queue in the second queuing system, and the second queuing system is In the queue system of the second network device, the time information is used to indicate the first remaining processing time of the data packet passing through the first network device, where the first remaining processing time is the difference between the first delay and the first processing time,
  • the first delay is a value not less than the absolute value of the difference between the first theoretical upper limit of time and the first transmission time, the first theoretical upper limit of time is the upper limit of the theoretical processing time from the first reference time to the second reference time, the The first reference time is the reference time for directing the data packet to enter the queue in the first queue system, the first queue system is the queue system of the first network device, and the first transmission time is when the data packet is sent by the first network
  • the actual transmission time from the first output time output by the device to the first time, and the first processing time is the
  • the processing unit 1720 is further configured to determine a target queue from a plurality of queues included in the second queue system according to the second reference time and add the data packet to the target queue;
  • the processing unit 1720 is further configured to send the data packet to the third network device according to the scheduling rule corresponding to the second queuing system.
  • the multiple queues included in the second queue system correspond one-to-one with multiple preset times, and the difference between any two adjacent preset times in the multiple preset times is the first. value, the processing unit 1720 is also used to:
  • the second reference time one of the queues included in the second queue system corresponding to the first target time is determined as the target queue, and the first target time is the sum of the second reference time and the second value , the second value is the absolute value of the difference between the second reference time and the third time plus an integer multiple of the first value, and the second reference time and the third time do not include the plurality of preset times At any moment in the first target moment, the first target moment is one moment in the plurality of preset moments.
  • the processing unit 1720 is further configured to: determine the second reference time according to the first delay and the first processing time.
  • the processing unit 1720 is further configured to: according to the first delay, the first reference time, the first output time when the data packet is output by the first network device, and the first time, the second reference time is determined.
  • the processing unit 1720 is further configured to: determine the second reference moment according to the following formula:
  • E 2 is the second reference moment, for this first moment, is the first delay, is the first output time when the data packet is output by the first network device, and E 1 is the first reference time.
  • processing unit 1720 is further configured to:
  • the first reference time the first output time when the data packet is output by the first network device, the time when the data packet is processed by the switch fabric of the second network device, and the first time , and determine the second reference time, wherein the time after the data packet is processed by the switching fabric of the second network device is less than the second reference time.
  • the processing unit 1720 is further configured to: determine the second reference moment according to the following formula:
  • E 2 is the second reference moment, is the moment after the data packet is processed through the switching fabric of the second network device, is the first delay, is the first output moment when the data packet is output by the first network device, E 1 is the first reference moment, for the first moment.
  • the time information includes a first time value, and the first time value is the first remaining processing time.
  • the time information includes first indication information, where the first indication information is used to indicate the first processing time.
  • the first indication information includes a second time value, and the second time value is the first processing time.
  • the first indication information includes a third time value and a fourth time value
  • the third time value is a first output moment when the data packet is output by the first network device
  • the third time value is Four time values are the first reference time.
  • the time information further includes second indication information, where the second indication information is used to indicate the first delay.
  • the processing unit 1720 is further configured to: determine that the target queue is a queue that is currently scheduled among the multiple queues included in the second queue system, and that the target queue is in an open state;
  • the transceiver unit 1710 is further configured to: send the data packet to the third network device according to the scheduling rule corresponding to the second queuing system.
  • the processing unit 1720 is further configured to: determine to close the target queue when the target queue satisfies the first preset condition.
  • the processing unit 1720 is further configured to: determine a second target time according to the first information, the second target time corresponds to the target queue, and the second target time is at the first target The opening time corresponding to the target queue after the time, the second target time is greater than any one preset time in a plurality of preset times, and the first information includes the scheduling sequence corresponding to each queue included in the second queue system and the corresponding opening time of each queue included in the second queue system;
  • the plurality of queues included in the second queuing system correspond to the plurality of preset times in one-to-one correspondence
  • the difference between any two adjacent preset times in the plurality of preset times is a first value
  • the first target time One of the queues included in the corresponding second queue system is the target queue
  • the first target time is the sum of the second reference time and a second value
  • the second value is the second reference time and the second value.
  • the absolute value of the difference at the third moment plus the integer multiple of the first value, the second reference moment and the third moment do not include any moment in the plurality of preset moments
  • the first target moment is a moment in the plurality of preset moments.
  • processing unit 1720 is further configured to:
  • the target queue is the queue with the highest priority among the multiple queues included in the second queuing system, determining that the target queue is the queue currently scheduled among the multiple queues included in the second queuing system;
  • multiple queues included in the second queue system correspond to multiple preset scheduling sequences one-to-one
  • the processing unit 1720 is further configured to: determine the target according to the multiple preset scheduling sequences When the preset scheduling sequence corresponding to the queue is the scheduling sequence corresponding to the queue scheduled by the second network device at the current moment, it is determined that the target queue is the queue scheduled at the current moment among the multiple queues included in the second queue system.
  • the first preset condition includes: the target queue is an empty queue, and the opening duration of the target queue is greater than or equal to a first value, and the first value is any one of a plurality of preset moments.
  • the difference between two adjacent preset times, the multiple preset times are in one-to-one correspondence with multiple queues included in the second queuing system.
  • FIG. 19 shows a schematic diagram of a hardware structure of a second network device 2000 provided by an embodiment of the present application.
  • the second network device 2000 shown in FIG. 19 may perform the corresponding steps performed by the second network device in the method of the foregoing embodiment.
  • the second network device 2000 includes a processor 2001 , a memory 2002 , an interface 2003 and a bus 2004 .
  • the interface 2003 may be implemented in a wireless or wired manner, and may specifically be a network card.
  • the above-mentioned processor 2001 , memory 2002 and interface 2003 are connected through a bus 2004 .
  • the interface 2003 may specifically include a transmitter and a receiver, which are used for the second network device to implement the above-mentioned transceiving.
  • the interface 2003 is configured to receive the data packet sent by the first network device at the first moment; and is also configured to send the data packet to the third network device according to the scheduling rule corresponding to the second queuing system.
  • the processor 2001 is configured to execute the processing performed by the second network device in the foregoing embodiment.
  • the processor is configured to determine a second reference time according to the time information carried by the data packet; and is further configured to determine a target queue from a plurality of queues included in the second queuing system according to the second reference time, and The data packet is added to the target queue; further used for sending the data packet to a third network device according to a scheduling rule corresponding to the second queuing system; and/or for other processes of the techniques described herein.
  • the memory 2002 includes an operating system 20021 and an application program 20022, which are used to store programs, codes or computer-executed instructions.
  • the memory 2002 may include read-only memory (ROM) and random access memory (RAM).
  • ROM read-only memory
  • RAM random access memory
  • the ROM includes a basic input/output system (basic input/output system, BIOS) or an embedded system
  • BIOS basic input/output system
  • the RAM includes an application program and an operating system.
  • BIOS basic input/output system
  • the second network device 2000 needs to be run, the system is booted through the BIOS solidified in the ROM or the bootloader in the embedded system to boot the second network device 2000 into a normal operation state. After the second network device 2000 enters the normal running state, the application program and the operating system running in the RAM, thus, the processing process involving the second network device 2000 in the method embodiment is completed.
  • FIG. 19 only shows a simplified design of the second network device 2000 .
  • the second network device may contain any number of interfaces, processors or memories.
  • Embodiments of the present application further provide a computer-readable medium, where program codes are stored in the computer-readable medium, and when the computer program codes are run on a computer, the computer can execute the methods in the above aspects.
  • These computer-readable storages include, but are not limited to, one or more of the following: read-only memory (ROM), programmable ROM (PROM), erasable PROM (erasable PROM, EPROM), Flash memory, electrical EPROM (electrically EPROM, EEPROM) and hard drive (hard drive).
  • An embodiment of the present application further provides a chip system, which is applied to a second network device.
  • the chip system includes: at least one processor, at least one memory, and an interface circuit, where the interface circuit is responsible for information between the chip system and the outside world interaction, the at least one memory, the interface circuit and the at least one processor are interconnected by a line, and the at least one memory stores computer-executable instructions; the computer-executable instructions are executed by the at least one processor to The operations of the second network device in the methods of the above aspects are performed.
  • the chip system can be a central processing unit (CPU), a microcontroller (MCU), a microprocessor (microprocessing unit, MPU), a digital signal processor (digital signal processor). signal processing, DSP), system on chip (SoC), application-specific integrated circuit (ASIC), field programmable gate array (FPGA) or programmable logic device (programmable logic device) device, PLD).
  • CPU central processing unit
  • MCU microcontroller
  • MPU microprocessor
  • DSP digital signal processor
  • SoC system on chip
  • ASIC application-specific integrated circuit
  • FPGA field programmable gate array
  • PLD programmable logic device
  • Embodiments of the present application further provide a computer program product, which is applied to a second network device, where the computer program product includes a series of computer-executable instructions, and when the computer-executable instructions are executed, all the above-mentioned aspects can be performed. operations of the second network device in the method described above.
  • the size of the sequence numbers of the above-mentioned processes does not mean the sequence of execution, and the execution sequence of each process should be determined by its functions and internal logic, and should not be dealt with in the embodiments of the present application. implementation constitutes any limitation.
  • the disclosed system, apparatus and method may be implemented in other manners.
  • the apparatus embodiments described above are only illustrative.
  • the division of the units is only a logical function division. In actual implementation, there may be other division methods.
  • multiple units or components may be combined or Can be integrated into another system, or some features can be ignored, or not implemented.
  • the shown or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, indirect coupling or communication connection of devices or units, and may be in electrical, mechanical or other forms.
  • the units described as separate components may or may not be physically separated, and components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution in this embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically alone, or two or more units may be integrated into one unit.
  • the functions, if implemented in the form of software functional units and sold or used as independent products, may be stored in a computer-readable storage medium.
  • the technical solution of the present application can be embodied in the form of a software product in essence, or the part that contributes to the prior art or the part of the technical solution, and the computer software product is stored in a storage medium, including Several computers execute instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present application.
  • the aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), magnetic disk or optical disk and other media that can store program codes .

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

本申请实施例提供了一种发送数据包的方法,该方法包括:第二网络设备可以根据预先定义的第一时延确定数据包在第一网络设备中的剩余处理时间,在该剩余处理时间大于零的情况下,以该数据包进入至该第二网络设备中的一个队列的时刻为起始时刻,经过一段时间到该数据包对应的第二参考时刻为止,该剩余处理时间在第二网络设备中被消耗掉,从而可以保证该数据包通过第一网络设备和第二网络设备转发后的确定性时延和抖动,进一步使得该数据包所在的流进入第二网络设备的形状和该数据包所在的流被第二网络设备输出后的形状相同。

Description

发送数据包的方法及网络设备
本申请要求于2020年07月31日提交中国专利局、申请号为202010760188.5、申请名称为“发送数据包的方法及网络设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及通信技术领域,并且更具体地,涉及发送数据包的方法及网络设备。
背景技术
确定性时延是指数据包在服从一定突发性要求的前提下,数据包传输所经历的时延(delay)及抖动(jitter)满足上界。如果要满足数据包端到端的确定性时延及抖动,就需要实现规模可扩展的数据面确定性数据包调度。
现有的调度方法(例如加权公平队列(weighted fair queue)、循环队列转发(cyclic queueing and forwarding,CAF)等)都无法满足确定性时延的需求。
发明内容
本申请提供一种发送数据包的方法及网络设备,在不同的网络场景情况下,能够保证网络端到端的确定性时延和抖动。
第一方面,提供了一种发送数据包的方法,其特征在于,该方法包括:
第二网络设备在第一时刻接收第一网络设备发送的数据包;
该第二网络设备根据该数据包携带的时间信息,确定第二参考时刻,该第二参考时刻为指导该数据包进入第二队列系统中的队列的参考时刻,该第二队列系统为该第二网络设备的队列系统,该时间信息用于指示该数据包通过该第一网络设备的第一剩余处理时间,该第一剩余处理时间为第一时延与第一处理时间的差,该第一时延为不小于第一理论时间上限与第一传输时间的差的绝对值的值,该第一理论时间上限为第一参考时刻至该第二参考时刻的理论处理时间上限,该第一参考时刻为指导该数据包进入第一队列系统中的队列的参考时刻,该第一队列系统为该第一网络设备的队列系统,该第一传输时间为该数据包被该第一网络设备输出的第一输出时刻至该第一时刻的实际传输时间,该第一处理时间为该第一参考时刻至该数据包被该第一网络设备输出的第一输出时刻的实际处理时间;
该第二网络设备根据该第二参考时刻从该第二队列系统包括的多个队列中确定目标队列并将该数据包加入该目标队列;
该第二网络设备根据该第二队列系统对应的调度规则将该数据包发送至第三网络设备。
在上述技术方案中,第二网络设备可以根据预先定义的第一时延确定该数据包在第一网络设备中的剩余处理时间,当该剩余处理时间大于零时,以该数据包进入至该第二网络 设备中的一个队列(即目标队列的一例)的时刻为起始时刻,经过一段时间到该数据包对应的第二参考时刻为止,该剩余处理时间在第二网络设备中被消耗掉,从而可以保证该数据包通过第一网络设备和第二网络设备转发后的确定性时延和抖动,进一步使得该数据包所在的流进入第二网络设备的形状和该数据包所在的流被第二网络设备输出后的形状相同。
结合第一方面,在第一方面的某些实现方式中,该第二队列系统包括的多个队列与多个预设时刻一一对应,该多个预设时刻中任意两个相邻预设时刻的差为第一值,该该第二网络设备根据该第二参考时刻从该第二队列系统包括的多个队列中确定目标队列,包括:
该第二网络设备根据该第二参考时刻,确定第一目标时刻对应的该第二队列系统包括的多个队列中的一个队列为该目标队列,该第一目标时刻为该第二参考时刻与第二值的和,该第二值为该第二参考时刻与第三时刻的差的绝对值加上该第一值的整数倍,该第二参考时刻与该第三时刻之间不包括该多个预设时刻中的任一个时刻,该第三时刻是该多个预设时刻中的一个时刻且该第三时刻大于该第二参考时刻,该第一目标时刻是该多个预设时刻中的一个时刻。
结合第一方面,在第一方面的某些实现方式中,该第二网络设备根据该数据包携带的时间信息,确定第二参考时刻,包括:
该第二网络设备根据该第一时延和该第一处理时间,确定该第二参考时刻。
结合第一方面,在第一方面的某些实现方式中,该第二网络设备根据该第一时延和该第一处理时间,确定该第二参考时刻,包括:
该第二网络设备根据该第一时延、该第一参考时刻、该数据包被该第一网络设备输出的第一输出时刻和该第一时刻,确定该第二参考时刻。
结合第一方面,在第一方面的某些实现方式中,该该第二网络设备根据该第一时延、该第一参考时刻、该数据包被该第一网络设备输出的第一输出时刻和该第一时刻,确定该第二参考时刻,包括:该第二网络设备根据以下公式确定该第二参考时刻:
Figure PCTCN2021104191-appb-000001
其中,E 2为该第二参考时刻,
Figure PCTCN2021104191-appb-000002
为该第一时刻,
Figure PCTCN2021104191-appb-000003
为该第一时延,
Figure PCTCN2021104191-appb-000004
为该数据包被该第一网络设备输出的第一输出时刻,E 1为该第一参考时刻。
结合第一方面,在第一方面的某些实现方式中,该该第二网络设备根据该第一时延和该第一处理时间,确定该第二参考时刻,包括:
该第二网络设备根据该第一时延、该第一参考时刻、该数据包被该第一网络设备输出的第一输出时刻、该数据包通过该第二网络设备的交换结构处理后的时刻和该第一时刻,确定该第二参考时刻,其中该数据包通过该第二网络设备的交换结构处理后的时刻小于该第二参考时刻。
结合第一方面,在第一方面的某些实现方式中,该该第二网络设备根据该第一时延、该第一参考时刻、该数据包被该第一网络设备输出的第一输出时刻、该数据包通过该第二网络设备的交换结构处理后的时刻和该第一时刻,确定该第二参考时刻,包括:该第二网络设备根据以下公式确定该第二参考时刻:
Figure PCTCN2021104191-appb-000005
其中,E 2为该第二参考时刻,
Figure PCTCN2021104191-appb-000006
为该数据包通过该第二网络设备的交换结构处理后 的时刻,
Figure PCTCN2021104191-appb-000007
为该第一时延,
Figure PCTCN2021104191-appb-000008
为该数据包被该第一网络设备输出的第一输出时刻,E 1为该第一参考时刻,
Figure PCTCN2021104191-appb-000009
为该第一时刻。
结合第一方面,在第一方面的某些实现方式中,该时间信息包括第一时间值,该第一时间值为该第一剩余处理时间。
结合第一方面,在第一方面的某些实现方式中,该时间信息包括第一指示信息,该第一指示信息用于指示该第一处理时间。
结合第一方面,在第一方面的某些实现方式中,该第一指示信息包括第二时间值,该第二时间值为该第一处理时间。
结合第一方面,在第一方面的某些实现方式中,该第一指示信息包括第三时间值和第四时间值,该第三时间值为该数据包被该第一网络设备输出的第一输出时刻,该第四时间值为该第一参考时刻。
结合第一方面,在第一方面的某些实现方式中,该时间信息还包括第二指示信息,该第二指示信息用于指示该第一时延。
结合第一方面,在第一方面的某些实现方式中,该该第二网络设备根据该第二队列系统对应的调度规则将该数据包发送至该第三网络设备,包括:
该第二网络设备确定该目标队列为该第二队列系统包括的多个队列中当前时刻被调度的队列,以及该目标队列为开启状态,该第二网络设备将该数据包发送至该第三网络设备。
结合第一方面,在第一方面的某些实现方式中,该方法还包括:
该第二网络设备在该目标队列满足第一预设条件的情况下,确定关闭该目标队列。
结合第一方面,在第一方面的某些实现方式中,在该第二网络设备确定关闭该目标队列之后,该方法还包括:
该第二网络设备根据第一信息,确定第二目标时刻,该第二目标时刻对应于该目标队列,该第二目标时刻为在第一目标时刻后该目标队列对应的开启的时刻,该第二目标时刻大于多个预设时刻中的任意一个预设时刻,该第一信息包括该第二队列系统包括的每个队列对应的调度顺序和该第二队列系统包括的每个队列对应的开启的时刻;
其中,该第二队列系统包括的多个队列与该多个预设时刻一一对应,该多个预设时刻中任意两个相邻预设时刻的差为第一值,该第一目标时刻对应的该第二队列系统包括的多个队列中的一个队列为该目标队列,该第一目标时刻为该第二参考时刻与第二值的和,该第二值为该第二参考时刻与第三时刻的差的绝对值加上该第一值的整数倍,该第二参考时刻与该第三时刻之间不包括该多个预设时刻中的任一个时刻,该第三时刻是该多个预设时刻中的一个时刻且该第三时刻大于该第二参考时刻,该第一目标时刻是该多个预设时刻中的一个时刻。
结合第一方面,在第一方面的某些实现方式中,该第二网络设备确定该目标队列为该第二队列系统包括的多个队列中当前时刻被调度的队列,包括:
当该第二网络设备确定该目标队列为该第二队列系统包括的多个队列中优先级最高的队列时,该第二网络设备确定该目标队列为该第二队列系统包括的多个队列中当前时刻被调度的队列;
在该第二网络设备确定关闭该目标队列之后,该方法还包括:
该第二网络设备将该目标队列的优先级设置为该第二队列系统包括的多个队列中优先级最低的队列,并将该第二队列系统包括的多个队列中除该目标队列之外的队列的优先级提升。
结合第一方面,在第一方面的某些实现方式中,该第二队列系统包括的多个队列与多个预设调度顺序一一对应,
该第二网络设备确定该目标队列为该第二队列系统包括的多个队列中当前时刻被调度的队列,包括:
当该第二网络设备根据该多个预设调度顺序确定该目标队列对应的预设调度顺序为该第二网络设备在该当前时刻调度的队列对应的调度顺序时,该第二网络设备确定该目标队列为该第二队列系统包括的多个队列中当前时刻被调度的队列。
结合第一方面,在第一方面的某些实现方式中,该第一预设条件包括:该目标队列为空队列,且该目标队列的开启时长大于等于第一值,该第一值为多个预设时刻中任意两个相邻预设时刻的差,该多个预设时刻与该第二队列系统包括的多个队列一一对应。
第二方面,提供了一种第二网络设备,其特征在于,该第二网络设备包括:
收发单元,用于在第一时刻接收第一网络设备发送的数据包;
处理单元,用于根据该数据包携带的时间信息,确定第二参考时刻,该第二参考时刻为指导该数据包进入第二队列系统中的队列的参考时刻,该第二队列系统为该第二网络设备的队列系统,该时间信息用于指示该数据包通过该第一网络设备的第一剩余处理时间,该第一剩余处理时间为第一时延与第一处理时间的差,该第一时延为不小于第一理论时间上限与第一传输时间的差的绝对值的值,该第一理论时间上限为第一参考时刻至该第二参考时刻的理论处理时间上限,该第一参考时刻为指导该数据包进入第一队列系统中的队列的参考时刻,该第一队列系统为该第一网络设备的队列系统,该第一传输时间为该数据包被该第一网络设备输出的第一输出时刻至该第一时刻的实际传输时间,该第一处理时间为该第一参考时刻至该数据包被该第一网络设备输出的第一输出时刻的实际处理时间;
该处理单元,还用于根据该第二参考时刻从该第二队列系统包括的多个队列中确定目标队列并将该数据包加入该目标队列;
该处理单元,还用于根据该第二队列系统对应的调度规则将该数据包发送至第三网络设备。
在上述技术方案中,第二网络设备可以根据预先定义的第一时延确定该数据包在第一网络设备中的剩余处理时间,当该剩余处理时间大于零时,以该数据包进入至该第二网络设备中的一个队列(即目标队列的一例)的时刻为起始时刻,经过一段时间到该数据包对应的第二参考时刻为止,该剩余处理时间在第二网络设备中被消耗掉,从而可以保证该数据包通过第一网络设备和第二网络设备转发后的确定性时延和抖动,进一步使得该数据包所在的流进入第二网络设备的形状和该数据包所在的流被第二网络设备输出后的形状相同。
结合第二方面,在第二方面的某些实现方式中,该第二队列系统包括的多个队列与多个预设时刻一一对应,
该处理单元还用于:
该第二参考时刻,确定第一目标时刻对应的该第二队列系统包括的多个队列中的一个 队列为该目标队列,该第一目标时刻为该第二参考时刻与第二值的和,该第二值为该第二参考时刻与第三时刻的差的绝对值加上该第一值的整数倍,该第二参考时刻与该第三时刻之间不包括该多个预设时刻中的任一个时刻,该第三时刻是该多个预设时刻中的一个时刻且该第三时刻大于该第二参考时刻,该第一目标时刻是该多个预设时刻中的一个时刻。
结合第二方面,在第二方面的某些实现方式中,该处理单元还用于:
根据该第一时延和该第一处理时间,确定该第二参考时刻。
结合第二方面,在第二方面的某些实现方式中,该处理单元还用于:
根据该第一时延、该第一参考时刻、该数据包被该第一网络设备输出的第一输出时刻和该第一时刻,确定该第二参考时刻。
结合第二方面,在第二方面的某些实现方式中,该处理单元还用于:
根据以下公式确定该第二参考时刻:
Figure PCTCN2021104191-appb-000010
其中,E 2为该第二参考时刻,
Figure PCTCN2021104191-appb-000011
为该第一时刻,
Figure PCTCN2021104191-appb-000012
为该第一时延,
Figure PCTCN2021104191-appb-000013
为该数据包被该第一网络设备输出的第一输出时刻,E 1为该第一参考时刻。
结合第二方面,在第二方面的某些实现方式中,该处理单元还用于:
根据该第一时延、该第一参考时刻、该数据包被该第一网络设备输出的第一输出时刻、该数据包通过该第二网络设备的交换结构处理后的时刻和该第一时刻,确定该第二参考时刻,其中该数据包通过该第二网络设备的交换结构处理后的时刻小于该第二参考时刻。
结合第二方面,在第二方面的某些实现方式中,该处理单元还用于:
根据以下公式确定该第二参考时刻:
Figure PCTCN2021104191-appb-000014
其中,E 2为该第二参考时刻,
Figure PCTCN2021104191-appb-000015
为该数据包通过该第二网络设备的交换结构处理后的时刻,
Figure PCTCN2021104191-appb-000016
为该第一时延,
Figure PCTCN2021104191-appb-000017
为该数据包被该第一网络设备输出的第一输出时刻,E 1为该第一参考时刻,
Figure PCTCN2021104191-appb-000018
为该第一时刻。
结合第二方面,在第二方面的某些实现方式中,该时间信息包括第一时间值,该第一
时间值为该第一剩余处理时间。
结合第二方面,在第二方面的某些实现方式中,该时间信息包括第一指示信息,该第
一指示信息用于指示该第一处理时间。
结合第二方面,在第二方面的某些实现方式中,该第一指示信息包括第二时间值,该第二时间值为该第一处理时间。
结合第二方面,在第二方面的某些实现方式中,该第一指示信息包括第三时间值和第四时间值,该第三时间值为该数据包被该第一网络设备输出的第一输出时刻,该第四时间值为该第一参考时刻。
结合第二方面,在第二方面的某些实现方式中,该时间信息还包括第二指示信息,该第二指示信息用于指示该第一时延。
结合第二方面,在第二方面的某些实现方式中,该处理单元还用于:
确定该目标队列为该第二队列系统包括的多个队列中当前时刻被调度的队列,以及该目标队列为开启状态;
该收发单元还用于:根据该第二队列系统对应的调度规则将该数据包发送至第三网络 设备。
结合第二方面,在第二方面的某些实现方式中,该处理单元还用于:
在该目标队列满足第一预设条件的情况下,确定关闭该目标队列。
结合第二方面,在第二方面的某些实现方式中,根据第一信息,确定第二目标时刻,该第二目标时刻对应于该目标队列,该第二目标时刻为在第一目标时刻后该目标队列对应的开启的时刻,该第二目标时刻大于多个预设时刻中的任意一个预设时刻,该第一信息包括该第二队列系统包括的每个队列对应的调度顺序和该第二队列系统包括的每个队列对应的开启的时刻;
其中,该第二队列系统包括的多个队列与该多个预设时刻一一对应,该多个预设时刻中任意两个相邻预设时刻的差为第一值,该第一目标时刻对应的该第二队列系统包括的多个队列中的一个队列为该目标队列,该第一目标时刻为该第二参考时刻与第二值的和,该第二值为该第二参考时刻与第三时刻的差的绝对值加上该第一值的整数倍,该第二参考时刻与该第三时刻之间不包括该多个预设时刻中的任一个时刻,该第三时刻是该多个预设时刻中的一个时刻且该第三时刻大于该第二参考时刻,该第一目标时刻是该多个预设时刻中的一个时刻。
结合第二方面,在第二方面的某些实现方式中,该处理单元还用于:
当确定该目标队列为该第二队列系统包括的多个队列中优先级最高的队列时,确定该目标队列为该第二队列系统包括的多个队列中当前时刻被调度的队列;
将该目标队列的优先级设置为该第二队列系统包括的多个队列中优先级最低的队列,并将该第二队列系统包括的多个队列中除该目标队列之外的队列的优先级提升。
结合第二方面,在第二方面的某些实现方式中,该第二队列系统包括的多个队列与多个预设调度顺序一一对应,
该处理单元还用于:
当根据该多个预设调度顺序确定该目标队列对应的预设调度顺序为该第二网络设备在该当前时刻调度的队列对应的调度顺序时,确定该目标队列为该第二队列系统包括的多个队列中当前时刻被调度的队列。
结合第二方面,在第二方面的某些实现方式中,该第一预设条件包括:该目标队列为空队列,且该目标队列的开启时长大于等于第一值,该第一值为多个预设时刻中任意两个相邻预设时刻的差,该多个预设时刻与该第二队列系统包括的多个队列一一对应。
第三方面,提供了一种第二网络设备,该第二网络设备包括存储器和处理器,该存储器用于存储计算机执行指令,该处理器用于读取该存储器中存储的计算机执行指令,使得该装置执行上述第一方面及第一方面的任意可能的实现方式中的方法。
第四方面,提供了一种处理器,包括:输入电路、输出电路和处理电路。所述处理电路用于通过所述输入电路接收信号,并通过所述输出电路发射信号,使得所述第一方面中的任一方面,以及第一方面中任一种可能实现方式中的方法被实现。
在具体实现过程中,上述处理器可以为芯片系统,输入电路可以为输入管脚,输出电路可以为输出管脚,处理电路可以为晶体管、门电路、触发器和各种逻辑电路等。输入电路所接收的输入的信号可以是由例如但不限于接收器接收并输入的,输出电路所输出的信号可以是例如但不限于输出给发射器并由发射器发射的,且输入电路和输出电路可以是同 一电路,该电路在不同的时刻分别用作输入电路和输出电路。本申请实施例对处理器及各种电路的具体实现方式不做限定。
第五方面,提供了一种处理装置,包括处理器和存储器。该处理器用于读取存储器中存储的计算机执行指令,并可通过接收器接收信号,通过发射器发射信号,以执行第一方面以及第一方面任一种可能实现方式中的方法。
可选地,所述处理器为一个或多个,所述存储器为一个或多个。
可选地,所述存储器可以与所述处理器集成在一起,或者所述存储器与处理器分离设置。
在具体实现过程中,存储器可以为非瞬时性(non-transitory)存储器,例如只读存储器(read only memory,ROM),其可以与处理器集成在同一块芯片系统上,也可以分别设置在不同的芯片系统上,本申请实施例对存储器的类型以及存储器与处理器的设置方式不做限定。
应理解,相关的数据交互过程例如发送指示信息可以为从处理器输出指示信息的过程,接收能力信息可以为处理器接收输入能力信息的过程。具体地,处理输出的数据可以输出给发射器,处理器接收的输入数据可以来自接收器。其中,发射器和接收器可以统称为收发器。
第六方面,提供了一种计算机可读存储介质,用于存储计算机程序,该计算机程序包括用于执行上述第一方面及上述第一方面的任意可能的实现方式中的方法的计算机执行指令。
第七方面,提供了一种包含计算机执行指令的计算机程序产品,当其在计算机上运行时,使得计算机执行上述第一方面及上述第一方面的任意可能的实现方式中的方法。
第八方面,提供了一种芯片系统,包括至少一个处理器和接口;所述至少一个所述处理器,用于调用并运行计算机程序,以使所述芯片系统执行上述第一方面及上述第一方面的任意可能的实现方式中的方法。
第九方面,提供了一种系统,包括上述的第二网络设备。
附图说明
图1是突发累积形成原因的示意图。
图2是能够应用本申请实施例的系统架构200的示意图。
图3是能够实现本申请实施例的路由器的示意性结构框图。
图4出了本申请实施例提供的发送数据包的方法400的示意性流程图。
图5是本申请实施例提供的时刻的示意图。
图6是本申请实施例提供的时间信息在报头中的封装格式。
图7是本申请实施例提供的第二网络设备在上行板确定第二参考时刻的时序图。
图8是本申请实施例提供的另一种第二网络设备在上行板确定第二参考时刻的时序图。
图9是本申请实施例提供的第二网络设备在下行板确定第二参考时刻的时序图。
图10是本申请实施例提供的另一种第二网络设备在下行板确定第二参考时刻的时序图。
图11是本申请实施例提供的第二队列系统的示意图。
图12是本申请实施例提供的数据包通过网络设备转发后的确定性时延的示意图。
图13是本申请实施例提供的发送数据包的方法的一个具体实施例。
图14是本申请实施例提供的数据包通过网络设备转发后的确定性时延的示意图。
图15是本申请实施提供的第二网络设备的功能模块。
图16是本申请实施提供的发送数据包的网络设备的功能模块。
图17是本申请实施提供的另一种发送数据包的网络设备的功能模块。
图18是本申请实施例提供的第二网络设备1700的示意性结构图。
图19是本申请实施例提供的第二网络设备2000的硬件结构示意图。
具体实施方式
下面将结合附图,对本申请中的技术方案进行描述。
本申请将围绕可包括多个设备、组件、模块等的系统来呈现各个方面、实施例或特征。应当理解和明白的是,各个系统可以包括另外的设备、组件、模块等,并且/或者可以并不包括结合附图讨论的所有设备、组件、模块等。此外,还可以使用这些方案的组合。
另外,在本申请实施例中,“示例的”、“例如”等词用于表示作例子、例证或说明。本申请中被描述为“示例”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用示例的一词旨在以具体方式呈现概念。
本申请实施例中,“相应的(corresponding,relevant)”和“对应的(corresponding)”有时可以混用,应当指出的是,在不强调其区别时,其所要表达的含义是一致的。
本申请实施例中,有时候下标如W 1可能会笔误为非下标的形式如W1,在不强调其区别时,其所要表达的含义是一致的。
本申请实施例描述的网络架构以及业务场景是为了更加清楚的说明本申请实施例的技术方案,并不构成对于本申请实施例提供的技术方案的限定,本领域普通技术人员可知,随着网络架构的演变和新业务场景的出现,本申请实施例提供的技术方案对于类似的技术问题,同样适用。
在本说明书中描述的参考“一个实施例”或“一些实施例”等意味着在本申请的一个或多个实施例中包括结合该实施例描述的特定特征、结构或特点。由此,在本说明书中的不同之处出现的语句“在一个实施例中”、“在一些实施例中”、“在其他一些实施例中”、“在另外一些实施例中”等不是必然都参考相同的实施例,而是意味着“一个或多个但不是所有的实施例”,除非是以其他方式另外特别强调。术语“包括”、“包含”、“具有”及它们的变形都意味着“包括但不限于”,除非是以其他方式另外特别强调。
本申请中,“至少一个”是指一个或者多个,“多个”是指两个或两个以上。“和/或”,描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B的情况,其中A,B可以是单数或者复数。字符“/”一般表示前后关联对象是一种“或”的关系。“以下至少一项(个)”或其类似表达,是指的这些项中的任意组合,包括单项(个)或复数项(个)的任意组合。例如,a,b,或c中的至少一项(个),可以表示:a,b,c,a-b,a-c,b-c,或a-b-c,其中a,b,c可以是单个,也可以是多个。
突发累积
互联网协议(internet protocol,IP)网络中,由于突发累积的存在,导致其无法为某条流提供确定性的端到端时延和抖动。
突发累积是导致时延不确定的根本原因。突发累积形成的原因是不同数据包之间的相互挤压。
图1示出了突发累积形成原因的示意图。
如图1中三条流(流1、流2和流3)同时到达网络设备101的时候是完全均匀的,由于网络设备101只能线速处理数据包,导致流2收到其他两条流的挤压,从而两个连续数据包紧挨在了一起,突发度增加。以上过程若干次循环之后,会导致某跳的流形成一个难以预测大突发,大突发进一步会挤压其他流,导致其他流的时延增加,并且难以预测。微突发逐跳累积是时延不确定性的根本原因。现有解决上述问题的方法要么依赖于全网设备的时间同步,要么对传输距离有限制,很难适用于大规模IP网络。
图2示出了能够应用本申请实施例的系统架构200的示意图。如图2所示,该系统架构200可以由边缘网络210、边缘网络220和核心网络230组成。
边缘网络210中包括用户设备211。边缘网络220包括用户设备221。核心网络230包括入口边缘(ingress edge)设备231、网络设备232、网络设备233、网络设备234和出口边缘(egress edge)设备235。
参见图2,用户设备211可以通过核心网络230与用户设备221进行通信。
本申请实施例可以由核心网络230中的设备实现。例如,可以由入口边缘设备231和网络设备232实现,也可以由网络设备231至网络设备235实现,还可以由网络设备232至出口边缘设备235实现。
下面,以网络设备231至网络设备235实现本申请实施例的方法为例进行介绍。
当入口边缘设备231是该多个流进入核心网络230中的第一个网络设备时,入口边缘设备231也可以称为第一跳的网络设备或者首跳网络设备。在此情况下,网络设备232是第二跳的网络设备,网络设备233是第三跳的网络设备,网络设备234是第四跳的网络设备,出口边缘设备235是第五跳的网络设备。
入口边缘设备231可以接收到多个业务流。入口边缘设备231对多个业务流中的每个业务流的处理方式是相同的。入口边缘设备231接收到的每个业务流的流量模型满足下列公式:
A i(t)=r i×t+B i
其中,t为时间;A i(t)为t时间内第i条业务流的数据总流量;r i为第i条业务流需要的带宽,B i为第i条业务流的最大突发度;r i为平均带宽,该平均带宽可以理解为第i条业务流在统计意义上的平均速度。
上述业务流有时也可称为流量(traffic)。
当入口边缘设备231接收到的某个目标流不满足上述流量模型时,入口边缘设备231可以利用现有的整形算法(例如,漏桶(leaky bucket)算法、令牌桶算法(token bucket)算法等)对该目标流进行整形,使得整形后的该目标流的流量模型满足上述流量模型。
能够实现本申请实施例的设备可以是路由器。能够实现本申请实施例的设备也可以是入口网关设备(例如,交换机)。
可以理解的是,图2仅是为了帮助本领域技术人员理解本申请方法的一个系统架构的 示意图,而并非是对能够应用本申请技术方案的系统架构的限制。例如,在一些实现方式中,该系统架构200可以包括更多数目的网络设备。例如,在一些实现方式中,边缘网络210或边缘网络220中还可以包括更多数目的用户设备。
图3示出了能够实现本申请实施例的路由器的示意性结构框图。如图3所示,路由器300包括上行板301、交换结构302和下行板303。
上行板也可以称为上行接口板。上行板301可以包括多个输入端口。上行板可以输入端口接收到的数据包(packet)进行拆封等处理,利用转发表查找输出端口。一旦查找到输出端口(为了便于描述,以下将查找到的输出端口称为目标输出端口),数据包就会被发送至交换结构302。
交换结构302将接收到的数据包转发到一个该目标输出端口。具体地,交换结构302将接收到的数据包转发到包括该目标输出端口的下行板303上。下行板也可以称为下行接口板。下行板303中包括多个输出端口。下行板303接收来自于交换结构302的数据包。下行板可以对接收到的数据包进行缓存管理、封装等处理,然后通过该目标输出端口将该数据包发送至下一跳网络设备。
可以理解的是,如图3所示的路由器仅示出了一个上行板301和一个下行板303。在一些实施例中,路由器可以包括多个上行板和/或多个下行板。
图4出了本申请实施例提供的发送数据包的方法400的示意性流程图。
如图4所示,该方法400包括步骤410至步骤440,该方法400可以应用于图2所示的核心网230中,下面对步骤410至步骤440进行详细介绍。
步骤410,第二网络设备在第一时刻接收第一网络设备发送的数据包。
本申请实施例对网络设备的类型不做具体限定,例如,网络设备可以是交换机、路由器等。网络设备有时也可称为网络节点(network node)或跳(hop)。
在本申请实施例中,第二网络设备为第一网络设备的下一跳网络设备。
参见图2,当第一网络设备为入口边缘设备231时,第二网络设备可以为网络设备232。当第一网络设备为网络设备232时,第二网络设备可以为网络设备234。当第一网络设备为网络设备234时,第二网络设备可以为出口边缘设备235。
可选地,在步骤410之前还可以包括,第一网络设备接收数据包。当第一网络设备为接收数据包的第一个网络设备(即首跳设备)时,第一网络设备可以利用算法(例如,漏桶(leaky bucket)算法)对第一网络设备接收的数据包所在的业务流1进行整形处理,使得整形后的业务流1满足下列公式:
A 1(t)=r 1×t+B 1
其中,t为时间;A 1(t)为t时间内业务流1的数据总流量;r 1为业务流1需要的带宽,B 1为业务流1的最大突发度;r 1为平均带宽,该平均带宽可以理解为业务流1在统计意义上的平均速度。
步骤420,第二网络设备根据数据包携带的时间信息,确定第二参考时刻。
在本申请实施例中,第二参考时刻为指导数据包进入第二队列系统中的队列的参考时刻,第二队列系统为第二网络设备的队列系统。换句话说,第二网络设备可以根据第二参考时刻确定该数据包应该进入到第二队列系统中的某一个队列。
其中,第二队列系统包括一组队列,该一组队列包括多个队列。第二队列系统有时也 可以称为第二队列组。
可选地,当第二网络设备接收到的多个的数据包携带的业务的优先级不相同时,第二网络设备还可以根据每个数据包携带的业务的优先级以及第二网络设备包括的多个队列系统对应的业务优先级,从多个队列系统中确定第二队列系统,多个队列系统中的任意两个队列系统对应的业务优先级不相同,第二队列系统对应的业务优先级中的一个业务优先级与数据包携带的业务的优先级相同。
其中,多个队列系统也可以称为多个队列组,每个队列组可以包括多个队列。每个队列组可以对应一个或多个业务优先级。
假设第二网络设备包括3个队列系统,分别为队列系统1、队列系统2、队列系统3,且队列系统1包括队列1(对应的业务优先级为1)和队列2(对应的业务优先级为2),队列系统2包括队列3(对应的业务优先级为3)、队列4(对应的业务优先级为4)和队列5(对应的业务优先级为5),队列系统3包括队列6(对应的业务优先级为6)和队列7(对应的业务优先级为6)。在此情况下,当第二网络设备接收到的数据包携带的业务的优先级为6时,第二网络设备可以确定队列系统3为第二队列系统。
在本申请实施例中,时间信息用于指示数据包通过第一网络设备的第一剩余处理时间,第一剩余处理时间为第一时延与第一处理时间的差,第一时延为不小于第一理论时间上限与第一传输时间的差的绝对值的值,第一理论时间上限为第一参考时刻至第二参考时刻的理论处理时间上限,第一参考时刻为指导数据包进入第一队列系统中的队列的参考时刻,第一队列系统为第一网络设备的队列系统,第一传输时间为数据包被第一网络设备输出的第一输出时刻至第一时刻的实际传输时间,第一处理时间为第一参考时刻至数据包被第一网络设备输出的第一输出时刻的实际处理时间。
为了便于描述,此处将“第一理论时间上限与第一传输时间的差的绝对值”记作第一绝对值。
在一些实现方式中,第一时延为不小于第一绝对值的值可以理解为,可以任意选取大于等于第一绝对值的值作为第一时延。例如,当第一绝对值为10微秒时,可以设置第一时延为10微秒,11微秒,20微秒或50微秒等。
在另一些实现方式中,第一时延为不小于第一绝对值的值可以理解为,可以将非负整数与第一绝对值的和作为第一时延。例如,当第一绝对值为10微秒,且非负整数为1.5微秒时,可以设置第一时延为11.5微秒。
上述第一理论时延上限为预定义的值。例如,可以根据具体的网络环境设置该第一理论时延上限。例如,可以设置第一理论时延上限为10微秒。或者,可以设置第一理论时延上限为100微秒。
上述第一传输时间也是一个固定的值。例如,第一传输时延可以为2微秒。或者,第一传输时延可以为12微秒。
还应理解的是,第一时延为不小于第一理论时间上限与第一传输时间的差的绝对值的值,由于该第一传输时间是一个固定的值,该第一理论时延上限也是预定义的固定值,所以该第一时延也是一个固定的非负值。
需说明的是,当第一网络设备为转发数据包的第一个网络设备(即首跳设备)时,第一参考时刻可以理解为,该数据包通过该第一网络设备时的任意一个时刻。例如。可以定 义该第一参考时刻为该数据包被该第一网络设备的整形结构输出的时刻。例如,可以定义该第一参考时刻为该数据包被该第一网络设备输出的时刻。例如。可以定义该第一参考时刻为该数据包进入该第一网络设备的时刻。换句话说,当第一网络设备为转发数据包的第一个网络设备时,第一参考时刻为预定义的时刻,该预定义的时刻可以为该数据包通过该第一网络设备时的任意一个时刻。
上述时间信息可以通过数据包报头携带。例如,报头可以是介质访问控制(media access control,MAC)头。或者,报头也可以是IP头(例如,IPv4报头或IPv6报头)。
可以理解的是,上述方法400中所描述的各个时刻默认均指精确的时刻值,各个时刻包括:第一时刻,第二时刻,第三时刻,第一参考时刻,第二参考时刻,第三参考时刻,第一输出时刻,预设时刻等。上述方法400中所描述的剩余处理时间(如第一剩余处理时间)、理论时间上限(如第一理论时间上限)等概念,指的是这些精确时刻值之间的差值。
在实际应用中,第二网络设备(例如,路由器)能够识别和表达的时间精度是有限的,通常为1ns或者2ns,本申请实施例提供的发送数据包的方法可以是基于此精度基础的。其中,时刻的精度与第二网络设备能够识别和表达的精度是相同的。
可选的,时刻(即上述方法400中所描述的各个时刻中的任一时刻)的实际发生时间也可以是在精度范围内的任一个时间。例如,如果第二网络设备能够识别和表达的精度为1ns,那么时刻的精度也是1ns。基于此,如果发送时刻1为1μs1ns,那么发送时刻1的实际时间可以是1μs1ns到1μs2ns中的任一个时间,例如1μs1.1ns或者1μs1.99ns等。可选的,时刻的精度也可以为预先设定的精度范围。例如,如果预先设定的精度为10μs,那么时刻精度也是10μs。时刻的实际发生时间可以是在精度范围内的任一个时间。基于此,如果发送时刻1是13μs,那么该发送时刻1的实际时间可以是13μs到23μs中的任一个时间,例如15μs、16μs或者18μs等。
可选的,上述方法400中所描述的各个时刻中的任一时刻还可以通过预先定义的编号来表示。具体的,可以将时间按照预定义的粒度划分为多个时刻,每个时刻用一个编号来表示。例如,可以以1分钟为粒度将24小时划分为1440个时刻,每个时刻用一个阿拉伯数字编号表示,例如,数字0表示0时0分到0时1分,数字1表示0时1分到0时2分,以此类推。如果发送时刻1为16,那么发送时刻1的实际时间可以是0时16分到0时17分中的任一个时间,例如0时16分08秒、0时16分31秒、0时16分59秒等。
下面,结合图5对上述时间精度进行举例说明。
示例性的,在图5中的(a)中采用细粒度的精度来表达时间,即以1ns粒度为时间的基本的粒度。例如,第一时刻可以是13μs0ns或13μs0.2ns等。示例性的,在图5中的(b)中采用粗粒度的精度来表达时间,例如,可以将13μs至23μs这段时间中的每个时刻值都看作为一个相同的值(例如,13μs、23μs,或13μs至23μs中的任意一个时刻)。示例性的,在图5中的(c)中,以10us的粗粒度作为时间的基本粒度并按顺序从小到大依次进行编号,用数字0表示0μs至10μs这段时间中的任意一个时刻,用数字1表示10μs至20μs这段时间中的任意一个时刻(例如,10μs2ns等),用数字3表示20μs至30μs这段时间中的任意一个时刻(例如,25μs等)。
下面,结合图6对时间信息包括的内容以及时间信息在报头中的封装格式进行介绍。
可选地,时间信息可以包括第一指示信息和第二指示信息,第一指示信息用于指示第 一处理时间,第二指示信息用于指示第一时延。其中,第一指示信息包括第三时间值和第四时间值,第三时间值为数据包被第一网络设备输出的第一输出时刻,第四时间值为第一参考时刻,参见图6格式一。
当第二网络设备获取的时间信息为格式一时,第二网络设备可以根据格式一中的第四时间值和第三时间值通过计算获取第一处理时间。
可选地,时间信息可以包括第一指示信息,第一指示信息用于指示第一处理时间。其中,第一指示信息包括第三时间值和第四时间值,第三时间值为数据包被第一网络设备输出的第一输出时刻,第四时间值为第一参考时刻,参见图6格式二。
与图6格式一相比,图6格式二中的报文不携带第一时延,第二网络设备可以通过其他方式获取第一时延。例如,第二网络设备可以通过控制面信令下发的方式获取该第一时延。
可选地,时间信息可以包括第一指示信息和第二指示信息,第一指示信息用于指示第一处理时间,第二指示信息用于指示第一时延。其中,第一指示信息包括第二时间值,第二时间值为第一处理时间,参见图6格式三。
与格式一、格式二相比,格式三对应的报头可以直接携带第一处理时间。
可选地,时间信息可以包括第一指示信息,第一指示信息用于指示第一处理时间。其中,第一指示信息包括第二时间值,第二时间值为第一处理时间,参见图6格式四。
与格式三相比,格式四中的报头不携带第一时延,第二网络设备可以通过其他方式获取第一时延。例如,第二网络设备可以通过控制面信令下发的方式获取该第一时延。
可选地,时间信息可以包括第一时间值,第一时间值为第一剩余处理时间,参见图6格式五。
与格式一至格式四相比,格式五中的报头可以直接携带第一剩余处理时间。
在本申请实施例中,第二网络设备可以在第二网络设备的上行板中确定第二参考时刻。第二网络设备也可以在第二网络设备的下行板中确定第二参考时刻。还应理解的是,当在第二网络设备的上行板中确定第二参考时刻时,第二网络设备可以根据第二参考时刻确定数据包进入上行板中的目标队列。当在第二网络设备的下行板中确定第二参考时刻时,第二网络设备可以根据第二参考时刻确定数据包进入下行板中的目标队列。
首先,介绍第二网络设备在上行板中确定第二参考时刻的方法。
在本申请实施例中,第二网络设备根据数据包携带的时间信息,确定第二参考时刻,包括:第二网络设备根据第一时延和第一处理时间,确定第二参考时刻。
其中,第二网络设备根据第一时延和第一处理时间,确定第二参考时刻,包括:第二网络设备根据第一时延、第一参考时刻、数据包被第一网络设备输出的第一输出时刻和第一时刻,确定第二参考时刻。
其中,第二网络设备根据第一时延、第一参考时刻、数据包被第一网络设备输出的第一输出时刻和第一时刻,确定第二参考时刻,包括:第二网络设备根据以下公式确定第二参考时刻:
Figure PCTCN2021104191-appb-000019
其中,E 2为第二参考时刻,
Figure PCTCN2021104191-appb-000020
为第一时刻,
Figure PCTCN2021104191-appb-000021
为第一时延,
Figure PCTCN2021104191-appb-000022
为第一处理时间,
Figure PCTCN2021104191-appb-000023
为数据包被第一网络设备输出的第一输出时刻,E 1为第一参考时刻,
Figure PCTCN2021104191-appb-000024
为第一剩余处理时间。
需说明的是,当第一网络设备为转发数据包的第一个网络设备(即首跳设备)时,第一参考时刻可以理解为,该数据包通过该第一网络设备时的任意一个时刻。例如。可以定义该第一参考时刻为该数据包被该第一网络设备的整形结构输出的时刻。例如,可以定义该第一参考时刻为该数据包被该第一网络设备输出的时刻。例如。可以定义该第一参考时刻为该数据包进入该第一网络设备的时刻。换句话说,当第一网络设备为转发数据包的第一个网络设备时,第一参考时刻为预定义的时刻,该预定义的时刻可以为该数据包通过该第一网络设备时的任意一个时刻。
下面,结合图7和图8具体介绍第二网络设备在上行板确定第二参考时刻的过程中涉及到的各个时刻。
图7示出了本申请实施例提供的第二网络设备在上行板确定第二参考时刻的时序图。
在图7中,网络设备232可以理解为接收数据包的第二个网络设备,网络设备233可以理解为接收数据包的第三个网络设备。其中,
Figure PCTCN2021104191-appb-000025
为网络设备232接收到来自上一跳网络设备发送的数据包的时刻;E 1为指导数据包进入网络设备232的队列系统中的队列的参考时刻,即第一参考时刻;
Figure PCTCN2021104191-appb-000026
为数据包被网络设备232输出的第一输出时刻;
Figure PCTCN2021104191-appb-000027
为网络设备233接收到网络设备232发送的数据包的时刻,即第一时刻;E 2为指导数据包进入网络设备233的队列系统中的队列的参考时刻,即第二参考时刻;
Figure PCTCN2021104191-appb-000028
为数据包被网络设备233输出的第二输出时刻。
Figure PCTCN2021104191-appb-000029
为数据包进入网络设备232的交换结构的时刻至数据包进入网络设备233的交换结构的时刻之间的时间(不包括数据包被网络设备232输出的时刻至数据包进入网络设备233的时刻之间的时间,即
Figure PCTCN2021104191-appb-000030
)。
应理解,图7仅为示意并不对本申请实施例构成任何限定。例如,在一些实施例中,当图7中的网络设备232为图2中的网络设备233时,图7中的网络设备233可以为图2中的网络设备234。例如,在一些实施例中,当图7中的网络设备232为图2中的网络设备234时,图7中的网络设备233可以为图2中的出口边缘设备235。
图8示出了本申请实施例提供的另一种第二网络设备在上行板确定第二参考时刻的时序图。应理解,图8中示出的各个时刻仅为示意并不对本申请构成任何限定。
在图8中,入口边缘设备231可以理解为接收数据包的第一个网络设备(即首跳设备),网络设备232可以理解为接收数据包的第二个网络设备。其中,
Figure PCTCN2021104191-appb-000031
为入口边缘设备231接收到数据包的时刻;E 1为指导数据包从入口边缘设备231的整形结构输出的时刻,即第一参考时刻的一例;
Figure PCTCN2021104191-appb-000032
为数据包被入口边缘设备231输出的第一输出时刻;
Figure PCTCN2021104191-appb-000033
为网络设备232接收到入口边缘设备231发送的数据包的时刻,即第一时刻;E 2为指导数据包进入网络设备232的队列系统中的队列的参考时刻,即第二参考时刻;
Figure PCTCN2021104191-appb-000034
为数据包被网络设备232输出的第二输出时刻。
Figure PCTCN2021104191-appb-000035
为数据包被入口边缘设备231的整形结构输出的时刻至数据包进入网络设备232的交换结构的时刻之间的时间(不包括数据包被入口边缘设备231输出的时刻至数据包进入网络设备232的时刻之间的时间,即
Figure PCTCN2021104191-appb-000036
)。
需说明的是,在图8中,由于入口边缘设备231为转发数据包的第一个网络设备(即首跳设备),此时第一参考时刻E 1可以理解为,该数据包通过该入口边缘设备231时的任意一个时刻。例如。可以定义该第一参考时刻为该数据包被该入口边缘设备231的整形结构输出的时刻。例如,可以定义该第一参考时刻为该数据包被该入口边缘设备231输出的 时刻。例如。可以定义该第一参考时刻为该数据包进入该入口边缘设备231的时刻。也就是说,此时的第一参考时刻为预定义的时刻,该预定义的时刻可以为该数据包通过该第一网络设备时的任意一个时刻。
下面,介绍第二网络设备在下行板中确定第二参考时刻的方法。
在本申请实施例中,第二网络设备根据数据包携带的时间信息,确定第二参考时刻,包括:第二网络设备根据第一时延和第一处理时间,确定第二参考时刻。
其中,第二网络设备在下行板中根据第一时延和第一处理时间确定第二参考时刻,包括以下两种方法:
方法一:
第二网络设备根据第一时延和第一处理时间,确定第二参考时刻,包括:第二网络设备根据第一时延、第一参考时刻、数据包被第一网络设备输出的第一输出时刻和第一时刻,确定第二参考时刻。
在一些实施例中,第二网络设备根据第一时延、第一参考时刻、数据包被第一网络设备输出的第一输出时刻和第一时刻,确定第二参考时刻,包括:第二网络设备根据以下公式确定第二参考时刻:
Figure PCTCN2021104191-appb-000037
其中,E 2为第二参考时刻,
Figure PCTCN2021104191-appb-000038
为第一时刻,
Figure PCTCN2021104191-appb-000039
为第一时延,
Figure PCTCN2021104191-appb-000040
为第一处理时间,
Figure PCTCN2021104191-appb-000041
为数据包被第一网络设备输出的第一输出时刻,E 1为第一参考时刻,
Figure PCTCN2021104191-appb-000042
为第一剩余处理时间。
需说明的是,当第一网络设备为转发数据包的第一个网络设备时,第一参考时刻可以理解为,该数据包通过该第一网络设备时的任意一个时刻。例如。可以定义该第一参考时刻为该数据包被该第一网络设备的整形结构输出的时刻。例如,可以定义该第一参考时刻为该数据包被该第一网络设备输出的时刻。例如。可以定义该第一参考时刻为该数据包进入该第一网络设备的时刻。也就是说,此时的第一参考时刻为预定义的时刻,该预定义的时刻可以为该数据包通过该第一网络设备时的任意一个时刻。
上述方法一中确定第二参考时刻的方法,与第二网络设备在上行板中确定第二参考时刻的方法相同。
方法二:
第二网络设备根据第一时延和第一处理时间,确定第二参考时刻,包括:第二网络设备根据第一时延、第一参考时刻、数据包被第一网络设备输出的第一输出时刻、数据包通过第二网络设备的交换结构处理后的时刻和第一时刻,确定第二参考时刻,其中数据包通过第二网络设备的交换结构处理后的时刻小于第二参考时刻。
在一些实施例中,第二网络设备根据第一时延、第一参考时刻、数据包被第一网络设备输出的第一输出时刻、数据包通过第二网络设备的交换结构处理后的时刻和第一时刻,确定第二参考时刻,包括:第二网络设备根据以下公式确定第二参考时刻:
Figure PCTCN2021104191-appb-000043
其中,E 2为第二参考时刻,
Figure PCTCN2021104191-appb-000044
为数据包通过第二网络设备的交换结构处理后的时刻,
Figure PCTCN2021104191-appb-000045
为第一剩余处理时间,
Figure PCTCN2021104191-appb-000046
为第一处理时间,
Figure PCTCN2021104191-appb-000047
为第一时延,
Figure PCTCN2021104191-appb-000048
为数据包被第一网络设备输出的第一输出时刻,E 1为第一参考时刻,
Figure PCTCN2021104191-appb-000049
为第一时刻。
需说明的是,当第一网络设备为转发数据包的第一个网络设备时,第一参考时刻可以理解为,该数据包通过该第一网络设备时的任意一个时刻。例如。该第一参考时刻可以是该数据包被该第一网络设备的整形结构输出的时刻。例如,该第一参考时刻可以是该数据包被该第一网络设备输出的时刻。例如。该第一参考时刻可以是该数据包进入该第一网络设备的时刻。也就是说,此时的第一参考时刻为预定义的时刻,该预定义的时刻可以为该数据包通过该第一网络设备时的任意一个时刻。
下面,结合图9和图10具体介绍第二网络设备在下行板确定第二参考时刻的过程中涉及到的各个时刻。
图9示出了示出了本申请实施例提供的第二网络设备在下行板确定第二参考时刻的时序图。其中,图9中包括的各个单元或结构的功能可以参见图7。需说明的是,图9所示的循环队列单元和出队列单元仅仅是逻辑上的单元结构。在实际应用中,循环队列单元和出队列单元可以包括在同一个物理单元中。或者,循环队列单元和出队列单元可以分别对应两个物理单元。
在图9中,网络设备232可以理解为接收数据包的第二个网络设备,网络设备233可以理解为接收数据包的第三个网络设备。其中,
Figure PCTCN2021104191-appb-000050
为网络设备232接收到来自上一跳网络设备发送的数据包的时刻;
Figure PCTCN2021104191-appb-000051
为数据包被网络设备232的交换结构输出的时刻;E 1为指导数据包进入网络设备232的队列系统中的队列的参考时刻,即第一参考时刻;
Figure PCTCN2021104191-appb-000052
为数据包被网络设备232输出的第一输出时刻;
Figure PCTCN2021104191-appb-000053
为网络设备233接收到网络设备232发送的数据包的时刻,即第一时刻;
Figure PCTCN2021104191-appb-000054
为数据包被网络设备233的交换结构输出的时刻;E 2为指导数据包进入网络设备233的队列系统中的队列的参考时刻,即第二参考时刻;
Figure PCTCN2021104191-appb-000055
为数据包被网络设备233输出的第二输出时刻;
Figure PCTCN2021104191-appb-000056
为第一参考时刻E 1至第二参考时刻E 2之间的时间(不包括数据包被网络设备232输出的时刻至数据包进入网络设备233的时刻之间的时间,即
Figure PCTCN2021104191-appb-000057
)。
应理解,图9仅为示意并不对本申请实施例构成任何限定。例如,在一些实施例中,当图9中的网络设备232为图2中的网络设备233时,图9中的网络设备233可以为图2中的网络设备234。例如,在一些实施例中,当图9中的网络设备232为图2中的网络设备234时,图9中的网络设备233可以为图2中的出口边缘设备235。
图10示出了本申请实施例提供的另一种第二网络设备在下行板确定第二参考时刻的时序图。其中,图10中包括的各个单元或结构的功能可以参见图8。应理解,图10中示出的各个时刻仅为示意并不对本申请构成任何限定。需说明的是,图10所示的循环队列单元和出队列单元仅仅是逻辑上的单元结构。在实际应用中,循环队列单元和出队列单元可以包括在同一个物理单元中。或者,循环队列单元和出队列单元可以分别对应两个物理单元。
在图10中,入口边缘设备231可以理解为接收数据包的第一个网络设备,入口边缘设备231可以理解为接收数据包的第二个网络设备。其中,
Figure PCTCN2021104191-appb-000058
为入口边缘设备231接收到来自上一跳网络设备发送的数据包的时刻;
Figure PCTCN2021104191-appb-000059
为数据包进入入口边缘设备231的整形结构的时刻;E 1为指导数据包从入口边缘设备231的整形结构输出的时刻,即第一参考时刻的一例;
Figure PCTCN2021104191-appb-000060
为数据包被入口边缘设备231输出的第一输出时刻;
Figure PCTCN2021104191-appb-000061
为网络设备232接收到入口边缘设备231发送的数据包的时刻,即第一时刻;
Figure PCTCN2021104191-appb-000062
为数据包被网络设备232的交换 结构输出的时刻;E 2为指导数据包进入网络设备232的队列系统中的队列的参考时刻,即第二参考时刻;
Figure PCTCN2021104191-appb-000063
为数据包被网络设备232输出的第二输出时刻;
Figure PCTCN2021104191-appb-000064
为第一参考时刻E 1至第二参考时刻E 2之间的时间(不包括数据包被入口边缘设备231输出的时刻至数据包进入网络设备232的时刻之间的时间,即
Figure PCTCN2021104191-appb-000065
)。
需说明的是,在图10中,由于入口边缘设备231为转发数据包的第一个网络设备(即首跳设备),此时第一参考时刻E 1可以理解为,该数据包通过该入口边缘设备231时的任意一个时刻。例如。可以定义该第一参考时刻为该数据包被该入口边缘设备231的整形结构输出的时刻。例如,可以定义该第一参考时刻为该数据包被该入口边缘设备231输出的时刻。例如。可以定义该第一参考时刻为该数据包进入该入口边缘设备231的时刻。也就是说,此时的第一参考时刻为预定义的时刻,该预定义的时刻可以为该数据包通过该入口边缘设备231时的任意一个时刻。
步骤430,第二网络设备根据第二参考时刻从第二队列系统包括的多个队列中确定目标队列并将数据包加入目标队列。
应理解的是,当在第二网络设备的上行板中确定第二参考时刻时,第二网络设备可以根据第二参考时刻确定数据包进入上行板中的目标队列。当在第二网络设备的下行板中确定第二参考时刻时,第二网络设备可以根据第二参考时刻确定数据包进入下行板中的目标队列。
在一些实施例中,第二队列系统包括的多个队列与多个预设时刻一一对应,多个预设时刻中任意两个相邻预设时刻的差为第一值,预设时刻可以理解为队列开启的时刻。
其中,第一值可以为预定义的值。例如,可以根据具体的应用场景或者设备能力设置第一值。例如,可以设置第一值为10微秒。或者,可以设置第一值为15微秒。
图11示出了本申请实施例提供的第二队列系统的示意图。
如图11所示,该第二队列系统包括M个队列,分别为队列Q1,队列Q2,队列Q3,……,队列QM,M为大于3的正整数。该M个队列与M个预设时刻一一对应。
在一些实施例中,队列Q1的优先级大于队列Q2的优先级,队列Q2的优先级大于队列Q3的优先级,以此类推。
参见图11,队列Q1至队列QM中的任意两个相邻队列(例如队列Q1和队列Q2,队列Q2和队列Q3)之间的时间间隔为Δ(即第一值)。假设起始时刻为T,那么队列Q1对应的预设时刻为T+Δ,队列Q2对应的预设时刻为T+2×Δ,队列Q3对应的预设时刻为T+3×Δ,以此类推,队列QM对应的预设时刻为T max。参见图11,该M个队列也可以是循环队列,在系统时间超过时刻T max之后,该M个队列继续以时间间隔Δ循环。例如,队列Q1对应的预设时刻与队列QM对应的预设时刻的时间间隔为Δ,换句话说,队列Q1对应的预设时刻为T max+Δ。类似的,队列Q2对应的预设时刻与队列Q1对应的预设时刻的时间间隔为Δ,换句话说,队列Q2对应的预设时刻为T max+2×Δ,以此类推。其中,确定循环队列的方法参见下文步骤440。
基于上述第二队列系统的设置方式,第二网络设备根据第二参考时刻从第二队列系统包括的多个队列中确定目标队列,包括:
第二网络设备根据第二参考时刻,确定第一目标时刻对应的第二队列系统包括的多个队列中的一个队列为目标队列,第一目标时刻为第二参考时刻与第二值的和,第二值为第 二参考时刻与第三时刻的差的绝对值加上第一值的整数倍,第二参考时刻与第三时刻之间不包括多个预设时刻中的任一个时刻,第三时刻是多个预设时刻中的一个时刻且该第三时刻大于第二参考时刻,第一目标时刻是多个预设时刻中的一个时刻。
例如,参见图11,第一值为Δ,第二参考时刻E 2=T+1.5×Δ,此时,第三时刻为T+2×Δ。
上述第二值为第二参考时刻与第三时刻的差的绝对值加上第一值的整数倍,具体的,第二值为第二参考时刻与第三时刻的差的绝对值加上第一值的n倍,n可以为负整数(例如,n=-1),n也可以为正整数(例如,n=1,2等),n还可以为零。应理解的是,由于第一值的取值非常小,所以第二参考时刻与第三时刻的差的绝对值与第二参考时刻与第三时刻的差的绝对值加上第一值的n倍近似相等。还应理解的是,当n为零时,第三时刻与第一目标时刻为同一个时刻。
参见图11,第一值为Δ,第二参考时刻E 2=T+1.5×Δ。当n=-1时,第三时刻为T+2×Δ时,第二值为|E 2-(T+2×Δ)|+(-1×Δ)=-0.5×Δ。因此,第一目标时刻为E 2-0.5×Δ=T+Δ。在此情况下,目标队列为队列Q1。当n=1时,第三时刻为T+2×Δ时,第二值为|E 2-(T+2×Δ)|+(1×Δ)=1.5×Δ。因此,第一目标时刻为E 2+1.5×Δ=T+3Δ。在此情况下,目标队列为队列Q3。当n=0时,第三时刻为T+2×Δ时,第二值为|E 2-(T+2×Δ)|+(0×Δ)=0.5×Δ。因此,第一目标时刻为E 2+0.5×Δ=T+2Δ。在此情况下,目标队列为队列Q2。
需说明的是,在实际应用中,上述第一值的n倍对于第二网络设备接收的同一条流包括的每个数据包来说是相同的值。也就是说,此时n为一个固定的取值。例如,在场景A中,第二网络设备在某个时刻接收业务流A,此时在确定与业务流A包括的每个数据包对应的第一目标时刻的过程中,设置n=-1。
应理解,图11仅为示意并不对本申请提供的根据第二参考时刻确定目标队列的方法构成任何限定。
还应理解的是,以数据包被加入目标队列的时刻为起始时刻,在经过一段固定时间(即第二网络设备包括的多个队列中任意两个相邻开启的队列的开启时刻间隔,即第一值)后,该数据包通过该第二网络设备的上一跳的剩余处理时间(即数据包通过第一网络设备的第一剩余处理时间)在第二网络设备中被消耗掉。
在另一些实施例中,第二队列系统可以包括N个一级队列和M个二级队列,N和M为大于等于1的正整数。N个一级队列与N个第一预设时刻对应,M个二级队列与M个第二预设时刻对应。任意两个相邻第一预设时刻的差为第一值,任意两个相邻第二预设时刻的差为第二值,且第一值小于第二值。任意一个一级队列的优先级高于任意一个二级队列的优先级。
根据上述第二队列系统的设置方式,第二网络设备根据第二参考时刻确定目标队列,包括:
第二网络设备根据第二参考时刻、N个第一预设时刻和M个第二预设时刻,确定数据包进入第二队列系统包括的多个队列中的一个队列。
应理解的是,当第二网络设备确定该数据包在某个时刻既可以进入N个一级队列中的一个队列又可以进入M个二级队列中的一个队列时,第二网络设备确定该数据包进入该 M个二级队列中的一个队列。
还应理解的是,根据上述第二队列系统的设置方式,第二网络设备都在N个一级队列中的一个队列将数据包发送至第三网络设备。也就是说,若第二网络设备确定将该数据包加入M个二级队列中的一个队列,则在此之后第二网络设备还会将该数据包从该数据包所在的M个二级队列中的一个队列出队并将该数据包加入N个一级队列中的一个队列。
根据上述第二队列系统的设置方式,第二网络设备确定数据包出队的方法,包括:
第二网络设备确定数据包从N个一级队列中的一个队列发送至第三网络设备的方法。具体的,第二网络设备可以根据N个一级队列对应的调度规则将该数据包发送至第三网络设备。其中,N个一级队列对应的调度规则可以是预先定义的调度规则。N个一级队列对应的调度规则也可以是与队列优先级相关的调度规则。本申请对此不作限定。
第二网络设备确定数据包从M个二级队列中的一个队列出队并入队至N个一级队列中的一个队列的方法。具体的,在数据包所加入的二级队列开启后,第二网络设备可以根据第二参考时刻将该数据包从该数据包所加入的二级队列出队并加入N个一级队列中的一个队列。
应理解的是,上述N个一级队列为一个循环队列,上述M个二级队列为另一个循环队列。也就是说,N个一级队列的循环方式与M个二级队列的循环方式互不影响。
步骤440,第二网络设备根据第二队列系统对应的调度规则将数据包发送至第三网络设备。
当时间信息包括第一处理时间时(参见图6中的格式四),在步骤440之前,还包括:
第二网络设备对数据包报头携带的第一处理时间进行更新。具体地,将数据包报头携带的第一处理时间更新为数据包被第二网络设备输出的第一输出时刻与第二参考时刻的差。
当时间信息包括数据包被第一网络设备输出的第一输出时刻(参见图6中的第三时间值)和第一参考时刻(参见图6中的第四时间值)时,在步骤440之前,还包括:
第二网络设备将数据包报头携带的数据包被第一网络设备输出的第一输出时刻更新为数据包被第二网络设备输出的第二输出时刻,以及将数据包报头携带的第一参考时刻更新为第二参考时刻。
在本申请实施例中,第二网络设备根据第二队列系统对应的调度规则将数据包发送至第三网络设备,包括:
第二网络设备确定目标队列为第二队列系统包括的多个队列中当前时刻被调度的队列,以及目标队列为开启状态,第二网络设备将数据包发送至第三网络设备。
可选地,在第二网络设备根据第二队列系统对应的调度规则将数据包发送至第三网络设备之后,还包括:
第二网络设备在目标队列满足第一预设条件的情况下,确定关闭目标队列。
其中,第一预设条件包括:目标队列为空队列,且目标队列的开启时长大于等于第一值,第一值为多个预设时刻中任意两个相邻预设时刻的差,多个预设时刻与第二队列系统包括的多个队列一一对应。
其中,第一值为预定义的值。第一值可以根据具体的应用场景或者设备能力设置第一值。例如,可以设置第一值为10微秒。或者,可以设置第一值为15微秒。
在一些实施例中,第二网络设备确定目标队列为第二队列系统包括的多个队列中当前时刻被调度的队列,包括:
当第二网络设备确定目标队列为第二队列系统包括的多个队列中优先级最高的队列时,第二网络设备确定目标队列为第二队列系统包括的多个队列中当前时刻被调度的队列;
在第二网络设备确定关闭目标队列之后,方法还包括:
第二网络设备将目标队列的优先级设置为第二队列系统包括的多个队列中优先级最低的队列,并将第二队列系统包括的多个队列中除目标队列之外的队列的优先级提升。
在上述方案中,网络设备按照严格优先级进行对第二队列系统包括的队列进行调度。换句话说,该网络设备按照优先级顺序调度对第二队列系统包括的队列进行调度,如果优先级高的队列中的数据包没有完成调度,那么该网络设备不会开始调度下一优先级的队列中的数据包。还应理解的是,在高优先级的队列排空但该高优先级的队列还没有被关闭的情况下,网络设备可以开始调度次高优先级的队列中的数据包。
例如,第二队列系统包括3个队列分别为队列1(优先级为1)、队列2(优先级为2)和队列3(优先级为3),其中,优先级1>优先级2>优先级3。由于队列1的优先级最高,第二网络设备可以确定队列1为目标队列。当第二网络设备已经完成对队列1中的所有数据包的调度后且该队列1的开启时长满足预设条件时,第二网络设备关闭队列1,同时,第二网络设备将队列2的优先级设置为1,队列3的优先级设置为2,队列1的优先级设置为3。在上述数据包的调度过程中,在第二网络设备已经完成对队列1中的所有数据包的调度后且队列1还未被关闭的情况下,第二网络设备可以开始对队列2中的数据包进行调度。
在另一些实施例中,第二队列系统包括的多个队列与多个预设调度顺序一一对应,第二网络设备确定目标队列为第二队列系统包括的多个队列中当前时刻被调度的队列,包括:
当第二网络设备根据多个预设调度顺序确定目标队列对应的预设调度顺序为第二网络设备在当前时刻调度的队列对应的调度顺序时,第二网络设备确定目标队列为第二队列系统包括的多个队列中当前时刻被调度的队列。
在上述方案中,网络设备可以按照预先定义好的调度顺序对第二队列系统包括的队列进行调度,具体调度队列过程中网络设备不需要比较每个队列的优先级。
可选地,在第二网络设备确定关闭目标队列之后,还包括:
第二网络设备根据第一信息,确定第二目标时刻,第二目标时刻对应于目标队列,第二目标时刻为在第一目标时刻后目标队列对应的开启的时刻,第二目标时刻大于多个预设时刻中的任意一个预设时刻,第一信息包括第二队列系统包括的每个队列对应的调度顺序和第二队列系统包括的每个队列对应的开启的时刻;
其中,第二队列系统包括的多个队列与多个预设时刻一一对应,多个预设时刻中任意两个相邻预设时刻的差为第一值,第一目标时刻对应的第二队列系统包括的多个队列中的一个队列为目标队列,第一目标时刻为第二参考时刻与第二值的和,第二值为第二参考时刻与第三时刻的差的绝对值加上第一值的整数倍,第二参考时刻与第三时刻之间不包括多个预设时刻中的任一个时刻,第三时刻是多个预设时刻中的一个时刻且第三时刻大于第二 参考时刻,第一目标时刻是多个预设时刻中的一个时刻。具体的,确定第二值和第三时刻的方法参见步骤430,此处不再详细赘述。
其中,第二队列系统包括的每个队列对应的开启的时刻可以为预定义。第二队列系统包括的每个队列对应的调度顺序可以是预定义的。
在上述方案中,第二网络设备可以循环利用第二队列系统包括的每个队列,从而提高资源利用率。
下面,结合图12介绍数据包经过上述第一网络设备和第二网络设备转发后的时延。应理解,图12仅为示意并不对本申请构成任何限定。例如,还可以以图7包括的网络设备分析数据包经过上述第一网络设备和第二网络设备转发后的时延。
还应理解的是,由于图12中的入口边缘设备231为转发数据包的第一个网络设备(即首跳设备),所以此时第一参考时刻E 1可以理解为,该数据包通过该入口边缘设备231时的任意一个时刻。例如。可以定义该第一参考时刻为该数据包被该入口边缘设备231的整形结构输出的时刻。例如,可以定义该第一参考时刻为该数据包被该入口边缘设备231输出的时刻。例如。可以定义该第一参考时刻为该数据包进入该入口边缘设备231的时刻。也就是说,此时的第一参考时刻为预定义的时刻,该预定义的时刻可以为该数据包通过该入口边缘设备231时的任意一个时刻。为了便于描述,在图12中,仅以第一参考时刻E 1该数据包被该入口边缘设备231输出的时刻为例进行介绍。
参见图12,
Figure PCTCN2021104191-appb-000066
为数据包被入口边缘设备231(即,第一网络设备的一例)接收至该数据包被入口边缘设备231入队至该入口边缘设备231的队列的最大时延;
Figure PCTCN2021104191-appb-000067
为该数据包被入口边缘设备231的整形结构输出至该数据包入队至网络设备232(即,第二网络设备的一例)的队列的最大时延(不包括
Figure PCTCN2021104191-appb-000068
);
Figure PCTCN2021104191-appb-000069
为该数据包被网络设备232入队至网络设备232的队列至该数据包被网络设备232输出的最大时延。图12中其余参数的含义与图8中参数的含义相同,此处不再详细赘述。其中,
Figure PCTCN2021104191-appb-000070
Figure PCTCN2021104191-appb-000071
均为预定义的值。例如,可以根据具体的应用场景或者设备能力进行设置。例如,在网络环境良好的情况下,可以设置
Figure PCTCN2021104191-appb-000072
Figure PCTCN2021104191-appb-000073
都为10微秒(或者5微秒)。或者,在网络环境良好的情况下,还可以设置
Figure PCTCN2021104191-appb-000074
为5微秒,设置
Figure PCTCN2021104191-appb-000075
为10微秒,设置
Figure PCTCN2021104191-appb-000076
为5微秒。例如,在网络环境较差的情况下,可以设置
Figure PCTCN2021104191-appb-000077
Figure PCTCN2021104191-appb-000078
都为10微秒(或者50微秒)。或者,在网络环境较差的情况下还可以
Figure PCTCN2021104191-appb-000079
为50微秒,设置
Figure PCTCN2021104191-appb-000080
为100微秒,设置
Figure PCTCN2021104191-appb-000081
为50微秒等。
根据本申请提供的发送数据包的方法,在数据包经过入口边缘设备231转发后的剩余处理时间大于零的情况下,在该数据包进入网络设备232后,网络设备232根据该剩余处理时间以及该网络设备232接收到该数据包的时刻,确定该数据包入队至该网络设备232的一个队列中。以该数据包进入至该网络设备232的一个队列的时刻为起始时刻,经过一段时间到该数据包对应的第二参考时刻为止,该剩余处理时间在该网络设备232中被消耗掉。因此,该数据包经过入口边缘设备231和网络设备232转发后的确定性时延为
Figure PCTCN2021104191-appb-000082
网络设备232对接收的流包括的每个数据包均采用本申请提供的发送数据包的方法后,可以保证该数据包所在的流进入该网络设备232和被该网络设备232输出的形状相同。
本申请实施例提供的发送数据包的方法,第二网络设备可以根据提前配置好的数据包 在第一网络设备中允许停留的最大时延确定该数据包在第一网络设备中的剩余处理时间,在该剩余处理时间大于零的情况下,以该数据包进入至该第二网络设备中的一个队列(即目标队列的一例)的时刻为起始时刻,经过一段时间到该数据包对应的第二参考时刻为止,该剩余处理时间在第二网络设备中被消耗掉,从而可以保证该数据包通过第一网络设备和第二网络设备转发后的确定性时延和抖动,进一步使得该数据包所在的流进入网络设备的形状和该数据包所在的流被网络设备输出后的形状相同。
与现有技术相比,本申请实施例提供的发送数据包的方法,不要求转发数据包的各网络设备的时间同步,对转发数据包的链路长度没有具体限定,可以适用于大规模网络中,提供确定性端到端时延上限和抖动上限。
下面结合图13和图14,介绍本申请实施例提供的发送数据包的方法的一个具体实施例。
图13示出了本申请实施例提供的发送数据包的方法的一个具体实施例。该方法包括步骤1210至步骤1250,下面对这些步骤进行详细介绍。应理解,图13仅为示意,并不对本申请构成任何限定。还应理解,图14中示出的各个时刻仅为示意,并不对本申请构成任何限定。例如,图14中的E 1还可以为数据包被入口边缘设备231输出的时刻。或者,图14中的E 1还可以为数据包进入入口边缘设备231的时刻。
步骤1210,入口边缘设备231获取数据流1,对数据流1进行整形处理。
入口边缘设备231可以利用漏桶(leaky bucket)算法对数据流1进行整形处理,使得整形后的数据流1满足下列公式:
A 1(t)=r 1×t+B 1
其中,t为时间;A 1(t)为t时间内数据流1的数据总流量;r 1为数据流1需要的带宽,B 1为数据流1的最大突发度;r 1为平均带宽,该平均带宽可以理解为数据流1在统计意义上的平均速度。
步骤1220,入口边缘设备231将携带时间信息1的数据包发送至网络设备232。
在步骤1220之前,还包括入口边缘设备231确定时间信息1。
其中,时间信息1用于指示数据包在入口边缘设备231中的剩余处理时间。该时间信息1可以包括数据包从入口边缘设备231的整形结构输出的时刻和数据包被入口边缘设备231输出的输出时刻,时间信息1被封装在数据包的报头中。为了便于描述,下面可以用参考时刻1表示数据包从入口边缘设备231的整形结构输出的时刻,由于入口边缘设备231为接收数据包的第一个网络设备(即首跳设备),所以参考时刻1为预定义的时刻。
具体的,参见图14,时间信息1包括E 1
Figure PCTCN2021104191-appb-000083
E 1为数据包从入口边缘设备231的整形结构输出的时刻,
Figure PCTCN2021104191-appb-000084
为数据包被入口边缘设备231输出的输出时刻。
步骤1230,网络设备232根据接收的数据包携带的时间信息1确定目标队列1。
其中,网络设备232根据接收的数据包携带的时间信息1确定目标队列1,包括:
网络设备232根据数据包携带的时间信息1,确定参考时刻2;以及网络设备232根据参考时刻2确定目标队列1。
其中,参考时刻2为指导数据包进入网络设备232的队列系统中的队列的参考时刻。
在确定参考时刻2之前,还包括网络设备232通过控制面获取时延1,时延1为数据包从入口边缘设备231的整形结构输出的时刻至参考时刻2之间的时间(不包括数据包被 入口边缘231输出的时刻至数据包被网络设备232接收的时刻之间的时间)。换句话说,时延1也可以理解为,以数据包从入口边缘设备231的整形结构输出的时刻为起始时刻,在经过该时延1(不包括数据包被入口边缘231输出的时刻至数据包被网络设备232接收的时刻之间的时间)后,该数据包一定会被入队到网络设备232的队列系统包括的多个队列中的一个队列。其中,时延1为预定义的值。
在一些实施例中,网络设备232可以根据以下公式确定参考时刻2:
Figure PCTCN2021104191-appb-000085
其中,E 2为参考时刻2,
Figure PCTCN2021104191-appb-000086
为数据包通过网络设备232的交换结构处理后的时刻,
Figure PCTCN2021104191-appb-000087
为数据包通过入口边缘设备231的剩余处理时间,
Figure PCTCN2021104191-appb-000088
为数据包在网络设备232的处理时延,
Figure PCTCN2021104191-appb-000089
为时延1,
Figure PCTCN2021104191-appb-000090
为数据包被第一网络设备输出的时刻,E 1为参考时刻1,
Figure PCTCN2021104191-appb-000091
为数据包进入网络设备232的时刻。
网络设备232根据参考时刻1,可以在网络设备232的下行板中确定目标队列1,具体确定目标队列1的方法与步骤430中的确定目标队列的方法相同,此处不再详细赘述。
应理解的是,在上述方案中以网络设备232接收网络设备231发送的数据包进入至该网络设备232中的一个队列(即目标队列1)的时刻为起始时刻,经过一段时间到参考时刻2为止,该数据包通过该网络设备231的剩余处理时间在该网络设备232中被消耗掉。
步骤1240,网络设备232将携带时间信息2的数据包发送至网络设备232。
在步骤1240之前,还包括网络设备232确定时间信息2,并将数据包报头中携带的时间信息1更新为时间信息2。其中,时间信息2可以包括参考时刻2和数据包被网络设备232输出的时刻。
对数据包报头携带的时间信息进行更新后,数据包携带的时间信息为时间信息2。
当网络设备232确定目标队列1的优先级(数据包所在的队列的优先级)为网络设备232包括的多个队列中优先级最高的队列,且目标队列1为开启状态时,网络设备232可以将携带时间信息2的数据包发送至网络设备232。
步骤1250,网络设备233根据接收的数据包携带的时间信息2确定目标队列2。
其中,网络设备233根据接收的数据包携带的时间信息2确定目标队列2,包括:
网络设备233根据数据包携带的时间信息2,确定参考时刻3;以及网络设备232根据参考时刻3确定目标队列2。
其中,参考时刻3为指导数据包进入网络设备233的队列系统中的队列的参考时刻。
在确定参考时刻3之前,还包括网络设备233通过控制面获取时延2,时延2为参考时刻2至参考时刻3之间的时间(不包括数据包被网络设备232输出的时刻至数据包被网络设备233接收的时刻之间的时间)。换句话说,时延2也可以理解为,以数据包从进入网络设备232的交换结构的时刻为起始时刻,在经过该时延2(不包括数据包被网络设备232输出的时刻至数据包被网络设备233接收的时刻之间的时间)后,该数据包一定会被调度到网络设备233的队列系统包括的多个队列中的一个队列。其中,时延2为预定义的值。
在一些实施例中,网络设备233可以根据以下公式确定参考时刻3:
Figure PCTCN2021104191-appb-000092
其中,E 3为参考时刻3,
Figure PCTCN2021104191-appb-000093
为数据包通过网络设备233的交换结构处理后的时刻,
Figure PCTCN2021104191-appb-000094
为数据包通过网络设备232的剩余处理时间,
Figure PCTCN2021104191-appb-000095
为数据包在网络设备232的处理时延,
Figure PCTCN2021104191-appb-000096
为时延2,
Figure PCTCN2021104191-appb-000097
为数据包被网络设备232输出的时刻,E 2为参考时刻2,
Figure PCTCN2021104191-appb-000098
为数据包进入网络设备233的时刻。
网络设备233根据参考时刻2,可以在网络设备233的下行板中确定网络设备233的多个队列中的一个队列为目标队列2,具体确定目标队列2的方法与步骤430中的确定目标队列的方法相同,此处不再详细赘述。
应理解的是,在上述方案中以网络设备233接收网络设备232发送的数据包进入至该网络设备233中的一个队列(即目标队列2)的时刻为起始时刻,经过一段时间到参考时刻3为止,该数据包通过该网络设备232的剩余处理时间在该网络设备233中被消耗掉。
基于上述方法,数据包经过入口边缘设备231至网络设备233转发处理后,可以确定转发该数据包的固定时延为时延1、时延2、时延3与时延4之和。其中,时延3为该数据包被入口边缘设备231接收至参考时刻1之间的时间(即图14中的
Figure PCTCN2021104191-appb-000099
),时延4为参考时刻3至该数据包被网络设备233输出的时刻之间的时间(即图14中的
Figure PCTCN2021104191-appb-000100
)。上述时延1、时延2、时延3与时延4为预定义的值。例如,可以设置时延1、时延2、时延3和时延4都为12微秒。本申请实施例提供的发送数据包的方法可以保证任意流的端到端时延上界不超过时延1、时延2、时延3与时延4之和。
本申请实施例提供的发送数据包的方法,可以保证数据包通过入口边缘设备231、网络设备232和网络设备233转发后的确定性时延和抖动,进一步使得该数据包所在的流进入网络设备的形状和该数据包所在的流被网络设备输出后的形状相同。
与现有技术相比,本申请实施例提供的发送数据包的方法,不要求转发数据包的各网络网络设备的时间同步,对转发数据包的链路长度也没有具体限定,可以适用于大规模网络中,提供确定性端到端时延上限和抖动上限。
需说明的是,图13中仅以数据包经过3个网络设备转发,且每个网络设备在下行板中确定参考时刻和根据该参考时刻确定数据包进入下行板中的目标队列为例介绍本申请提供的发送数据包的方法,但这并不对本申请构成任何限定。例如,数据包还可以经过更多(例如,5个网络设备或者10个网络设备等)或更少的网络设备(例如,2个网络设备)转发等。
以上,结合图2至图14详细介绍了本申请实施例提供的发送数据包的方法。下面结合图15具体介绍本申请实施提供的第二网络设备的功能模块。
图15示出了本申请实施提供的第二网络设备的功能模块。
如图15所示,该第二网络设备可以包括6个功能模块,按照每个功能模块处理数据包的时间顺序这6个功能模块依次为:时间信息捕捉模块(packet arrival time capture)、有界时延模块(bounded variable delay units)、报头更新模块(damper header update unit)、时延均等模块(latency equalizer)、排队子系统(queueing subsystem)以及报头插入模块(damper header insertion unit)。
下面,具体介绍上述各个功能模块的功能。
时间信息捕捉模块(packet arrival time capture):用于获取方法400中的时间信息以及参考时刻(例如,第一参考时刻或第二参考时刻)。
有界时延模块(bounded variable delay units):用于对数据包进行解析、查表、交换 网转发等。其中,上述任意一个对数据包的处理均有着一个可预知的最大时延上界。
需说明的是,时间信息捕捉模块和有界时延模块共同用于获取方法400中的时间信息以及参考时刻。
报头更新模块(damper header update unit):用于对数据包携带的时间信息(即,方法400中的时间信息)进行更新。
时延均等模块(latency equalizer):用于对进入网络设备中的数据包等待一定时间后将该数据包加入该网络设备的队列中。具体的,该网络设备通过循环门控的调度方式实现数据包的主动等待。数据包经过时延均等模块(latency equalizer)后,可以完成对数据包的整形。
排队子系统(queueing subsystem):用于对网络设备的包括的多个队列进行排队管理。
报头插入模块(damper header insertion unit):用于在数据包被网络设备输出至该网络设备的下一跳网络设备之前,将与该网络设备相关的时间信息(即,方法400中的时间信息)插入该数据包的报文头中。
图16示出了本申请实施提供的发送数据包的网络设备的功能模块。
如图16所示,包括3个网络设备,分别为网络设备#1、网络设备#2和网络设备#3。网络设备#1和网络设备#3包括图15中的第二网络设备包括的所有功能模块。网络设备#2仅仅包括图15中的第二网络设备包括的4个功能模块,按照各模块处理数据包的顺序这4个功能模块依次为时间信息捕捉模块(packet arrival time capture)、有界时延模块(bounded variable delay units)、排队子系统(queueing subsystem)和报头插入模块(damper header insertion unit)。
下面,结合本申请实施例提供的发送数据包的方法400,具体介绍数据包经过网络设备包括的各个模块的处理过程。
假设已经知道数据包在网络设备1中可能经历的最大时延为
Figure PCTCN2021104191-appb-000101
数据包在网络设备2中可能经历的最大时延为
Figure PCTCN2021104191-appb-000102
数据包在网络设备3中可能经历的最大时延为
Figure PCTCN2021104191-appb-000103
且数据包在进入网络设备1之前已经被其上一跳设备打上了该数据包在上一跳设备中剩余处理时间。
网络设备1按照本申请实施例提供的发送数据包的方法处理接收的数据包,在满足预设条件后网络设备1将该数据包发送给网络设备2。
网络设备2接收到网络设备1发送的该数据包后继续按照本申请实施例提供的发送数据包的方法处理该数据包。但是由于网络设备2的功能模块中没有时延均等模块(latency equalizer),因此在网络设备2中只能按照默认的调度方式对数据包进行转发。由于网络设备2的功能模块包括时间信息捕捉模块(packet arrival time capture)和报头插入模块(damper header insertion unit),因此在网络设备2中可以通过时间信息捕捉模块(packet arrival time capture)确定该数据包通过该网络设备2的处理时间(例如,处理时间可以为数据包进入网络设备2的交换结构的时间至数据包被网络设备2输出的输出时刻之间的时间),并利用报头插入模块(damper header insertion unit)将该处理时间插入该数据包的报头,然后在满足预设条件后网络设备2将该数据包发送给网络设备3。
数据包经过网络设备1和网络设备2处理后,该数据包携带的时间信息用于指示数据包通过网络设备1的剩余处理时间与数据包通过网络设备2的剩余处理时间的和。
网络设备3接收到网络设备2发送的数据包后,根据该数据包携带的时间信息,将数据包在网络设备3中按照本申请实施例提供的发送数据包的方法进行处理。其中,数据包在网络设备3中主动等待的时间包括数据包通过网络设备1的剩余处理时间与数据包通过网络设备2的剩余处理时间的和。
基于上述方法,可以在部分网络设备(网络设备#1和网络设备#3)中实现数据包的主动等待的功能,可以在所有网络设备上实现获取时间信息的能力,从而可以保证端到端的确定性时延和抖动。
图17示出了本申请实施提供的发送数据包的网络设备的功能模块。
如图17所示,包括3个网络设备,分别为网络设备#1、网络设备#2和网络设备#3。网络设备#1和网络设备#3包括图15中的第二网络设备包括的所有功能模块。网络设备#2仅仅包括图15中的第二网络设备包括的2个功能模块,按照各模块处理数据包的顺序这2个功能模块依次为有界时延模块(bounded variable delay units)和排队子系统(queueing subsystem)。
下面,结合本申请实施例提供的方法数据包的方法,具体介绍数据包经过网络设备包括的各个模块的处理过程。
假设已经知道数据包在网络设备1中可能经历的最大时延为
Figure PCTCN2021104191-appb-000104
数据包在网络设备2中可能经历的最大时延为
Figure PCTCN2021104191-appb-000105
数据包在网络设备3中可能经历的最大时延为
Figure PCTCN2021104191-appb-000106
且数据包在进入网络设备1之前已经被其上一跳设备打上了该数据包在上一跳设备中剩余处理的时间。
网络设备1按照本申请实施例提供的发送数据包的方法处理接收的数据包,在满足预设条件后网络设备1将该数据包发送给网络设备2。
网络设备2接收到网络设备1发送的该数据包后,按照网络设备2中预定义的方法对数据包进行调度。
数据包经过网络设备1和网络设备2处理后,该数据包携带的时间信息用于指示数据包通过网络设备1的剩余处理时间。
网络设备3接收到网络设备2发送的数据包后,根据该数据包携带的时间信息,将数据包在网络设备3中按照本申请实施例提供的发送数据包的方法进行处理。其中,数据包在网络设备3中主动等待的时间为数据包通过网络设备1的剩余处理时间。
根据本申请实施例提供的方法,可以确定任意流离开网络设备1的“时延均等”模块之后的流量形状,与该任意流进入网络设备1时的流量形状完全一致。由于,又知道经过网络设备1和网络设备2的所有流的流量特征,所以可以知道,该任意流在经过网络设备1的排队子系统之后和经过网络设备2之后该任意流的具体形状,因此也可以计算该任意流在网络设备3上的最坏时延上界。
基于上述方法,可以在部分网络设备(网络设备#1和网络设备#3)中实现数据包的主动等待的功能和获取时间信息的能力,从而可以保证端到端的确定性时延和抖动。
在本申请实施例中,某条流经过网络设备3的时延均等模块(latency equalizer)后的形状与其经过网络设备1的时延均等模块(latency equalizer)后的形状相比,突发度变大了。与图16所示的网络设备的功能相比,在本申请实施例中数据包经过网络设备3的时延上界变大了,从而使得端到端的时延上限和抖动上限变大了。
下面,结合图18和图19详细介绍本申请提供的第二网络设备和第二网络设备的硬件结构。
图18示出了本申请实施例提供的第二网络设备1700的示意性结构图。
参见图18,该第二网络设备1700包括:收发单元1710、处理单元1720。其中,收发单元1710和处理单元1720之间通过内部连接通路互相通信,传递控制和/或数据信号。
收发单元1710,用于在第一时刻接收第一网络设备发送的数据包;
该处理单元1720,用于根据该数据包携带的时间信息,确定第二参考时刻,该第二参考时刻为指导该数据包进入第二队列系统中的队列的参考时刻,该第二队列系统为该第二网络设备的队列系统,该时间信息用于指示该数据包通过该第一网络设备的第一剩余处理时间,该第一剩余处理时间为第一时延与第一处理时间的差,该第一时延为不小于第一理论时间上限与第一传输时间的差的绝对值的值,该第一理论时间上限为第一参考时刻至该第二参考时刻的理论处理时间上限,该第一参考时刻为指导该数据包进入第一队列系统中的队列的参考时刻,该第一队列系统为该第一网络设备的队列系统,该第一传输时间为该数据包被该第一网络设备输出的第一输出时刻至该第一时刻的实际传输时间,该第一处理时间为该第一参考时刻至该数据包被该第一网络设备输出的第一输出时刻的实际处理时间;
该处理单元1720,还用于根据该第二参考时刻从该第二队列系统包括的多个队列中确定目标队列并将该数据包加入该目标队列;
该处理单元1720,还用于根据该第二队列系统对应的调度规则将该数据包发送至第三网络设备。
可选地,在一些实施例中,该第二队列系统包括的多个队列与多个预设时刻一一对应,该多个预设时刻中任意两个相邻预设时刻的差为第一值,该处理单元1720还用于:
根据该第二参考时刻,确定第一目标时刻对应的该第二队列系统包括的多个队列中的一个队列为该目标队列,该第一目标时刻为该第二参考时刻与第二值的和,该第二值为该第二参考时刻与第三时刻的差的绝对值加上该第一值的整数倍,该第二参考时刻与该第三时刻之间不包括该多个预设时刻中的任一个时刻,该第一目标时刻是该多个预设时刻中的一个时刻。
可选地,在一些实施例中,该处理单元1720还用于:根据该第一时延和该第一处理时间,确定该第二参考时刻。
可选地,在一些实施例中,该处理单元1720还用于:根据该第一时延、该第一参考时刻、该数据包被该第一网络设备输出的第一输出时刻和该第一时刻,确定该第二参考时刻。
可选地,在一些实施例中,该处理单元1720还用于:根据以下公式确定该第二参考时刻:
Figure PCTCN2021104191-appb-000107
其中,E 2为该第二参考时刻,
Figure PCTCN2021104191-appb-000108
为该第一时刻,
Figure PCTCN2021104191-appb-000109
为该第一时延,
Figure PCTCN2021104191-appb-000110
为该数据包被该第一网络设备输出的第一输出时刻,E 1为该第一参考时刻。
可选地,在一些实施例中,该处理单元1720还用于:
根据该第一时延、该第一参考时刻、该数据包被该第一网络设备输出的第一输出时刻、 该数据包通过该第二网络设备的交换结构处理后的时刻和该第一时刻,确定该第二参考时刻,其中该数据包通过该第二网络设备的交换结构处理后的时刻小于该第二参考时刻。
可选地,在一些实施例中,该处理单元1720还用于:根据以下公式确定该第二参考时刻:
Figure PCTCN2021104191-appb-000111
其中,E 2为该第二参考时刻,
Figure PCTCN2021104191-appb-000112
为该数据包通过该第二网络设备的交换结构处理后的时刻,
Figure PCTCN2021104191-appb-000113
为该第一时延,
Figure PCTCN2021104191-appb-000114
为该数据包被该第一网络设备输出的第一输出时刻,E 1为该第一参考时刻,
Figure PCTCN2021104191-appb-000115
为该第一时刻。
可选地,在一些实施例中,该时间信息包括第一时间值,该第一时间值为该第一剩余处理时间。
可选地,在一些实施例中,该时间信息包括第一指示信息,该第一指示信息用于指示该第一处理时间。
可选地,在一些实施例中,该第一指示信息包括第二时间值,该第二时间值为该第一处理时间。
可选地,在一些实施例中,该第一指示信息包括第三时间值和第四时间值,该第三时间值为该数据包被该第一网络设备输出的第一输出时刻,该第四时间值为该第一参考时刻。
可选地,在一些实施例中,该时间信息还包括第二指示信息,该第二指示信息用于指示该第一时延。
可选地,在一些实施例中,该处理单元1720还用于:确定该目标队列为该第二队列系统包括的多个队列中当前时刻被调度的队列,以及该目标队列为开启状态;
该收发单元1710还用于:根据该第二队列系统对应的调度规则将该数据包发送至第三网络设备。
可选地,在一些实施例中,该处理单元1720还用于:在该目标队列满足第一预设条件的情况下,确定关闭该目标队列。
可选地,在一些实施例中,该处理单元1720还用于:根据第一信息,确定第二目标时刻,该第二目标时刻对应于该目标队列,该第二目标时刻为在第一目标时刻后该目标队列对应的开启的时刻,该第二目标时刻大于多个预设时刻中的任意一个预设时刻,该第一信息包括该第二队列系统包括的每个队列对应的调度顺序和该第二队列系统包括的每个队列对应的开启的时刻;
其中,该第二队列系统包括的多个队列与该多个预设时刻一一对应,该多个预设时刻中任意两个相邻预设时刻的差为第一值,该第一目标时刻对应的该第二队列系统包括的多个队列中的一个队列为该目标队列,该第一目标时刻为该第二参考时刻与第二值的和,该第二值为该第二参考时刻与第三时刻的差的绝对值加上该第一值的整数倍,该第二参考时刻与该第三时刻之间不包括该多个预设时刻中的任一个时刻,该第一目标时刻是该多个预设时刻中的一个时刻。
可选地,在一些实施例中,该处理单元1720还用于:
当确定该目标队列为该第二队列系统包括的多个队列中优先级最高的队列时,确定该目标队列为该第二队列系统包括的多个队列中当前时刻被调度的队列;
将该目标队列的优先级设置为该第二队列系统包括的多个队列中优先级最低的队列,并将该第二队列系统包括的多个队列中除该目标队列之外的队列的优先级提升。
可选地,在一些实施例中,该第二队列系统包括的多个队列与多个预设调度顺序一一对应,该处理单元1720还用于:根据该多个预设调度顺序确定该目标队列对应的预设调度顺序为该第二网络设备在该当前时刻调度的队列对应的调度顺序时,确定该目标队列为该第二队列系统包括的多个队列中当前时刻被调度的队列。
可选地,在一些实施例中,该第一预设条件包括:该目标队列为空队列,且该目标队列的开启时长大于等于第一值,该第一值为多个预设时刻中任意两个相邻预设时刻的差,该多个预设时刻与该第二队列系统包括的多个队列一一对应。
图19示出了本申请实施例提供的第二网络设备2000的硬件结构示意图。图19所示第二网络设备2000可以执行上述实施例的方法中第二网络设备执行的相应步骤。
如图19所示,所述第二网络设备2000包括处理器2001、存储器2002、接口2003和总线2004。其中接口2003可以通过无线或有线的方式实现,具体来讲可以是网卡。上述处理器2001、存储器2002和接口2003通过总线2004连接。
所述接口2003具体可以包括发送器和接收器,用于第二网络设备实现上述收发。例如,所述接口2003用于在第一时刻接收第一网络设备发送的数据包;还用于根据所述第二队列系统对应的调度规则将所述数据包发送至第三网络设备。
所述处理器2001用于执行上述实施例中由第二网络设备进行的处理。例如,该处理器用于根据所述数据包携带的时间信息,确定第二参考时刻;还用于根据所述第二参考时刻从所述第二队列系统包括的多个队列中确定目标队列并将所述数据包加入所述目标队列;还用于根据所述第二队列系统对应的调度规则将所述数据包发送至第三网络设备;和/或用于本文所描述的技术的其他过程。存储器2002包括操作系统20021和应用程序20022,用于存储程序、代码或计算机执行指令,当处理器或硬件设备执行这些程序、代码或计算机执行指令时可以完成方法实施例中涉及第二网络设备的处理过程。可选的,所述存储器2002可以包括只读存储器(read-only memory,ROM)和随机存取存储器(random access memory,RAM)。其中,所述ROM包括基本输入/输出系统(basic input/output system,BIOS)或嵌入式系统;所述RAM包括应用程序和操作系统。当需要运行第二网络设备2000时,通过固化在ROM中的BIOS或者嵌入式系统中的bootloader引导系统进行启动,引导第二网络设备2000进入正常运行状态。在第二网络设备2000进入正常运行状态后,运行在RAM中的应用程序和操作系统,从而,完成方法实施例中涉及第二网络设备2000的处理过程。
可以理解的是,图19仅仅示出了第二网络设备2000的简化设计。在实际应用中,第二网络设备可以包含任意数量的接口,处理器或者存储器。
本申请实施例还提供了一种计算机可读介质,该计算机可读介质存储有程序代码,当该计算机程序代码在计算机上运行时,使得计算机执行上述各方面中的方法。这些计算机可读存储包括但不限于如下的一个或者多个:只读存储器(read-only memory,ROM)、可编程ROM(programmable ROM,PROM)、可擦除的PROM(erasable PROM,EPROM)、Flash存储器、电EPROM(electrically EPROM,EEPROM)以及硬盘驱动器(hard drive)。
本申请实施例还提供了一种芯片系统,应用于第二网络设备中,该芯片系统包括:至 少一个处理器、至少一个存储器和接口电路,所述接口电路负责所述芯片系统与外界的信息交互,所述至少一个存储器、所述接口电路和所述至少一个处理器通过线路互联,所述至少一个存储器中存储有计算机执行指令;所述计算机执行指令被所述至少一个处理器执行,以进行上述各个方面的所述的方法中所述第二网络设备的操作。
在具体实现过程中,该芯片系统可以以中央处理器(central processing unit,CPU)、微控制器(micro controller unit,MCU)、微处理器(micro processing unit,MPU)、数字信号处理器(digital signal processing,DSP)、片上系统(system on chip,SoC)、专用集成电路(application-specific integrated circuit,ASIC)、现场可编程门阵列(field programmable gate array,FPGA)或可编辑逻辑器件(programmable logic device,PLD)的形式实现。
本申请实施例还提供了一种计算机程序产品,应用于第二网络设备中,所述计算机程序产品包括一系列计算机执行指令,当所述计算机执行指令被运行时,以进行上述各个方面的所述的方法中所述第二网络设备的操作。
应理解,在本申请的各种实施例中,上述各过程的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统、装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。
在本申请所提供的几个实施例中,应该理解到,所揭露的系统、装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。
所述功能如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干计算机执行指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例所述方法的全部或部 分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(read-only memory,ROM)、随机存取存储器(random access memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。

Claims (39)

  1. 一种发送数据包的方法,其特征在于,所述方法包括:
    第二网络设备在第一时刻接收第一网络设备发送的数据包;
    所述第二网络设备根据所述数据包携带的时间信息,确定第二参考时刻,所述第二参考时刻为指导所述数据包进入第二队列系统中的队列的参考时刻,所述第二队列系统为所述第二网络设备的队列系统,所述时间信息用于指示所述数据包通过所述第一网络设备的第一剩余处理时间,所述第一剩余处理时间为第一时延与第一处理时间的差,所述第一时延为不小于第一理论时间上限与第一传输时间的差的绝对值的值,所述第一理论时间上限为第一参考时刻至所述第二参考时刻的理论处理时间上限,所述第一参考时刻为指导所述数据包进入第一队列系统中的队列的参考时刻,所述第一队列系统为所述第一网络设备的队列系统,所述第一传输时间为所述数据包被所述第一网络设备输出的第一输出时刻至所述第一时刻的实际传输时间,所述第一处理时间为所述第一参考时刻至所述数据包被所述第一网络设备输出的第一输出时刻的实际处理时间;
    所述第二网络设备根据所述第二参考时刻从所述第二队列系统包括的多个队列中确定目标队列并将所述数据包加入所述目标队列;
    所述第二网络设备根据所述第二队列系统对应的调度规则将所述数据包发送至第三网络设备。
  2. 如权利要求1所述的方法,其特征在于,所述第二队列系统包括的多个队列与多个预设时刻一一对应,所述多个预设时刻中任意两个相邻预设时刻的差为第一值,所述所述第二网络设备根据所述第二参考时刻从所述第二队列系统包括的多个队列中确定目标队列,包括:
    所述第二网络设备根据所述第二参考时刻,确定第一目标时刻对应的所述第二队列系统包括的多个队列中的一个队列为所述目标队列,所述第一目标时刻为所述第二参考时刻与第二值的和,所述第二值为所述第二参考时刻与第三时刻的差的绝对值加上所述第一值的整数倍,所述第二参考时刻与所述第三时刻之间不包括所述多个预设时刻中的任一个时刻,所述第三时刻是所述多个预设时刻中的一个时刻且所述第三时刻大于所述第二参考时刻,所述第一目标时刻是所述多个预设时刻中的一个时刻。
  3. 如权利要求1或2所述的方法,其特征在于,所述第二网络设备根据所述数据包携带的时间信息,确定第二参考时刻,包括:
    所述第二网络设备根据所述第一时延和所述第一处理时间,确定所述第二参考时刻。
  4. 如权利要求3所述的方法,其特征在于,所述第二网络设备根据所述第一时延和所述第一处理时间,确定所述第二参考时刻,包括:
    所述第二网络设备根据所述第一时延、所述第一参考时刻、所述数据包被所述第一网络设备输出的第一输出时刻和所述第一时刻,确定所述第二参考时刻。
  5. 如权利要求4所述的方法,其特征在于,所述所述第二网络设备根据所述第一时延、所述第一参考时刻、所述数据包被所述第一网络设备输出的第一输出时刻和所述第一时刻,确定所述第二参考时刻,包括:所述第二网络设备根据以下公式确定所述第二参考 时刻:
    Figure PCTCN2021104191-appb-100001
    其中,E 2为所述第二参考时刻,
    Figure PCTCN2021104191-appb-100002
    为所述第一时刻,
    Figure PCTCN2021104191-appb-100003
    为所述第一时延,
    Figure PCTCN2021104191-appb-100004
    为所述数据包被所述第一网络设备输出的第一输出时刻,E 1为所述第一参考时刻。
  6. 如权利要求3所述的方法,其特征在于,所述所述第二网络设备根据所述第一时延和所述第一处理时间,确定所述第二参考时刻,包括:
    所述第二网络设备根据所述第一时延、所述第一参考时刻、所述数据包被所述第一网络设备输出的第一输出时刻、所述数据包通过所述第二网络设备的交换结构处理后的时刻和所述第一时刻,确定所述第二参考时刻,其中所述数据包通过所述第二网络设备的交换结构处理后的时刻小于所述第二参考时刻。
  7. 如权利要求6所述的方法,其特征在于,所述所述第二网络设备根据所述第一时延、所述第一参考时刻、所述数据包被所述第一网络设备输出的第一输出时刻、所述数据包通过所述第二网络设备的交换结构处理后的时刻和所述第一时刻,确定所述第二参考时刻,包括:所述第二网络设备根据以下公式确定所述第二参考时刻:
    Figure PCTCN2021104191-appb-100005
    其中,E 2为所述第二参考时刻,
    Figure PCTCN2021104191-appb-100006
    为所述数据包通过所述第二网络设备的交换结构处理后的时刻,
    Figure PCTCN2021104191-appb-100007
    为所述第一时延,
    Figure PCTCN2021104191-appb-100008
    为所述数据包被所述第一网络设备输出的第一输出时刻,E 1为所述第一参考时刻,
    Figure PCTCN2021104191-appb-100009
    为所述第一时刻。
  8. 如权利要求1-7任一项所述的方法,其特征在于,
    所述时间信息包括第一时间值,所述第一时间值为所述第一剩余处理时间。
  9. 如权利要求1-7任一项所述的方法,其特征在于,
    所述时间信息包括第一指示信息,所述第一指示信息用于指示所述第一处理时间。
  10. 如权利要求9所述的方法,其特征在于,
    所述第一指示信息包括第二时间值,所述第二时间值为所述第一处理时间。
  11. 如权利要求9所述的方法,其特征在于,
    所述第一指示信息包括第三时间值和第四时间值,所述第三时间值为所述数据包被所述第一网络设备输出的第一输出时刻,所述第四时间值为所述第一参考时刻。
  12. 如权利要求10或11所述的方法,其特征在于,
    所述时间信息还包括第二指示信息,所述第二指示信息用于指示所述第一时延。
  13. 如权利要求1-12任一项所述的方法,其特征在于,所述所述第二网络设备根据所述第二队列系统对应的调度规则将所述数据包发送至所述第三网络设备,包括:
    所述第二网络设备确定所述目标队列为所述第二队列系统包括的多个队列中当前时刻被调度的队列,以及所述目标队列为开启状态,所述第二网络设备将所述数据包发送至所述第三网络设备。
  14. 如权利要求13所述的方法,其特征在于,所述方法还包括:
    所述第二网络设备在所述目标队列满足第一预设条件的情况下,确定关闭所述目标队列。
  15. 如权利要求14所述的方法,其特征在于,在所述第二网络设备确定关闭所述目标队列之后,所述方法还包括:
    所述第二网络设备根据第一信息,确定第二目标时刻,所述第二目标时刻对应于所述目标队列,所述第二目标时刻为在第一目标时刻后所述目标队列对应的开启的时刻,所述第二目标时刻大于多个预设时刻中的任意一个预设时刻,所述第一信息包括所述第二队列系统包括的每个队列对应的调度顺序和所述第二队列系统包括的每个队列对应的开启的时刻;
    其中,所述第二队列系统包括的多个队列与所述多个预设时刻一一对应,所述多个预设时刻中任意两个相邻预设时刻的差为第一值,所述第一目标时刻对应的所述第二队列系统包括的多个队列中的一个队列为所述目标队列,所述第一目标时刻为所述第二参考时刻与第二值的和,所述第二值为所述第二参考时刻与第三时刻的差的绝对值加上所述第一值的整数倍,所述第二参考时刻与所述第三时刻之间不包括所述多个预设时刻中的任一个时刻,所述第三时刻是所述多个预设时刻中的一个时刻且所述第三时刻大于所述第二参考时刻,所述第一目标时刻是所述多个预设时刻中的一个时刻。
  16. 如权利要求14或15所述的方法,其特征在于,
    所述第二网络设备确定所述目标队列为所述第二队列系统包括的多个队列中当前时刻被调度的队列,包括:
    当所述第二网络设备确定所述目标队列为所述第二队列系统包括的多个队列中优先级最高的队列时,所述第二网络设备确定所述目标队列为所述第二队列系统包括的多个队列中当前时刻被调度的队列;
    在所述第二网络设备确定关闭所述目标队列之后,所述方法还包括:
    所述第二网络设备将所述目标队列的优先级设置为所述第二队列系统包括的多个队列中优先级最低的队列,并将所述第二队列系统包括的多个队列中除所述目标队列之外的队列的优先级提升。
  17. 如权利要求14或15所述的方法,其特征在于,所述第二队列系统包括的多个队列与多个预设调度顺序一一对应,
    所述第二网络设备确定所述目标队列为所述第二队列系统包括的多个队列中当前时刻被调度的队列,包括:
    当所述第二网络设备根据所述多个预设调度顺序确定所述目标队列对应的预设调度顺序为所述第二网络设备在所述当前时刻调度的队列对应的调度顺序时,所述第二网络设备确定所述目标队列为所述第二队列系统包括的多个队列中当前时刻被调度的队列。
  18. 如权利要求14-17任一项所述的方法,其特征在于,所述第一预设条件包括:所述目标队列为空队列,且所述目标队列的开启时长大于等于第一值,所述第一值为多个预设时刻中任意两个相邻预设时刻的差,所述多个预设时刻与所述第二队列系统包括的多个队列一一对应。
  19. 一种第二网络设备,其特征在于,所述第二网络设备包括:
    收发单元,用于在第一时刻接收第一网络设备发送的数据包;
    处理单元,用于根据所述数据包携带的时间信息,确定第二参考时刻,所述第二参考时刻为指导所述数据包进入第二队列系统中的队列的参考时刻,所述第二队列系统为所述第二网络设备的队列系统,所述时间信息用于指示所述数据包通过所述第一网络设备的第一剩余处理时间,所述第一剩余处理时间为第一时延与第一处理时间的差,所述第一时延 为不小于第一理论时间上限与第一传输时间的差的绝对值的值,所述第一理论时间上限为第一参考时刻至所述第二参考时刻的理论处理时间上限,所述第一参考时刻为指导所述数据包进入第一队列系统中的队列的参考时刻,所述第一队列系统为所述第一网络设备的队列系统,所述第一传输时间为所述数据包被所述第一网络设备输出的第一输出时刻至所述第一时刻的实际传输时间,所述第一处理时间为所述第一参考时刻至所述数据包被所述第一网络设备输出的第一输出时刻的实际处理时间;
    所述处理单元,还用于根据所述第二参考时刻从所述第二队列系统包括的多个队列中确定目标队列并将所述数据包加入所述目标队列;
    所述处理单元,还用于根据所述第二队列系统对应的调度规则将所述数据包发送至第三网络设备。
  20. 如权利要求19所述的第二网络设备,其特征在于,所述第二队列系统包括的多个队列与多个预设时刻一一对应,
    所述处理单元还用于:
    所述第二参考时刻,确定第一目标时刻对应的所述第二队列系统包括的多个队列中的一个队列为所述目标队列,所述第一目标时刻为所述第二参考时刻与第二值的和,所述第二值为所述第二参考时刻与第三时刻的差的绝对值加上所述第一值的整数倍,所述第二参考时刻与所述第三时刻之间不包括所述多个预设时刻中的任一个时刻,所述第三时刻是所述多个预设时刻中的一个时刻且所述第三时刻大于所述第二参考时刻,所述第一目标时刻是所述多个预设时刻中的一个时刻。
  21. 如权利要求19或20所述的第二网络设备,其特征在于,所述处理单元还用于:
    根据所述第一时延和所述第一处理时间,确定所述第二参考时刻。
  22. 如权利要求21所述的第二网络设备,其特征在于,所述处理单元还用于:
    根据所述第一时延、所述第一参考时刻、所述数据包被所述第一网络设备输出的第一输出时刻和所述第一时刻,确定所述第二参考时刻。
  23. 如权利要求22所述的第二网络设备,其特征在于,所述处理单元还用于:
    根据以下公式确定所述第二参考时刻:
    Figure PCTCN2021104191-appb-100010
    其中,E 2为所述第二参考时刻,
    Figure PCTCN2021104191-appb-100011
    为所述第一时刻,
    Figure PCTCN2021104191-appb-100012
    为所述第一时延,
    Figure PCTCN2021104191-appb-100013
    为所述数据包被所述第一网络设备输出的第一输出时刻,E 1为所述第一参考时刻。
  24. 如权利要求21所述的第二网络设备,其特征在于,所述处理单元还用于:
    根据所述第一时延、所述第一参考时刻、所述数据包被所述第一网络设备输出的第一输出时刻、所述数据包通过所述第二网络设备的交换结构处理后的时刻和所述第一时刻,确定所述第二参考时刻,其中所述数据包通过所述第二网络设备的交换结构处理后的时刻小于所述第二参考时刻。
  25. 如权利要求24所述的第二网络设备,其特征在于,所述处理单元还用于:
    根据以下公式确定所述第二参考时刻:
    Figure PCTCN2021104191-appb-100014
    其中,E 2为所述第二参考时刻,
    Figure PCTCN2021104191-appb-100015
    为所述数据包通过所述第二网络设备的交换结构处理后的时刻,
    Figure PCTCN2021104191-appb-100016
    为所述第一时延,
    Figure PCTCN2021104191-appb-100017
    为所述数据包被所述第一网络设备输出的第一 输出时刻,E 1为所述第一参考时刻,
    Figure PCTCN2021104191-appb-100018
    为所述第一时刻。
  26. 如权利要求19-25任一项所述的第二网络设备,其特征在于,
    所述时间信息包括第一时间值,所述第一时间值为所述第一剩余处理时间。
  27. 如权利要求19-25任一项所述的第二网络设备,其特征在于,
    所述时间信息包括第一指示信息,所述第一指示信息用于指示所述第一处理时间。
  28. 如权利要求27所述的第二网络设备,其特征在于,
    所述第一指示信息包括第二时间值,所述第二时间值为所述第一处理时间。
  29. 如权利要求27所述的第二网络设备,其特征在于,
    所述第一指示信息包括第三时间值和第四时间值,所述第三时间值为所述数据包被所述第一网络设备输出的第一输出时刻,所述第四时间值为所述第一参考时刻。
  30. 如权利要求28或29所述的第二网络设备,其特征在于,
    所述时间信息还包括第二指示信息,所述第二指示信息用于指示所述第一时延。
  31. 如权利要求19-30任一项所述的第二网络设备,其特征在于,
    所述处理单元还用于:
    确定所述目标队列为所述第二队列系统包括的多个队列中当前时刻被调度的队列,以及所述目标队列为开启状态;
    所述收发单元还用于:根据所述第二队列系统对应的调度规则将所述数据包发送至第三网络设备。
  32. 如权利要求31所述的第二网络设备,其特征在于,所述处理单元还用于:
    在所述目标队列满足第一预设条件的情况下,确定关闭所述目标队列。
  33. 如权利要求32所述的第二网络设备,其特征在于,所述处理单元还用于:
    根据第一信息,确定第二目标时刻,所述第二目标时刻对应于所述目标队列,所述第二目标时刻为在第一目标时刻后所述目标队列对应的开启的时刻,所述第二目标时刻大于多个预设时刻中的任意一个预设时刻,所述第一信息包括所述第二队列系统包括的每个队列对应的调度顺序和所述第二队列系统包括的每个队列对应的开启的时刻;
    其中,所述第二队列系统包括的多个队列与所述多个预设时刻一一对应,所述多个预设时刻中任意两个相邻预设时刻的差为第一值,所述第一目标时刻对应的所述第二队列系统包括的多个队列中的一个队列为所述目标队列,所述第一目标时刻为所述第二参考时刻与第二值的和,所述第二值为所述第二参考时刻与第三时刻的差的绝对值加上所述第一值的整数倍,所述第二参考时刻与所述第三时刻之间不包括所述多个预设时刻中的任一个时刻,所述第三时刻是所述多个预设时刻中的一个时刻且所述第三时刻大于所述第二参考时刻,所述第一目标时刻是所述多个预设时刻中的一个时刻。
  34. 如权利要求32或33所述的第二网络设备,其特征在于,
    所述处理单元还用于:
    当确定所述目标队列为所述第二队列系统包括的多个队列中优先级最高的队列时,确定所述目标队列为所述第二队列系统包括的多个队列中当前时刻被调度的队列;
    将所述目标队列的优先级设置为所述第二队列系统包括的多个队列中优先级最低的队列,并将所述第二队列系统包括的多个队列中除所述目标队列之外的队列的优先级提升。
  35. 如权利要求32或33所述的第二网络设备,其特征在于,所述第二队列系统包括的多个队列与多个预设调度顺序一一对应,
    所述处理单元还用于:
    当根据所述多个预设调度顺序确定所述目标队列对应的预设调度顺序为所述第二网络设备在所述当前时刻调度的队列对应的调度顺序时,确定所述目标队列为所述第二队列系统包括的多个队列中当前时刻被调度的队列。
  36. 如权利要求32-35任一项所述的第二网络设备,其特征在于,所述第一预设条件包括:所述目标队列为空队列,且所述目标队列的开启时长大于等于第一值,所述第一值为多个预设时刻中任意两个相邻预设时刻的差,所述多个预设时刻与所述第二队列系统包括的多个队列一一对应。
  37. 一种第二网络设备,其特征在于,包括处理器和存储器,所述存储器用于存储计算机执行指令,所述处理器用于读取所述存储器中存储的所述计算机执行指令,以实现如权利要求1至18中任一项所述的方法。
  38. 一种计算机可读存储介质,其特征在于,包括计算机程序,当其在计算机上运行时,使得所述计算机执行如权利要求1至18中任一项所述的方法。
  39. 一种芯片系统,其特征在于,包括至少一个处理器和接口;所述至少一个所述处理器,用于调用并运行计算机程序,以使所述芯片系统执行如权利要求1至18中任一项所述的方法。
PCT/CN2021/104191 2020-07-31 2021-07-02 发送数据包的方法及网络设备 WO2022022222A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP21851520.3A EP4184887A4 (en) 2020-07-31 2021-07-02 METHOD FOR SENDING DATA PACKET, AND NETWORK DEVICE
US18/159,875 US20230171201A1 (en) 2020-07-31 2023-01-26 Method for sending data packet and network device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010760188.5A CN114095454A (zh) 2020-07-31 2020-07-31 发送数据包的方法及网络设备
CN202010760188.5 2020-07-31

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US18/159,875 Continuation US20230171201A1 (en) 2020-07-31 2023-01-26 Method for sending data packet and network device

Publications (1)

Publication Number Publication Date
WO2022022222A1 true WO2022022222A1 (zh) 2022-02-03

Family

ID=80037484

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/104191 WO2022022222A1 (zh) 2020-07-31 2021-07-02 发送数据包的方法及网络设备

Country Status (4)

Country Link
US (1) US20230171201A1 (zh)
EP (1) EP4184887A4 (zh)
CN (1) CN114095454A (zh)
WO (1) WO2022022222A1 (zh)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150222970A1 (en) * 2014-02-04 2015-08-06 Nec Laboratories America, Inc. Lossless and low-delay optical burst switching using soft reservations and opportunistic transmission
CN106921586A (zh) * 2015-12-25 2017-07-04 华为技术有限公司 一种数据流整形方法、数据调度方法以及装置
CN108282415A (zh) * 2017-12-29 2018-07-13 北京华为数字技术有限公司 一种调度方法及设备
CN110086728A (zh) * 2018-01-26 2019-08-02 华为技术有限公司 发送报文的方法、第一网络设备及计算机可读存储介质
CN111416779A (zh) * 2020-03-27 2020-07-14 西安电子科技大学 基于时限的互联网业务队列调度方法

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7852763B2 (en) * 2009-05-08 2010-12-14 Bae Systems Information And Electronic Systems Integration Inc. System and method for determining a transmission order for packets at a node in a wireless communication network
US9124482B2 (en) * 2011-07-19 2015-09-01 Cisco Technology, Inc. Delay budget based forwarding in communication networks
EP3073680B1 (en) * 2015-03-23 2017-12-06 Alcatel Lucent Methods, queueing system, network element and network system for queueing and processing of packets
EP3720069A4 (en) * 2017-12-31 2020-12-02 Huawei Technologies Co., Ltd. METHOD, DEVICE, AND SYSTEM FOR SENDING A MESSAGE

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150222970A1 (en) * 2014-02-04 2015-08-06 Nec Laboratories America, Inc. Lossless and low-delay optical burst switching using soft reservations and opportunistic transmission
CN106921586A (zh) * 2015-12-25 2017-07-04 华为技术有限公司 一种数据流整形方法、数据调度方法以及装置
CN108282415A (zh) * 2017-12-29 2018-07-13 北京华为数字技术有限公司 一种调度方法及设备
CN110086728A (zh) * 2018-01-26 2019-08-02 华为技术有限公司 发送报文的方法、第一网络设备及计算机可读存储介质
CN111416779A (zh) * 2020-03-27 2020-07-14 西安电子科技大学 基于时限的互联网业务队列调度方法

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
LIANMING ZHANG: "Bounds on End-to-End Delay Jitter with Self-Similar Input Traffic in Ad Hoc Wireless Network", COMPUTING, COMMUNICATION, CONTROL, AND MANAGEMENT, 2008. CCCM '08. ISECS INTERNATIONAL COLLOQUIUM ON, IEEE, PISCATAWAY, NJ, USA, 3 August 2008 (2008-08-03), Piscataway, NJ, USA , pages 538 - 541, XP031314230, ISBN: 978-0-7695-3290-5 *
See also references of EP4184887A4

Also Published As

Publication number Publication date
EP4184887A1 (en) 2023-05-24
US20230171201A1 (en) 2023-06-01
CN114095454A (zh) 2022-02-25
EP4184887A4 (en) 2023-12-13

Similar Documents

Publication Publication Date Title
EP4258611A2 (en) Message sending method, network node and system
CN114338523B (zh) 一种报文转发方法和装置
CN106789721B (zh) 一种基于令牌桶的智能qos方法及系统
US11968111B2 (en) Packet scheduling method, scheduler, network device, and network system
WO2022022224A1 (zh) 调度数据包的方法和相关装置
Hua et al. Scheduling design and analysis for end-to-end heterogeneous flows in an avionics network
US7292578B1 (en) Flexible, high performance support for QoS on an arbitrary number of queues
CN111108728B (zh) 对报文进行处理方法及装置
Wu et al. Network congestion avoidance through packet-chaining reservation
Soni et al. Optimizing network calculus for switched ethernet network with deficit round robin
CN108989233B (zh) 拥塞管理方法及装置
CN106899514B (zh) 保障多媒体业务服务质量的队列调度方法
Mello et al. Evaluation of current QoS mechanisms in networks on chip
CN111092825B (zh) 一种传输报文的方法和装置
WO2022022222A1 (zh) 发送数据包的方法及网络设备
Yang et al. Crsp: Network congestion control through credit reservation
CN108632162B (zh) 一种队列调度方法及转发设备
Jha et al. New Queuing Technique for Improving Computer Networks QoS
Tokmakov et al. A case for data centre traffic management on software programmable ethernet switches
Yang et al. BFRP: Endpoint congestion avoidance through bilateral flow reservation
Tong et al. Quantum varying deficit round robin scheduling over priority queues
Chen et al. Credit-based low latency packet scheduling algorithm for real-time applications
Bianco HERO: High-speed Enhanced Routing Operation in Ethernet NICs for Software Routers⋆
Alanazi et al. Ml-ecn: Multi-level ecn marking for fair datacenter traffic forwarding
Chen et al. Packet Scheduling Algorithm Based on Priority Adjustment in Wireless Sensor Networks

Legal Events

Date Code Title Description
ENP Entry into the national phase

Ref document number: 2021851520

Country of ref document: EP

Effective date: 20230215

NENP Non-entry into the national phase

Ref country code: DE