WO2022022219A1 - 传输报文的方法、装置、设备及可读存储介质 - Google Patents

传输报文的方法、装置、设备及可读存储介质 Download PDF

Info

Publication number
WO2022022219A1
WO2022022219A1 PCT/CN2021/104057 CN2021104057W WO2022022219A1 WO 2022022219 A1 WO2022022219 A1 WO 2022022219A1 CN 2021104057 W CN2021104057 W CN 2021104057W WO 2022022219 A1 WO2022022219 A1 WO 2022022219A1
Authority
WO
WIPO (PCT)
Prior art keywords
network device
packet
time
packet flow
dwell time
Prior art date
Application number
PCT/CN2021/104057
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 EP21851061.8A priority Critical patent/EP4184872A4/en
Publication of WO2022022219A1 publication Critical patent/WO2022022219A1/zh
Priority to US18/161,247 priority patent/US20230171197A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0852Delays
    • 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
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/16Threshold monitoring
    • 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/15Flow control; Congestion control in relation to multipoint 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/17Interaction among intermediate nodes, e.g. hop by hop
    • 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/22Traffic shaping
    • 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/10Flow control; Congestion control
    • H04L47/28Flow control; Congestion control in relation to timing considerations
    • H04L47/286Time to live
    • 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/564Attaching a deadline to packets, e.g. earliest due date first
    • H04L47/566Deadline varies as a function of time spent in the queue
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/08Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
    • H04L43/0852Delays
    • H04L43/087Jitter

