Message processing method, system, device, medium and product

By obtaining the RTT between forwarding devices and selecting low-latency ports to generate a forwarding table, the problem of link latency affecting transmission efficiency in communication networks is solved, and efficient data transmission and automatic detection and filtering of faulty links are realized.

CN122293572APending Publication Date: 2026-06-26CLOUD INTELLIGENCE ASSETS HOLDING (SINGAPORE) PTE LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CLOUD INTELLIGENCE ASSETS HOLDING (SINGAPORE) PTE LTD
Filing Date
2024-12-24
Publication Date
2026-06-26

AI Technical Summary

Technical Problem

In communication networks, transmission link latency between forwarding devices affects message transmission efficiency, leading to a decline in service experience and even causing services to become unusable.

Method used

By obtaining the round-trip time (RTT) between the first and second forwarding devices, a target port with a low RTT is selected, and a forwarding table containing the target port is generated in order to send the data packets to be processed.

Benefits of technology

It ensures high-efficiency data transmission and automatically filters out faulty links when they fail, guaranteeing normal packet forwarding, reducing the difficulty of link failure detection, and improving the efficiency of forwarding table generation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122293572A_ABST
    Figure CN122293572A_ABST
Patent Text Reader

Abstract

This invention provides a message processing method, system, device, medium, and product. The method, applied in network communication, includes: first obtaining the round-trip time (RTT) between candidate ports in a first forwarding device and a second forwarding device; then selecting an available target port in the first forwarding device based on the RTT; and finally generating a forwarding table in the first forwarding device based on transmission link information including the target port. This forwarding table is used to forward data packets to be processed to the second forwarding device. As can be seen, the above method selects ports and generates forwarding tables based on RTT. Since ports with low RTTs are selected, the transmission links selected from the forwarding table also have low latency, thus ensuring data transmission efficiency. Furthermore, the forwarding table generation process includes a link fault detection process, which allows faulty transmission links between the first and second forwarding devices to be filtered out during the RTT-based forwarding table generation process, ensuring that all transmission links in the forwarding table are available. Even if a transmission link fails, using the forwarding table will not affect the normal forwarding of messages.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of network communication, and more particularly to a message processing method, system, device, medium, and product. Background Technology

[0002] Various forwarding devices in a communication network enable the transmission of messages between different networks or subnets, ensuring that users can access the services provided by service providers. Specifically, forwarding devices can query transmission link information in their local forwarding tables and use the query results to transmit messages.

[0003] In practice, the latency of the transmission link between forwarding devices obviously affects the packet transmission efficiency, thereby impacting the user experience of the service and potentially even causing the service to become unusable. Therefore, ensuring efficient packet transmission becomes a pressing issue. Summary of the Invention

[0004] In view of this, embodiments of the present invention provide a message processing method, system, device, medium, and product to ensure the efficiency of message transmission.

[0005] In a first aspect, embodiments of the present invention provide a message processing method, including:

[0006] Obtain the round-trip time between the alternative ports in the first forwarding device and the second forwarding device;

[0007] Based on the round-trip time, the target port is determined from the candidate ports;

[0008] A forwarding table is generated in the first forwarding device based on the transmission link information containing the target port, so as to send the data packet to be processed to the second forwarding device using the forwarding table.

[0009] In a second aspect, embodiments of the present invention provide a message processing system, including: a first forwarding device and a second forwarding device;

[0010] The first forwarding device is configured to obtain the round-trip time between the candidate ports in the first forwarding device and the second forwarding device respectively; determine the target port from the candidate ports according to the round-trip time; and generate a forwarding table in the first forwarding device according to the link information containing the target port.

[0011] The second forwarding device is used to receive the data packets to be processed sent by the first forwarding device using the forwarding table.

[0012] Thirdly, embodiments of the present invention provide an electronic device, including a processor and a memory, wherein the memory is used to store one or more computer instructions, wherein the one or more computer instructions, when executed by the processor, implement the message processing method described in the first aspect. The electronic device may further include a communication interface for communicating with other devices or communication systems.

[0013] Fourthly, embodiments of the present invention provide a non-transitory machine-readable storage medium storing executable code, wherein when the executable code is executed by a processor of an electronic device, the processor is able to at least implement the message processing method as described in the first aspect.

[0014] Fifthly, embodiments of the present invention provide a computer program product, the computer program product including a computer program or instructions, which, when executed by a processor, cause the processor to implement the message processing method as described in the first aspect above.

[0015] The packet processing method provided in this embodiment of the invention first obtains the round-trip time (RTT) between the candidate ports in the first forwarding device and the second forwarding device. Then, based on this RTT, it selects an available target port in the first forwarding device. Finally, it generates a forwarding table in the first forwarding device based on the transmission link information including the target port. The first forwarding device can use the aforementioned forwarding table to forward the data packet to be processed to the second forwarding device.

[0016] As can be seen, the above method selects ports and generates a forwarding table based on round-trip time (RTT). Since ports with low RTTs are selected, the transmission links chosen from the forwarding table also have low latency, thus ensuring data transmission efficiency. Furthermore, since obtaining the RTT means that the transmission link between the port and the second forwarding device is not faulty, the process of generating the forwarding table actually includes a link fault detection process. That is, during the process of generating the forwarding table based on RTT, faulty transmission links between the first and second forwarding devices can be filtered out, ensuring that all transmission links in the forwarding table are usable. Therefore, even if a transmission link fails, using the above forwarding table will not affect the normal forwarding of packets. Moreover, using RTT can directly detect link faults without relying on other devices on the transmission link. Attached Figure Description

[0017] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0018] Figure 1 A flowchart of a message processing method provided in an embodiment of the present invention;

[0019] Figure 2 A flowchart of an RTT determination method provided in an embodiment of the present invention;

[0020] Figure 3a This is a schematic diagram illustrating the relationship between an interface, a port group, and ports, provided as an embodiment of the present invention.

[0021] Figure 3b This is a schematic diagram illustrating the relationship between an interface, alternative ports, and a target port, provided for an embodiment of the present invention.

[0022] Figure 3c This is a schematic diagram illustrating the relationship between another interface, alternative ports, and target ports provided in an embodiment of the present invention.

[0023] Figure 4 A flowchart illustrating a method for determining a time delay interval provided in an embodiment of the present invention;

[0024] Figure 5 This is a schematic diagram of the structure of a probe message provided in an embodiment of the present invention;

[0025] Figure 6a This is a schematic diagram illustrating the alternating update and usage process of multiple forwarding tables, as provided in an embodiment of the present invention.

[0026] Figure 6b This is a schematic diagram illustrating another process of alternating updates and use of multiple forwarding tables provided in an embodiment of the present invention;

[0027] Figure 7 This is a schematic diagram of the structure of a message processing system provided in an embodiment of the present invention;

[0028] Figure 8 This is a schematic diagram of another message processing system provided in an embodiment of the present invention;