Definitions

  • the present application relates to the field of communication technologies, and in particular, to a method, apparatus, device, and readable storage medium for transmitting messages.
  • IP Internet Protocol
  • the network device in the IP network processes the packets at wire speed, when the network device receives multiple different packet streams at the same time, the packets in the different packet streams are squeezed against each other and the gap between the packets is reduced.
  • the burst degree is continuously accumulated, resulting in increased delay and jitter during packet transmission, which is difficult to predict. Therefore, it is necessary to provide a packet transmission method that can eliminate the accumulation of burstiness, thereby ensuring the determinability of packet delay and jitter.
  • message transmission is performed by a method of cyclic queuing and forwarding (CQF).
  • CQF cyclic queuing and forwarding
  • the method firstly aligns the clock edges of all network devices in the IP network, thereby ensuring that different network devices are in the same cycle at the same time. After that, for the adjacent network devices in the IP network, the packets sent by the first network device in the first cycle are received by the second network device in the first cycle, and the packets sent by the second network device in the second The received packet is forwarded to the third network device within the first cycle, and the third network device completes the packet reception within the second cycle.
  • the transmission of the message can be realized.
  • the path length between network devices is N, that is, there are (N+1) network devices between the two ends and the cycle duration is T
  • the maximum total delay of the packet between the two ends during transmission is ( N+1)T
  • the minimum total delay is (N-1)T
  • the jitter is 2T, thus ensuring that the packet has a deterministic delay during transmission.
  • the present application provides a method, device, device and readable storage medium for transmitting messages, so as to improve the effect of message transmission.
  • the technical solutions are as follows:
  • a method for transmitting a message comprising:
  • the second network device first receives the first packet sent by the first network device, and then obtains the second packet in the target packet flow and the first dwell time of the second packet on the first network device according to the first packet and the second residence time of the target packet flow on the first network device.
  • the first dwell time is the time difference between the first time and the second time
  • the first time is the time when the second packet enters the queue system of the first network device
  • the second time is when the second packet passes through the first time.
  • the second dwell time is the upper threshold limit for the destination packet flow to stay on the first network device.
  • the second network device determines the time difference between the second dwell time of the target packet flow on the first network device and the first dwell time of the second packet on the first network device, where the time difference is Active delay time of the second packet on the second network device.
  • the second network device obtains the third dwell time of the second packet on the second network device, and obtains the fourth dwell time of the target packet flow on the second network device, so as to encapsulate the second packet on the second network
  • the third dwell time on the device, the fourth dwell time of the target packet flow on the second network device, and the second packet are used to obtain the third packet.
  • the third dwell time is the time difference between the third time and the fourth time
  • the third time is the time when the second network device ends the active delay of the second packet
  • the fourth time is the time when the second packet has passed
  • the fourth dwell time is the upper threshold limit for the destination packet flow to stay on the second network device.
  • the second network device After the second network device receives the first packet and reaches the active delay time and passes through the queuing system of the second network device, the second network device sends the packet to the next-hop network device of the second network device on the core network transmission path of the target packet flow Third message.
  • Each network device actively delays the packets to be transmitted to ensure that the packets to be transmitted have a deterministic delay between a pair of adjacent network devices, thereby ensuring that the packets to be transmitted are between the two ends. deterministic time delay.
  • the active delay time of each network device is obtained based on the packet flow in which the to-be-transmitted packet is located, thereby avoiding mutual interference between different packet flows. This method is not only simple to implement, but also suitable for IP networks of various scales. It can be seen that this method is more practical and has better transmission effect.
  • the core network transmission path of the target packet flow includes one or more network devices located upstream of the first network device and one or more network devices located downstream of the first network device.
  • the packet also includes one or more upstream dwell times of the target packet flow on one or more upstream network devices.
  • the one or more upstream dwell times are in one-to-one correspondence with one or more upstream network devices.
  • the dwell time is the upper limit of the threshold value for the target packet flow to stay on an upstream network device.
  • the first packet also includes one or more downstream dwell times of the target packet flow on one or more downstream network devices.
  • the multiple downstream dwell times are in one-to-one correspondence with one or more downstream network devices, and any downstream dwell time is the upper limit of the threshold for the destination packet flow to stay on one downstream network device;
  • Encapsulating the third dwell time of the second packet on the second network device, the fourth dwell time of the target packet flow on the second network device, and the second packet to obtain the third packet including: encapsulating the second packet
  • the third packet is obtained by calculating the packet, the third dwell time of the second packet on the second network device, and the downstream dwell time of the target packet flow on one or more network devices downstream of the first network device.
  • the method before the second network device receives the first packet sent by the first network device, the method further includes: receiving a first instruction sent by the first network device; The first port on the network device that transmits the target packet flow; the fifth dwell time corresponding to the first port is obtained, the fifth dwell time is the time determined based on the first other packet flow, and the first other packet flow is the second network
  • the device obtains the packet flow transmitted through the first port before the target packet flow; updates the fifth dwell time based on the target packet flow to obtain the sixth dwell time; uses the sixth dwell time as the target packet flow on the second network device the fourth dwell time.
  • the method before the second network device receives the first packet sent by the first network device, the method further includes: receiving a second instruction sent by the first network device; and acquiring the target packet according to the second instruction Fourth dwell time of the text stream on the second network device; sending the fourth dwell time to the first network device.
  • the method further includes: receiving a third packet sent by the first network device instruction, and the third instruction is used to notify the second network device of the first information, where the first information is that the first network device stops acquiring the target packet stream; the sixth dwell time is updated according to the third instruction to obtain the seventh dwell time.
  • a method for transmitting a message comprising:
  • the first network device obtains the second packet in the target packet flow to be transmitted, and obtains the first dwell time of the second packet on the first network device, where the first dwell time is between the first moment and the second moment
  • the first time is when the second packet enters the queue system of the first network device, and the second time is when the second packet is sent by the first network device after being queued in the queue system of the first network device. time;
  • the second residence time is an upper limit of the threshold value of the target packet flow staying on the first network device
  • the core network transmission path of the target packet flow includes other network devices other than the first network device, encapsulates the second packet, and encapsulates the first packet of the second packet on the first network device.
  • the dwell time and the second dwell time of the target packet flow on the first network device to obtain the first packet including: encapsulating the second packet, the first dwell time of the second packet on the first network device, the destination
  • the second dwell time of the packet flow on the first network device and the dwell time of the target packet flow on other network devices to obtain the first packet, and the dwell time of the target packet flow on other network devices is the target packet The upper threshold for the stream to stay on other network devices.
  • the method before the first network device acquires the second packet in the target packet stream to be transmitted, the method further includes: determining a second port on the first network device for transmitting the target packet stream; Obtain the eighth dwell time corresponding to the second port, where the eighth dwell time is a time determined based on the second other packet flow, and the second other packet flow is the data transmitted through the second port before the first network device obtains the target packet flow. packet flow; determining the second dwell time of the target packet flow on the first network device based on the eighth dwell time; and storing the second dwell time of the target packet flow on the first network device.
  • the method before the first network device acquires the second packet in the target packet stream to be transmitted, the method further includes: sending a first instruction to other network devices, where the first instruction is used for other network devices Any one of the network devices obtains and stores the residence time of the target packet flow on any network device.
  • the method before the first network device acquires the second packet in the target packet stream to be transmitted, the method further includes: sending a second instruction to other network devices; receiving target packets sent by other network devices The dwell time of the packet flow on other network devices, and the dwell time of the target packet flow on other network devices is sent by other network devices based on the second instruction.
  • the method further includes: stopping acquiring the target packet flow, and sending a third instruction to other network devices, where the third instruction is used to send the other network devices
  • the first information is notified, where the first information is that the first network device stops acquiring the target packet flow.
  • a device for transmitting a message comprising:
  • a receiving module used for the second network device to receive the first message sent by the first network device
  • the obtaining module is used for the second network device to obtain the second packet in the target packet flow, the first residence time of the second packet on the first network device, and the target packet flow in the first network according to the first packet.
  • the second dwell time on the device is the time difference between the first moment and the second moment, the first moment is the moment when the second packet enters the queue system of the first network device, and the second moment is At the moment when the second packet is sent by the first network device after being queued in the queuing system of the first network device, the second dwell time is the upper threshold limit of the destination packet flow staying on the first network device;
  • a determining module used by the second network device to determine the time difference between the second dwell time of the target packet flow on the first network device and the first dwell time of the second packet on the first network device, the time difference The value is the active delay time of the second packet on the second network device;
  • the obtaining module is further configured to obtain the third dwell time of the second packet on the second network device, and obtain the fourth dwell time of the target packet flow on the second network device, where the third dwell time is the time between the third moment and the third time.
  • the time difference between the four times the third time is the time when the second network device ends the active delay of the second packet, and the fourth time is when the second packet is queued by the second network device after being queued in the queue system of the second network device.
  • the fourth dwell time is the upper limit of the threshold value for the target packet flow to stay on the second network device;
  • an encapsulation module configured to encapsulate the third dwell time of the second packet on the second network device, the fourth dwell time of the target packet flow on the second network device, and the second packet to obtain the third packet;
  • the sending module is configured to send the second network device to the next network device on the core network transmission path of the target message flow after the second network device receives the first message and reaches the active delay time and passes through the queuing system of the second network device.
  • the hop network device sends the third packet.
  • the core network transmission path of the target packet flow includes one or more network devices located upstream of the first network device and one or more network devices located downstream of the first network device.
  • the packet also includes one or more upstream dwell times of the target packet flow on one or more upstream network devices.
  • the one or more upstream dwell times are in one-to-one correspondence with one or more upstream network devices.
  • the dwell time is the upper limit of the threshold value for the target packet flow to stay on an upstream network device.
  • the first packet also includes one or more downstream dwell times of the target packet flow on one or more downstream network devices.
  • the multiple downstream dwell times are in one-to-one correspondence with one or more downstream network devices, and any downstream dwell time is the upper threshold limit for the destination packet flow to stay on one downstream network device; the encapsulation module is used to encapsulate the second packet , the third dwell time of the second packet on the second network device and the downstream dwell time of the target packet flow on one or more network devices downstream of the first network device to obtain the third packet.
  • the receiving module is further configured to receive the first instruction sent by the first network device; the obtaining module is further configured to determine the first instruction to transmit the target packet stream on the second network device according to the first instruction A port; obtains the fifth dwell time corresponding to the first port, the fifth dwell time is the time determined based on the first other packet flow, and the first other packet flow is the first other packet flow before the second network device obtains the target packet flow through the first The packet flow transmitted by the port; the fifth dwell time is updated based on the target packet flow to obtain the sixth dwell time; the sixth dwell time is taken as the fourth dwell time of the target packet flow on the second network device.
  • the receiving module is further configured to receive a third instruction sent by the first network device, where the third instruction is used to notify the second network device of first information, where the first information is that the first network device stops Acquiring the target message stream; the acquiring module is further configured to update the sixth dwell time according to the third instruction to obtain the seventh dwell time.
  • the receiving module is further configured to receive a third instruction sent by the first network device, where the third instruction is used to notify the second network device of first information, where the first information is that the first network device stops Acquiring the target message stream; the acquiring module is further configured to update the sixth dwell time according to the third instruction to obtain the seventh dwell time.
  • a device for transmitting a message comprising:
  • the obtaining module is used for the first network device to obtain the second packet in the target packet flow to be transmitted, and obtain the first dwell time of the second packet on the first network device, where the first dwell time is the difference between the first moment and the The time difference between the second moments.
  • the first moment is when the second packet enters the queue system of the first network device, and the second moment is when the second packet is queued in the queue system of the first network device.
  • a time when the network device sends; obtain the second residence time of the target packet flow on the first network device, and the second residence time is the upper limit of the threshold value for the target packet flow to stay on the first network device;
  • an encapsulation module configured to encapsulate the second packet, the first dwell time of the second packet on the first network device, and the second dwell time of the target packet flow on the first network device, to obtain the first packet;
  • the sending module is configured to send the first message to the second network device.
  • the core network transmission path of the target packet flow includes other network devices except the first network device, and the encapsulation module is configured to encapsulate the second packet, and the second packet is stored in the first network
  • the dwell time on the device is the upper limit of the threshold for the destination packet flow to stay on other network devices.
  • the apparatus further includes: a determining module, where the determining module is configured to determine a second port for transmitting the target packet flow on the first network device; obtain an eighth dwell time corresponding to the second port, and the eighth The dwell time is a time determined based on the second other packet flow, and the second other packet flow is the packet flow transmitted through the second port before the first network device obtains the target packet flow; based on the eighth dwell time, the target packet flow is determined.
  • the second dwell time of the packet flow on the first network device; the second dwell time of the target packet flow on the first network device is stored.
  • the sending module is further configured to send a first instruction to other network devices, where the first instruction is used by any network device of other network devices to acquire and store the target packet flow on any network device. dwell time.
  • the sending module is further configured to send the second instruction to other network devices;
  • the apparatus further includes: a receiving module, configured to receive the destination packet flow sent by the other network devices and the stay on the other network devices time, the residence time of the target packet flow on other network devices is sent by other network devices based on the second instruction.
  • the sending module is further configured to stop acquiring the target packet stream, and send a third instruction to other network devices, where the third instruction is used to notify other network devices of the first information, where the first information is the first information.
  • a network device stops acquiring the target packet flow.
  • a fifth aspect provides a network device, the network device includes a memory and a processor; at least one instruction is stored in the memory, and at least one instruction is loaded and executed by the processor to implement the first aspect of the present application or any of the first aspects.
  • a sixth aspect provides a network device, the network device includes a memory and a processor; at least one instruction is stored in the memory, and at least one instruction is loaded and executed by the processor to implement the second aspect or any of the second aspects of the present application.
  • a communication apparatus comprising: a transceiver, a memory, and a processor.
  • the transceiver, the memory and the processor communicate with each other through an internal connection path, the memory is used for storing instructions, and the processor is used for executing the instructions stored in the memory to control the transceiver to receive signals and control the transceiver to send signals , and when the processor executes the instructions stored in the memory, the processor is caused to perform the method provided by the first aspect or any one of the exemplary embodiments of the first aspect.
  • a communication apparatus comprising: a transceiver, a memory and a processor.
  • the transceiver, the memory and the processor communicate with each other through an internal connection path, the memory is used for storing instructions, and the processor is used for executing the instructions stored in the memory to control the transceiver to receive signals and control the transceiver to send signals , and when the processor executes the instructions stored in the memory, the processor is caused to perform the method provided by the second aspect or any one of the exemplary embodiments of the second 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 a read only memory (ROM), which can be integrated with the processor on the same chip, or can be separately set in different On the chip, 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
  • a system for transmitting messages includes a first network device and a second network device, and the first network device and the second network device are connected in communication.
  • the first network device is configured to execute any one of the above-mentioned methods for transmitting packets in the first aspect
  • the second network device is configured to execute any one of the above-mentioned methods for transmitting packets.
  • a computer program comprising: computer program code, when the computer program code is executed by a computer, causing the computer to execute the methods in the above aspects.
  • a readable storage medium stores programs or instructions.
  • the programs or instructions are executed on a computer, the methods in the above aspects are executed.
  • a chip including a processor for invoking and executing instructions stored in the memory from a memory, so that a communication device on which the chip is installed executes the methods in the above aspects.
  • a thirteenth aspect provides a chip, comprising: an input interface, an output interface, a processor, and a memory, the input interface, the output interface, the processor, and the memory are connected through an internal connection path, and the processor is used to execute codes in the memory, When the code is executed, the processor is configured to perform the methods of the above-described aspects.
  • FIG. 1 is a schematic diagram of a transmission scenario provided by an embodiment of the present application.
  • FIG. 2 is a schematic diagram of an implementation environment provided by an embodiment of the present application.
  • FIG. 3 is a flowchart of a method for transmitting a message provided by an embodiment of the present application.
  • FIG. 4 is a schematic structural diagram of a first network device provided by an embodiment of the present application.
  • FIG. 5 is a schematic structural diagram of a second network device provided by an embodiment of the present application.
  • FIG. 6 is a schematic time diagram provided by an embodiment of the present application.
  • FIG. 7 is a schematic diagram of a network architecture provided by an embodiment of the present application.
  • FIG. 8 is a flowchart of a method for transmitting a message provided by an embodiment of the present application.
  • FIG. 9 is a schematic diagram of a network architecture provided by an embodiment of the present application.
  • FIG. 10 is a schematic structural diagram of an apparatus for transmitting a message provided by an embodiment of the present application.
  • FIG. 11 is a schematic structural diagram of an apparatus for transmitting a message provided by an embodiment of the present application.
  • FIG. 12 is a schematic structural diagram of a device for transmitting packets according to an embodiment of the present application.
  • wire-speed refers to the maximum amount of data that a network device can handle. Therefore, when the total data volume of packets received by the network device exceeds the maximum data volume that the network device can handle, the network device can only transmit a part of all the received packets, resulting in packet squeeze. .
  • the upstream network device simultaneously receives three packet streams to be transmitted, and the packet gaps included in the received packet streams are uniform. Since the upstream network device adopts a wire-speed processing mechanism, the packets included in the packet flow processed by the upstream network device are squeezed against each other, and the gap between the packets is reduced. Therefore, compared with the packet stream received by the upstream network device, the burst degree (brust) of the packet stream processed by the upstream network device increases, forming a micro-burst. Since the packet flow processed by the upstream network device will continue to be transmitted to other downstream network devices, the above-mentioned process of forming a micro-burst is repeated continuously.
  • the accumulated micro-bursts form large bursts. Packet flows with large bursts will further squeeze other packet flows in the network, thereby increasing the delay and jitter of each packet flow in the network to unpredictable values. Extended jitter has a large uncertainty.
  • deterministic network is a hot spot in the industry, industrial Internet, smart factory, programmable logic controller (PLC) remote transmission, cloudification, augmented reality (AR)/virtual reality (VR) Businesses such as real-time interaction, remote surgery, and tactile Internet all have the need to build deterministic networks. Therefore, it is necessary to provide a method that can eliminate the transmission packets accumulated in the micro-burst, so as to ensure that the packets have a deterministic delay.
  • an embodiment of the present application provides a method for transmitting a packet, and the method can be applied to the network architecture shown in FIG. 2 .
  • the network architecture includes, but is not limited to, larger scale operator networks, smaller scale campus networks, and other types of IP networks.
  • a first terminal node, a first edge node, a core node (core node), a second edge node and a second terminal node which are connected in sequence communication are included.
  • the first edge node and the second edge node are gateway devices
  • the core node is a router.
  • the first terminal node and the first edge node form an edge network
  • the second terminal node and the second edge node form another edge network
  • the second edge node constitutes a core network.
  • the first edge node is used for the packet transmission.
  • the ingress edge node (ingress edge node) entering the core network, and the second edge node is the egress edge node (egress edge node) for the packet to leave the core network.
  • the second terminal node in response to the transmission direction of the packet being from the second terminal node to the first terminal node, the second terminal node is the ingress edge node, and the first terminal node is the egress edge node.
  • the packet sent by the first terminal node first enters the edge network, and then enters the core network through the first edge node. Afterwards, the packet is forwarded by each core node in the core network, and enters another edge network from the second edge node, thereby reaching the second terminal node. It can be seen that the first terminal node, the first edge node, the core node, the second edge node and the second terminal node form a packet transmission path.
  • the deterministic delay of a packet in this embodiment means that: in the process of transmission from the first terminal node to the second terminal node (or from the second terminal node to the first terminal node), the packet is transmitted on the transmission path.
  • the delay and jitter on the network are always not greater than the predictable and determinable upper limit.
  • Each port in each node included in the packet transmission path reserves a bandwidth (Ri) for the packet flow (Flow i) where the packet is located.
  • the bandwidth reserved by the port is the bandwidth required for transmitting the packet flow.
  • a i (t) R i ⁇ t+B i (1)
  • a i is the total data volume of the packet flow in time t
  • R i is the average rate of the packet flow
  • B i is the maximum burst degree of the packet flow.
  • Condition 3 In response to the packet flow in which the packet sent by the first terminal node is located does not satisfy the above formula, the first edge node performs leaky bucket shaping on the packet flow, and the packet flow after leaky bucket shaping meets the above formula, so that It is ensured that the packet flows entering the core network are all packet flows that satisfy the above formula.
  • an embodiment of the present application provides a method for transmitting packets, and the method can be implemented through interaction between a first network device and a second network device. As shown in FIG. 3, the method includes the following processes 301-308.
  • the first network device acquires a second packet in the target packet flow to be transmitted, and acquires a first residence time of the second packet on the first network device.
  • the first network device is a device for sending the second packet
  • the next hop of the first network device is the second network device
  • the second network device The device is a device for receiving the second packet sent by the first network device.
  • both the first network device and the second network device are devices having both a message sending function and a message receiving function, and the first network device and the second network device may use different functions as required.
  • the first network device includes a shaper, a queuing system, and a scheduler.
  • the shaper is used to shape the data volume of the target packet flow when the data volume of the target packet flow does not satisfy the above formula (1), so that the data volume of the target packet flow meets the above formula (1).
  • the packets included in the target packet flow enter the queue system in the first network device, and the queue system in the first network device is used in the first network device
  • Each message formed in the message queue forms a message queue, and each message is queued in the message queue to be sent by the scheduler.
  • FIG. 4 For a schematic structural diagram of the first network device, reference may be made to FIG. 4 . In FIG.
  • shaper represents a shaper
  • Q represents a queue system
  • S represents a scheduler. It can be understood that each packet in the first network device includes a second packet, other packets in the target packet flow except the second packet, and packets in other packet flows other than the target packet flow. Arts.
  • the scheduler is configured to sequentially send the packets to the second network device according to the sequence in the packet queue.
  • the second network device includes a damper, a queuing system, and a scheduler.
  • a schematic structural diagram of the second network device can be seen in FIG. 5 , where D in FIG. 5 represents a damper.
  • the module between D and Q in FIG. 5 is a switching network, and the situation in which D is located before the switching network shown in FIG. 5 is only an example. In this embodiment, D may be located at any position before Q. For example D can also be located behind the switching network.
  • the damper is used to actively delay the received second packet for a reference duration, and then delay the second packet after the reference duration.
  • the second packet is released, so that the second packet can enter the queue system in the second network device, and wait in the queue system to be sent to the network device of the next hop of the second network device.
  • the manner in which the damper determines the reference duration will be described later in 305, which will not be described here.
  • the first network device includes a shaper, a queue system, and a scheduler for a situation where the upstream of the first network device does not include other network devices. If the upstream of the first network device further includes other network devices, the first network device has the same structure as the second network device. That is, the first network device includes a damper, a queue system and a scheduler.
  • the first dwell time of the second packet on the first network device refers to the time difference between the first moment and the second moment.
  • the upstream of the first network device does not include other network devices, that is, the structure of the first network device includes a shaper, a queue system, and a scheduler
  • the second packet can be used as the first network device at any time on the first network device.
  • first moment includes but is not limited to the moment when the first network device receives the second packet, the moment when the second packet is released by the shaper of the first network device, and the second packet enters the queue system of the first network device and the time when the second packet is sent by the first network device, and so on.
  • the first moment includes but is not limited to the moment when the first network device receives the second packet, the moment when the second packet is released by the shaper of the first network device, and the second packet enters the queue system of the first network device and the time when the second packet is sent by the first network device, and so on.
  • the moment when the second packet enters the queue system in the first network device may be used as the first moment.
  • the first network device includes other network devices, that is, the structure of the first network device includes a damper, a queuing system, and a scheduler
  • the first moment can also be considered as the second packet passing through the damper of the first network device.
  • the second time is the time when the second packet is sent by the first network device after being queued in the queuing system in the first network device.
  • the first network device adds a first timestamp for indicating the first moment to the second packet.
  • a second timestamp for indicating the second time is added to the second packet. Therefore, the first stay time of the second packet on the first network device can be obtained by calculating the first time stamp and the second time stamp.
  • the described moments include the first moment and the second moment mentioned above, and also include the third moment and the fourth moment involved in the following.
  • the time precision that network devices can identify and express is limited.
  • the time precision is arranged in descending order of magnitude, and the time precision includes but is not limited to: attosecond (as), femtosecond (fs), picosecond (picosecond, ps), nanosecond (nanosecond, ns), microsecond (microsecond, ⁇ s), millisecond (millisecond, ms), second (second, s), minute (minute, min), etc.
  • attosecond as
  • femtosecond fs
  • picosecond picosecond
  • nanosecond nanosecond
  • microsecond microsecond
  • millisecond millisecond
  • second second, s
  • minute minute
  • the time precision is set according to actual needs. For example, time precision also includes time precision less than as, or time precision greater than min, and so on.
  • the time precision is the same as the time precision that can be recognized and expressed by network devices such as routers.
  • the actual occurrence time of the moment includes any time within the time precision. For example, if the time precision that the network device can identify and express is 1 ns, then the time precision is also 1 ns. If time 1 is 1 ⁇ s-1 ns, the actual occurrence time of time 1 includes any time within the time precision of 1 ⁇ s-1 ns to 1 ⁇ s-2 ns, such as 1 ⁇ s-1.1 ns, 1 ⁇ s-1.99 ns, and so on.
  • the precision of the moment includes a set precision range
  • the actual occurrence time of the moment includes any time within the precision range.
  • the accuracy of the time is also 10 ⁇ s.
  • time 1 is 13 ⁇ s
  • the actual occurrence time of time 1 includes any time within the precision range of 13 ⁇ s to 23 ⁇ s, such as 15 ⁇ s, 16 ⁇ s, or 18 ⁇ s.
  • time 1 is 16
  • the actual occurrence time of time 1 includes any time from 0:16 to 0:17, such as 0:16:08, 0:16:31, 0:16:59 Wait.
  • the first network device acquires the second residence time of the target packet flow on the first network device.
  • the second residence time of the target packet flow on the first network device refers to an upper threshold limit of the target packet flow staying on the first network device.
  • the upper limit of the threshold is a possible maximum value from the first moment to the second moment.
  • the upper limit of the threshold is the maximum time that the target packet flow can stay on the first network device.
  • each packet flow on the first network device has a corresponding second dwell time, and the second dwell times of different packet flows on the first network device are the same or different.
  • the method before the first network device acquires the second packet to be transmitted, the method further includes: determining a second port on which the target packet flow is transmitted on the first network device, and acquiring the first port corresponding to the second port. Eight dwell times.
  • the eighth dwell time is a time determined based on the second other packet flow, and the second other packet flow refers to the packet flow transmitted through the second port before the first network device obtains the target packet flow. Based on the eighth dwell time, the second dwell time of the target packet flow on the first network device is determined, and the second dwell time of the target packet flow on the first network device is stored.
  • the first network device may include multiple transmission ports, and each transmission port is used to transmit one or more packet streams.
  • the second port used to transmit the target packet stream on the first network device is one of the multiple transmission ports, and the target packet stream can be transmitted from the first network device to the second network through the second port equipment.
  • the eighth dwell time corresponding to the second port is calculated by the first network device, or is sent to the first network device by the network management device under the control plane. In the former case, the first network device uses the network calculus theory to calculate the eighth dwell time corresponding to the second port according to the relevant parameters of the second other packet flow.
  • the second other packet stream is the packet stream transmitted through the second port before the first network device obtains the target packet stream, that is, the packet stream transmitted through the second port when the first network device calculates the eighth dwell time message flow.
  • the relevant parameters of the second other packet flow include but are not limited to the average flow rate of all the second other packet flow and the burst degree corresponding to each second other packet flow.
  • the first network device uses the network calculus theory as a basis in the process of calculating the eighth dwell time corresponding to the second port, and the network calculus theory indicates that any packet flow passing through the second port will affect the The eighth dwell time corresponding to the second port. Therefore, as the number of packet flows passing through the second port increases, the eighth dwell time corresponding to the second port also increases. When the number of packet flows passing through the second port is reduced, the eighth dwell time corresponding to the second port is also reduced.
  • the second port is used to transmit the second other packet flow before the target packet flow is acquired, so after the first network device acquires the target packet flow, the number of packet flows passing through the second port Increase.
  • determining the second dwell time of the target packet flow on the first network device based on the eighth dwell time includes: using the ninth dwell time obtained by updating the eighth dwell time as the second dwell time.
  • D i h indicates the second residence time of the any packet flow on the any network device.
  • the subscript i is used to distinguish different packet flows, and the superscript h is used to distinguish different network devices.
  • the second residence time of the target packet flow on the first network device is D i 1 .
  • the first network device After the first network device obtains the second dwell time of the target packet flow on the first network device, and the first network device stores the second dwell time, the first network device obtains the second packet to be transmitted.
  • the second residence time can be obtained by reading after the text.
  • the target packet flow is identified by a quintuple, where the quintuple includes a source IP address, a source port, a destination IP address, a destination port, and a transport layer protocol, and all packets included in the target packet stream. Each packet carries the quintuple corresponding to the target packet flow.
  • the first network device stores the second dwell time corresponding to the quintuple corresponding to the target packet flow.
  • the first network device obtains the second packet, since the second packet carries the quintuple corresponding to the target packet stream, it can confirm that the second packet belongs to the target packet stream, so that the quintuple can be obtained by reading the second packet.
  • the second dwell time corresponding to the tuple is not limited to the above-mentioned quintuple, and the identifier mode may be selected according to experience or actual needs.
  • the packet flow can also be identified by a triplet.
  • the calculation of the second residence time of the target packet flow on the first network device needs to be applied to the delay caused by the target packet flow, only before the first network device obtains the second packet.
  • the calculation of the second residence time can be completed before the first network device acquires the second packet, so that the first network device can read the second packet after acquiring the second packet. Get the second dwell time.
  • the first network device has not acquired the target packet flow before acquiring the second packet, that is, if the first network device acquires the target packet flow for the first time when acquiring the second packet, then The calculation of the second dwell time needs to be performed after the second packet is obtained.
  • the calculation method can refer to the above description.
  • this embodiment does not limit the execution sequence of 301 and 302, and the execution sequence includes but is not limited to executing 301 first and then executing 302, first executing 302 and then executing 301, and executing 301 and 302 simultaneously.
  • the first network device encapsulates the second packet, the first dwell time of the second packet on the first network device, and the second dwell time of the target packet flow on the first network device to obtain the first packet, Send the first packet to the second network device.
  • this embodiment may directly encapsulate the first dwell time, the second dwell time, and the second packet, thereby obtaining the first packet.
  • the time difference between the second dwell time and the first dwell time may also be calculated, and then the calculated time difference and the second packet are encapsulated to obtain the first packet.
  • the time difference is the active delay time of the second packet on the second network device, and the damper in the second network device is configured to actively delay the second packet according to the calculated time difference. The process of active delay will be described later, and will not be repeated here.
  • the second network device receives the first packet sent by the first network device, and obtains, according to the first packet, the second packet in the target packet flow and the first dwell time of the second packet on the first network device and the second residence time of the target packet flow on the first network device.
  • the second network device can obtain the first packet included in the first packet by parsing the first packet.
  • a dwell time, a second dwell time, and a second message In the case where the first network device encapsulates the time difference between the second dwell time and the first dwell time and the second packet, the second network device can obtain the difference between the second dwell time and the first dwell time through parsing time difference and the second packet.
  • the transmission time required for the first packet to be transmitted from the first network device to the second network device is negligible. That is to say, it can be considered that the moment when the second network device receives the first packet sent by the first network device and the second moment when the first network device sends the first packet is the same moment.
  • the second network device since the second network device includes a damper, a queue system, and a scheduler, the moment when the second network device receives the first packet can also be considered as after the second network device obtains the second packet according to the first packet, The moment when the second packet enters the damper of the second network device.
  • the second network device determines a time difference between the second dwell time of the target packet flow on the first network device and the first dwell time of the second packet on the first network device, where the time difference is Active delay time of the second packet on the second network device.
  • the second network device when the second network device parses and obtains the first dwell time, the second dwell time, and the second packet, the second network device makes a difference between the second dwell time and the first dwell time, so as to obtain the time difference value.
  • the second network device parses and obtains the time difference between the second dwell time and the first dwell time and the second packet, the second network device has obtained the time difference during the parsing process, so there is no need to further Calculation. It can be understood that the value of the time difference is not less than zero.
  • the second network device acquires the third residence time of the second packet on the second network device, and acquires the fourth residence time of the target packet flow on the second network device.
  • the damper in the second network device actively delays the second packet according to the time difference .
  • the second packet stays in the damper of the second network device and does not enter the queue system and scheduler in the second network device.
  • the second network device releases the second packet through the damper, so that the second packet can enter the queue system of the second network device.
  • the second network device may further acquire the third stay time and the fourth stay time.
  • the third dwell time of the second packet on the second network device refers to the time difference between the third moment and the fourth moment.
  • the third time is the time when the second network device ends the active delay of the second packet
  • the third time is the time when the second packet is damped by the second network device after being actively delayed by the damper of the second network device.
  • the time when the server is released or in other words, the time when the second packet enters the queue system of the second network device.
  • the fourth time is the time when the second packet is sent by the second network device after being queued in the queuing system in the second network device, or the time when the second packet leaves the scheduler of the second network device.
  • the third dwell time is actually the sum of the dwell time of the second packet in the queue system and the scheduler in the second network device.
  • the fourth dwell time is the upper threshold limit of the target packet flow staying on the second network device, that is, the maximum time that the target packet flow can stay on the second network device.
  • the second network device may acquire the fourth dwell time according to the first instruction sent by the first network device, see the following processes 3061 and 3062.
  • the first network device Before the first network device acquires the second packet to be transmitted, the first network device sends a first instruction to other network devices.
  • the other network devices refer to network devices other than the first network device in the core network transmission path of the target packet flow.
  • the first network device may determine the above-mentioned other network devices by determining the core network transmission path of the target packet flow.
  • the first network device may determine the destination IP address of the target packet flow according to the quintuple corresponding to the target packet flow. Afterwards, the stored routing table is queried according to the destination IP address of the target packet flow, so as to determine the core network transmission path of the target packet flow.
  • the first network device can send resource reservation signaling to each of the other network devices, and each network device that receives the resource reservation signaling is the target packet.
  • the flow reserves the corresponding bandwidth so that the target packet flow can be normally transmitted in the future.
  • the any network device if the any network device successfully reserves the bandwidth, the any network device feeds back the reservation success signaling to the first network device.
  • the first network device can confirm that the above-mentioned core network transmission path can be used for the transmission of the target packet flow, so as to further report to other network devices.
  • Each of the network devices sends the first instruction.
  • the first network device needs to re-determine the core network transmission path of the target packet flow one or more times, Until all network devices in other network devices on the re-determined core network transmission path feed back reservation success signaling to the first network device. After that, the first network device sends the first instruction to each network device among other network devices on the re-determined core network transmission path.
  • other network devices may include one or more network devices located upstream of the first network device and one or more network devices located downstream of the first network device.
  • sending the first instruction by the first network device to other network devices includes: the first network device sending the first instruction to one or more network devices located downstream of the first network device among the other network devices.
  • the core network transmission path includes at least the first network device and the second network device, and may also include one or more As the network device of the core node, other network devices other than the first network device in the transmission path of the core network include at least the second network device.
  • the first instruction sent by the first network device is used for any one of the other network devices to acquire and store the residence time of the target packet flow on any one of the network devices.
  • each network device performs the same operation as the second network device after receiving the first instruction. Therefore, in 3062, the operation performed by each network device that has received the first instruction based on the first instruction is described by taking the second network device as an example.
  • the second network device receives the first instruction sent by the first network device, and acquires and stores the fourth residence time of the target packet flow on the second network device according to the first instruction.
  • acquiring the fourth residence time of the target packet flow on the second network device by the second network device includes: determining a first port for transmitting the target packet flow on the second network device, acquiring the first The fifth dwell time corresponding to the port, where the fifth dwell time is a time determined based on the first other packet flow, and the first other packet flow is the packet flow transmitted through the first port before the second network device obtains the target packet flow .
  • the fifth dwell time is updated based on the target packet flow to obtain the sixth dwell time, and the sixth dwell time is used as the fourth dwell time of the target packet flow on the second network device.
  • the second network device can obtain the fourth dwell time according to the method in this embodiment.
  • the subsequent process of transmitting the target packet flow through the first port will affect the process of transmitting the first other packet flow through the first port, so that the first other packet flow is transmitted during the transmission process.
  • delay increases. Therefore, after the fifth dwell time corresponding to the first port is updated to the sixth dwell time, it is also necessary to update the upper limit of the threshold for the first other packet flow to stay on the second network device based on the sixth dwell time, so as to It is ensured that the first other packet flow also has a deterministic delay in the transmission process.
  • the upper limit of the threshold value of the any one of the packet flows staying on the second network device is less than the sixth dwell time corresponding to the first port, the The upper limit of the threshold for any packet flow to stay on the second network device is updated to the sixth stay time. If the upper threshold limit of any packet flow staying on the second network device is not less than the sixth dwell time, there is no need to update the upper threshold limit of any packet flow staying on the second network device.
  • the second network device After the second network device obtains the fourth dwell time based on the first instruction, the second network device stores the fourth dwell time, for example, a quintuple or triple corresponding to the fourth dwell time and the target packet flow
  • the groups are correspondingly stored so that the stored fourth dwell time can be read when required.
  • other network devices include one or more network devices in addition to the second network device, since each network device performs the same operation as the second network device after receiving the first instruction, other network devices Any network device in the device acquires and stores the residence time of the target packet flow on the any network device, thereby ensuring normal transmission of the target packet flow.
  • the second network device encapsulates the third dwell time of the second packet on the second network device, the fourth dwell time of the target packet flow on the second network device, and the second packet to obtain a third packet.
  • the second network device may directly encapsulate the third dwell time, the fourth dwell time and the second packet, or may first calculate the time difference between the fourth dwell time and the third dwell time, and then The time difference between the fourth dwell time and the third dwell time and the second packet are encapsulated to obtain a third packet.
  • each operation performed by the second network device in the above description is directed to the case where the second network device is not the last network device on the core network transmission path of the target packet flow.
  • the second network device needs to send the second packet to the terminal node having the destination IP address of the second packet. Since there is usually no damper set on the terminal node, the second network device does not need to obtain the third and fourth dwell times of the second packet on the second network device, but directly encapsulates the second packet and Other information required for transmitting the second message is sufficient.
  • the second network device After the second network device receives the first packet and reaches the active delay time and is queued in the queue system of the second network device, it sends the second network device to the next-hop network device of the second network device on the core network transmission path of the target packet flow. Send the third message.
  • the active delay time is the time that the second packet stays in the damper of the second network device.
  • the second packet After the second network device receives the first packet and reaches the active delay time, the second packet enters the buffer of the second network device. queue system. After that, the second packet can be sent by the second network device after being queued in the queue system of the second network device.
  • the total time that the second packet stays on the second network device is the sum of the active delay time and the queuing time in the queue system of the second network device. Therefore, the second network device receives the first packet and reaches the active delay time. After queuing in the queuing system of the second network device, the second network device can send the third packet.
  • each pair of adjacent network devices on the core network transmission path of the target packet flow interacts with each other according to the methods described in 301-308, so as to ensure that the second packet is transmitted in each pair.
  • the delay between adjacent network devices is deterministic, thereby ensuring that the second packet has a deterministic delay between two terminal nodes.
  • FIG. 7 shows a situation in which a total of h network devices are included on the core network transmission path of the target packet flow.
  • the time delays D i 1 , D i 2 , D i 3 , . . . , D i h-1 between each pair of adjacent network devices on the transmission path of the core network can be determined according to the methods described in 301-308 above.
  • the time for the second packet to be transmitted from the terminal node used for sending the second packet to the first network device in the transmission path of the core network, and the second packet are ignored.
  • D i 1 , D i 2 , D i 3 , ..., D i h-1 are all calculated times, so only D i 0 and D i h will affect the second packet.
  • the upper limit of the jitter of the second packet between the two terminal nodes is D i 0 +D i h . It can be seen that when the second packet is transmitted between two terminal nodes, the delay of the second packet is lower than the above-mentioned upper delay limit D, and the jitter of the second packet is lower than the above-mentioned jitter upper limit D i 0 +D i h . Therefore, according to the definition of the deterministic delay, it can be known that the method described in the above 301-308 can ensure that the second packet has a deterministic delay during the transmission process between the two terminal nodes.
  • an embodiment of the present application further provides another method for transmitting a packet.
  • the method includes the following processes 801 - 809 .
  • the first network device acquires a second packet in the target packet flow to be transmitted, and acquires a first residence time of the second packet on the first network device.
  • the first network device acquires the second residence time of the target packet flow on the first network device.
  • 801 can refer to the description in 301 above, and 802 can refer to the description in 302 above, which will not be repeated here.
  • the first network device encapsulates the second packet, the first dwell time of the second packet on the first network device, the second dwell time of the target packet flow on the first network device, and the second dwell time of the target packet flow on other The dwell time on the network device, obtain the first packet, and send the first packet to the second network device.
  • the residence time of the target packet flow on other network devices is the upper limit of the threshold value for the target packet flow to stay on other network devices.
  • other network devices may include one or more network devices located upstream of the first network device and one or more network devices located downstream of the first network device.
  • the first network device performs encapsulation, it only encapsulates the residence time of the target packet flow on one or more network devices located downstream of the first network device.
  • each network device located downstream of the first network device does not need to use the residence time of the target packet flow on one or more network devices located upstream of the first network device in the process of transmitting the second packet.
  • this encapsulation method the bandwidth required in the transmission process can be reduced, and the waste of network resources can be avoided.
  • the first network device Before the first network device obtains the second packet to be transmitted, it also needs to obtain the residence time of the target packet flow on other network devices according to the following procedures 8031-8033.
  • the first network device sends a second instruction to other network devices.
  • the first network device interacts with other network devices in the transmission path of the core network by sending the second instruction, so that the first network device can obtain the residence time of the target packet flow on other network devices.
  • the first network device sends the second instruction to one or more network devices located downstream of the first network device among other network devices.
  • Each network device that has received the second instruction performs the same operation as the second network device, so 8032 and 8033 both take the second network device as an example for description.
  • the second network device receives the second instruction sent by the first network device, obtains the fourth residence time of the target packet flow on the second network device according to the second instruction, and sends the fourth residence time to the first network device.
  • the process of acquiring the fourth dwell time by the second network device according to the second instruction reference may be made to the process of acquiring the fourth dwell time by the second network device according to the first instruction in 3062, which will not be repeated here. It should be noted that, because the process of acquiring the fourth dwell time by the second network device needs to be applied to the delay that can be caused by the target packet flow, the second network device has not yet acquired the target packet flow when it receives the second instruction. In the case of , the first network device may carry the delay that can be caused by the target packet flow in the second instruction, so that the second network device can normally determine the fourth dwell time. After the second network device acquires the fourth stay time, the fourth stay time is returned to the first network device.
  • the first network device receives the residence time of the target packet flow sent by the other network device on the other network device.
  • the first network device can receive the residence time of the target packet flow on any one of the other network devices.
  • the first network device stores the residence time of the target packet flow on other network devices in correspondence with the quintuple or triplet corresponding to the target packet flow, so as to facilitate reading when needed.
  • the first network device After the first network device obtains the residence time of the target packet flow on other network devices, it can further encapsulate to obtain the first packet.
  • the first network device may calculate the time difference between the second dwell time and the first dwell time, and then use the time difference, the dwell time of the target packet flow on other network devices, and the second packet. Encapsulation is performed to obtain the first packet.
  • the first network device can store the residence time of the target packet flow on all network devices on the transmission path of the core network. Therefore, any network device located downstream of the first network device does not need to store the residence time of the target packet flow on any network device by itself, but reads from the residence time of the target packet flow on other network devices. That's it.
  • the second network device receives the first packet sent by the first network device.
  • the first packet received by the second network device further includes: one or more upstream dwell times of the target packet flow on one or more upstream network devices, one or more upstream dwell times and one or more upstream dwell times.
  • any upstream dwell time is the upper limit of the threshold for the destination packet flow to stay on an upstream network device.
  • one or more downstream dwell times of the target packet flow on one or more downstream network devices are in one-to-one correspondence with one or more downstream network devices, and any downstream dwell time It is the upper limit of the threshold for the destination packet flow to stay on a downstream network device.
  • the second network device obtains, according to the first packet, the second packet in the target packet flow, the first dwell time of the second packet on the first network device, and the target packet flow on the first network device. The second dwell time and the dwell time of the target packet flow on other network devices.
  • the second network device can obtain the second packet in the target packet flow by parsing the first packet, the first residence time of the second packet on the first network device, and the target packet flow in the first The second dwell time on the network device and the dwell time of the target packet flow on other network devices.
  • the second network device determines a time difference between the second dwell time of the target packet flow on the first network device and the first dwell time of the second packet on the first network device, where the time difference is Active delay time of the second packet on the second network device.
  • the second network device obtains the third dwell time of the second packet on the second network device, and obtains the fourth dwell time of the target packet flow on the second network device.
  • the second network device can read the dwell time of the target packet flow in the first packet and obtain the target packet flow on other network devices. Fourth dwell time on the second network device. It should be noted that, after obtaining the fourth residence time of the target packet flow on the second network device in 807, there is no need to follow the upper limit of the threshold for the first other packet flow to stay on the second network device as described in 306. to update. The reason is that the dwell time of the first other packet flow on the second network device is also stored in the first network device, and the second network device does not need to store the dwell time of the first other packet flow on the second network device by itself. time.
  • the updating process is performed by the first network device.
  • the first network device After the first network device performs the update process, it stores the updated upper threshold limit in each packet included in the first other packet stream, and the second network device can obtain the updated threshold by reading the packet.
  • Upper threshold is the updated upper threshold limit in each packet included in the first other packet stream.
  • the second network device encapsulates the second packet, the third dwell time of the second packet on the second network device, and the downstream dwell time of the target packet flow on one or more network devices downstream of the first network device , get the third message.
  • the dwell time that needs to be encapsulated with the second packet also includes the target packet flow on one or more network devices downstream of the first network device. downstream residence time.
  • the target packet flow on the second network device may be deleted from the downstream dwell time of the target packet flow on one or more network devices downstream of the first network device.
  • the fourth dwell time on the second network device is obtained, thereby obtaining the downstream dwell time of the target packet flow on one or more network devices downstream of the second network device. After that, the downstream dwell time of the target packet flow on one or more network devices downstream of the second network device, the second packet, and other required dwell times are re-encapsulated.
  • the second network device After the second network device receives the first packet and reaches the active delay time and is queued in the queue system of the second network device, it sends the second network device to the next-hop network device of the second network device on the core network transmission path of the target packet flow. Send the third message.
  • the method further includes Procedures A1-A3 are as follows.
  • the first network device stops acquiring the target packet stream, and sends a third instruction to other network devices.
  • the third instruction is used to notify other network devices of the first information.
  • the first information is that the first network device stops acquiring the target packet stream. .
  • the first network device stops acquiring the target packet stream, that is, the target packet stream has left the core network, it is necessary to update the core network transmission path of the target packet stream based on the network calculus theory.
  • the dwell time corresponding to the transmission port of the packet flow It can be understood that, in addition to sending the third instruction, the first network device also needs to update the ninth dwell time corresponding to the local second port of the first network device for transmitting the target packet flow.
  • the second network device receives a third instruction sent by the first network device, where the third instruction is used to notify the second network device of first information, where the first information is that the first network device stops acquiring the Destination packet flow.
  • any network device on the core network transmission path of the target packet flow can receive the third instruction.
  • the updating process of the dwell time corresponding to the transmission port used for transmitting the target packet flow on any network device is described.
  • the second network device updates the sixth stay time according to the third instruction to obtain the seventh stay time.
  • the transmission port on the second network device for transmitting the target packet flow is the first port, and during the process of transmitting the target packet flow, the dwell time corresponding to the first port is the sixth dwell time.
  • updating the sixth dwell time to obtain the seventh dwell time includes: taking the difference between the sixth dwell time and the delay that can be caused by the target packet flow as the seventh dwell time.
  • the second network device After obtaining the seventh dwell time, the second network device further stores the seventh dwell time, so that after the first network device obtains the new packet flow, it can calculate the new packet according to the stored seventh dwell time Fourth dwell time of the stream on the second network device.
  • FIG. 9 shows a core network architecture for transmitting messages.
  • the network devices shown in FIG. 9 are numbered as 1, 2, .
  • any network device only stores the upper threshold limit of the packet flow in which the packet resides on the any network device.
  • the network device 1 only stores the upper threshold limit of the packet flow staying on the network device 1 .
  • the process of transmitting the message includes the following B1-B10.
  • the network devices 1-(h-1) all store the dwell time corresponding to each local transmission port.
  • the network device 1 After receiving the message 1 from the terminal node used for sending the message 1, the network device 1 rectifies the message 1, so that the data amount of the message satisfies the requirement of formula (1).
  • the network device 1 sends resource reservation signaling to the network device 2-h.
  • the network device 1 reads the upper threshold D i 1 of the packet 1 staying in the local hop from the local, obtains the time D 1 that the packet 1 stays in the queue system and the scheduler of the local hop through statistics, and encapsulates D 1 and D i 1 and packet 1 obtain packet 2, and send packet 2 to network device 2.
  • the network device 2 reads the upper threshold D i 2 of the locally stored packet 1 staying at the current hop, obtains the time D 2 that the packet 1 stays in the queue system and the scheduler of the current hop through statistics, and encapsulates D 2 , D i 2 and message 1 obtain message 3, and send message 3 to network device 3.
  • any network device H (3 ⁇ H ⁇ (h-1)) in the network device 3-(h-1), receives the packet H sent by the previous hop network device (H-1), the packet H It includes the upper threshold D i (H-1) of the packet 1 staying on the previous hop network device, the time D (H -1) that the packet 1 stays in the queue system and scheduler of the previous hop network device, and Message 1.
  • the network device H reads the upper threshold D i H of the locally stored packet 1 staying at the current hop, obtains the time D H that the packet 1 stays in the queue system and the scheduler of the current hop through statistics, and encapsulates D H , D i H and the message 1 obtain the message (H+1), and send the message (H+1) to the network device (H+1).
  • the network device h encapsulates the packet 1, and sends the encapsulated packet 1 to a terminal node for receiving the packet 1.
  • the network device 1 stores the upper limit of the threshold value that the packet stream containing the packet stays on all network devices in the network device 2-h, and the process of transmitting the packet includes the following: C1-C11.
  • the network devices 1-(h-1) all store the dwell time corresponding to each local transmission port.
  • the network device 1 sends resource reservation signaling to the network device 2-h.
  • the network device 1 receives the upper threshold D i 2 , . , obtain the dwell time of the packet 1 on each network device on the transmission path of the core network, and store it as a list. Included in the list are: D i 1 , D i 2 , D i 3 , ..., D i h-1 , D i h .
  • the network device 1 encapsulates the packet 1, the time D 1 that the packet 1 stays in the queue system and scheduler of this hop, and the list obtained in C5, obtains the packet 2, and sends the packet 2 to the network device. 2.
  • the network device 2 obtains the time D 2 that the packet 1 stays in the queue system and scheduler of this hop according to statistics, deletes D i 1 from the list, and deletes the packet 1, D 2 and the list after D i 1 is deleted. It is encapsulated as packet 3 and sent to network device 3 .
  • any network device H (3 ⁇ H ⁇ (h-1)) in the network device 3-(h-1), receives the packet H sent by the previous-hop network device (H-1), and receives the packet H from the packet Read D (H-1) from H, read D i (H-1) from the list of message H, and calculate message 1 according to the read D (H-1) and D i (H-1) At the active delay time d (H-1) on this hop, message 1 is released from the damper after the active delay time d (H-1) .
  • the network device H obtains the time DH that the message 1 stays in the queue system and scheduler of this hop according to statistics, deletes Di ( H -1) from the list, and deletes the message 1 , D2 and D i from the list .
  • the list after (H-1) is encapsulated as a message (H+1) and sent to the network device (H+1).
  • the network device h encapsulates the packet 1, and sends the encapsulated packet 1 to the terminal node for receiving the packet 1.
  • each network device in this application actively delays the second packet to be transmitted to ensure that the packet to be transmitted has a deterministic delay between a pair of adjacent network devices, thereby ensuring that Therefore, the second packet to be transmitted has a deterministic delay between the two ends.
  • the active delay time of each network device is obtained based on the target packet flow where the second packet is located, thereby avoiding mutual interference between different packet flows. Therefore, the methods provided by the embodiments of the present application are not only simple to implement, but also applicable to IP networks of various scales. It can be seen that this method is more practical and has better transmission effect.
  • an embodiment of the present application further provides an apparatus for transmitting a message, and the apparatus is applied to a second network device to execute the methods for transmitting a message shown in FIG. 3 and FIG. 8 .
  • the device includes:
  • the receiving module 1001 is used for the second network device to receive the first message sent by the first network device;
  • the obtaining module 1002 is used for the second network device to obtain the second packet in the target packet flow, the first residence time of the second packet on the first network device, and the target packet flow in the first network device according to the first packet.
  • the first dwell time is the time difference between the first time and the second time.
  • the first time is the time when the second packet enters the queue system of the first network device.
  • the second time is the moment when the second packet is sent by the first network device after being queued in the queuing system of the first network device, and the second dwell time is the upper threshold limit for the destination packet flow to stay on the first network device;
  • the determining module 1003 is used for the second network device to determine the time difference between the second dwell time of the target packet flow on the first network device and the first dwell time of the second packet on the first network device, time The difference is the active delay time of the second packet on the second network device;
  • the obtaining module 1002 is further configured to obtain the third dwell time of the second packet on the second network device, and obtain the fourth dwell time of the target packet flow on the second network device, where the third dwell time is the difference between the third moment and the second network device.
  • the fourth dwell time is the upper limit of the threshold value for the target packet flow to stay on the second network device;
  • an encapsulation module 1004 configured to encapsulate the third dwell time of the second packet on the second network device, the fourth dwell time of the target packet flow on the second network device, and the second packet to obtain a third packet;
  • the sending module 1005 is used for the second network device to send the second network device to the downlink of the second network device on the core network transmission path of the target packet flow after receiving the first packet and reaching the active delay time and queuing in the queue system of the second network device.
  • the one-hop network device sends the third packet.
  • the core network transmission path of the target packet flow includes one or more network devices located upstream of the first network device and one or more network devices located downstream of the first network device.
  • the packet also includes one or more upstream dwell times of the target packet flow on one or more upstream network devices.
  • the one or more upstream dwell times are in one-to-one correspondence with one or more upstream network devices.
  • the dwell time is the upper limit of the threshold value for the target packet flow to stay on an upstream network device.
  • the first packet also includes one or more downstream dwell times of the target packet flow on one or more downstream network devices.
  • the multiple downstream dwell times are in one-to-one correspondence with one or more downstream network devices, and any downstream dwell time is the upper limit of the threshold for the destination packet flow to stay on one downstream network device;
  • An encapsulation module 1004 configured to encapsulate the second packet, the third dwell time of the second packet on the second network device, and the downstream dwell time of the target packet flow on one or more network devices downstream of the first network device , get the third message.
  • the receiving module 1001 is further configured to receive the first instruction sent by the first network device;
  • the obtaining module 1002 is further configured to determine, according to the first instruction, a first port for transmitting the target packet flow on the second network device; obtain a fifth dwell time corresponding to the first port, where the fifth dwell time is based on the first other packet
  • the time determined by the flow, the first other message flow is the message flow transmitted through the first port before the second network device obtains the target message flow; the fifth dwell time is updated based on the target message flow, and the sixth dwell time is obtained;
  • the sixth dwell time is used as the fourth dwell time of the target packet flow on the second network device.
  • the receiving module 1001 is further configured to receive a third instruction sent by the first network device, where the third instruction is used to notify the second network device of first information, where the first information is the first network device Stop getting the target packet stream;
  • the obtaining module 1002 is further configured to update the sixth stay time according to the third instruction to obtain the seventh stay time.
  • the receiving module 1001 is further configured to receive a third instruction sent by the first network device, where the third instruction is used to notify the second network device of first information, where the first information is the first network device Stop getting the target packet stream;
  • the obtaining module 1002 is further configured to update the sixth stay time according to the third instruction to obtain the seventh stay time.
  • an embodiment of the present application further provides an apparatus for transmitting a message, and the apparatus is applied to a first network device to execute the method for transmitting a message shown in FIG. 3 and FIG. 8 .
  • the device includes:
  • the obtaining module 1101 is used for the first network device to obtain the second packet in the target packet flow to be transmitted, and obtain the first dwell time of the second packet on the first network device, where the first dwell time is the first moment The time difference from the second time.
  • the first time is when the second packet enters the queue system of the first network device, and the second time is when the second packet is queued in the queue system of the first network device. the time when the first network device sends; obtain the second dwell time of the target packet flow on the first network device, where the second dwell time is the upper threshold limit of the target packet flow staying on the first network device;
  • an encapsulation module 1102 configured to encapsulate the second packet, the first dwell time of the second packet on the first network device, and the second dwell time of the target packet flow on the first network device, to obtain the first packet;
  • the sending module 1103 is configured to send the first packet to the second network device.
  • the core network transmission path of the target packet flow includes other network devices except the first network device, and the encapsulation module 1102 is configured to encapsulate the second packet, and the second packet is in the first The first dwell time on the network device, the second dwell time of the target packet flow on the first network device, and the dwell time of the target packet flow on other network devices to obtain the first packet, and the target packet flow on other network devices
  • the dwell time on the network device is the upper limit of the threshold for the destination packet flow to stay on other network devices.
  • the apparatus further includes: a determining module, where the determining module is configured to determine a second port for transmitting the target packet flow on the first network device; obtain an eighth dwell time corresponding to the second port, and the eighth The dwell time is a time determined based on the second other packet flow, and the second other packet flow is the packet flow transmitted through the second port before the first network device obtains the target packet flow; based on the eighth dwell time, the target packet flow is determined.
  • the second dwell time of the packet flow on the first network device; the second dwell time of the target packet flow on the first network device is stored.
  • the sending module 1103 is further configured to send a first instruction to other network devices, where the first instruction is used by any network device of the other network devices to acquire and store the target packet flow on any network device residence time.
  • the sending module 1103 is further configured to send the second instruction to other network devices;
  • the apparatus further includes: a receiving module configured to receive the residence time of the target packet stream sent by other network devices on other network devices, where the residence time of the target packet stream on other network devices is sent by other network devices based on the second instruction.
  • the sending module 1103 is further configured to stop acquiring the target packet stream, and send a third instruction to other network devices, where the third instruction is used to notify other network devices of the first information, where the first information is The first network device stops acquiring the target packet flow.
  • each network device in this application actively delays the message to be transmitted to ensure that the message to be transmitted has a deterministic delay between a pair of adjacent network devices, thereby ensuring that the message to be transmitted has a deterministic delay.
  • the transmitted packets have a deterministic delay between the two ends.
  • the active delay time of each network device is obtained based on the packet flow in which the to-be-transmitted packet is located, thereby avoiding mutual interference between different packet flows. Therefore, the methods provided by the embodiments of the present application are not only simple to implement, but also applicable to IP networks of various scales. It can be seen that this method is more practical and has better transmission effect.
  • An embodiment of the present application provides a network device, the network device includes a memory and a processor; at least one instruction is stored in the memory, and at least one instruction is loaded and executed by the processor, so as to implement the required execution by the first network device in the present application. method.
  • An embodiment of the present application provides a network device, the network device includes a memory and a processor; at least one instruction is stored in the memory, and the at least one instruction is loaded and executed by the processor, so as to implement the required execution by the second network device in the present application. method.
  • an embodiment of the present application further provides a device 1200 for transmitting packets, and the device 1200 for transmitting packets shown in FIG. 12 is used to perform operations involved in the method for uploading packets.
  • the device 1200 for transmitting messages includes: a memory 1201 , a processor 1202 and an interface 1203 , and the memory 1201 , the processor 1202 and the interface 1203 are connected through a bus 1204 .
  • At least one instruction is stored in the memory 1201, and at least one instruction is loaded and executed by the processor 1202, so as to implement any of the above-mentioned methods for transmitting a message.
  • the interface 1203 is used to communicate with other devices in the network, and the interface 1203 may be implemented in a wireless or wired manner.
  • the interface 1203 may be a network card.
  • the tunnel configuration device 1200 may communicate with the server through the interface 1203 .
  • FIG. 12 only shows a simplified design of the device 1200 for transmitting messages.
  • the tunnel configuration device may contain any number of interfaces, processors or memories.
  • the above-mentioned processor may be a central processing unit (Central Processing Unit, CPU), or other general-purpose processors, digital signal processing (digital signal processing, DSP), application specific integrated circuit (application specific integrated circuit, ASIC), Field-programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
  • a general purpose processor may be a microprocessor or any conventional processor or the like. It should be noted that the processor may be a processor supporting an advanced RISC machine (ARM) architecture.
  • ARM advanced RISC machine
  • the above-mentioned memory may include read-only memory and random access memory, and provide instructions and data to the processor.
  • the memory may also include non-volatile random access memory.
  • the memory may also store device type information.
  • An embodiment of the present application provides a communication apparatus, and the apparatus includes: a transceiver, a memory, and a processor.
  • the transceiver, the memory and the processor communicate with each other through an internal connection path, the memory is used for storing instructions, and the processor is used for executing the instructions stored in the memory to control the transceiver to receive signals and control the transceiver to send signals , and when the processor executes the instructions stored in the memory, the processor is made to execute the method required to be executed by the first network device in this application.
  • An embodiment of the present application provides a communication apparatus, and the apparatus includes: a transceiver, a memory, and a processor.
  • the transceiver, the memory and the processor communicate with each other through an internal connection path, the memory is used for storing instructions, and the processor is used for executing the instructions stored in the memory to control the transceiver to receive signals and control the transceiver to send signals , and when the processor executes the instructions stored in the memory, the processor is made to execute the method required to be executed by the first network device in this application.
  • 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 a read only memory (ROM), which can be integrated with the processor on the same chip, or can be separately set in different On the chip, 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 system includes a first network device and a second network device, and the first network device and the second network device are connected in communication.
  • first network device and the second network device are connected in communication.
  • the embodiments of the present application provide a computer program (product), and the computer program (product) includes: computer program code, when the computer program code is run by a computer, the computer program code enables the computer to execute any one of the above-mentioned exemplary embodiments of the present application. Methods.
  • the embodiments of the present application provide a readable storage medium, where the readable storage medium stores programs or instructions, and when the programs or instructions are run on a computer, the methods provided by any of the exemplary embodiments of the present application are executed.
  • An embodiment of the present application provides a chip, including a processor, configured to call and execute an instruction stored in the memory from a memory, so that a communication device installed with the chip executes the method provided by any of the exemplary embodiments of the present application .
  • An embodiment of the present application provides a chip, including: an input interface, an output interface, a processor, and a memory, the input interface, the output interface, the processor, and the memory are connected through an internal connection path, and the processor is used to execute code in the memory, When the code is executed, the processor is configured to perform the method provided by any of the exemplary embodiments of this application.
  • processor may be a central processing unit (Central Processing Unit, CPU), or other general-purpose processors, digital signal processing (digital signal processing, DSP), application specific integrated circuit (application specific integrated circuit, ASIC), field-programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
  • a general purpose processor may be a microprocessor or any conventional processor or the like. It should be noted that the processor may be a processor supporting an advanced RISC machine (ARM) architecture.
  • ARM advanced RISC machine
  • the above-mentioned memory may include read-only memory and random access memory, and provide instructions and data to the processor.
  • the memory may also include non-volatile random access memory.
  • the memory may also store device type information.
  • the memory may be volatile memory or non-volatile memory, or may include both volatile and non-volatile memory.
  • the non-volatile memory may be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically programmable Erase programmable read-only memory (electrically EPROM, EEPROM) or flash memory.
  • Volatile memory may be random access memory (RAM), which acts as an external cache. By way of example and not limitation, many forms of RAM are available.
  • SRAM static RAM
  • DRAM dynamic random access memory
  • SDRAM synchronous dynamic random access memory
  • double data rate synchronous dynamic random access Memory double data date SDRAM, DDR SDRAM
  • enhanced synchronous dynamic random access memory enhanced SDRAM, ESDRAM
  • synchronous link dynamic random access memory direct memory bus random access memory
  • direct rambus RAM direct rambus RAM
  • the present application provides a computer program.
  • the processor or the computer can execute the corresponding steps and/or processes in the foregoing method embodiments.
  • a computer program product includes one or more computer instructions.
  • the computer may be a general purpose computer, a special purpose computer, a computer network, or other programmable device.
  • Computer instructions may be stored in or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transmitted from a website site, computer, server, or data center over a wire (e.g.
  • coaxial cable, optical fiber, digital subscriber line) or wireless means to another website site, computer, server or data center.
  • a computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server, a data center, or the like that includes an integration of one or more available media.
  • Useful media may be magnetic media (eg, floppy disks, hard disks, magnetic tapes), optical media (eg, optical disks), or semiconductor media (eg, solid state drives (SSDs)), among others.

Landscapes

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

Abstract

本申请公开了传输报文的方法、装置、设备及可读存储介质,属于通信技术领域。应用于第二网络设备的方法包括:首先接收第一网络设备发送的第一报文,再根据该第一报文获取第二报文、第一停留时间以及第二停留时间。之后,确定第二停留时间与第一停留时间之间的时间差值。接着,确定第三停留时间以及第四停留时间,从而封装第三停留时间、第四停留时间以及第二报文,获得第三报文。接收到第一报文达到该时间差值并经过第二网络设备的队列***的排队之后,向第二网络设备的下一跳网络设备发送第三报文。通过对待传输的报文进行主动延迟的方式,保证了待传输的报文在传输过程中的确定性时延,该方法适用于各种规模的IP网络。

Description

传输报文的方法、装置、设备及可读存储介质
本申请要求于2020年07月31日提交的申请号为202010761634.4、发明名称为“传输报文的方法、装置、设备及可读存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及通信技术领域,特别涉及一种传输报文的方法、装置、设备及可读存储介质。
背景技术
随着通信技术的发展,通过互联网协议(Internet Protocol,IP)网络传输的报文数量也越来越多。由于IP网络中的网络设备对报文进行线速处理,因而在网络设备同时接收到多个不同报文流的情况下,不同报文流中的报文相互挤压、报文间隙减小,从而使得突发度不断累积,导致报文在传输过程中的时延及抖动增大且难以预测。因此,需要提供一种能够消除突发度累积的报文传输方法,从而保证报文的时延及抖动的可确定性。
相关技术中,通过循环排队和转发(cyclic queueing and forwarding,CQF)的方法进行报文传输。该方法首先对IP网络中的所有网络设备进行时钟边缘的对齐,从而保证不同网络设备在同一时刻处于相同的周期。之后,对于IP网络中相邻的网络设备,第一个网络设备在第一个周期内发送的报文由第二个网络设备在该第一个周期内接收,第二个网络设备在第二个周期内将接收到的报文转发给第三个网络设备,第三个网络设备在第二个周期内完成报文的接收。以此类推,便能够实现报文的传输。若网络设备之间的路径长度为N,即两端之间共包括(N+1)个网络设备且周期时长为T,则传输过程中报文在两端之间的最大总时延为(N+1)T,最小总时延为(N-1)T,抖动为2T,从而在传输过程中保证了报文具有确定性时延。
然而,由于相关技术需要对IP网络中的所有网络设备进行时钟同步,因而该方法实现较为复杂。另外,由于周期时长的限制,相邻的一对网络设备之间的距离不能过长,因而该方法仅适用于规模较小的IP网络中,较为局限。可见,相关技术所提供的方法不够实用,传输效果较差。
发明内容
本申请提供了一种传输报文的方法、装置、设备及可读存储介质,以提高报文传输效果,技术方案如下:
一方面,提供了一种传输报文的方法,该方法包括:
第二网络设备首先接收第一网络设备发送的第一报文,再根据第一报文获取目标报文流中的第二报文、第二报文在第一网络设备上的第一停留时间以及目标报文流在第一网络设备上的第二停留时间。其中,第一停留时间为第一时刻与第二时刻之间的时间差值,第一时刻是第二报文进入第一网络设备的队列***的时刻,第二时刻是第二报文经过第一网络设备的队列***的排队之后被第一网络设备发送的时刻,第二停留时间是目标报文流在第一网络设 备上停留的阈值上限。之后,第二网络设备确定目标报文流在第一网络设备上的第二停留时间与第二报文在第一网络设备上的第一停留时间之间的时间差值,该时间差值为第二报文在第二网络设备上的主动延迟时间。
接着,第二网络设备获取第二报文在第二网络设备上的第三停留时间,获取目标报文流在第二网络设备上的第四停留时间,从而封装第二报文在第二网络设备上的第三停留时间、目标报文流在第二网络设备上的第四停留时间以及第二报文,获得第三报文。其中,第三停留时间为第三时刻与第四时刻之间的时间差值,第三时刻是第二网络设备结束对第二报文的主动延迟的时刻,第四时刻是第二报文经过第二网络设备的队列***的排队之后被第二网络设备发送的时刻,第四停留时间是目标报文流在第二网络设备上停留的阈值上限。在第二网络设备接收到第一报文达到主动延迟时间并经过第二网络设备的队列***的排队之后,向目标报文流的核心网络传输路径上第二网络设备的下一跳网络设备发送第三报文。
各个网络设备通过对待传输的报文进行主动延迟的方式,保证了待传输的报文在相邻的一对网络设备之间具有确定性时延,进而保证了待传输的报文在两端之间具有确定性时延。并且,各个网络设备进行主动延迟的时间是基于待传输报文所在的报文流得到的,从而避免了不同报文流之间的相互干扰。该方法不仅实现较为简单,而且适用于各种规模的IP网络。可见,该方法较为实用、传输效果较好。
在一种可能的实现方式中,目标报文流的核心网络传输路径中包含位于第一网络设备上游的一个或多个网络设备以及位于第一网络设备下游的一个或多个网络设备,第一报文还包括目标报文流在上游的一个或多个网络设备上的一个或多个上游停留时间,一个或多个上游停留时间与上游的一个或多个网络设备一一对应,任一个上游停留时间是目标报文流在上游的一个网络设备上停留的阈值上限,第一报文还包括目标报文流在下游的一个或多个网络设备上的一个或多个下游停留时间,一个或多个下游停留时间与下游的一个或多个网络设备一一对应,任一个下游停留时间是目标报文流在下游的一个网络设备上停留的阈值上限;
封装第二报文在第二网络设备上的第三停留时间、目标报文流在第二网络设备上的第四停留时间以及第二报文,获得第三报文,包括:封装第二报文、第二报文在第二网络设备上的第三停留时间以及目标报文流在第一网络设备下游的一个或多个网络设备上的下游停留时间,获得第三报文。
在一种可能的实现方式中,在第二网络设备接收第一网络设备发送的第一报文之前,方法还包括:接收第一网络设备发送的第一指令;根据第一指令确定在第二网络设备上传输目标报文流的第一端口;获取第一端口对应的第五停留时间,第五停留时间为基于第一其他报文流确定的时间,第一其他报文流为第二网络设备获取目标报文流之前通过第一端口传输的报文流;基于目标报文流更新第五停留时间,得到第六停留时间;将第六停留时间作为目标报文流在第二网络设备上的第四停留时间。
在一种可能的实现方式中,在第二网络设备接收第一网络设备发送的第一报文之前,方法还包括:接收第一网络设备发送的第二指令;根据第二指令,获取目标报文流在第二网络设备上的第四停留时间;向第一网络设备发送第四停留时间。
在一种可能的实现方式中,向目标报文流的核心网络传输路径上第二网络设备的下一跳网络设备发送第三报文之后,方法还包括:接收第一网络设备发送的第三指令,第三指令用于向第二网络设备通知第一信息,第一信息为第一网络设备停止获取目标报文流;根据第三 指令更新第六停留时间,得到第七停留时间。
第二方面,提供了一种传输报文的方法,该方法包括:
第一网络设备获取待传输的目标报文流中的第二报文,获取第二报文在第一网络设备上的第一停留时间,第一停留时间为第一时刻与第二时刻之间的时间差值,第一时刻是第二报文进入第一网络设备的队列***的时刻,第二时刻是第二报文经过第一网络设备的队列***的排队之后被第一网络设备发送的时刻;
获取目标报文流在第一网络设备上的第二停留时间,第二停留时间是目标报文流在第一网络设备上停留的阈值上限;
封装第二报文、第二报文在第一网络设备上的第一停留时间以及目标报文流在第一网络设备上的第二停留时间,获得第一报文;向第二网络设备发送第一报文。
在一种可能的实现方式中,目标报文流的核心网络传输路径中包含除第一网络设备以外的其他网络设备,封装第二报文、第二报文在第一网络设备上的第一停留时间以及目标报文流在第一网络设备上的第二停留时间,获得第一报文,包括:封装第二报文、第二报文在第一网络设备上的第一停留时间、目标报文流在第一网络设备上的第二停留时间以及目标报文流在其他网络设备上的停留时间,获得第一报文,目标报文流在其他网络设备上的停留时间为目标报文流在其他网络设备上停留的阈值上限。
在一种可能的实现方式中,第一网络设备获取待传输的目标报文流中的第二报文之前,方法还包括:确定在第一网络设备上传输目标报文流的第二端口;获取第二端口对应的第八停留时间,第八停留时间为基于第二其他报文流确定的时间,第二其他报文流为第一网络设备获取目标报文流之前通过第二端口传输的报文流;基于第八停留时间,确定目标报文流在第一网络设备上的第二停留时间;存储目标报文流在第一网络设备上的第二停留时间。
在一种可能的实现方式中,第一网络设备获取待传输的目标报文流中的第二报文之前,方法还包括:向其他网络设备发送第一指令,第一指令用于其他网络设备的任一个网络设备获取并存储目标报文流在任一个网络设备上的停留时间。
在一种可能的实现方式中,第一网络设备获取待传输的目标报文流中的第二报文之前,方法还包括:向其他网络设备发送第二指令;接收其他网络设备发送的目标报文流在其他网络设备上的停留时间,目标报文流在其他网络设备上的停留时间为其他网络设备基于第二指令发送。
在一种可能的实现方式中,向第二网络设备发送第一报文之后,方法还包括:停止获取目标报文流,向其他网络设备发送第三指令,第三指令用于向其他网络设备通知第一信息,第一信息为第一网络设备停止获取目标报文流。
第三方面,提供了一种传输报文的装置,该装置包括:
接收模块,用于第二网络设备接收第一网络设备发送的第一报文;
获取模块,用于第二网络设备根据第一报文获取目标报文流中的第二报文、第二报文在第一网络设备上的第一停留时间以及目标报文流在第一网络设备上的第二停留时间,第一停留时间为第一时刻与第二时刻之间的时间差值,第一时刻是第二报文进入第一网络设备的队列***的时刻,第二时刻是第二报文经过第一网络设备的队列***的排队之后被第一网络设备发送的时刻,第二停留时间是目标报文流在第一网络设备上停留的阈值上限;
确定模块,用于第二网络设备确定目标报文流在第一网络设备上的第二停留时间与第二 报文在第一网络设备上的第一停留时间之间的时间差值,时间差值为第二报文在第二网络设备上的主动延迟时间;
获取模块,还用于获取第二报文在第二网络设备上的第三停留时间,获取目标报文流在第二网络设备上的第四停留时间,第三停留时间为第三时刻与第四时刻之间的时间差值,第三时刻是第二网络设备结束对第二报文的主动延迟的时刻,第四时刻是第二报文经过第二网络设备的队列***的排队之后被第二网络设备发送的时刻,第四停留时间是目标报文流在第二网络设备上停留的阈值上限;
封装模块,用于封装第二报文在第二网络设备上的第三停留时间、目标报文流在第二网络设备上的第四停留时间以及第二报文,获得第三报文;
发送模块,用于第二网络设备接收到第一报文达到主动延迟时间并经过第二网络设备的队列***的排队之后,向目标报文流的核心网络传输路径上第二网络设备的下一跳网络设备发送第三报文。
在一种可能的实现方式中,目标报文流的核心网络传输路径中包含位于第一网络设备上游的一个或多个网络设备以及位于第一网络设备下游的一个或多个网络设备,第一报文还包括目标报文流在上游的一个或多个网络设备上的一个或多个上游停留时间,一个或多个上游停留时间与上游的一个或多个网络设备一一对应,任一个上游停留时间是目标报文流在上游的一个网络设备上停留的阈值上限,第一报文还包括目标报文流在下游的一个或多个网络设备上的一个或多个下游停留时间,一个或多个下游停留时间与下游的一个或多个网络设备一一对应,任一个下游停留时间是目标报文流在下游的一个网络设备上停留的阈值上限;封装模块,用于封装第二报文、第二报文在第二网络设备上的第三停留时间以及目标报文流在第一网络设备下游的一个或多个网络设备上的下游停留时间,获得第三报文。
在一种可能的实现方式中,接收模块,还用于接收第一网络设备发送的第一指令;获取模块,还用于根据第一指令确定在第二网络设备上传输目标报文流的第一端口;获取第一端口对应的第五停留时间,第五停留时间为基于第一其他报文流确定的时间,第一其他报文流为第二网络设备获取目标报文流之前通过第一端口传输的报文流;基于目标报文流更新第五停留时间,得到第六停留时间;将第六停留时间作为目标报文流在第二网络设备上的第四停留时间。
在一种可能的实现方式中,接收模块,还用于接收第一网络设备发送的第三指令,第三指令用于向第二网络设备通知第一信息,第一信息为第一网络设备停止获取目标报文流;获取模块,还用于根据第三指令更新第六停留时间,得到第七停留时间。
在一种可能的实现方式中,接收模块,还用于接收第一网络设备发送的第三指令,第三指令用于向第二网络设备通知第一信息,第一信息为第一网络设备停止获取目标报文流;获取模块,还用于根据第三指令更新第六停留时间,得到第七停留时间。
第四方面,提供了一种传输报文的装置,该装置包括:
获取模块,用于第一网络设备获取待传输的目标报文流中的第二报文,获取第二报文在第一网络设备上的第一停留时间,第一停留时间为第一时刻与第二时刻之间的时间差值,第一时刻是第二报文进入第一网络设备的队列***的时刻,第二时刻是第二报文经过第一网络设备的队列***的排队之后被第一网络设备发送的时刻;获取目标报文流在第一网络设备上的第二停留时间,第二停留时间是目标报文流在第一网络设备上停留的阈值上限;
封装模块,用于封装第二报文、第二报文在第一网络设备上的第一停留时间以及目标报文流在第一网络设备上的第二停留时间,获得第一报文;
发送模块,用于向第二网络设备发送第一报文。
在一种可能的实现方式中,目标报文流的核心网络传输路径中包含除第一网络设备以外的其他网络设备,封装模块,用于封装第二报文、第二报文在第一网络设备上的第一停留时间、目标报文流在第一网络设备上的第二停留时间以及目标报文流在其他网络设备上的停留时间,获得第一报文,目标报文流在其他网络设备上的停留时间为目标报文流在其他网络设备上停留的阈值上限。
在一种可能的实现方式中,装置还包括:确定模块,确定模块用于确定在第一网络设备上传输目标报文流的第二端口;获取第二端口对应的第八停留时间,第八停留时间为基于第二其他报文流确定的时间,第二其他报文流为第一网络设备获取目标报文流之前通过第二端口传输的报文流;基于第八停留时间,确定目标报文流在第一网络设备上的第二停留时间;存储目标报文流在第一网络设备上的第二停留时间。
在一种可能的实现方式中,发送模块,还用于向其他网络设备发送第一指令,第一指令用于其他网络设备的任一个网络设备获取并存储目标报文流在任一个网络设备上的停留时间。
在一种可能的实现方式中,发送模块,还用于向其他网络设备发送第二指令;装置还包括:接收模块,用于接收其他网络设备发送的目标报文流在其他网络设备上的停留时间,目标报文流在其他网络设备上的停留时间为其他网络设备基于第二指令发送。
在一种可能的实现方式中,发送模块,还用于停止获取目标报文流,向其他网络设备发送第三指令,第三指令用于向其他网络设备通知第一信息,第一信息为第一网络设备停止获取目标报文流。
第五方面,提供了一种网络设备,网络设备包括存储器及处理器;存储器中存储有至少一条指令,至少一条指令由处理器加载并执行,以实现本申请第一方面或第一方面的任一种示例性实施例所提供的方法。
第六方面,提供了一种网络设备,网络设备包括存储器及处理器;存储器中存储有至少一条指令,至少一条指令由处理器加载并执行,以实现本申请第二方面或第二方面的任一种示例性实施例所提供的方法。
第七方面,提供了一种通信装置,该装置包括:收发器、存储器和处理器。其中,该收发器、该存储器和该处理器通过内部连接通路互相通信,该存储器用于存储指令,该处理器用于执行该存储器存储的指令,以控制收发器接收信号,并控制收发器发送信号,并且当该处理器执行该存储器存储的指令时,使得该处理器执行第一方面或第一方面的任一种示例性实施例所提供的方法。
第八方面,提供了一种通信装置,该装置包括:收发器、存储器和处理器。其中,该收发器、该存储器和该处理器通过内部连接通路互相通信,该存储器用于存储指令,该处理器用于执行该存储器存储的指令,以控制收发器接收信号,并控制收发器发送信号,并且当该处理器执行该存储器存储的指令时,使得该处理器执行第二方面或第二方面的任一种示例性实施例所提供的方法。
可选地,处理器为一个或多个,存储器为一个或多个。
可选地,存储器可以与处理器集成在一起,或者存储器与处理器分离设置。
在具体实现过程中,存储器可以为非瞬时性(non-transitory)存储器,例如只读存储器(read only memory,ROM),其可以与处理器集成在同一块芯片上,也可以分别设置在不同的芯片上,本申请实施例对存储器的类型以及存储器与处理器的设置方式不做限定。
第九方面,提供了一种传输报文的***,***包括第一网络设备及第二网络设备,该第一网络设备及第二网络设备通信连接。第一网络设备用于执行上述第一方面任一的传输报文的方法,第二网络设备用于执行上述第二方面任一的传输报文的方法。
第十方面,提供了一种计算机程序(产品),计算机程序(产品)包括:计算机程序代码,当计算机程序代码被计算机运行时,使得计算机执行上述各方面中的方法。
第十一方面,提供了一种可读存储介质,可读存储介质存储程序或指令,当程序或指令在计算机上运行时,上述各方面中的方法被执行。
第十二方面,提供了一种芯片,包括处理器,用于从存储器中调用并运行存储器中存储的指令,使得安装有芯片的通信设备执行上述各方面中的方法。
第十三方面,提供一种芯片,包括:输入接口、输出接口、处理器和存储器,输入接口、输出接口、处理器以及存储器之间通过内部连接通路相连,处理器用于执行存储器中的代码,当代码被执行时,处理器用于执行上述各方面中的方法。
附图说明
图1为本申请实施例提供的传输场景示意图;
图2为本申请实施例提供的实施环境示意图;
图3为本申请实施例提供的传输报文的方法流程图;
图4为本申请实施例提供的第一网络设备的结构示意图;
图5为本申请实施例提供的第二网络设备的结构示意图;
图6为本申请实施例提供的时刻示意图;
图7为本申请实施例提供的网络架构示意图;
图8为本申请实施例提供的传输报文的方法流程图;
图9为本申请实施例提供的网络架构示意图;
图10为本申请实施例提供的传输报文的装置的结构示意图;
图11为本申请实施例提供的传输报文的装置的结构示意图;
图12为本申请实施例提供的传输报文的设备的结构示意图。
具体实施方式
本申请的实施方式部分使用的术语仅用于对本申请的具体实施例进行解释,而非旨在限定本申请。
在IP网络中,网络设备往往采用线速处理机制传输报文,线速是指网络设备所能吞吐的最大数据量。因此,在网络设备接收到的报文的总数据量超过网络设备所能吞吐的最大数据量时,网络设备仅能传输接收到的所有报文中的一部分报文,从而造成报文的挤压。
以图1所示的场景为例,上游网络设备同时接收到三个待传输的报文流,接收的各报文流中所包括的报文间隙均匀。由于上游网络设备采用线速处理机制,因而经过上游网络设备处理得到的报文流所包括的各报文之间相互挤压,报文间隙减小。因此,相比于上游网络设 备接收到的报文流,经过上游网络设备处理后的报文流的突发度(brust)增加,形成微突发。由于经过上游网络设备处理后的报文流会继续被传输至其他下游网络设备,因而上述形成微突发的过程不断重复。在经过某个下游网络设备的传输之后,累积的微突发形成大突发。具有大突发的报文流会进一步对网络中的其他报文流造成挤压,从而使得网络中各报文流的时延(delay)及抖动(jitter)增大至难以预测的数值,时延及抖动均具有较大的不确定性。
对此,需要消除报文传输过程中所产生的微突发,以使得报文经过多个网络设备的传输过程中,也就是报文在端与端之间的传输过程中,报文的时延及抖动始终能够维持在低于某一上限且能够预测的数值。其中,报文所具有的此种时延及抖动也称为确定性时延,能够使报文具有确定性时延的IP网络也称为确定性网络。目前,确定性网络是业界热点,工业互联网、智能工厂、可编程逻辑控制器(programmable logic controller,PLC)远程传输、云化、增强现实(augmented reality,AR)/虚拟现实(virtual reality,VR)实时交互、远程手术以及触觉互联网等业务均存在构建确定性网络的需求。因此,有必要提供一种能够消除微突发累积的传输报文的方法,从而保证报文具有确定性时延。
基于此,本申请实施例提供了一种传输报文的方法,该方法可应用于图2所示的网络架构中。示例性地,该网络架构包括但不限于较大规模的运营商网络、较小规模的园区网络以及其他类型的IP网络。图2中,包括顺次通信连接的第一终端节点、第一边缘节点、核心节点(core node)、第二边缘节点以及第二终端节点。示例性地,第一边缘节点及第二边缘节点为网关设备,核心节点为路由器。
在图2所示的网络架构中,第一终端节点与第一边缘节点构成一个边缘网络(edge network),第二终端节点与第二边缘节点构成另一个边缘网络,第一边缘节点、核心节点以及第二边缘节点构成一个核心网络(core network)。在第一终端节点以及第二终端节点之间进行端到端的报文传输时,响应于报文的传输方向为由第一终端节点至第二终端节点,则第一边缘节点为用于报文进入核心网络的入口边缘节点(ingress edge node),第二边缘节点为用于报文离开核心网络的出口边缘节点(egress edge node)。或者,响应于报文的传输方向为由第二终端节点至第一终端节点,则第二终端节点为入口边缘节点,第一终端节点为出口边缘节点。以报文的传输方向为由第一终端节点至第二终端节点为例,则第一终端节点发送的报文首先进入边缘网络,再经过第一边缘节点进入核心网络。之后,报文经过核心网络中各核心节点的转发,从第二边缘节点进入另一个边缘网络,从而到达第二终端节点。可见,第一终端节点、第一边缘节点、核心节点、第二边缘节点及第二终端节点形成了报文的传输路径。因此,本实施例中报文具有确定性时延是指:从第一终端节点传输至第二终端节点(或者从第二终端节点传输至第一终端节点)的过程中,报文在传输路径上的时延及抖动始终不大于可预测的、能够确定得到的上限。
另外,图2所示的网络架构需要满足如下条件:
条件一:报文的传输路径所包括的各节点中的每个端口,均为报文所在的报文流(Flow i)预留了带宽(Ri)。其中,端口预留的带宽是传输该报文流所需的带宽。
条件二:第一终端节点发送报文所在的报文流时,报文流的数据量满足如下的公式(1):
A i(t)=R i·t+B i   (1)
其中,A i为报文流在t时间内的总数据量,R i为报文流的平均速率,B i为报文流的最大突发度。
条件三:响应于第一终端节点发送的报文所在的报文流不满足上述公式,则第一边缘节点对报文流进行漏桶整形,经过漏桶整形的报文流满足上述公式,从而保证了进入核心网络的报文流均为满足上述公式的报文流。
基于图2所示的网络架构,本申请实施例提供了一种传输报文的方法,该方法可通过第一网络设备和第二网络设备的交互实现。如图3所示,该方法包括如下的过程301-308。
301,第一网络设备获取待传输的目标报文流中的第二报文,获取第二报文在第一网络设备上的第一停留时间。
在传输目标报文流中的第二报文的过程中,第一网络设备是用于对第二报文进行发送的设备,第一网络设备的下一跳为第二网络设备,第二网络设备是用于对第一网络设备发送的第二报文进行接收的设备。当然,第一网络设备及第二网络设备均为既具有报文发送功能又具有报文接收功能的设备,第一网络设备及第二网络设备可根据需要使用不同的功能。
示例性地,第一网络设备包括整形(shaper)器、队列***(queuing system)以及调度器(scheduler)。整形器用于在目标报文流的数据量不满足上述公式(1)的情况下,对目标报文流的数据量进行整形,以使得目标报文流的数据量满足上述公式(1)。在目标报文流的数据量满足上述公式(1)之后,目标报文流所包括的报文进入第一网络设备中的队列***,第一网络设备中的队列***用于第一网络设备中的各报文形成报文队列,各报文在报文队列中排队等待被调度器发送。第一网络设备的结构示意图可参见图4,图4中shaper表示整形器,Q表示队列***,S表示调度器。能够理解的是,第一网络设备中的各报文包括第二报文、目标报文流中除第二报文以外的其他报文以及除目标报文流以外的其他报文流中的报文。调度器用于按照报文队列中的顺序依次将报文发送给第二网络设备。
第二网络设备包括阻尼器(damper)、队列***以及调度器。第二网络设备的结构示意图可参见图5,图5中D表示阻尼器。需要说明的是,图5中D及Q之间的模块为交换网,图5中示出的D位于交换网之前的情况仅为示例,本实施例中D可位于Q之前的任一位置,例如D也可位于交换网之后。以第二报文为例,在第二网络设备接收到第一网络设备发送的第二报文后,阻尼器用于对接收到的第二报文进行参考时长的主动延迟,在参考时长之后再对第二报文进行释放,从而使得第二报文能够进入第二网络设备中的队列***,在队列***中等待被发送至第二网络设备下一跳的网络设备。其中,阻尼器确定参考时长的方式会在后文305中进行说明,此处先不进行赘述。
需要说明的是,上述说明中第一网络设备包括整形器、队列***以及调度器针对于第一网络设备上游不包含其他的网络设备的情况。在第一网络设备上游还包括其他的网络设备的情况下,第一网络设备具有与第二网络设备相同的结构。即:第一网络设备包括阻尼器、队列***以及调度器。
基于第一网络设备所具有的结构,第二报文在第一网络设备上的第一停留时间是指:第一时刻与第二时刻之间的时间差值。其中,若第一网络设备上游不包含其他网络设备,也就是第一网络设备的结构包括整形器、队列***及调度器,则第二报文在第一网络设备上的任一时刻均能够作为第一时刻。例如,第一时刻包括但不限于第一网络设备接收到第二报文的时刻、第二报文被第一网络设备的整形器释放的时刻、第二报文进入第一网络设备的队列***的时刻以及第二报文被第一网络设备发送的时刻等等。示例性地,参见图6,本实施例可采用第二报文进入第一网络设备中的队列***的时刻作为第一时刻。若第一网络设备包含其他 网络设备,也就是第一网络设备的结构包括阻尼器、队列***及调度器,则该第一时刻也可认为是第二报文经过第一网络设备的阻尼器的主动延迟之后被第一网络设备的阻尼器释放的时刻。另外,第二时刻是第二报文经过第一网络设备中的队列***的排队之后被第一网络设备发送的时刻。示例性地,第一网络设备在第二报文进入第一网络设备中的队列***时,为第二报文添加用于指示第一时刻的第一时间戳。在第二报文离开调度器时,为第二报文添加用于指示第二时刻的第二时间戳。因此,通过第一时间戳及第二时间戳便能够计算得到第二报文在第一网络设备上的第一停留时间。
接下来,对本申请实施例中涉及的时刻进行说明。能够理解的是,所说明的时刻包括上文中涉及的第一时刻和第二时刻,也包括后文中涉及的第三时刻和第四时刻。
对于路由器等网络设备而言,网络设备所能够识别和表达的时间精度是有限的。在示例性实施例中,按照量级从小到大的顺序对时间精度进行排列,则时间精度包括但不限于:阿秒(attosecond,as)、飞秒(femtosecond,fs)、皮秒(picosecond,ps)、纳秒(nanosecond,ns)、微秒(microsecond,μs)、毫秒(millisecond,ms)、秒(second,s)以及分钟(minute,min)等。当然,这些时间精度仅为举例,不用于对时间精度造成限定。时间精度根据实际需求进行设置。例如,时间精度还包括小于as的时间精度,或者大于min的时间精度等等。
示例性地,时刻的精度与路由器等网络设备能够识别和表达的时间精度是相同的。时刻的实际发生时间包括该时间精度内的任一个时间。例如,在网络设备能够识别和表达的时间精度为1ns的情况下,那么时刻的精度也为1ns。如果时刻1为1μs-1ns,则时刻1的实际发生时间包括1μs-1ns至1μs-2ns这一时间精度内的任一个时间,例如1μs-1.1ns、1μs-1.99ns等。
示例性地,时刻的精度包括设置得到的精度范围,时刻的实际发生时间包括该精度范围内的任一个时间。以精度范围为10μs为例,则时刻的精度也是10μs。例如,时刻1是13μs,则时刻1的实际发生时间包括13μs至23μs这一精度范围内的任一个时间,例如15μs、16μs或者18μs等。
示例性地,时刻设置得到的编号来表示。将时间按照参考粒度划分为多个时刻,每个时刻用一个编号来表示。例如,以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秒等。
302,第一网络设备获取目标报文流在第一网络设备上的第二停留时间。
其中,目标报文流在第一网络设备上的第二停留时间是指:目标报文流在第一网络设备上停留的阈值上限。在第一网络设备上游不包含其他网络设备的情况下,该阈值上限是由第一时刻到第二时刻的一个可能的最大值。在第一网络设备上游包含其他网络设备的情况下,该阈值上限是目标报文流能够在第一网络设备上停留的最大时间。在本实施例中,第一网络设备上的每条报文流均具有一个对应的第二停留时间,而不同报文流在第一网络设备上的第二停留时间相同或不同。
在示例性实施例中,第一网络设备获取待传输的第二报文之前,方法还包括:确定在第一网络设备上传输目标报文流的第二端口,获取该第二端口对应的第八停留时间。其中,该第八停留时间是基于第二其他报文流确定的时间,第二其他报文流是指第一网络设备获取目标报文流之前通过第二端口传输的报文流。基于该第八停留时间,确定目标报文流在第一网 络设备上的第二停留时间,存储目标报文流在第一网络设备上的第二停留时间。
其中,第一网络设备可能包括有多个传输端口,每个传输端口用于传输一个或多个报文流。用于在第一网络设备上传输目标报文流的第二端口即为多个传输端口中的一个传输端口,通过该第二端口可将目标报文流由第一网络设备传输至第二网络设备。示例性地,第二端口对应的第八停留时间由第一网络设备计算得到,或者由网络管理设备在控制面下发给第一网络设备。在前一种情况中,第一网络设备采用网络演算理论,根据第二其他报文流的相关参数计算第二端口对应的第八停留时间。第二其他报文流是第一网络设备获取目标报文流之前通过该第二端口传输的报文流,也就是在第一网络设备进行第八停留时间的计算时通过该第二端口传输的报文流。第二其他报文流的相关参数包括但不限于所有第二其他报文流的平均流速率以及各个第二其他报文流对应的突发度。
需要说明的是,由于第一网络设备在计算第二端口对应的第八停留时间的过程中将网络演算理论作为了依据,而网络演算理论指示通过第二端口的任一报文流均会影响该第二端口对应的第八停留时间。因此,通过第二端口的报文流数量增加,则第二端口对应的第八停留时间也增大。通过第二端口的报文流数量减小,则第二端口对应的第八停留时间也减小。在本实施例中,获取到目标报文流之前第二端口用于传输第二其他报文流,因而在第一网络设备获取到目标报文流之后,通过该第二端口的报文流数量增加。因此,需要对基于目标报文流对第二端口对应的第八停留时间进行更新,得到第九停留时间,且第九停留时间大于第八停留时间。其中,基于目标报文流对第二端口对应的第八停留时间进行更新,得到第九停留时间,包括:将目标报文流所能造成的时延与第八停留时间之和作为第九停留时间。相应地,基于该第八停留时间确定目标报文流在第一网络设备上的第二停留时间,包括:将对第八停留时间更新得到的第九停留时间作为第二停留时间。
在本实施例中,对于任一个网络设备上的任一个报文流,通过D i h表示该任一个报文流在该任一个网络设备上的第二停留时间。其中,下标i用于区分不同报文流,上标h用于区分不同网络设备。以目标报文流为第i个报文流、第一网络设备为第1个网络设备为例,则目标报文流在第一网络设备上的第二停留时间为D i 1
在第一网络设备获取到目标报文流在第一网络设备上的第二停留时间之后,第一网络设备对该第二停留时间进行存储,则第一网络设备获取到待传输的第二报文后通过读取即可获取该第二停留时间。示例性地,本实施例通过五元组对目标报文流进行标识,五元组包括源IP地址、源端口、目的IP地址、目的端口以及传输层协议,目标报文流中包括的所有报文均携带有目标报文流对应的五元组。在存储过程中,第一网络设备将第二停留时间与目标报文流对应的五元组进行对应存储。相应地,第一网络设备获取第二报文后,由于第二报文携带有目标报文流对应的五元组,因而可确认第二报文属于目标报文流,从而读取得到该五元组对应的第二停留时间。当然,本实施例中能够作为报文流标识的不仅限于上述五元组,根据经验或实际需要对标识方式进行选择即可。例如,本实施例还能够通过三元组对报文流进行标识。
需要说明的是,由于计算目标报文流在第一网络设备上的第二停留时间时需要应用到目标报文流所能造成的时延,因而只有在第一网络设备获取第二报文之前已经获取过目标报文流的情况下,才能在第一网络设备获取第二报文之前完成该第二停留时间的计算,从而使得第一网络设备在获取第二报文之后通过读取即可获取到第二停留时间。换言之,在第一网络 设备获取第二报文之前未获取过目标报文流的情况下,也就是第一网络设备在获取第二报文时才首次获取到目标报文流的情况下,则需要在获取到第二报文之后再进行第二停留时间的计算。无论何时进行第二停留时间的计算,计算方式均可参照上文说明。
另外,本实施例不对301及302的执行顺序加以限定,执行顺序包括但不限于先执行301再执行302、先执行302再执行301以及同时执行301及302。
303,第一网络设备封装第二报文、第二报文在第一网络设备上的第一停留时间以及目标报文流在第一网络设备上的第二停留时间,获得第一报文,向第二网络设备发送第一报文。
在封装过程中,本实施例可直接对第一停留时间、第二停留时间以及第二报文进行封装,从而得到第一报文。或者,还可以计算第二停留时间与第一停留时间的时间差值,再对计算得到的时间差值以及第二报文进行封装,从而得到第一报文。其中,该时间差值为第二报文在第二网络设备上的主动延迟时间,第二网络设备中的阻尼器用于按照该计算得到的时间差值对第二报文进行主动延迟。主动延迟的过程会在后文中进行说明,此处先不进行赘述。
304,第二网络设备接收第一网络设备发送的第一报文,根据第一报文获取目标报文流中的第二报文、第二报文在第一网络设备上的第一停留时间以及目标报文流在第一网络设备上的第二停留时间。
在第一网络设备直接对第一停留时间、第二停留时间以及第二报文进行封装的情况下,第二网络设备通过解析该第一报文,能够获得第一报文中所包括的第一停留时间、第二停留时间以及第二报文。在第一网络设备对第二停留时间与第一停留时间之间的时间差值以及第二报文进行封装的情况下,第二网络设备通过解析能够获得第二停留时间与第一停留时间之间的时间差值以及第二报文。
需要说明的是,本实施例中第一报文从第一网络设备传输至第二网络设备所需的传输时间可忽略不计。也就是说,可认为第二网络设备接收第一网络设备发送的第一报文的时刻与第一网络设备发送第一报文的第二时刻为同一时刻。另外,由于第二网络设备包括阻尼器、队列***以及调度器,因而第二网络设备接收到第一报文的时刻也可认为是第二网络设备根据第一报文获得第二报文之后,该第二报文进入第二网络设备的阻尼器的时刻。
305,第二网络设备确定目标报文流在第一网络设备上的第二停留时间与第二报文在第一网络设备上的第一停留时间之间的时间差值,该时间差值为第二报文在第二网络设备上的主动延迟时间。
其中,在第二网络设备解析获得了第一停留时间、第二停留时间以及第二报文的情况下,第二网络设备将第二停留时间与第一停留时间作差,从而得到该时间差值。在第二网络设备解析获得了第二停留时间与第一停留时间之间的时间差值以及第二报文的情况下,第二网络设备在解析过程中已获得该时间差值,因而无需再进行计算。能够理解的是,该时间差值的数值不小于零。
306,第二网络设备获取第二报文在第二网络设备上的第三停留时间,获取目标报文流在第二网络设备上的第四停留时间。
基于第二网络设备所具有的结构,在确定第二停留时间与第一停留时间之间的时间差值之后,第二网络设备中的阻尼器按照该时间差值对第二报文进行主动延迟。在主动延迟过程中,第二报文停留在第二网络设备的阻尼器内,而不进入第二网络设备中的队列***及调度器。在接收到第一报文的时长达到主动延迟时间之后,第二网络设备再通过阻尼器释放第二 报文,从而使得第二报文能够进入第二网络设备的队列***中。在第二报文进入第二网络设备的队列***之后,第二网络设备可进一步获取第三停留时间以及第四停留时间。
参见图6,第二报文在第二网络设备上的第三停留时间是指:第三时刻与第四时刻之间的时间差值。第三时刻是第二网络设备结束对第二报文的主动延迟的时刻,该第三时刻也即是第二报文经过第二网络设备的阻尼器的主动延迟之后被第二网络设备的阻尼器释放的时刻,或者说是第二报文进入第二网络设备的队列***的时刻。第四时刻是第二报文经过第二网络设备中的队列***的排队之后被第二网络设备发送的时刻,或者说是第二报文离开第二网络设备的调度器的时刻。可见,第三停留时间实际上是第二报文在第二网络设备中的队列***及调度器中停留的时间之和。第四停留时间是目标报文流在第二网络设备上停留的阈值上限,也就是目标报文流能够在第二网络设备上停留的最大时间。
第二网络设备获取第三停留时间的方式可参见301中的说明。在示例性实施例中,第二网络设备可根据第一网络设备发送的第一指令获取第四停留时间,参见如下的过程3061及3062。
3061,在第一网络设备获取待传输的第二报文之前,第一网络设备向其他网络设备发送第一指令。
其中,其他网络设备是指目标报文流的核心网络传输路径中除第一网络设备以外的网络设备。第一网络设备通过确定目标报文流的核心网络传输路径,即可确定出上述其他网络设备。在确定目标报文流的核心网络传输路径的过程中,第一网络设备可根据目标报文流对应的五元组确定目标报文流的目的IP地址。之后,按照目标报文流的目的IP地址查询存储的路由表,即可确定目标报文流的核心网络传输路径。
示例性地,第一网络设备确定核心网络传输路径之后,可向其他网络设备中的各个网络设备分别发送资源预留信令,则收到资源预留信令的各个网络设备分别为目标报文流预留相应的带宽,以便于后续能够正常对目标报文流进行传输。对于任一个收到资源预留信令的网络设备,若该任一个网络设备成功预留了带宽,则该任一个网络设备向第一网络设备反馈预留成功信令。在其他网络设备中所有网络设备均向第一网络设备反馈预留成功信令的情况下,第一网络设备便可确认上述核心网络传输路径能够用于目标报文流的传输,从而进一步向其他网络设备中的各个网络设备发送第一指令。相应地,在其他网络设备中仅有部分网络设备向第一网络设备反馈了预留成功信令的情况下,第一网络设备需要重新确定目标报文流的核心网络传输路径一次或多次,直至重新确定的核心网络传输路径上其他网络设备中所有网络设备均向第一网络设备反馈预留成功信令为止。之后,第一网络设备向重新确定的核心网络传输路径上其他网络设备中的各个网络设备发送第一指令。
能够理解的是,其他网络设备中可能包括位于第一网络设备上游的一个或多个网络设备以及位于第一网络设备下游的一个或多个网络设备。示例性地,第一网络设备向其他网络设备发送第一指令,包括:第一网络设备向其他网络设备中位于第一网络设备下游的一个或多个网络设备发送第一指令。由于本实施例提供的方法通过第一网络设备与第二网络设备的交互实现,因而该核心网络传输路径中至少包括第一网络设备及第二网络设备,此外还可能包括一个或多个用于作为核心节点的网络设备,则核心网络传输路径中除第一网络设备以外的其他网络设备中至少包括第二网络设备。
在本实施例中,第一网络设备发送的第一指令用于其他网络设备中的任一个网络设备获 取并存储目标报文流在任一个网络设备上的停留时间。在其他网络设备中除第二网络设备以外还包括一个或多个网络设备的情况下,各个网络设备在接收到第一指令之后均与第二网络设备执行相同的操作。因此,在3062中以第二网络设备为例对接收到第一指令的各网络设备基于第一指令所执行的操作进行说明。
3062,第二网络设备接收第一网络设备发送的第一指令,根据第一指令获取并存储目标报文流在第二网络设备上的第四停留时间。
在示例性实施例中,第二网络设备获取目标报文流在第二网络设备上的第四停留时间,包括:确定在第二网络设备上传输目标报文流的第一端口,获取第一端口对应的第五停留时间,第五停留时间为基于第一其他报文流确定的时间,第一其他报文流为第二网络设备获取目标报文流之前通过第一端口传输的报文流。基于目标报文流更新第五停留时间,得到第六停留时间,将第六停留时间作为目标报文流在第二网络设备上的第四停留时间。其中,第二网络设备在接收到第一指令之后,便可根据该实施例中的方法进行第四停留时间的获取。第二网络设备获取第四停留时间的过程可参见302中对第一网络设备获取第二停留时间的过程的说明,此处不再进行赘述。
在第二网络设备中,考虑到后续通过第一端口传输目标报文流的过程会影响到通过第一端口传输第一其他报文流的过程,从而导致第一其他报文流在传输过程中的时延增大。因此,在将第一端口对应的第五停留时间更新为第六停留时间之后,还需要基于该第六停留时间对第一其他报文流在第二网络设备上停留的阈值上限进行更新,以保证第一其他报文流在传输过程中也具有确定性时延。
示例性地,对于第一其他报文流中的任一个报文流,若该任一个报文流在第二网络设备上停留的阈值上限小于第一端口对应的第六停留时间,则将该任一个报文流在第二网络设备上停留的阈值上限更新为第六停留时间。若该任一个报文流在第二网络设备上停留的阈值上限不小于第六停留时间,则无需对该任一个报文流在第二网络设备上停留的阈值上限进行更新。
在第二网络设备基于第一指令获取到第四停留时间之后,第二网络设备对该第四停留时间进行存储,例如将该第四停留时间与目标报文流对应的五元组或三元组进行对应存储,以便于在需要时能够读取已存储的第四停留时间。另外,在其他网络设备中除第二网络设备以外还包括一个或多个网络设备的情况下,由于各个网络设备在接收到第一指令之后均与第二网络设备执行相同的操作,因而其他网络设备中的任一个网络设备均获取并存储目标报文流在该任一个网络设备上的停留时间,从而保证了对目标报文流的正常传输。
307,第二网络设备封装第二报文在第二网络设备上的第三停留时间、目标报文流在第二网络设备上的第四停留时间以及第二报文,获得第三报文。
在封装过程中,第二网络设备可对第三停留时间、第四停留时间以及第二报文直接进行封装,也可以先计算第四停留时间与第三停留时间之间的时间差值,再将第四停留时间与第三停留时间之间的时间差值以及第二报文进行封装,从而得到第三报文。
需要说明的是,上述说明中第二网络设备所执行的各操作均针对于第二网络设备不是目标报文流的核心网络传输路径上的最后一个网络设备的情况。在第二网络设备是目标报文流的核心网络传输路径上的最后一个网络设备的情况下,第二网络设备需要将第二报文发送至具有第二报文的目的IP地址的终端节点。由于该终端节点上往往不设置有阻尼器,因而第二 网络设备无需再获取第二报文在第二网络设备上的第三停留时间及第四停留时间,而是直接封装第二报文以及传输第二报文所需的其他信息即可。
308,第二网络设备接收到第一报文达到主动延迟时间并经过第二网络设备的队列***的排队之后,向目标报文流的核心网络传输路径上第二网络设备的下一跳网络设备发送第三报文。
其中,主动延迟时间是第二报文在第二网络设备的阻尼器中停留的时间,在第二网络设备接收到第一报文达到主动延迟时间之后,第二报文进入第二网络设备的队列***。之后,第二报文再经过第二网络设备的队列***的排队,便能够被第二网络设备所发送。第二报文在第二网络设备上停留的全部时间即为主动延迟时间与经过第二网络设备的队列***排队的时间之和,因此,第二网络设备接收到第一报文达到主动延迟时间并经过第二网络设备的队列***的排队之后,第二网络设备便能够发送第三报文。
在第二报文的传输过程中,目标报文流的核心网络传输路径上每一对相邻的网络设备均按照301-308中说明的方法进行交互,从而保证第二报文在每一对相邻的网络设备之间的时延均具有确定性,进而保证第二报文在两个终端节点之间具有确定性时延。参见图7,图7示出了目标报文流的核心网络传输路径上共包括h个网络设备的情况。按照上述301-308说明中的方法可确定核心网络传输路径上每一对相邻网络设备之间的时延D i 1、D i 2、D i 3、……、D i h-1。另外,将第二报文在核心网络传输路径上第一个网络设备的整形器中的最大停留时间D i 0,将第二报文在核心网络传输路径上最后一个网络设备的队列***及调度器中停留的时间记录为D i h,则第二报文在两个终端节点之间的时延上限可表示为如下的公式(2)。
D=D i 0+D i 1+D i 2+D i 3+……+D i h-1+D i h   (2)
能够理解的是,根据公式(2)所计算的时延上限中,忽略了第二报文从用于发送第二报文的终端节点传输至核心网络传输路径中首个网络设备的时间、第二报文在核心网络传输路径中每一对相邻的网络设备之间的传输时间以及第二报文从核心网络传输路径中最后一个网络设备传输至用于接收第二报文的终端节点的时间。
在实际应用中,D i 1、D i 2、D i 3、……、D i h-1均为已计算好的时间,因而只有D i 0以及D i h会影响到第二报文的时延,则第二报文在两个终端节点之间的抖动上限即为D i 0+D i h。可见,在两个终端节点之间对第二报文进行传输时,第二报文的时延低于上述时延上限D,第二报文的抖动低于上述抖动上限D i 0+D i h。因此,结合确定性时延的定义可知,通过上述301-308中说明的方法能够保证第二报文在两个终端节点之间的传输过程中具有确定性时延。
基于图2所示的网络架构,本申请实施例还提供了另外一种传输报文的方法,参见图8,该方法包括如下的过程801-809。
801,第一网络设备获取待传输的目标报文流中的第二报文,获取第二报文在第一网络设备上的第一停留时间。
802,第一网络设备获取目标报文流在第一网络设备上的第二停留时间。
其中,801可参见上文301中的说明,802可参见上文302中的说明,此处不再进行赘述。
803,第一网络设备封装第二报文、第二报文在第一网络设备上的第一停留时间、目标报文流在第一网络设备上的第二停留时间以及目标报文流在其他网络设备上的停留时间,获得第一报文,向第二网络设备发送第一报文。
其中,目标报文流在其他网络设备上的停留时间是目标报文流在其他网络设备上停留的阈值上限。根据3061中的说明可知,其他网络设备中可能包括位于第一网络设备上游的一个或多个网络设备,以及位于第一网络设备下游的一个或多个网络设备。示例性地,第一网络设备在进行封装时,仅对目标报文流在位于第一网络设备下游的一个或多个网络设备上的停留时间进行封装。其原因在于:位于第一网络设备下游的各网络设备在传输第二报文的过程中,无需使用目标报文流在位于第一网络设备上游的一个或多个网络设备上的停留时间。通过此种封装方式,能够降低传输过程中所需占用的带宽,避免对网络资源的浪费。
在第一网络设备获取待传输第二报文之前,还需要按照如下的过程8031-8033获取目标报文流在其他网络设备上的停留时间。
8031,第一网络设备向其他网络设备发送第二指令。
其中,第一网络设备通过发送第二指令与核心网络传输路径中的其他网络设备进行交互,以便于第一网络设备获取到目标报文流在其他网络设备上的停留时间。示例性地,第一网络设备向其他网络设备中位于第一网络设备下游的一个或多个网络设备发送该第二指令。接收到第二指令的各个网络设备均与第二网络设备执行相同的操作,因而在8032及8033中均以第二网络设备为例进行说明。
8032,第二网络设备接收第一网络设备发送的第二指令,根据第二指令获取目标报文流在第二网络设备上的第四停留时间,向第一网络设备发送第四停留时间。
其中,第二网络设备根据第二指令获取第四停留时间的过程可参见3062中第二网络设备根据第一指令获取第四停留时间的过程,此处不再加以赘述。需要说明的是,由于第二网络设备获取第四停留时间的过程需要应用到目标报文流能够造成的时延,因而在第二网络设备接收到第二指令时还未获取过目标报文流的情况下,第一网络设备可将目标报文流能够造成的时延携带于该第二指令中,以便于第二网络设备正常确定第四停留时间。在第二网络设备获取第四停留时间之后,便将该第四停留时间返回给第一网络设备。
8033,第一网络设备接收其他网络设备发送的目标报文流在其他网络设备上的停留时间。
由于接收到第二指令的各个网络设备均与第二网络设备执行相同的操作,因而第一网络设备能够接收到目标报文流在其他网络设备中任一个网络设备上的停留时间。示例性地,第一网络设备将目标报文流在其他网络设备上的停留时间与目标报文流对应的五元组或三元组进行对应存储,以便于在需要时进行读取。
在第一网络设备获取到目标报文流在其他网络设备上的停留时间之后,便可进一步封装得到第一报文。示例性地,第一网络设备可计算第二停留时间与第一停留时间之间的时间差值,再将该时间差值、目标报文流在其他网络设备上的停留时间以及第二报文进行封装,从而得到第一报文。通过上述801-803,第一网络设备能够存储目标报文流在核心网络传输路径上所有网络设备上的停留时间。因此,位于第一网络设备下游的任一个网络设备均无需自行存储目标报文流在该任一个网络设备上的停留时间,而是从目标报文流在其他网络设备上的停留时间中读取即可。
804,第二网络设备接收第一网络设备发送的第一报文。
相比于304中第一报文仅包括第一停留时间、第二停留时间以及第二报文,或者仅包括第二停留时间与第一停留时间之间的时间差值以及第二报文,804中第二网络设备接收的第一报文中还包括:目标报文流在上游的一个或多个网络设备上的一个或多个上游停留时间,一个 或多个上游停留时间与上游的一个或多个网络设备一一对应,任一个上游停留时间是目标报文流在上游的一个网络设备上停留的阈值上限。以及,目标报文流在下游的一个或多个网络设备上的一个或多个下游停留时间,一个或多个下游停留时间与下游的一个或多个网络设备一一对应,任一个下游停留时间是目标报文流在下游的一个网络设备上停留的阈值上限。
805,第二网络设备根据第一报文获取目标报文流中的第二报文、第二报文在第一网络设备上的第一停留时间、目标报文流在第一网络设备上的第二停留时间以及目标报文流在其他网络设备上的停留时间。
其中,第二网络设备通过解析第一报文即可获得获取目标报文流中的第二报文、第二报文在第一网络设备上的第一停留时间、目标报文流在第一网络设备上的第二停留时间以及目标报文流在其他网络设备上的停留时间。
806,第二网络设备确定目标报文流在第一网络设备上的第二停留时间与第二报文在第一网络设备上的第一停留时间之间的时间差值,该时间差值为第二报文在第二网络设备上的主动延迟时间。
第二网络设备确定时间差值的过程可参见305中的说明,此处不再进行赘述。
807,第二网络设备获取第二报文在第二网络设备上的第三停留时间,获取目标报文流在第二网络设备上的第四停留时间。
第二网络设备获取第三停留时间的过程可参见306中的说明,第二网络设备从第一报文中目标报文流在其他网络设备上的停留时间中即可读取得到目标报文流在第二网络设备上的第四停留时间。需要说明的是,在807中获取到目标报文流在第二网络设备上的第四停留时间后,无需按照306中说明的对第一其他报文流在第二网络设备上停留的阈值上限进行更新。其原因在于,第一其他报文流在第二网络设备上的停留时间也已存储于第一网络设备中,第二网络设备无需自行存储第一其他报文流在第二网络设备上的停留时间。因此,即使需要更新第一其他报文流在第二网络设备上停留的阈值上限,该更新过程也由第一网络设备来执行。在第一网络设备执行更新过程之后,会将更新得到的阈值上限存储于第一其他报文流所包括的各个报文中,第二网络设备通过从报文中读取即可获取更新得到的阈值上限。
808,第二网络设备封装第二报文、第二报文在第二网络设备上的第三停留时间以及目标报文流在第一网络设备下游的一个或多个网络设备上的下游停留时间,获得第三报文。
第二网络设备封装得到第三报文以及发送第三报文的过程可参见307中的说明。需要说明的是,在下一跳网络设备转发第二报文的过程中,需要与第二报文一同封装的停留时间同样包括目标报文流在第一网络设备下游的一个或多个网络设备上的下游停留时间。示例性地,在下一跳网络设备的封装过程中,可以首先从目标报文流在第一网络设备下游的一个或多个网络设备上的下游停留时间中删除目标报文流在第二网络设备上的第四停留时间,从而得到目标报文流在第二网络设备下游的一个或多个网络设备上的下游停留时间。之后,再封装目标报文流在第二网络设备下游的一个或多个网络设备上的下游停留时间、第二报文以及所需的其他停留时间。
809,第二网络设备接收到第一报文达到主动延迟时间并经过第二网络设备的队列***的排队之后,向目标报文流的核心网络传输路径上第二网络设备的下一跳网络设备发送第三报文。
第二网络设备发送第三报文的过程可参见308中的说明,此处不再加以赘述。
在示例性实施例中,无论第一网络设备及第二网络设备是通过上述301-308还是801-809进行交互,在第一网络设备向第二网络设备发送第一报文之后,方法还包括如下的过程A1-A3。
A1,第一网络设备停止获取目标报文流,向其他网络设备发送第三指令,第三指令用于向其他网络设备通知第一信息,第一信息为第一网络设备停止获取目标报文流。
在第一网络设备停止获取目标报文流,也就是目标报文流已离开核心网络的情况下,需要基于网络演算理论更新目标报文流的核心网络传输路径中各个网络设备上用于传输目标报文流的传输端口对应的停留时间。能够理解的是,第一网络设备除了发送第三指令以外,也需要对第一网络设备本地的用于传输该目标报文流的第二端口对应的第九停留时间进行更新。
A2,第二网络设备接收第一网络设备发送的第三指令,第三指令用于向所述第二网络设备通知第一信息,所述第一信息为所述第一网络设备停止获取所述目标报文流。
由于第一网络设备进行了第三指令的发送,因而目标报文流的核心网络传输路径上的任一个网络设备均能够接收到第三指令。在A3中,以第二网络设备为例,对任一个网络设备上用于传输目标报文流的传输端口对应的停留时间的更新过程进行说明。
A3,第二网络设备根据第三指令更新第六停留时间,得到第七停留时间。
其中,第二网络设备上用于传输目标报文流的传输端口是第一端口,在传输目标报文流的过程中,该第一端口对应的停留时间即为第六停留时间。示例性地,更新第六停留时间,得到第七停留时间,包括:将第六停留时间与目标报文流所能造成的时延之差作为该第七停留时间。在得到第七停留时间之后,第二网络设备还对第七停留时间进行存储,以便于第一网络设备获取到新的报文流之后,能够根据存储的第七停留时间计算该新的报文流在第二网络设备上的第四停留时间。
参见图9,图9示出了一种用于传输报文的核心网络架构。为便于描述,将图9示出的各网络设备编号为1、2、……、h,对上述301-308及801-809所提供的传输报文的方法分别进行说明。
根据301-308所提供的传输报文的方法,任一个网络设备上仅存储有报文所在的报文流在该任一个网络设备上停留的阈值上限。例如,网络设备1上仅存储有报文流在网络设备1上停留的阈值上限。则传输报文的过程包括如下的B1-B10。
B1,网络设备1-(h-1)均存储本地各传输端口对应的停留时间。
B2,网络设备1从用于发送报文1的终端节点接收到报文1之后,对报文1进行整流,使得报文的数据量满足公式(1)的要求。
B3,网络设备1向网络设备2-h发送资源预留信令。
B4,对于2-h中的任一网络设备,该任一网络设备根据资源预留信令成功为报文1预留带宽之后,根据本地存储的各传输端口对应的停留时间确定报文1在该任一网络设备上的停留时间并存储。
B5,网络设备1从本地读取报文1在本跳停留的阈值上限D i 1,统计得到报文1在本跳的队列***及调度器中停留的时间D 1,封装D 1、D i 1及报文1得到报文2,将报文2发送给网络设备2。
B6,网络设备2接收报文2,根据报文2中的D 1及D i 1计算报文1在本跳上的主动延迟时间d 1=D i 1-D 1,在主动延迟时间d 1之后将报文1从阻尼器中释放。
B7,网络设备2读取本地存储的报文1在本跳停留的阈值上限D i 2,统计得到报文1在本跳的队列***及调度器中停留的时间D 2,封装D 2、D i 2及报文1得到报文3,将报文3发送给网络设备3。
B8,网络设备3-(h-1)中的任一个网络设备H(3≤H≤(h-1)),接收上一跳网络设备(H-1)发送的报文H,报文H中包含报文1在上一跳网络设备上停留的阈值上限D i (H-1)、报文1在上一跳网络设备的队列***及调度器中停留的时间D (H-1)以及报文1。网络设备H计算报文1在本跳的主动延迟时间d (H-1)=D i (H-1)-D (H-1),在主动延迟时间d (H-1)之后将报文1从阻尼器中释放。
B9,网络设备H读取本地存储的报文1在本跳停留的阈值上限D i H,统计得到报文1在本跳的队列***及调度器中停留的时间D H,封装D H、D i H及报文1得到报文(H+1),将报文(H+1)发送给网络设备(H+1)。
B10,网络设备h,封装报文1,将封装后的报文1发送给用于接收报文1的终端节点。
根据801-809所提供的传输报文的方法,网络设备1上存储有报文所在的报文流在网络设备2-h中所有网络设备上停留的阈值上限,则传输报文的过程包括如下的C1-C11。
C1,网络设备1-(h-1)均存储本地各传输端口对应的停留时间。
C2,网络设备1从用于发送报文1的终端节点接收到报文1之后,对报文1进行整流,使得报文1的数据量满足公式(1)的要求。
C3,网络设备1向网络设备2-h发送资源预留信令。
C4,对于2-h中的任一网络设备,该任一网络设备根据资源预留信令成功为报文预留带宽之后,根据本地存储的各传输端口对应的停留时间确定报文1在该任一网络设备上停留的阈值上限并返回给网络设备1。
C5,网络设备1接收网络设备2返回的报文1在网络设备2上停留的阈值上限D i 2、……、网络设备h返回的报文1在网络设备h上停留的阈值上限D i h,得到报文1在核心网络传输路径上的各个网络设备上的停留时间,并存储为列表。该列表中包括:D i 1、D i 2、D i 3、……、D i h-1、D i h
C6,网络设备1将报文1、报文1在本跳的队列***及调度器中停留的时间D 1以及C5中得到的列表进行封装,得到报文2,将报文2发送给网络设备2。
C7,网络设备2接收报文2,从报文2中读取D 1,从报文2的列表中读取D i 1,根据读取的D 1及D i 1计算报文1在本跳上的主动延迟时间d 1=D i 1-D 1,在主动延迟时间d 1之后将报文1从阻尼器中释放。
C8,网络设备2统计得到报文1在本跳的队列***及调度器中停留的时间D 2,从列表中删除D i 1,将报文1、D 2以及删除了D i 1之后的列表封装为报文3发送给网络设备3。
C9,网络设备3-(h-1)中的任一个网络设备H(3≤H≤(h-1)),接收上一跳网络设备(H-1)发送的报文H,从报文H中读取D (H-1),从报文H的列表中读取D i (H-1),根据读取的D (H-1)及D i (H-1)计算报文1在本跳上的主动延迟时间d (H-1),在主动延迟时间d (H-1)之后将报文1从阻尼器中释放。
C10,网络设备H统计得到报文1在本跳的队列***及调度器中停留的时间D H,从列表中删除D i (H-1),将报文1、D 2以及删除了D i (H-1)之后的列表封装为报文(H+1)发送给网络设 备(H+1)。
C11,网络设备h,封装报文1,将封装后的报文1发送给用于接收报文1的终端节点。
综上所述,本申请中各个网络设备通过对待传输的第二报文进行主动延迟的方式,保证了待传输的报文在相邻的一对网络设备之间具有确定性时延,进而保证了待传输的第二报文在两端之间具有确定性时延。并且,各个网络设备进行主动延迟的时间是基于第二报文所在的目标报文流得到的,从而避免了不同报文流之间的相互干扰。因此,本申请实施例所提供的方法不仅实现较为简单,而且适用于各种规模的IP网络。可见,该方法较为实用、传输效果较好。
如图10所示,本申请实施例还提供了一种传输报文的装置,该装置应用于第二网络设备,以执行上述图3及图8所示的传输报文的方法。该装置包括:
接收模块1001,用于第二网络设备接收第一网络设备发送的第一报文;
获取模块1002,用于第二网络设备根据第一报文获取目标报文流中的第二报文、第二报文在第一网络设备上的第一停留时间以及目标报文流在第一网络设备上的第二停留时间,第一停留时间为第一时刻与第二时刻之间的时间差值,第一时刻是第二报文进入第一网络设备的队列***的时刻,第二时刻是第二报文经过第一网络设备的队列***的排队之后被第一网络设备发送的时刻,第二停留时间是目标报文流在第一网络设备上停留的阈值上限;
确定模块1003,用于第二网络设备确定目标报文流在第一网络设备上的第二停留时间与第二报文在第一网络设备上的第一停留时间之间的时间差值,时间差值为第二报文在第二网络设备上的主动延迟时间;
获取模块1002,还用于获取第二报文在第二网络设备上的第三停留时间,获取目标报文流在第二网络设备上的第四停留时间,第三停留时间为第三时刻与第四时刻之间的时间差值,第三时刻是第二网络设备结束对第二报文的主动延迟的时刻,第四时刻是第二报文经过第二网络设备的队列***的排队之后被第二网络设备发送的时刻,第四停留时间是目标报文流在第二网络设备上停留的阈值上限;
封装模块1004,用于封装第二报文在第二网络设备上的第三停留时间、目标报文流在第二网络设备上的第四停留时间以及第二报文,获得第三报文;
发送模块1005,用于第二网络设备接收到第一报文达到主动延迟时间并经过第二网络设备的队列***的排队之后,向目标报文流的核心网络传输路径上第二网络设备的下一跳网络设备发送第三报文。
在一种可能的实现方式中,目标报文流的核心网络传输路径中包含位于第一网络设备上游的一个或多个网络设备以及位于第一网络设备下游的一个或多个网络设备,第一报文还包括目标报文流在上游的一个或多个网络设备上的一个或多个上游停留时间,一个或多个上游停留时间与上游的一个或多个网络设备一一对应,任一个上游停留时间是目标报文流在上游的一个网络设备上停留的阈值上限,第一报文还包括目标报文流在下游的一个或多个网络设备上的一个或多个下游停留时间,一个或多个下游停留时间与下游的一个或多个网络设备一一对应,任一个下游停留时间是目标报文流在下游的一个网络设备上停留的阈值上限;
封装模块1004,用于封装第二报文、第二报文在第二网络设备上的第三停留时间以及目标报文流在第一网络设备下游的一个或多个网络设备上的下游停留时间,获得第三报文。
在一种可能的实现方式中,接收模块1001,还用于接收第一网络设备发送的第一指令;
获取模块1002,还用于根据第一指令确定在第二网络设备上传输目标报文流的第一端口;获取第一端口对应的第五停留时间,第五停留时间为基于第一其他报文流确定的时间,第一其他报文流为第二网络设备获取目标报文流之前通过第一端口传输的报文流;基于目标报文流更新第五停留时间,得到第六停留时间;将第六停留时间作为目标报文流在第二网络设备上的第四停留时间。
在一种可能的实现方式中,接收模块1001,还用于接收第一网络设备发送的第三指令,第三指令用于向第二网络设备通知第一信息,第一信息为第一网络设备停止获取目标报文流;
获取模块1002,还用于根据第三指令更新第六停留时间,得到第七停留时间。
在一种可能的实现方式中,接收模块1001,还用于接收第一网络设备发送的第三指令,第三指令用于向第二网络设备通知第一信息,第一信息为第一网络设备停止获取目标报文流;
获取模块1002,还用于根据第三指令更新第六停留时间,得到第七停留时间。
参见图11,本申请实施例还提供了一种传输报文的装置,该装置应用于第一网络设备,以执行上述图3及图8所示的传输报文的方法。该装置包括:
获取模块1101,用于第一网络设备获取待传输的目标报文流中的第二报文,获取第二报文在第一网络设备上的第一停留时间,第一停留时间为第一时刻与第二时刻之间的时间差值,第一时刻是第二报文进入第一网络设备的队列***的时刻,第二时刻是第二报文经过第一网络设备的队列***的排队之后被第一网络设备发送的时刻;获取目标报文流在第一网络设备上的第二停留时间,第二停留时间是目标报文流在第一网络设备上停留的阈值上限;
封装模块1102,用于封装第二报文、第二报文在第一网络设备上的第一停留时间以及目标报文流在第一网络设备上的第二停留时间,获得第一报文;
发送模块1103,用于向第二网络设备发送第一报文。
在一种可能的实现方式中,目标报文流的核心网络传输路径中包含除第一网络设备以外的其他网络设备,封装模块1102,用于封装第二报文、第二报文在第一网络设备上的第一停留时间、目标报文流在第一网络设备上的第二停留时间以及目标报文流在其他网络设备上的停留时间,获得第一报文,目标报文流在其他网络设备上的停留时间为目标报文流在其他网络设备上停留的阈值上限。
在一种可能的实现方式中,装置还包括:确定模块,确定模块用于确定在第一网络设备上传输目标报文流的第二端口;获取第二端口对应的第八停留时间,第八停留时间为基于第二其他报文流确定的时间,第二其他报文流为第一网络设备获取目标报文流之前通过第二端口传输的报文流;基于第八停留时间,确定目标报文流在第一网络设备上的第二停留时间;存储目标报文流在第一网络设备上的第二停留时间。
在一种可能的实现方式中,发送模块1103,还用于向其他网络设备发送第一指令,第一指令用于其他网络设备的任一个网络设备获取并存储目标报文流在任一个网络设备上的停留时间。
在一种可能的实现方式中,发送模块1103,还用于向其他网络设备发送第二指令;
装置还包括:接收模块,用于接收其他网络设备发送的目标报文流在其他网络设备上的停留时间,目标报文流在其他网络设备上的停留时间为其他网络设备基于第二指令发送。
在一种可能的实现方式中,发送模块1103,还用于停止获取目标报文流,向其他网络设备发送第三指令,第三指令用于向其他网络设备通知第一信息,第一信息为第一网络设备停止获取目标报文流。
综上所述,本申请中各个网络设备通过对待传输的报文进行主动延迟的方式,保证了待传输的报文在相邻的一对网络设备之间具有确定性时延,进而保证了待传输的报文在两端之间具有确定性时延。并且,各个网络设备进行主动延迟的时间是基于待传输报文所在的报文流得到的,从而避免了不同报文流之间的相互干扰。因此,本申请实施例所提供的方法不仅实现较为简单,而且适用于各种规模的IP网络。可见,该方法较为实用、传输效果较好。
应理解的是,上述图10或图11提供的装置在实现其功能时,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将设备的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。另外,上述实施例提供的装置与方法实施例属于同一构思,其具体实现过程详见方法实施例,这里不再赘述。
本申请实施例提供了一种网络设备,网络设备包括存储器及处理器;存储器中存储有至少一条指令,至少一条指令由处理器加载并执行,以实现本申请中第一网络设备所需执行的方法。
本申请实施例提供了一种网络设备,网络设备包括存储器及处理器;存储器中存储有至少一条指令,至少一条指令由处理器加载并执行,以实现本申请中第二网络设备所需执行的方法。
参见图12,本申请实施例还提供一种传输报文的设备1200,图12所示的传输报文的设备1200用于执行上传输报文的方法所涉及的操作。该传输报文的设备1200包括:存储器1201、处理器1202及接口1203,存储器1201、处理器1202及接口1203之间通过总线1204连接。
其中,存储器1201中存储有至少一条指令,至少一条指令由处理器1202加载并执行,以实现上述任一所述的传输报文的方法。
接口1203用于与网络中的其他设备进行通信,该接口1203可以通过无线或有线的方式实现,示例性地,该接口1203可以是网卡。例如,隧道配置设备1200可通过该接口1203与服务器进行通信。
应理解的是,图12仅仅示出了传输报文的设备1200的简化设计。在实际应用中,隧道配置设备可以包含任意数量的接口,处理器或者存储器。此外,上述处理器可以是中央处理器(Central Processing Unit,CPU),还可以是其他通用处理器、数字信号处理器(digital signal processing,DSP)、专用集成电路(application specific integrated circuit,ASIC)、现场可编程门阵列(field-programmable gate array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者是任何常规的处理器等。值得说明的是,处理器可以是支持进阶精简指令集机器(advanced RISC machines,ARM)架构的处理器。
进一步地,在一种可选的实施例中,上述存储器可以包括只读存储器和随机存取存储器,并向处理器提供指令和数据。存储器还可以包括非易失性随机存取存储器。例如,存储器还 可以存储设备类型的信息。
本申请实施例提供了一种通信装置,该装置包括:收发器、存储器和处理器。其中,该收发器、该存储器和该处理器通过内部连接通路互相通信,该存储器用于存储指令,该处理器用于执行该存储器存储的指令,以控制收发器接收信号,并控制收发器发送信号,并且当该处理器执行该存储器存储的指令时,使得该处理器执行本申请中第一网络设备所需执行的方法。
本申请实施例提供了一种通信装置,该装置包括:收发器、存储器和处理器。其中,该收发器、该存储器和该处理器通过内部连接通路互相通信,该存储器用于存储指令,该处理器用于执行该存储器存储的指令,以控制收发器接收信号,并控制收发器发送信号,并且当该处理器执行该存储器存储的指令时,使得该处理器执行本申请中第一网络设备所需执行的方法。
可选地,处理器为一个或多个,存储器为一个或多个。
可选地,存储器可以与处理器集成在一起,或者存储器与处理器分离设置。
在具体实现过程中,存储器可以为非瞬时性(non-transitory)存储器,例如只读存储器(read only memory,ROM),其可以与处理器集成在同一块芯片上,也可以分别设置在不同的芯片上,本申请实施例对存储器的类型以及存储器与处理器的设置方式不做限定。
提供了一种传输报文的***,***包括第一网络设备及第二网络设备,该第一网络设备及第二网络设备通信连接。其中,第一网络设备及第二设备传输报文的方法可参见上述图2-图4所示实施例的相关描述,此处不再赘述。
本申请实施例提供了一种计算机程序(产品),计算机程序(产品)包括:计算机程序代码,当计算机程序代码被计算机运行时,使得计算机执行上述本申请的任一种示例性实施例所提供的方法。
本申请实施例提供了一种可读存储介质,可读存储介质存储程序或指令,当程序或指令在计算机上运行时,本申请的任一种示例性实施例所提供的方法被执行。
本申请实施例提供了一种芯片,包括处理器,用于从存储器中调用并运行存储器中存储的指令,使得安装有芯片的通信设备执行本申请的任一种示例性实施例所提供的方法。
本申请实施例提供了一种芯片,包括:输入接口、输出接口、处理器和存储器,输入接口、输出接口、处理器以及存储器之间通过内部连接通路相连,处理器用于执行存储器中的代码,当代码被执行时,处理器用于执行本申请的任一种示例性实施例所提供的方法。
应理解的是,上述处理器可以是中央处理器(Central Processing Unit,CPU),还可以是其他通用处理器、数字信号处理器(digital signal processing,DSP)、专用集成电路(application specific integrated circuit,ASIC)、现场可编程门阵列(field-programmable gate array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者是任何常规的处理器等。值得说明的是,处理器可以是支持进阶精简指令集机器(advanced RISC machines,ARM)架构的处理器。
进一步地,在一种可选的实施例中,上述存储器可以包括只读存储器和随机存取存储器,并向处理器提供指令和数据。存储器还可以包括非易失性随机存取存储器。例如,存储器还 可以存储设备类型的信息。
该存储器可以是易失性存储器或非易失性存储器,或可包括易失性和非易失性存储器两者。其中,非易失性存储器可以是只读存储器(read-only memory,ROM)、可编程只读存储器(programmable ROM,PROM)、可擦除可编程只读存储器(erasable PROM,EPROM)、电可擦除可编程只读存储器(electrically EPROM,EEPROM)或闪存。易失性存储器可以是随机存取存储器(random access memory,RAM),其用作外部高速缓存。通过示例性但不是限制性说明,许多形式的RAM可用。例如,静态随机存取存储器(static RAM,SRAM)、动态随机存取存储器(dynamic random access memory,DRAM)、同步动态随机存取存储器(synchronous DRAM,SDRAM)、双倍数据速率同步动态随机存取存储器(double data date SDRAM,DDR SDRAM)、增强型同步动态随机存取存储器(enhanced SDRAM,ESDRAM)、同步连接动态随机存取存储器(synchlink DRAM,SLDRAM)和直接内存总线随机存取存储器(direct rambus RAM,DR RAM)。
本申请提供了一种计算机程序,当计算机程序被计算机执行时,可以使得处理器或计算机执行上述方法实施例中对应的各个步骤和/或流程。
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行计算机程序指令时,全部或部分地产生按照本申请的流程或功能。计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线)或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心进行传输。计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包含一个或多个可用介质集成的服务器、数据中心等数据存储设备。可用介质可以是磁性介质,(例如,软盘、硬盘、磁带)、光介质(例如光盘)、或者半导体介质(例如固态硬盘(SSD))等。

Claims (24)

  1. 一种传输报文的方法,其特征在于,所述方法包括:
    第二网络设备接收第一网络设备发送的第一报文;
    所述第二网络设备根据所述第一报文获取目标报文流中的第二报文、所述第二报文在所述第一网络设备上的第一停留时间以及所述目标报文流在所述第一网络设备上的第二停留时间,所述第一停留时间为第一时刻与第二时刻之间的时间差值,所述第一时刻是所述第二报文进入所述第一网络设备的队列***的时刻,所述第二时刻是所述第二报文经过所述第一网络设备的队列***的排队之后被所述第一网络设备发送的时刻,所述第二停留时间是所述目标报文流在所述第一网络设备上停留的阈值上限;
    所述第二网络设备确定所述目标报文流在所述第一网络设备上的第二停留时间与所述第二报文在所述第一网络设备上的第一停留时间之间的时间差值,所述时间差值为所述第二报文在所述第二网络设备上的主动延迟时间;
    获取所述第二报文在所述第二网络设备上的第三停留时间,获取所述目标报文流在所述第二网络设备上的第四停留时间,所述第三停留时间为第三时刻与第四时刻之间的时间差值,所述第三时刻是所述第二网络设备结束对第二报文的主动延迟的时刻,所述第四时刻是所述第二报文经过所述第二网络设备的队列***的排队之后被所述第二网络设备发送的时刻,所述第四停留时间是所述目标报文流在所述第二网络设备上停留的阈值上限;
    封装所述第二报文在所述第二网络设备上的第三停留时间、所述目标报文流在第二网络设备上的第四停留时间以及所述第二报文,获得第三报文;
    所述第二网络设备接收到所述第一报文达到所述主动延迟时间并经过所述第二网络设备的队列***的排队之后,向所述目标报文流的核心网络传输路径上所述第二网络设备的下一跳网络设备发送所述第三报文。
  2. 根据权利要求1所述的方法,其特征在于,所述目标报文流的核心网络传输路径中包含位于所述第一网络设备上游的一个或多个网络设备以及位于所述第一网络设备下游的一个或多个网络设备,所述第一报文还包括所述目标报文流在所述上游的一个或多个网络设备上的一个或多个上游停留时间,所述一个或多个上游停留时间与所述上游的一个或多个网络设备一一对应,任一个上游停留时间是所述目标报文流在上游的一个网络设备上停留的阈值上限,所述第一报文还包括所述目标报文流在所述下游的一个或多个网络设备上的一个或多个下游停留时间,所述一个或多个下游停留时间与所述下游的一个或多个网络设备一一对应,任一个下游停留时间是所述目标报文流在下游的一个网络设备上停留的阈值上限;
    所述封装所述第二报文在所述第二网络设备上的第三停留时间、所述目标报文流在第二网络设备上的第四停留时间以及所述第二报文,获得第三报文,包括:
    封装所述第二报文、所述第二报文在第二网络设备上的第三停留时间以及所述目标报文流在所述第一网络设备下游的一个或多个网络设备上的下游停留时间,获得所述第三报文。
  3. 根据权利要求1或2所述的方法,其特征在于,在所述第二网络设备接收第一网络设备发送的第一报文之前,所述方法还包括:
    接收所述第一网络设备发送的第一指令;
    根据所述第一指令确定在所述第二网络设备上传输所述目标报文流的第一端口;
    获取所述第一端口对应的第五停留时间,所述第五停留时间为基于第一其他报文流确定的时间,所述第一其他报文流为所述第二网络设备获取所述目标报文流之前通过所述第一端口传输的报文流;
    基于所述目标报文流更新所述第五停留时间,得到第六停留时间;
    将所述第六停留时间作为所述目标报文流在所述第二网络设备上的第四停留时间。
  4. 根据权利要求1-3中任一项所述的方法,其特征在于,在所述第二网络设备接收第一网络设备发送的第一报文之前,所述方法还包括:
    接收所述第一网络设备发送的第二指令;
    根据所述第二指令,获取所述目标报文流在所述第二网络设备上的所述第四停留时间;
    向所述第一网络设备发送所述第四停留时间。
  5. 根据权利要求3或4所述的方法,其特征在于,所述向所述目标报文流的核心网络传输路径上所述第二网络设备的下一跳网络设备发送所述第三报文之后,所述方法还包括:
    接收所述第一网络设备发送的第三指令,所述第三指令用于向所述第二网络设备通知第一信息,所述第一信息为所述第一网络设备停止获取所述目标报文流;
    根据所述第三指令更新所述第六停留时间,得到第七停留时间。
  6. 一种传输报文的方法,其特征在于,所述方法包括:
    第一网络设备获取待传输的目标报文流中的第二报文,获取所述第二报文在所述第一网络设备上的第一停留时间,所述第一停留时间为第一时刻与第二时刻之间的时间差值,所述第一时刻是所述第二报文进入所述第一网络设备的队列***的时刻,所述第二时刻是所述第二报文经过所述第一网络设备的队列***的排队之后被所述第一网络设备发送的时刻;
    获取所述目标报文流在所述第一网络设备上的第二停留时间,所述第二停留时间是所述目标报文流在所述第一网络设备上停留的阈值上限;
    封装所述第二报文、所述第二报文在所述第一网络设备上的第一停留时间以及所述目标报文流在所述第一网络设备上的第二停留时间,获得第一报文;
    向第二网络设备发送所述第一报文。
  7. 根据权利要求6所述的方法,其特征在于,所述目标报文流的核心网络传输路径中包含除所述第一网络设备以外的其他网络设备,所述封装所述第二报文、所述第二报文在所述第一网络设备上的第一停留时间以及所述目标报文流在所述第一网络设备上的第二停留时间,获得第一报文,包括:
    封装所述第二报文、所述第二报文在所述第一网络设备上的第一停留时间、所述目标报文流在所述第一网络设备上的第二停留时间以及所述目标报文流在所述其他网络设备上的停留时间,获得所述第一报文,所述目标报文流在所述其他网络设备上的停留时间为所述目标报文流在所述其他网络设备上停留的阈值上限。
  8. 根据权利要求6或7所述的方法,其特征在于,所述第一网络设备获取待传输的目标报文流中的第二报文之前,所述方法还包括:
    确定在所述第一网络设备上传输所述目标报文流的第二端口;
    获取所述第二端口对应的第八停留时间,所述第八停留时间为基于第二其他报文流确定的时间,所述第二其他报文流为所述第一网络设备获取所述目标报文流之前通过所述第二端口传输的报文流;
    基于所述第八停留时间,确定所述目标报文流在所述第一网络设备上的第二停留时间;
    存储所述目标报文流在所述第一网络设备上的第二停留时间。
  9. 根据权利要求7或8所述的方法,其特征在于,所述第一网络设备获取待传输的目标报文流中的第二报文之前,所述方法还包括:
    向所述其他网络设备发送第一指令,所述第一指令用于所述其他网络设备的任一个网络设备获取并存储所述目标报文流在所述任一个网络设备上的停留时间。
  10. 根据权利要求7-9中任一项所述的方法,其特征在于,所述第一网络设备获取待传输的目标报文流中的第二报文之前,所述方法还包括:
    向所述其他网络设备发送第二指令;
    接收所述其他网络设备发送的所述目标报文流在所述其他网络设备上的停留时间,所述目标报文流在所述其他网络设备上的停留时间为所述其他网络设备基于所述第二指令发送。
  11. 根据权利要求7-9中任一项所述的方法,其特征在于,所述向第二网络设备发送所述第一报文之后,所述方法还包括:
    停止获取所述目标报文流,向所述其他网络设备发送第三指令,所述第三指令用于向所述其他网络设备通知第一信息,所述第一信息为所述第一网络设备停止获取所述目标报文流。
  12. 一种传输报文的装置,其特征在于,所述装置包括:
    接收模块,用于第二网络设备接收第一网络设备发送的第一报文;
    获取模块,用于所述第二网络设备根据所述第一报文获取目标报文流中的第二报文、所述第二报文在所述第一网络设备上的第一停留时间以及所述目标报文流在所述第一网络设备上的第二停留时间,所述第一停留时间为第一时刻与第二时刻之间的时间差值,所述第一时刻是所述第二报文进入所述第一网络设备的队列***的时刻,所述第二时刻是所述第二报文经过所述第一网络设备的队列***的排队之后被所述第一网络设备发送的时刻,所述第二停留时间是所述目标报文流在所述第一网络设备上停留的阈值上限;
    确定模块,用于所述第二网络设备确定所述目标报文流在所述第一网络设备上的第二停留时间与所述第二报文在所述第一网络设备上的第一停留时间之间的时间差值,所述时间差值为所述第二报文在所述第二网络设备上的主动延迟时间;
    所述获取模块,还用于获取所述第二报文在所述第二网络设备上的第三停留时间,获取所述目标报文流在所述第二网络设备上的第四停留时间,所述第三停留时间为第三时刻与第 四时刻之间的时间差值,所述第三时刻是所述第二网络设备结束对第二报文的主动延迟的时刻,所述第四时刻是所述第二报文经过所述第二网络设备的队列***的排队之后被所述第二网络设备发送的时刻,所述第四停留时间是所述目标报文流在所述第二网络设备上停留的阈值上限;
    封装模块,用于封装所述第二报文在所述第二网络设备上的第三停留时间、所述目标报文流在第二网络设备上的第四停留时间以及所述第二报文,获得第三报文;
    发送模块,用于所述第二网络设备接收到所述第一报文达到所述主动延迟时间并经过所述第二网络设备的队列***的排队之后,向所述目标报文流的核心网络传输路径上所述第二网络设备的下一跳网络设备发送所述第三报文。
  13. 根据权利要求12所述的装置,其特征在于,所述目标报文流的核心网络传输路径中包含位于所述第一网络设备上游的一个或多个网络设备以及位于所述第一网络设备下游的一个或多个网络设备,所述第一报文还包括所述目标报文流在所述上游的一个或多个网络设备上的一个或多个上游停留时间,所述一个或多个上游停留时间与所述上游的一个或多个网络设备一一对应,任一个上游停留时间是所述目标报文流在上游的一个网络设备上停留的阈值上限,所述第一报文还包括所述目标报文流在所述下游的一个或多个网络设备上的一个或多个下游停留时间,所述一个或多个下游停留时间与所述下游的一个或多个网络设备一一对应,任一个下游停留时间是所述目标报文流在下游的一个网络设备上停留的阈值上限;
    所述封装模块,用于封装所述第二报文、所述第二报文在第二网络设备上的第三停留时间以及所述目标报文流在所述第一网络设备下游的一个或多个网络设备上的下游停留时间,获得所述第三报文。
  14. 根据权利要求12或13所述的装置,其特征在于,所述接收模块,还用于接收所述第一网络设备发送的第一指令;
    所述获取模块,还用于根据所述第一指令确定在所述第二网络设备上传输所述目标报文流的第一端口;获取所述第一端口对应的第五停留时间,所述第五停留时间为基于第一其他报文流确定的时间,所述第一其他报文流为所述第二网络设备获取所述目标报文流之前通过所述第一端口传输的报文流;基于所述目标报文流更新所述第五停留时间,得到第六停留时间;将所述第六停留时间作为所述目标报文流在所述第二网络设备上的第四停留时间。
  15. 根据权利要求12-14中任一项所述的装置,其特征在于,所述接收模块,还用于接收所述第一网络设备发送的第三指令,所述第三指令用于向所述第二网络设备通知第一信息,所述第一信息为所述第一网络设备停止获取所述目标报文流;
    所述获取模块,还用于根据所述第三指令更新所述第六停留时间,得到第七停留时间。
  16. 根据权利要求14或15所述的装置,其特征在于,所述接收模块,还用于接收所述第一网络设备发送的第三指令,所述第三指令用于向所述第二网络设备通知第一信息,所述第一信息为所述第一网络设备停止获取所述目标报文流;
    所述获取模块,还用于根据所述第三指令更新所述第六停留时间,得到第七停留时间。
  17. 一种传输报文的装置,其特征在于,所述装置包括:
    获取模块,用于第一网络设备获取待传输的目标报文流中的第二报文,获取所述第二报文在所述第一网络设备上的第一停留时间,所述第一停留时间为第一时刻与第二时刻之间的时间差值,所述第一时刻是所述第二报文进入所述第一网络设备的队列***的时刻,所述第二时刻是所述第二报文经过所述第一网络设备的队列***的排队之后被所述第一网络设备发送的时刻;获取所述目标报文流在所述第一网络设备上的第二停留时间,所述第二停留时间是所述目标报文流在所述第一网络设备上停留的阈值上限;
    封装模块,用于封装所述第二报文、所述第二报文在所述第一网络设备上的第一停留时间以及所述目标报文流在所述第一网络设备上的第二停留时间,获得第一报文;
    发送模块,用于向第二网络设备发送所述第一报文。
  18. 根据权利要求17所述的装置,其特征在于,所述目标报文流的核心网络传输路径中包含除所述第一网络设备以外的其他网络设备,所述封装模块,用于封装所述第二报文、所述第二报文在所述第一网络设备上的第一停留时间、所述目标报文流在所述第一网络设备上的第二停留时间以及所述目标报文流在所述其他网络设备上的停留时间,获得所述第一报文,所述目标报文流在所述其他网络设备上的停留时间为所述目标报文流在所述其他网络设备上停留的阈值上限。
  19. 根据权利要求17或18所述的装置,其特征在于,所述装置还包括:确定模块,所述确定模块用于确定在所述第一网络设备上传输所述目标报文流的第二端口;获取所述第二端口对应的第八停留时间,所述第八停留时间为基于第二其他报文流确定的时间,所述第二其他报文流为所述第一网络设备获取所述目标报文流之前通过所述第二端口传输的报文流;基于所述第八停留时间,确定所述目标报文流在所述第一网络设备上的第二停留时间;存储所述目标报文流在所述第一网络设备上的第二停留时间。
  20. 根据权利要求18或19所述的装置,其特征在于,所述发送模块,还用于向所述其他网络设备发送第一指令,所述第一指令用于所述其他网络设备的任一个网络设备获取并存储所述目标报文流在所述任一个网络设备上的停留时间。
  21. 根据权利要求18-20中任一项所述的装置,其特征在于,所述发送模块,还用于向所述其他网络设备发送第二指令;
    所述装置还包括:接收模块,用于接收所述其他网络设备发送的所述目标报文流在所述其他网络设备上的停留时间,所述目标报文流在所述其他网络设备上的停留时间为所述其他网络设备基于所述第二指令发送。
  22. 根据权利要求18-20中任一项所述的装置,其特征在于,所述发送模块,还用于停止获取所述目标报文流,向所述其他网络设备发送第三指令,所述第三指令用于向所述其他网络设备通知第一信息,所述第一信息为所述第一网络设备停止获取所述目标报文流。
  23. 一种网络设备,其特征在于,所述网络设备包括存储器及处理器;所述存储器中存储有至少一条指令,所述至少一条指令由所述处理器加载并执行,以实现权利要求1-5或6-11中任一项所述的传输报文的方法。
  24. 一种计算机可读存储介质,其特征在于,所述存储介质中存储有至少一条指令,所述指令由处理器加载并执行以实现如权利要求1-11中任一项所述的传输报文的方法。
PCT/CN2021/104057 2020-07-31 2021-07-01 传输报文的方法、装置、设备及可读存储介质 WO2022022219A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP21851061.8A EP4184872A4 (en) 2020-07-31 2021-07-01 METHOD, APPARATUS AND DEVICE FOR TRANSMITTING MESSAGES, AND READABLE STORAGE MEDIUM
US18/161,247 US20230171197A1 (en) 2020-07-31 2023-01-30 Packet transmission method, apparatus, device, and readable storage medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010761634.4A CN114095397A (zh) 2020-07-31 2020-07-31 传输报文的方法、装置、设备及可读存储介质
CN202010761634.4 2020-07-31

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US18/161,247 Continuation US20230171197A1 (en) 2020-07-31 2023-01-30 Packet transmission method, apparatus, device, and readable storage medium

Publications (1)

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

Family

ID=80037476

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/104057 WO2022022219A1 (zh) 2020-07-31 2021-07-01 传输报文的方法、装置、设备及可读存储介质

Country Status (4)

Country Link
US (1) US20230171197A1 (zh)
EP (1) EP4184872A4 (zh)
CN (1) CN114095397A (zh)
WO (1) WO2022022219A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116599871B (zh) * 2023-07-14 2023-10-03 腾讯科技(深圳)有限公司 一种网络时延的确定方法和相关装置

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100284274A1 (en) * 2009-05-08 2010-11-11 Bae Systems System and method for determining a transmission order for packets at a node in a wireless communication network
CN107431667A (zh) * 2015-03-20 2017-12-01 阿尔卡特朗讯公司 在网络设备中调度数据包
CN108449228A (zh) * 2018-03-05 2018-08-24 新华三技术有限公司 报文处理方法及网络设备
US10277518B1 (en) * 2017-01-16 2019-04-30 Innovium, Inc. Intelligent packet queues with delay-based actions
CN110086728A (zh) * 2018-01-26 2019-08-02 华为技术有限公司 发送报文的方法、第一网络设备及计算机可读存储介质
CN110166380A (zh) * 2018-02-14 2019-08-23 华为技术有限公司 调度报文的方法、第一网络设备及计算机可读存储介质

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP3720069A4 (en) * 2017-12-31 2020-12-02 Huawei Technologies Co., Ltd. METHOD, DEVICE, AND SYSTEM FOR SENDING A MESSAGE

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100284274A1 (en) * 2009-05-08 2010-11-11 Bae Systems System and method for determining a transmission order for packets at a node in a wireless communication network
CN107431667A (zh) * 2015-03-20 2017-12-01 阿尔卡特朗讯公司 在网络设备中调度数据包
US10277518B1 (en) * 2017-01-16 2019-04-30 Innovium, Inc. Intelligent packet queues with delay-based actions
CN110086728A (zh) * 2018-01-26 2019-08-02 华为技术有限公司 发送报文的方法、第一网络设备及计算机可读存储介质
CN110166380A (zh) * 2018-02-14 2019-08-23 华为技术有限公司 调度报文的方法、第一网络设备及计算机可读存储介质
CN108449228A (zh) * 2018-03-05 2018-08-24 新华三技术有限公司 报文处理方法及网络设备

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP4184872A4

Also Published As

Publication number Publication date
EP4184872A1 (en) 2023-05-24
US20230171197A1 (en) 2023-06-01
CN114095397A (zh) 2022-02-25
EP4184872A4 (en) 2024-01-10

Similar Documents

Publication Publication Date Title
US11245634B2 (en) Time-sensitive networking (TSN) packet forwarding
Nasrallah et al. Performance comparison of IEEE 802.1 TSN time aware shaper (TAS) and asynchronous traffic shaper (ATS)
CN111431822A (zh) 一种确定性时延业务智能调度与控制实施方法
US11785113B2 (en) Client service transmission method and apparatus
US9515940B2 (en) Method for transmitting data in a packet-oriented communications network and correspondingly configured user terminal in said communications network
WO2021089018A1 (zh) 一种通信方法、装置及***
WO2021147368A1 (zh) 调整服务等级的方法、装置、设备、***及存储介质
CN113711572A (zh) 一种报文传输方法及装置
WO2020192397A1 (zh) 一种发送设备的调整方法和通信装置
WO2021008562A1 (zh) 流速控制方法和装置
WO2022078232A1 (zh) 确定性业务的转发方法及装置
WO2022022219A1 (zh) 传输报文的方法、装置、设备及可读存储介质
CN113383505A (zh) 用于tsn集成的去抖动缓冲器能力的信令
WO2021238694A1 (zh) 确定传输业务流的带宽的方法、设备和***
WO2021073103A1 (zh) 随流信息遥测能力的确认方法和设备
CN112753206B (zh) 工业通信网络内数据传输的方法和通信设备
Elshuber et al. Dependable and predictable time-triggered Ethernet networks with COTS components
JP2017521961A (ja) パケット交換ネットワーク内でコヒーレントデータフローを送信するためのシグナリング
KR101681613B1 (ko) 분산 병렬 데이터 전송 시스템에서 자원들을 스케줄링하기 위한 장치 및 그 방법
WO2023236832A1 (zh) 数据调度处理方法、设备、装置及存储介质
JP2014147019A (ja) 通信装置、通信方法及び通信プログラム
EP4329262A1 (en) Packet forwarding method and related apparatus
WO2024016327A1 (zh) 报文传输
Sakamoto et al. Bandwidth control using adaptive packet policer management for packet transport network based on service layer request
CN115883457A (zh) 一种通信方法以及路由设备

Legal Events

Date Code Title Description
ENP Entry into the national phase

Ref document number: 2021851061

Country of ref document: EP

Effective date: 20230215

NENP Non-entry into the national phase

Ref country code: DE