[0029] Figure 9 This is a schematic diagram of the structure of a message processing device provided in an embodiment of the present invention;

[0030] Figure 10 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation

[0031] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0032] The terminology used in the embodiments of this invention is for the purpose of describing particular embodiments only and is not intended to limit the invention. The singular forms “a,” “the,” and “the” used in the embodiments of this invention and the appended claims are also intended to include the plural forms, unless the context clearly indicates otherwise. “Multiple” generally includes at least two, but does not exclude the inclusion of at least one.

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

[0034] Depending on the context, the words “if” or “suppose” as used here can be interpreted as “when” or “in response to determination” or “in response to identification.” Similarly, depending on the context, the phrases “if determination” or “if identification (of the condition or event of the statement)” can be interpreted as “when determination” or “in response to determination” or “when identification (of the condition or event of the statement)” or “in response to identification (of the condition or event of the statement).”

[0035] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this invention are all information and data authorized by the user or fully authorized by all parties. Furthermore, the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions, and corresponding operation entry points are provided for users to choose to authorize or refuse.

[0036] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a product or system comprising a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a product or system. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the product or system that includes said element.

[0037] Based on the introduction in the background art, before describing in detail the content provided in the various embodiments of the present invention, the background of using the following embodiments of the present invention can be described in more detail.

[0038] Users generate messages while using services provided by service providers. These messages, called data packets, can represent data streams. Through transmission links between different forwarding devices in a communication network, data packets can be transmitted between different networks or subnets to ensure the normal operation of the service. Service providers can provide services through applications or cloud services. Data packets generated by different services can belong to different data streams, and the content of the data packets varies depending on the service. For example, when the service is cloud gaming, the data packets may include game data; when the service is cloud computing, the data packets may include calculation results.

[0039] The first forwarding device and the second forwarding device can be two adjacent devices on any transmission link in a communication network that are transmitting data. Even if the transmission link between them fails, the method or system provided in the following embodiments of the present invention can still ensure the normal transmission of data packets. Optionally, the cause of the transmission link failure may include a port failure of the first forwarding device, or it may include failures of other devices on the transmission link.

[0040] The devices located at both ends of the transmission link can be referred to as the source device and the destination device, respectively, and the remaining devices on the transmission link can be referred to as intermediate devices. Optionally, in one case, the first forwarding device can be the source device on the transmission link, and the second forwarding device can be an intermediate device on the transmission link. In another case, both the first and second forwarding devices can be intermediate devices on the transmission link. Yet another case, the first forwarding device can be an intermediate device on the transmission link, and the second forwarding device can be the destination device on the transmission link.

[0041] The following detailed description of some embodiments of the present invention, in conjunction with the accompanying drawings, is provided. Where there is no conflict between the embodiments, the following embodiments and features can be combined with each other. Furthermore, the timing of the steps in the following method embodiments is merely an example and not a strict limitation.

[0042] Figure 1 This is a flowchart illustrating a message processing method provided in an embodiment of the present invention. The method provided in this embodiment can be executed by a first forwarding device in a communication network. Figure 1 As shown, the method may include the following steps:

[0043] S101, obtain the RTT between the alternative ports in the first forwarding device and the second forwarding device respectively.

[0044] Message transmission can occur between the first and second forwarding devices. More specifically, these messages can be sent from the backup port of the first forwarding device to the second forwarding device. Optionally, these messages can be data packets generated by users during service usage, or probe packets transmitted between the first and second forwarding devices specifically for detecting link failures. The first forwarding device can then use historical data packets or probe packets to determine the RTT between the backup port and the second forwarding device. The historical data packets can be data packets forwarded to the second forwarding device via the backup port of the first forwarding device within a historical time period. Optionally, the historical time period can be any period prior to the current time, and the historical time period can be in the range of seconds, such as 10 seconds.

[0045] The RTT (Round-Trip Time) between the alternative ports and the second forwarding device refers to the RTT between the alternative ports and the second forwarding device mentioned in the embodiments of this invention. The RTT can be defined as the total time required for a message to be sent from any of the alternative ports included in the first forwarding device, transmitted to the second forwarding device via the transmission link mapped to that port, for the second forwarding device to respond to the message, and for the second forwarding device to return the response result to the first forwarding device. For any port in the first forwarding device, the hash result of the port number maps that port to a corresponding transmission link. It is easily understood that a smaller RTT indicates lower transmission link latency.

[0046] Based on the aforementioned meaning of RTT, when the first forwarding device obtains the RTT based on historical data packets, the specific process can be as follows: For historical data packets sent from the backup ports of the first forwarding device, the first forwarding device can obtain the sending time of the historical data packet and the time when it receives the response result of the historical data packet from the second forwarding device. Based on the sending time of the historical data packet and the receiving time of the response result, the RTT between the backup ports and the second forwarding device is determined. It can be seen that one RTT corresponds to one port. The specific process by which the first forwarding device obtains the RTT using probe packets can be seen below. Figure 2 Detailed description of the illustrated embodiment.

[0047] It is easy to understand that if the first forwarding device can obtain the RTT, it means that the port corresponding to the RTT and the transmission link mapped to the port have not failed. Therefore, the process of the first forwarding device obtaining the RTT actually includes the fault detection process of the transmission link.

[0048] Optionally, the first forwarding device and the second forwarding device can belong to different clusters, and each cluster can be provided by a service provider. Optionally, the forwarding devices in a cluster can include any device with packet forwarding function in a communication network, such as a switch, gateway, or router. Optionally, the forwarding devices in a cluster can be physical devices or virtual devices. Any forwarding device in any cluster can transmit packets with any forwarding device in other clusters. The embodiments of the present invention are illustrated using the packet transmission process between a first forwarding device in one cluster and a second forwarding device in another cluster as an example.

[0049] S102, determine the target port from the candidate ports according to the RTT.

[0050] Then, the first forwarding device can select a target port from the candidate ports based on the RTT obtained in step S101. Optionally, the first forwarding device can filter out RTTs less than or equal to a preset threshold from the RTTs obtained in step S101, and the port corresponding to the selected RTT can be determined as the target port. Optionally, the preset threshold can usually be set to a small value; therefore, the transmission link mapped to the target port selected in the above manner has low latency.

[0051] S103, a forwarding table in the first forwarding device is generated based on the transmission link information including the target port. The forwarding table is used to send the data packet to be processed to the second forwarding device, and the transmission link information in the forwarding table corresponds to the transmission link between the first forwarding device and the second forwarding device.

[0052] Finally, the first forwarding device can generate a forwarding table locally, which can record transmission link information including the aforementioned target ports. When a data packet to be processed is obtained after the forwarding table is generated, the first forwarding device can use this forwarding table to forward the data packet to the second forwarding device.

[0053] Specifically, since the transmission links in the forwarding table are all low-latency, the first forwarding device may optionally send the message to be processed from any port in the target port and transmit it to the second forwarding device via the transmission link mapped to that port.

[0054] In practice, the first forwarding device and the second forwarding device can transmit data packets belonging to different data streams. Therefore, the data packets to be processed forwarded by the forwarding table and the historical data packets used in step S101 can belong to the same or different data streams.

[0055] In this embodiment, the RTT (Round-Trip Time) between the candidate ports in the first forwarding device and the second forwarding device is obtained. Then, based on this RTT, an available target port in the first forwarding device is selected. Finally, a forwarding table in the first forwarding device is generated based on the transmission link information including the target port. The first forwarding device can use this forwarding table to forward the data packets to be processed to the second forwarding device.

[0056] As can be seen, the above method selects ports and generates a forwarding table based on round-trip time (RTT). Since ports with low RTTs are selected, the transmission links chosen from the forwarding table also have low latency, thus ensuring efficient data transmission. Furthermore, since obtaining the RTT means that the transmission link between the port and the second forwarding device is not faulty, the forwarding table generation process actually includes a link fault detection process. Therefore, even if the transmission link between the first and second forwarding devices fails, the faulty transmission link can be filtered out during the RTT-based forwarding table generation process. This ensures that all transmission links in the forwarding table are usable and will not affect the normal forwarding of packets.

[0057] exist Figure 1 Based on the illustrated embodiment, optionally, for the first forwarding device, which manifests as a physical device, the aforementioned logic for generating the forwarding table and the logic for forwarding data packets can be implemented by a programmable network switching chip in the first forwarding device. Optionally, the network switching chip can be implemented using a Programming Protocol-Independent Packet Processors (P4) language. Furthermore, this hardware network switching chip makes the first forwarding device more suitable for forwarding large data flows.

[0058] Furthermore, the technical effects achieved by the methods and systems provided in the various embodiments of the present invention can also be understood in conjunction with the following:

[0059] 1. When the source and second forwarding devices are deployed in wide area networks (WANs) or metropolitan area networks (MANs) with wide coverage and high transmission traffic, packets will pass through equipment from different vendors and networks of different operators during their transmission from the first to the second forwarding device. In this case, if segmented routing traffic engineering (SRTE) technology is used for fault detection of the transmission link, it is necessary to utilize the network topology information collected by each device in the transmission link.

[0060] And such Figure 1 As described in the illustrated embodiment, the first forwarding device can directly use RTT to detect link faults without relying on other devices in the transmission link, thereby reducing the difficulty of link fault detection and making it easier for the first forwarding device to select a fault-free, low-latency transmission link to transmit the data packets to be processed.

[0061] Optionally, the first and second forwarding devices mentioned in the embodiments of the present invention can be devices provided by the service provider. Therefore, by using the methods and systems provided by the present invention, the service provider can have the ability to select low-latency transmission links in real time.

[0062] 2. The forwarding table used in the data packet forwarding process is located on the data plane of the first forwarding device. This forwarding table is generated directly by the first forwarding device using data plane data. It is not issued by the decision center in the communication network, nor does it require the control plane of the first forwarding device to issue data. Omitting the issuance process obviously improves the efficiency of forwarding table generation.

[0063] 3. According to Figure 1 As can be seen from the description in the illustrated embodiment, the forwarding table is generated based on RTT. In practice, RTT is second-level data, which can shorten the time required for the first forwarding device to obtain RTT, thereby further improving the efficiency of forwarding table generation, making the time for generating the forwarding table also second-level.

[0064] 4. Optionally, using the methods or systems provided in the embodiments of the present invention, the first forwarding device can also periodically generate a forwarding table. When a transmission link between the first forwarding device and the second forwarding device fails within the current generation period of the forwarding table, since the forwarding table can be generated within seconds, the first forwarding device can also remove the faulty link from the forwarding table corresponding to the previous generation period within seconds, and then add the fault-recovered or other non-faulty, low-latency transmission links to the forwarding table to obtain the forwarding table corresponding to the current generation period, that is, to achieve link escape within seconds.

[0065] For the periodic generation of the forwarding table, optionally, when the next generation cycle of the forwarding table is reached, the first forwarding device can first clear the forwarding table corresponding to the current generation cycle, and then regenerate the forwarding table corresponding to the next generation cycle in accordance with the method provided in the above embodiments.

[0066] Figure 1 The illustrated embodiment describes the process of determining the RTT between the port of the first forwarding device and the second forwarding device based on historical data packets. The specific process by which the first forwarding device determines the RTT based on probe packets can be found below. Figure 2 The illustrated embodiment.

[0067] Figure 2 This is a flowchart of an RTT determination method provided by an embodiment of the present invention, which is also an optional specific implementation of step S101. Figure 2 As shown, the method may include the following steps:

[0068] S201, obtain the sending time of the probe message and the receiving time of the response message. The probe message is sent using different ports among the alternative ports, and the response message is obtained by the second forwarding device after responding to the probe message.

[0069] S202, determine the RTT between different ports and the second forwarding device based on the sending time and receiving time.

[0070] The first forwarding device can acquire probe packets and send them out from different ports of the backup ports. The second forwarding device, upon acquiring a probe packet, can respond to it to receive a response packet, which can then be sent back to the first forwarding device. The first forwarding device can then obtain the time difference between the transmission time of the probe packet from the backup port and the reception time of the response packet; this time difference is the RTT (Round-Trip Time) between the backup port and the second forwarding device.

[0071] Optionally, probe messages can be generated periodically, and the first forwarding device can also periodically generate a forwarding table based on the periodically generated probe messages, with the length of the forwarding table generation period being equal to the length of the probe period. Optionally, probe messages can be generated by the first forwarding device or generated and sent to the first forwarding device by a decision center in the communication network.

[0072] In this embodiment, the first forwarding device can use probe packets to achieve RTT statistics.

[0073] Optionally, to ensure the accuracy of RTT calculation, the first and second forwarding devices can also synchronize their clocks using a Network Time Protocol (NTP) server as the standard.

[0074] Optionally, the first forwarding device in various embodiments of the present invention may include at least one interface, and any interface may include multiple groups of ports. Furthermore, the ports in each group of ports have connected port numbers, and the number of ports in different groups of ports is the same. An illustrative relationship between interfaces and port groups can be illustrated as follows: Figure 3a As shown. Figure 3a The value in represents the port number of the port, such as... Figure 3a As shown, each interface includes 3 groups of ports, and each group of ports can contain up to 16 ports. However, it should be noted that all of these are included. Figure 3a This is just an illustration; this scheme does not limit the number of port groups contained in an interface, nor does it limit the number of ports in a port group.

[0075] based on Figure 3a The relationship between the interface, alternative ports, and target ports can be further explained below.

[0076] Optionally, the alternative ports of the first forwarding device can be a preset number of ports randomly selected from all ports of the first forwarding device. That is, the alternative ports can be ports distributed in different port groups. Optionally, the alternative ports can also be at least one complete set of ports under all interfaces of the first forwarding device.

[0077] In practice, the first forwarding device can transmit packets with forwarding devices in different clusters. Considering the accuracy of packet transmission, the alternative ports can be at least one complete set of ports under the target interface corresponding to the cluster to which the second forwarding device belongs. Optionally, the target interface can be some interfaces in the first forwarding device, and the number of target interfaces can be at least one. Assuming the target interfaces are interface 1 and interface 2, the alternative ports can be at least one set of ports under interface 1 and interface 2.

[0078] Continuing with the example above, when the candidate ports are all ports under interface 1 and interface 2, another optional method for selecting the target port is as follows: After obtaining the RTT between the candidate ports and the second forwarding device based on historical data packets or probe packets, the first forwarding device can select ports from at least one group of ports whose RTT is less than or equal to a preset threshold to determine the target ports. In this case, at least one port in a group can be selected as the target port. The relationship between the candidate ports and the target ports can be as follows: Figure 3b As shown. Figure 3b As shown, target ports are represented by rectangles with diagonal lines, and these selected target ports can be written into the forwarding table.

[0079] Another alternative target port selection method involves the first forwarding device filtering ports from at least one group, selecting the port with the smallest RTT (Round-Trip Time). In this case, one port out of each group can be selected as the target port. The relationship between the candidate ports and the target port can be as follows: Figure 3c As shown. Figure 3c As shown, the target port is represented by a rectangle with a diagonal line. Furthermore, the more ports in a port group, the smaller the RTT can be selected.

[0080] Regardless of whether the backup ports of the source forwarding device are a complete set of ports or ports scattered across different port groups, after the first forwarding device obtains the RTT between the backup ports and the second forwarding device based on historical data packets or probe packets, there is another optional method for selecting the target port. The first forwarding device can obtain the target delay interval between the first forwarding device and the second forwarding device. The first forwarding device can filter out the target port from the candidate ports based on whether the RTT between the backup ports and the second forwarding device falls within the target delay interval. Specifically, for any port among the backup ports, if the RTT between that port and the second forwarding device falls within the target delay interval, then that port is determined as the target port.

[0081] Optionally, the relationship between the target port selected using the target delay interval and the candidate ports can be as follows: Figure 3b or Figure 3c As shown.

[0082] In this embodiment, the candidate ports of the first forwarding device can be at least one complete group of ports, or ports scattered across different port groups. Depending on the composition of the candidate ports, the first forwarding device can use a preset threshold or delay interval to select the destination port.

[0083] The process of determining the target delay interval between the first and second forwarding devices can be further described below. Figure 4 This is a flowchart illustrating a method for determining a time delay interval according to an embodiment of the present invention. Figure 4 As shown, the method may include the following steps:

[0084] S301, obtain the type of the data stream to which the historical data packets belong, and the link quality of the different transmission links between the first forwarding device and the second forwarding device.

[0085] During the forwarding of historical data packets, the type of data stream to which the historical data packet belongs, as well as the link quality of the different transmission links between the first forwarding device and the second forwarding device, can also be obtained.

[0086] Optionally, the data stream to which the historical data packets belong can include static data streams with low latency requirements, or real-time data streams with low latency requirements, such as audio data streams, game data streams, etc.

[0087] Optionally, link quality can be characterized by metrics such as signal strength and link performance. Link strength can be further characterized by metrics such as Received Significant Strength Indication (RSSI) and Signal-to-Noise Ratio (SNR). Link performance can be further characterized by metrics such as Bit Error Rate (BER), Packet Reception Rate (PRR), and Probability of Successful Packet Reception (PSPR).

[0088] S302, determine the reference length of the delay interval based on the link quality.

[0089] S303 determines a target delay interval with a reference length based on the RTT between the alternative port and the second forwarding device, and the type of data stream.

[0090] Then, the reference length of the delay interval can be determined based on the link quality and the type of data stream to which the historical data packets belong. Optionally, the stronger the signal strength of the transmission link and the better the link performance, the smaller the reference length of the delay interval.

[0091] Finally, an initial delay interval can be determined based on the maximum and minimum RTT values ​​between the alternative ports and the second forwarding device. Then, the initial delay interval is truncated according to the reference length determined above to obtain a target delay interval with the reference length. Optionally, the data stream type of the historical data packets can have a preset correspondence with the truncation position of the initial delay interval, and the lower the required delay for the data stream type, the earlier the truncation position.

[0092] For example, if the maximum and minimum RTT values ​​are 50 milliseconds and 70 milliseconds respectively, then the initial latency interval is [50 milliseconds, 70 milliseconds]. If the historical data packet belongs to a real-time data stream, and the truncation position corresponding to this type of data stream is 25%, then the final target latency interval obtained is [50 milliseconds, 55 milliseconds]. If the historical data packet belongs to a static data stream, and the truncation position corresponding to this type of data stream is 50%, then the final target latency interval obtained is [50 milliseconds, 60 milliseconds].

[0093] It should be noted that the delay interval determination method provided in this embodiment can be executed by the first forwarding device, or it can be executed by the central decision-making device in the communication network and then sent to the first forwarding device. Furthermore, regardless of who determines the target delay interval, the target delay interval can also be synchronously transmitted to the second forwarding device.

[0094] In this embodiment, a suitable latency range can be determined by combining factors such as data stream type and link quality to ensure the accuracy of forwarding generation.

[0095] Optionally, to ensure that the transmission link mapped to the selected target port has low latency, the second forwarding device can use a response rule table to determine whether to send a response message to the first forwarding device when the current probe period arrives. Optionally, Table 1 below is an illustrative response rule table provided in an embodiment of the present invention.

[0096] Table 1:

[0097] Src_identify Dst_identify Maximum Latency 172.16.1.1 172.16.2.1 60000000 (ns)

[0098] In Table 1 above, Src_identify is the address of the cluster where the first forwarding device is located, Dst_identify is the address of the cluster where the second forwarding device is located, and Maximum Latency is the maximum latency. Optionally, the data in the response rule table can be stored in key-value pairs, and the addresses of the first and second forwarding devices can be stored as keys, while the maximum latency can be stored as values.

[0099] The specific usage process of the response rule table can be described as follows: In the current probe cycle, after receiving the probe message, the second forwarding device can calculate the time difference between the sending time and the receiving time of the probe message. If this time difference is greater than the maximum delay in the table, it indicates that the transmission link transmitting the probe message has high latency and will not be recorded in the forwarding table. Therefore, the second forwarding device can choose not to respond to the probe message, and the port used to send the probe message will not receive the response message, and the port will not be selected as the target port by the first forwarding device.

[0100] The maximum latency in the detection rule table is the maximum value corresponding to the latency interval between the first and second forwarding devices calculated in the previous detection cycle. Furthermore, the latency intervals within different detection cycles can be determined according to the above rules. Figure 4 The method described in the illustrated embodiment is determined.

[0101] In this embodiment, the second forwarding device can compare the time difference and maximum latency using a local response rule table. Based on the comparison result, the first forwarding device can determine whether to respond to the probe packet. For probe packets that do not receive a response, the port used by the first forwarding device to send the probe packet will not receive a response packet. Therefore, the first forwarding device will not identify the port that did not receive a response packet as the target port. Thus, it can be guaranteed that the transmission link mapped to the target port selected by the first forwarding device has low latency.

[0102] Optionally, the format of the probe message can be as follows: Figure 5 As shown. The meaning of each part of the probe message will be explained below, from the inside out. For example... Figure 5As shown, the Pay load is the payload of the tunnel packet. Specifically, the payload may include the Detect Sequence, the time the first forwarding device sent the probe packet (Local Timestamp), the time the second forwarding device received the probe packet (Remote Timestamp), the Packet Type, the Egress port number used to send the probe packet, the table index, and the Upport number used to send the probe packet. The Packet Type may include Request and Response packets. The Inner IP Header is the source IP address in the inner 5-tuple information. The Vxlan Header is the Vxlan header, Sport is the source port number in the outer 5-tuple information, and Dport is the destination port number in the outer 5-tuple information. The source IP address in the outer 5-tuple information may include the IP Header and an additional IP Header (UPD Header) outside the IP Header. The outer 5-tuple information provides identification information for the probe packet at the network and transport layers. The Ethernet Header is the header of an Ethernet frame, providing address information for probe packets at the data link layer.

[0103] In practice, the five-tuple information in the data packet to be processed may include IP address, destination IP address, source port number, destination port number, and the protocol used. These items are all variable. Therefore, when performing hash calculation on the five-tuple information to select a low-latency transmission link for this data packet to be processed, it will greatly increase the computational burden of link selection.

[0104] To address the aforementioned issues, the data packets can be further encapsulated. Specifically, the data packets to be processed mentioned in the above embodiments can be unencapsulated raw packets. Upon receiving the raw packets, the first forwarding device can encapsulate them. The encapsulated tunnel packet can include outer 5-tuple information and inner 5-tuple information. The inner 5-tuple corresponds to the transmission protocol of the unencapsulated raw packet, while the outer 5-tuple corresponds to the tunneling protocol. Furthermore, with the source IP address and destination IP address in the outer 5-tuple information fixed, the destination port number and the protocol used are also immutable; the only variable item is the source port number.

[0105] Therefore, after the forwarding table is generated, when the first forwarding device obtains the original packet, it can first use the tunneling protocol to encapsulate the outer 5-tuple information outside the original packet to obtain the tunnel packet. Since the source IP address and destination IP address in the outer 5-tuple information of the tunnel packet are fixed, the variable item in the tunnel packet's 5-tuple information includes the source port number. Therefore, after the first forwarding device performs a hash calculation on the source port number in the tunnel packet, it can select a low-latency transmission link based on the calculation result, thereby reducing computational pressure. Here, the original packet can be an unencapsulated, unprocessed data packet.

[0106] Alternatively, the communication network including the first forwarding device and the second forwarding device can be specifically a cloud data center network. Such networks are multi-tenant, and in order to ensure the security and privacy of data between different tenants, tunnel packets are often used for transmission. Therefore, the process of encapsulating the original packet into a tunnel packet in this solution will not add extra pressure to the packet processing system.

[0107] In this embodiment, after the original message is encapsulated, a low-latency transmission link can be selected from the forwarding table using the encapsulated tunnel message.

[0108] Based on the above embodiments, regarding the format of the probe message, it should be noted that although... Figure 5 The diagram shows that a probe message can contain outer 5-tuple information and memory 5-tuple information, but optionally, a probe message can also contain a single 5-tuple, meaning the probe message can contain... Figure 5 The outer quintuple information shown does not include Figure 5 The inner 5-tuple information is shown in the figure. In summary, the requirement that the probe message in each embodiment of the present invention must meet is that the 5-tuple information contained in the probe message and used in the process of generating the forwarding table is consistent with the outer 5-tuple information of the tunnel message obtained after encapsulating the data packet. However, the embodiments of the present invention do not limit whether the probe message has other 5-tuple information.

[0109] Furthermore, regardless of whether the first forwarding device generates the forwarding table using historical data packets or probe packets, and regardless of whether the historical data packets or probe packets used in the forwarding table generation process are encapsulated, and regardless of whether the data packets to be processed forwarded using the forwarding table are encapsulated, in order to ensure that the data packets to be processed can also be forwarded normally during the forwarding table generation process, the first forwarding device can generate and use multiple forwarding tables locally alternately. That is, during the generation of a forwarding table, if the first forwarding device receives a data packet to be processed, it can use other forwarding tables to forward the data packet to be processed.

[0110] Multiple forwarding tables can be generated within different generation periods. More specifically, when the first forwarding device generates a forwarding table based on probe messages, different forwarding tables are generated based on probe messages within different probe periods. Furthermore, any one of the multiple forwarding tables can be generated according to the methods provided in the above embodiments, thereby ensuring that the transmission links in these multiple forwarding tables are all available and have low latency.

[0111] Assuming the first forwarding device locally contains a first forwarding table and a second forwarding table generated at different generation cycles, and that the forwarding tables are generated based on historical data packets, then the alternating generation and use of the forwarding tables can also be combined with... Figure 6a Understanding. For example... Figure 6a As shown in (1), ① indicates that within the current generation cycle of the forwarding table, the first forwarding device can calculate the RTT based on historical data packets and further generate the first forwarding table. ② indicates that simultaneously with ①, the first forwarding device can use the second forwarding table to forward the received data packets to be processed to the second forwarding device. For example... Figure 6a As shown in (2), ③ indicates that in the next generation cycle of the forwarding table, the first forwarding device can calculate the RTT based on historical data packets and further generate the second forwarding table, which is to update the second forwarding table used in ②. ④ indicates that at the same time as ③, the first forwarding device can use the first forwarding table generated in ① to forward the received data packets to be processed to the second forwarding device. Among them, the generation time of the historical data packets used in ① can be earlier than the historical data packets used in ③.

[0112] Similarly, when the first forwarding device is generated based on probe messages, the alternating generation and use of the forwarding table can also be combined with... Figure 6b Understanding. For example... Figure 6b As shown in (1), ⑤ indicates that within the current generation period of the forwarding table, the first forwarding device can acquire and send probe messages to the second forwarding device. ⑥ indicates that the first forwarding device can also acquire response messages from the probe messages of the second forwarding device, and calculate the RTT based on the sending time of the probe messages and the receiving time of the response messages to generate the first forwarding table. ⑦ indicates that simultaneously with ⑥, the first forwarding device can use the second forwarding table to forward the received data packets to be processed to the second forwarding device. For example... Figure 6bAs shown in (2), ⑧ indicates that in the next generation cycle of the forwarding table, the first forwarding device can acquire and send probe messages. ⑨ indicates that the first forwarding device can also acquire response messages from probe messages from the second forwarding device, and calculate the RTT based on the sending time of the probe message and the receiving time of the response message to generate the second forwarding table, which is to update the second forwarding table used in ⑦. ⑩ indicates that at the same time as ⑨, the first forwarding device can use the first forwarding table generated in ⑥ to forward the received data packets to be processed to the second forwarding device. Among them, the probes used in ⑤ and ⑧ can be generated in different probe cycles.

[0113] In this embodiment, the setting of multiple forwarding tables allows the first forwarding device to still use other forwarding tables to forward data packets received during the generation of a forwarding table, thereby improving the blocking of data packets caused by the generation of forwarding tables.

[0114] When the first forwarding device generates a forwarding table based on probe messages, optionally, it can generate and use multiple forwarding tables alternately based on a probe rule table. Optionally, the decision center in the communication network can distribute the probe rule table to the first forwarding device. The first forwarding device can sequentially read the records in the probe rule table at different generation cycles of the forwarding table and determine whether to regenerate the forwarding table and which forwarding table to regenerate based on the content of the records.

[0115] A record in the probe rule table contains three fields: table identifier, packet type, and action. The table identifier uniquely identifies the forwarding table; the packet type can include probe packets (Request) and their response packets (Reply); the action can include clearing the forwarding table (Set) and regenerating the cleared forwarding table (Update). Optionally, the data in the probe rule table can be stored in key-value pairs, with the table identifier and packet type stored as keys and the action as value.

[0116] Assuming that the first forwarding device may include a first forwarding table and a second forwarding table locally, Table 2 below is an illustrative detection rule table provided by an embodiment of the present invention, and the table identifiers of the two tables are represented by tab le0 and tab le1, respectively.

[0117] Table 2

[0118] Index Packet Type Action table0 Request Set table0 table0 Reply Update table0 table1 Request Set table1 table1 Reply Update table1

[0119] When the first forwarding device reaches the current generation cycle of the forwarding table, it reads the first record in Table 2. This record indicates that if the first forwarding device receives a probe message, it will clear the first forwarding table. Next, the first forwarding device can also read the second record in Table 2. This record indicates that if the first forwarding device receives a response message, it will regenerate the first forwarding table. The specific generation process can be found in the relevant descriptions in the above embodiments. At the next generation cycle of the forwarding table, the first forwarding device can sequentially read the last two records in Table 2 to clear and regenerate the second forwarding table.

[0120] Alternatively, the detection rule table can also be schematically represented as shown in Table 3 below.

[0121] Table 3

[0122] Index Packet Type Action table0 Request Set table0 table0 Reply Update table0 table0 Request Set table0 table0 Reply Update table0 table1 Request Set table1 table1 Reply Update table1

[0123] When the first forwarding device reaches the current generation cycle of the forwarding table, it reads the first record in Table 3 to clear the first forwarding table upon receiving a probe message. Next, the first forwarding device can read the second record in Table 3 to regenerate the first forwarding table upon receiving a response message. At the next generation cycle of the forwarding table, the first forwarding device can sequentially read the third and fourth records in Table 3 to clear and regenerate the first forwarding table again. At yet another generation cycle of the forwarding table, the first forwarding device can sequentially read the fifth and sixth records in Table 3 to clear and regenerate the second forwarding table.

[0124] In this embodiment, according to the contents recorded in the detection rule table, the first forwarding device can generate and use multiple forwarding tables alternately, and can also continuously update any data table in multiple forwarding tables.

[0125] The above Figure 1 The embodiment shown in Figure 6 has described the message processing process from a methodological perspective. Based on this, the above message processing process can also be explained from a system perspective.

[0126] Figure 7 This invention provides a message processing system. For example... Figure 7 As shown, the system may include: a first forwarding device and a second forwarding device.

[0127] The first forwarding device can obtain the RTT (Round-Trip Time) between its alternative ports and the second forwarding device, and select a target port from the alternative ports based on this RTT. The transmission links mapped to the selected target ports are all available and have low latency. Finally, the first forwarding device can generate a forwarding table based on the link information including the target port. When the first forwarding device receives a data packet to be processed, it can use this forwarding table to forward the packet to the second forwarding device.

[0128] In this embodiment, the RTT (Round-Trip Time) between the candidate ports in the first forwarding device and the second forwarding device is obtained. Then, based on this RTT, an available target port in the first forwarding device is selected. Finally, a forwarding table in the first forwarding device is generated based on the transmission link information including the target port. The first forwarding device can use this forwarding table to forward the data packets to be processed to the second forwarding device.

[0129] As can be seen, the above process selects ports and generates a forwarding table based on round-trip time (RTT). Since ports with low RTTs are selected, the transmission links chosen from the forwarding table also have low latency, thus ensuring efficient data transmission. Furthermore, since obtaining the RTT means that the transmission link between the port and the second forwarding device is not faulty, the forwarding table generation process actually includes a link fault detection process. Therefore, even if the transmission link between the first and second forwarding devices fails, the faulty transmission link can be filtered out during the RTT-based forwarding table generation process. This ensures that all transmission links in the forwarding table are usable and will not affect the normal forwarding of packets.

[0130] In addition, the contents not described in detail in this embodiment and the technical effects that can be achieved can be referred to the relevant descriptions in the embodiment shown in Figure 1, and will not be repeated here.

[0131] Optionally, the process of generating the forwarding table described above can be specifically executed by a programmable network chip configured in the first forwarding device.

[0132] Optionally, the first and second forwarding devices provided above can be devices provided by the service provider. Therefore, by using the method and system provided by the present invention, the service provider can have the ability to select low-latency transmission links in real time.

[0133] Optionally, the first forwarding device may also have at least one interface, in which case the interface, port group, alternative ports, and target ports may have different relationships, and the target port may also have different selection methods depending on the different relationships. For details, please refer to the above. Figures 3a-4 The relevant descriptions in the illustrated embodiments will not be repeated here.

[0134] Figure 8A schematic diagram of another message processing structure provided by an embodiment of the present invention. (See diagram below.) Figure 8 As shown, in Figure 7 Based on the system shown, the system may also include a decision center.

[0135] The decision center can determine the target latency range based on the RTT (Round-Trip Time) between the candidate ports obtained by the first forwarding device and the second forwarding device. This target latency range can be distributed to both the first and second forwarding devices. The first forwarding device can then select a target port based on this target latency range.

[0136] When the RTT is determined using probe messages, and this target delay interval corresponds to the current probe cycle, the second forwarding device can determine whether to send a response message to the first forwarding device when the next probe cycle arrives, based on this target delay interval.

[0137] Optionally, the process of determining the target latency interval described above can be specifically determined by the decision component in the decision center, and the specific method for determining the target latency interval can be found above. Figure 4 The descriptions in the illustrated embodiments will not be repeated here.

[0138] Optionally, the decision center may also include a probing component. Specifically, the probing component may include a message transceiver subcomponent for sending probing messages and receiving response messages from the second forwarding device. These probing and response messages are used to enable the first forwarding device to obtain RTT (Round-Trip Time).

[0139] Optionally, the detection component may further include a driver program for sending response rule tables and detection rule tables to the first and second forwarding devices.

[0140] Optionally, the decision center may also include a clock synchronization server, and the probe component may further include a synchronization sub-component. The clock synchronization server can then send its own reference clock to the synchronization sub-component in the probe component. The synchronization sub-component can forward this reference clock to a first forwarding device and a second forwarding device, enabling the first and second forwarding devices to perform clock calibration based on the reference clock.

[0141] Optionally, the first forwarding device can also generate multiple forwarding tables. These multiple forwarding tables can be generated and used alternately using a probe rule table. For details, please refer to [link to documentation]. Figure 6a and Figure 6b The relevant content in the illustrated embodiments will not be repeated here.

[0142] In this embodiment, the collaborative work of the components in the decision center, the first forwarding device, and the second forwarding device enables the generation of a forwarding table. Furthermore, regardless of whether the transmission link between the first and second forwarding devices fails, using this forwarding table ensures that the data packets to be processed are transmitted using a low-latency transmission link.

[0143] In addition, the contents not described in detail in this embodiment and the technical effects that can be achieved can be referred to the relevant descriptions in the embodiment shown in Figure 1, and will not be repeated here.

[0144] The message processing apparatus of one or more embodiments of the present invention will be described in detail below. Those skilled in the art will understand that the apparatus can be configured using commercially available hardware components through the steps taught in this solution.

[0145] Figure 9 This is a schematic diagram of a message processing device provided in an embodiment of the present invention. Figure 9 As shown, the device may include:

[0146] The acquisition module 11 is used to acquire the round-trip delay between the alternative ports in the first forwarding device and the second forwarding device.

[0147] The port selection module 12 is used to determine the target port from the candidate ports based on the round-trip time.

[0148] The generation module 13 is used to generate a forwarding table in the first forwarding device based on the transmission link information containing the target port, wherein the forwarding table is used to send the data packet to be processed to the second forwarding device, and the transmission link information in the forwarding table corresponds to the transmission link between the first forwarding device and the second forwarding device.

[0149] Optionally, the acquisition module 11, the port selection module 12, and the generation module 13 may be programmable network switching chips deployed in the first forwarding device.

[0150] Each interface in the first forwarding device has at least one set of ports, and the alternative ports include ports from the at least one set of ports of the target interface, wherein the target interface includes at least one interface in the first forwarding device.

[0151] The port selection module 12 is used to determine the target port from at least one group of ports of the target interface according to the round-trip time.

[0152] Optionally, the port selection module 12 is used to obtain the target delay interval between the first forwarding device and the second forwarding device; if the round-trip time between any port and the second forwarding device falls within the target delay interval, then the any port is determined as the target port.

[0153] Optionally, the apparatus further includes: a delay interval determination module 14, configured to determine an initial delay interval based on the round-trip delay between the alternative port and the second forwarding device; and to extract a target delay interval with a reference length from the initial delay interval based on the type of the data stream.

[0154] Optionally, the device further includes: a duration determination module 15, used to obtain the type of the data stream to which the historical data packet belongs, and the link quality of each of the different transmission links between the first forwarding device and the second forwarding device, wherein the historical data packet is transmitted between the first forwarding device and the second forwarding device using the different transmission links;

[0155] The reference length of the delay interval is determined based on the link quality.

[0156] Optionally, the acquisition module 11 is used to acquire the sending time of the probe message and the receiving time of the response message. The probe message is sent using different ports among the alternative ports, and the response message is obtained by the second forwarding device after responding to the probe message.

[0157] Based on the sending time and the receiving time, the round-trip time between the different ports and the second forwarding device is determined.

[0158] Optionally, the generation module 13 is used to generate the first forwarding table based on the transmission link information including the target port. The first forwarding device further includes a second forwarding table. The first and second forwarding tables are generated based on the probe packets in different probe cycles. The second forwarding table is used to forward the data packets to be processed generated in the current probe cycle to the second forwarding device.

[0159] The probe messages transmitted between the first forwarding device and the second forwarding device contain 5-tuple information with the same format as the 5-tuple information in the tunnel message, and the data messages transmitted between the first forwarding device and the second forwarding device include tunnel messages.

[0160] Optionally, the first forwarding table is generated based on the probe messages within the current probe cycle.

[0161] The generation module 13 is used to determine the target table identifier corresponding to the next detection cycle according to the detection rule table when the next detection cycle after the current detection cycle is reached. The forwarding table with the target table identifier includes a first forwarding table or a second forwarding table.

[0162] In response to the receipt of a probe message generated in the next probe cycle, the forwarding table with the target table identifier is cleared; in response to the receipt of a response message of the probe message, a forwarding table with the target table identifier is regenerated.

[0163] Optionally, the device further includes an encapsulation module 16, used to encapsulate the second original message using the target port, and to send the encapsulated tunnel message using the target port.

[0164] Figure 9 The device shown can perform Figure 1 The method shown in Figure 6 is described in detail in this embodiment. For parts not described in detail in this embodiment, please refer to the following: Figure 1 ~Description of the embodiment shown in Figure 6. For the execution process and technical effects of this technical solution, please refer to... Figure 1 The descriptions in the embodiments shown in Figure 6 will not be repeated here.

[0165] Furthermore, in one possible design, the message processing methods provided in the above embodiments can be applied to electronic devices. For example... Figure 10 As shown, the electronic device may include a processor 21 and a memory 22. The memory 22 is used to store data that supports the electronic device in performing the above-described actions. Figure 1 The program of the message processing method provided in the embodiment shown in Figure 6 is configured to execute the program stored in the memory 22.

[0166] The program includes one or more computer instructions, wherein the one or more computer instructions, when executed by processor 21, can achieve the above-mentioned... Figure 1 The steps in the message processing method provided in the embodiment shown in Figure 6.

[0167] Optionally, the processor 21 is also used to perform the aforementioned Figure 1 ~ All or part of the steps in the embodiment shown in Figure 6.

[0168] The structure of the electronic device may also include a communication interface 23 for the electronic device to communicate with other devices or communication systems.

[0169] Furthermore, embodiments of the present invention provide a non-transitory machine-readable storage medium for storing computer software instructions used in the aforementioned electronic device, which includes instructions for executing the above-mentioned... Figure 1 The procedure involved in the message processing method shown in Figure 6.

[0170] In addition, embodiments of the present invention provide a computer program product. This computer program product includes a computer program or instructions. When the computer program or instructions are executed by a processor, the processor is enabled to perform the above-described functions. Figure 1 The steps or functions for message processing shown in Figure 6.

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

Claims

1. A message processing method, characterized in that, Applied to the first forwarding device, including: Obtain the round-trip time between the candidate ports in the first forwarding device and the second forwarding device; Based on the round-trip time, the target port is determined from the candidate ports; A forwarding table is generated in the first forwarding device based on the transmission link information containing the target port. The forwarding table is used to send the data packets to be processed to the second forwarding device. The transmission link information in the forwarding table corresponds to the transmission link between the first forwarding device and the second forwarding device.

2. The method according to claim 1, characterized in that, Each interface in the first forwarding device has at least one set of ports, and the alternative ports include ports from the at least one set of ports of the target interface, wherein the target interface includes at least one interface in the first forwarding device; The step of determining the target port from the candidate ports based on the round-trip time includes: The target port is determined from at least one set of ports having the target interface based on the round-trip time.

3. The method according to claim 1, characterized in that, The step of determining the target port from the candidate ports based on the round-trip time includes: Obtain the target delay interval between the first forwarding device and the second forwarding device; If the round-trip time between any port of the first forwarding device and the second forwarding device falls within the target delay interval, then that port is determined as the target port.

4. The method according to claim 3, characterized in that, The method further includes: The initial delay interval is determined based on the round-trip delay between the alternative port and the second forwarding device; Based on the type of the data stream, the target delay interval with a reference length is extracted from the initial delay interval.

5. The method according to claim 4, characterized in that, The method further includes: The type of the data stream to which the historical data packets belong and the link quality of the different transmission links between the first forwarding device and the second forwarding device are obtained, wherein the historical data packets are transmitted between the first forwarding device and the second forwarding device using the different transmission links; The reference length of the target delay interval is determined based on the link quality.

6. The method according to claim 1, characterized in that, The process of obtaining the round-trip time between the candidate ports in the first forwarding device and the second forwarding device includes: The sending time of the probe message and the receiving time of the response message are obtained. The probe message is sent using different ports among the alternative ports, and the response message is obtained by the second forwarding device after responding to the probe message. Based on the sending time and the receiving time, the round-trip time between the different ports and the second forwarding device is determined.

7. The method according to claim 6, characterized in that, The probe message transmitted between the first forwarding device and the second forwarding device contains quintuple information with the same format as the quintuple information in the tunnel message.

8. The method according to claim 6, characterized in that, The step of generating a forwarding table in the first forwarding device based on the transmission link information including the target port includes: A first forwarding table is generated in the first forwarding device based on the transmission link information containing the target port. The first forwarding device also includes a second forwarding table. The first and second forwarding tables are generated based on the probe packets in different probe cycles. The second forwarding table is used to forward the data packets to be processed generated in the current probe cycle to the second forwarding device.

9. The method according to claim 8, characterized in that, The first forwarding table is generated based on the probe messages within the current probe cycle; after generating the first forwarding table, the method further includes: When the next detection cycle is reached after the current detection cycle, the target table identifier corresponding to the next detection cycle is determined according to the detection rule table. The forwarding table with the target table identifier includes a first forwarding table or a second forwarding table. In response to the receipt of a probe message generated in the next probe cycle, the forwarding table with the target table identifier is cleared; In response to the receipt of the response message of the probe message, a forwarding table with the target table identifier is regenerated.

10. The method according to claim 1, characterized in that, The data packets transmitted between the first forwarding device and the second forwarding device include tunnel packets; The step of forwarding the data packet to be processed to the second forwarding device using the forwarding table includes: The second original message is encapsulated using the target port; The encapsulated tunnel message is sent using the target port.

11. The method according to any one of claims 1 to 9, characterized in that, The method is applied to a programmable network switching chip in the first forwarding device.

12. A message processing system, characterized in that, include: First forwarding device and second forwarding device; The first forwarding device is used to obtain the round-trip delay between the alternative ports in the first forwarding device and the second forwarding device respectively; Based on the round-trip time, a target port is determined from the candidate ports; a forwarding table in the first forwarding device is generated based on the link information containing the target port; The second forwarding device is used to receive the data packets to be processed sent by the first forwarding device using the forwarding table.

13. The system according to claim 12, characterized in that, The first forwarding device includes: a programmable network switching chip, configured to determine a target port from the candidate ports based on the round-trip time; and generate a forwarding table in the first forwarding device based on link information containing the target port.

14. The system according to claim 12, characterized in that, Each interface in the first forwarding device has at least one set of ports, and the alternative ports include ports from the at least one set of ports of the target interface, wherein the target interface includes at least one interface in the first forwarding device; The first forwarding device is configured to determine the target port from at least one set of ports of the target interface based on the round-trip time.

15. The system according to claim 12, characterized in that, The system further includes: a decision center, configured to determine a target latency interval between the first forwarding device and the second forwarding device based on the round-trip time between the alternative ports and the second forwarding device; and to send the target latency interval to the first forwarding device; The first forwarding device is configured to determine any port as the target port if the round-trip time between any port of the first forwarding device and the second forwarding device falls within the target delay interval.

16. The system according to claim 15, characterized in that, The decision center includes a decision component for obtaining the type of the data stream to which the historical data packets belong and the link quality of the different transmission links between the first forwarding device and the second forwarding device, wherein the historical data packets are transmitted between the first forwarding device and the second forwarding device using the different transmission links; The reference length of the delay interval is determined based on the link quality. The target delay interval with the reference length is determined based on the round-trip delay between the alternative ports and the second forwarding device, and the type of the data stream.

17. The system according to claim 15, characterized in that, The decision center includes: a detection component, used to send a detection message and a response message to the detection message to the first forwarding device; The first forwarding device is configured to forward the probe message to the second forwarding device via different ports among the alternative ports; and to determine the round-trip time between the different ports and the second forwarding device based on the sending time of the probe message and the receiving time of the response message. The second forwarding device is configured to respond to the probe message to obtain the response message; and send the response message to the probe component.

18. The system according to claim 17, characterized in that, The target latency interval corresponds to the current detection period, and the historical latency interval corresponds to the historical detection periods preceding the current detection period. The detection component is used to send a response rule table to the second forwarding device; The second forwarding device is configured to query the historical delay interval in the response rule table in response to the reception of the probe packet within the current probe period; Determine the difference between the sending time of the probe message and the receiving time of the probe message by the second forwarding device within the current detection period; If the time difference exceeds the historical delay interval, the probe message will not be responded to.

19. The system according to claim 17, characterized in that, The system also includes a clock synchronization server for sending a reference clock to the detection component; The detection component is used to forward the reference clock to the first forwarding device and the second forwarding device, so that the first forwarding device and the second forwarding device can perform clock calibration according to the reference clock.

20. A repeater device, characterized in that, include: A memory and a processor; wherein the memory stores executable code, and when the executable code is executed by the processor, the processor performs the message processing method as described in any one of claims 1 to 10.

21. A non-transitory machine-readable storage medium, characterized in that, The non-transitory machine-readable storage medium stores executable code that, when executed by a processor of an electronic device, causes the processor to perform the message processing method as described in any one of claims 1 to 11.

22. A computer program product, characterized in that, The computer program product includes a computer program or instructions that enable the computer program or instructions to perform the steps of the message processing method according to any one of claims 1 to 11.