Message transmission method and apparatus

By using the transport layer connection sharing mechanism of the universal bus protocol in the data center, the problem of too many RC connections in high-performance data centers is solved, saving resources and improving transmission efficiency.

WO2024221927A1PCT designated stage expired Publication Date: 2024-10-31HUAWEI TECH CO LTD
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2023/136178
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-04-28
Filing Date
2023-12-04
Publication Date
2024-10-31

AI Technical Summary

Technical Problem

In high-performance data centers, in the RDMA-based reliable connection (RC) mode, the larger the network scale, the greater the number of connections required, resulting in increased resource consumption and making it difficult to effectively reduce the number of RC connections.

Method used

By establishing a transport layer connection in the Universal Bus Protocol (UB) between the transport layer of the first device and the transport layer of the second device, different applications are allowed to share the same transport layer connection, avoiding the establishment of independent connections for each application, This reduces the number of connections and ensures transmission reliability and efficiency through load balancing and retransmission mechanisms.

Benefits of technology

It effectively reduces the number of RC connections, saves resource consumption, improves transmission efficiency and reliability, reduces the cost of connection establishment and maintenance, and improves network performance and utilization.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2023136178_31102024_PF_FP_ABST
    Figure CN2023136178_31102024_PF_FP_ABST
Patent Text Reader

Abstract

The present application provides a message transmission method, which is applied to a first device, the first device comprising a transmission layer and a transaction layer. The method comprises: the first device receiving a first-application message to be sent to a second device; the first device determining whether a transmission layer TP connection has been established between the transmission layer of the first device and the transmission layer of the second device; when at least one TP connection has been established between the transmission layer of the first device and the transmission layer of the second device, the first device determining that the at least one TP connection is used for transmitting the message of the first application, wherein the at least one TP connection is a TP connection established by the first device in order to transmit the message of a second application. The message transmission method allows messages of different applications to be transmitted via the same TP connection, without needing to establish a reliable connection for each application, thereby reducing the resource overhead required for establishing connections.
Need to check novelty before this filing date? Find Prior Art

Description

Message transmission method and device

[0001] This application claims priority to the Chinese patent application filed with the China Patent Office on April 28, 2023, with application number 202310483155.4 and application name “Method and Apparatus for Message Transmission”, the entire contents of which are incorporated by reference into this application. Technical Field

[0002] The embodiments of the present application relate to the field of computer technology, and in particular to a method and apparatus for message transmission. Background Art

[0003] In the application scenarios of cross-network communication between communication devices, the network requirements are reflected in two key indicators: high throughput and low latency. To achieve high throughput and low latency, the industry generally adopts Remote Direct Memory Access (RDMA) technology to replace traditional Transmission Control Protocol (TCP) technology to reduce latency and lower the occupancy rate of the central processing unit (CPU) in the data center.

[0004] Currently, InfiniBand (IB) and RDMA over Converged Ethernet (RoCE), the industry's leading RDMA technologies, are widely used in high-performance data center interconnects. IB and RoCE are network protocols designed for RDMA and support Reliable Connect (RC) mode. In RC mode, messages arrive in order and are delivered reliably. However, in RC mode, larger networks require more RC connections, leading to greater resource consumption. Therefore, reducing the number of RC connections is a pressing issue.

[0005] Summary of the Invention

[0006] An embodiment of the present application provides a method for message transmission, which is applied to a first device, in which messages of different applications (such as a first application and a second application) in the first device can share a connection for transmission, in order to achieve the purpose of reducing the number of connections.

[0007] In a first aspect, a method for message transmission is provided, which is applied to a first device. The method can be executed by the first device, or by a circuit configured in the first device, which is not limited in this application. For convenience, the following description uses the first device as an example. The first device includes a transaction layer and a transport layer. The message transmission method includes:

[0008] The transport layer of the first device receives a message from the transaction layer of the first device, where the message is a message of a first application to be sent to the second device; when at least one first transport layer TP connection has been established between the transport layer of the first device and the transport layer of the second device, the transport layer of the first device sends first indication information to the transaction layer of the first device, where the first indication information is used to indicate that the at least one first TP connection is used to transmit the message of the first application; the transport layer of the first device sends the message of the first application to the transport layer of the second device through the at least one first TP connection, where the at least one first TP connection is a TP connection used by the transport layer of the first device to transmit the message of the second application.

[0009] Based on the above technical solution, after the transport layer of the first device receives a message from the first application to be sent to the second device, it determines whether a transport layer connection has been established between the transport layer of the first device and the transport layer of the second device. If a transport layer connection has been established, the message of the first application can be sent to the transport layer of the second device through the established transport layer connection, without the need to re-establish a connection for the message of the first application. The established transport layer connection is a connection established by the transport layer of the first device for the message of the second application. In this message transmission method, different applications can share the transport layer connection, without the need to establish a different connection for each application, thereby reducing the number of connections and saving the resources required to establish connections.

[0010] In combination with the first aspect, in certain implementations of the first aspect, when a TP connection is not established between the transport layer of the first device and the transport layer of the second device, the method further includes: the transport layer of the first device obtains the Internet Protocol IP address information of the second device; the transport layer of the first device establishes at least one second TP connection between the transport layer of the first device and the transport layer of the second device based on the IP address information of the second device, and the at least one second TP connection is used to transmit the message of the first application.

[0011] Based on the above technical solution, after the transport layer of the first device receives a message from the first application to be sent to the second device, if it is determined that a transport layer connection has not been established between the transport layer of the first device and the transport layer of the second device, the transport layer of the first device can obtain the IP address information of the second device, and based on the obtained IP address information and its own timely establishment of the transport layer connection required for transmitting the message, thereby ensuring the timeliness of message transmission. It should be noted that after at least one second TP connection is established between the transport layer of the first device and the transport layer of the second device, if the transport layer of the first device receives a message from a third application to be sent to the second device, the message of the third application can be transmitted through the at least one second TP connection, without establishing a different connection for the third application, thereby reducing the number of connections and saving the resources required to establish a connection.

[0012] In combination with the first aspect, in certain implementations of the first aspect, the transport layer of the first device sends the message of the first application to the transport layer of the second device through the at least one first TP connection, including: the transport layer of the first device sends the message of the first application to the transport layer of the second device through the TP connection with the lightest load among the at least one first TP connection.

[0013] Based on the above technical solution, the transport layer of the first device can select the TP with the lightest load to connect and transmit the message, thereby achieving load balancing.

[0014] In combination with the first aspect, in some implementations of the first aspect, the method also includes: the transport layer of the first device receives a response message from the transport layer of the second device, and the response message is used to indicate whether the message of the first application is successfully executed by the transaction layer of the second device.

[0015] Based on the above technical solution, the second device can send a response message to the transport layer of the first device through the transport layer of the second device to indicate whether the message is successfully executed by the transaction layer of the second device, and can promptly report the congestion problem caused by multiple applications sharing the transport layer connection to transmit messages.

[0016] In combination with the first aspect, in certain implementations of the first aspect, if the response message is a transaction response TAACK, indicating that the transaction layer of the second device successfully executes the message of the first application, the method also includes: the transport layer of the first device sends a completion queue entry CQE to the transaction layer of the first device, and the CQE is used to indicate that the message of the first application is successfully transmitted.

[0017] In combination with the first aspect, in certain implementations of the first aspect, if the first response message is a transaction negative acknowledgment TANAK, indicating that the transaction layer of the second device failed to successfully execute the message of the first application, the method also includes: the transport layer of the first device sends the TANAK to the transaction layer of the first device; the transport layer of the first device receives the message of the first application from the transaction layer of the first device, and re-sends the message of the first application to the transport layer of the second device.

[0018] Based on the above technical solution, if the transaction layer of the second device fails to successfully receive the message of the first application, the transport layer of the first device can retransmit the message of the first application to achieve reliable transmission.

[0019] In combination with the first aspect, in certain implementations of the first aspect, the transport layer of the first device receives a message from the transaction layer of the first device, including: the transport layer of the first device receives a send queue entry SQE from the transaction layer of the first device, the destination address of the SQE is the address of the second device, and the SQE carries the message of the first application sent to the second device.

[0020] In combination with the first aspect, in some implementations of the first aspect, the transport layer of the first device receives the SQE from the transaction layer of the first device, including: the transport layer of the first device receives the SQE from at least one sending interface of the first device.

[0021] In combination with the first aspect, in certain implementations of the first aspect, before the transport layer of the first device sends the message of the first application to the transport layer of the second device through the at least one first TP connection, the method also includes: the transport layer of the first device determines the at least one first TP connection based on the destination entity identifier DEID carried in the SQE.

[0022] In a second aspect, a device for message transmission is provided, which includes: a storage module for storing programs; a processing module for executing the programs stored in the storage module. When the program stored in the storage module is executed, the processing module is used to execute the method provided in the first aspect above.

[0023] In a third aspect, a computer-readable storage medium is provided, which stores program code for execution by a device, wherein the program code includes code for executing the method provided in the first aspect.

[0024] In a fourth aspect, a computer program product comprising instructions is provided, which, when run on a computer, enables the computer to execute the method provided in the first aspect.

[0025] In a fifth aspect, a chip is provided, which includes a processing module and a communication interface. The processing module reads instructions stored in a memory through the communication interface to execute the method provided in the first aspect.

[0026] Optionally, as an implementation method, the chip may further include a storage module, in which instructions are stored. The processing module is used to execute the instructions stored on the storage module. When the instructions are executed, the processing module is used to execute the method provided in the first aspect above.

[0027] In a sixth aspect, a chip is provided, comprising a first device for executing the method provided in the first aspect and a second device for receiving a message.

[0028] In a seventh aspect, a computer device is provided, the computer device including the chip according to the sixth aspect. For example, the computer device includes but is not limited to a switch or a server in a data center.

[0029] In an eighth aspect, a terminal device is provided, the terminal device including the chip described in the sixth aspect. For example, the terminal device includes but is not limited to mobile phones, vehicles, and other terminals.

[0030] In a ninth aspect, a system for message transmission is provided, the system comprising a first device for executing the method provided in the first aspect and a second device for receiving messages. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] FIG1 is a schematic diagram of the structure of a computer device provided in an embodiment of the present application.

[0032] FIG2 is a schematic diagram of a data center provided in an embodiment of the present application.

[0033] FIG3 is a schematic diagram of a universal bus protocol message format provided in an embodiment of the present application.

[0034] FIG4 is a schematic structural diagram of a host provided in an embodiment of the present application.

[0035] FIG5 is a schematic flowchart of a message transmission method provided in the present application.

[0036] FIG6 is a schematic diagram of establishing a TPG between the transport layers of two devices provided in this application.

[0037] FIG7 is a schematic diagram of multiple SQEs writing into a JFS provided by this application.

[0038] FIG8 is a schematic diagram of load balancing provided by this application.

[0039] FIG9 is a schematic flowchart of another message transmission method provided in the present application.

[0040] FIG10 shows a schematic structural diagram of a message transmission apparatus 1000 provided in an embodiment of the present application.

[0041] FIG11 shows a schematic structural diagram of a chip system 1100 provided in an embodiment of the present application.

[0042] FIG12 schematically shows a conceptual partial view of a computer program product provided by an embodiment of the present application. DETAILED DESCRIPTION

[0043] The technical solutions in the embodiments of the present application will be described below with reference to the accompanying drawings.

[0044] In many applications, the computer devices that deploy the applications need to access data to implement the application's functionality. For example, a computer device that deploys a database application needs to perform extensive data access to update the database or respond to data query requests and return query results to the user. Another example is a computer device that deploys a web application that needs to perform extensive data access to return requested content to the user.

[0045] A computer device can be a server or a terminal. Terminals include, but are not limited to, user devices such as desktop computers, laptops, and smartphones. For ease of understanding, the following describes the structure of a computer device.

[0046] 1 , the computer device includes a processor 101, an input / output device (IO device) 102, a memory 103, a cache 104, a memory management unit (MMU) 105, an input / output memory management unit (IOMMU) 106, an external memory 107, and a bus 108.

[0047] The processor 101 includes at least one core. This core is also called a computing engine. Each core can independently execute tasks. When the processor 101 includes multiple cores, tasks from applications can be divided, allowing the application to fully utilize multiple cores and execute more tasks within a specific time period. In this embodiment, the processor 101 can be a main processor, such as a central processing unit (CPU).

[0048] Input / output devices 102 refer to hardware devices capable of inputting and / or outputting data. Input / output devices 102 can be categorized as input devices and output devices. Input devices may include devices such as a mouse, keyboard, joystick, stylus, and microphone, while output devices may include devices such as a display and speakers.

[0049] Memory 103, also known as internal memory or main memory, is used to temporarily store computational data in processor 101. Furthermore, memory 103 is also used to temporarily store data exchanged with external memory 107. Memory 103 can typically be implemented using storage media such as dynamic random access memory (DRAM) or static random access memory (SRAM).

[0050] Cache 104 (in this embodiment, processor cache, such as a CPU cache) is used to reduce the average time required for processor 101 to access memory 103. Referring to Figure 1 , in the pyramid storage system, cache 104 is located in the second layer from the top, just below the processor 101 registers (not shown in Figure 1 ) and above memory 103 (which is located in the third layer from the top). Typically, the capacity of cache 104 is much smaller than that of memory 103, but its access speed can approach the frequency of processor 101.

[0051] The memory management unit 105 is a computer hardware component for processing data access requests. Specifically, the memory management unit 105 is configured to map virtual addresses (VAs) in data access requests. The memory management unit 105 can intercept data access requests issued by the core of the processor 101 and map (or translate) the virtual addresses in the data access requests into physical addresses (PAs) to facilitate access to the memory 103 based on the PAs.

[0052] The I / O memory management unit 106 is essentially a memory management unit. Similar to how the memory management unit 105 maps virtual addresses visible to the processor 101 to physical addresses, the I / O memory management unit 106 is used to map virtual addresses (also called device addresses or IO addresses) visible to the input and output devices 102 to physical addresses.

[0053] The external memory 107 is also called external memory or auxiliary memory, and is usually used to persist data. For example, the external memory 107 can persist the calculation data in the storage processor 101. Even if the power supply is abnormal, the data written to the external memory 107 can still be saved, avoiding data loss. In specific implementation, the external memory 107 includes at least one non-volatile memory 1071. When the external memory includes multiple non-volatile memories, these multiple non-volatile memories can be of the same type or different types. For example, in the example of Figure 1, the external memory 107 can include two types of non-volatile memories, such as storage class memory (SCM) and solid state drive (SSD).

[0054] Bus 108 is used to connect the various functional components of a computer device. Bus 108 is a common communication trunk for transmitting information between the various functional components of a computer device. Bus 108 can be a transmission line formed by wires. Depending on the connection objects, bus 108 can be divided into internal buses and external buses.

[0055] The internal bus uses an internal bus protocol to transmit information. The internal bus protocol includes a bus protocol for accessing the memory space of the computer device. The external bus uses an external bus protocol to transmit information. The external bus protocol includes a bus protocol for accessing the external memory space of the computer device. The memory space refers to the address space of the internal memory, and the external memory space refers to the address space of the external memory.

[0056] In some embodiments, the internal bus protocol includes, but is not limited to, the Peripheral Component Interconnect (PCI) bus, the Peripheral Component Interconnect (PCI Express) protocol, the Intel™ Quick Path Interconnect (QPI) protocol, and the Unified Bus (UB) protocol. The external bus protocol includes, but is not limited to, the Small Computer System Interface (SCSI) protocol or the Serial Attached SCSI (SAS) protocol.

[0057] It should be noted that the computer device shown in Figure 1 is illustrated by taking the external memory 107 as the remote external memory. As shown in Figure 1, the external memory 107 includes a network card 1072. The network card 1072 can be, for example, a smart NIC network interface card (i.e., a network adapter card). The external memory 107 is connected to the network through the network card 1072, and is then connected to other components of the computer device 101 through the network. The network can be a wired communication network, such as an optical fiber communication network, or a wireless communication network, such as a wireless local area network (WLAN) or a fifth generation (5G) mobile communication network.

[0058] In some possible implementations, the external memory 107 of the computer device may also be local external memory, and other components of the computer device, such as the processor 101, may be connected to the local external memory via the bus 108. In other possible implementations, the computer device may include both remote external memory and local external memory. In addition, the embodiments of the present application may be applicable to centralized storage or distributed storage scenarios, which are not limited in this embodiment.

[0059] This application mainly relates to data transmission across networks, and is illustratively applied to a server cluster that requires cross-network communication, such as a data center as shown in Figure 2. The internal structure of the switch or server shown in Figure 2 is the same as that shown in Figure 1 above.

[0060] In addition, the devices involved in the transmission of messages in this application support the Unified Bus (UB) protocol, and a transport layer connection can be established between the devices. The UB protocol can also be called Lingqu Bus or Unified Bus, a bus protocol standard. This application does not limit the name of the UB protocol.

[0061] The Universal Bus Protocol breaks down existing protocol barriers, eliminating unnecessary intermediate conversion overhead and achieving extremely low latency. The Universal Bus Protocol defines independent transaction and transport layers. Transport layers are connected, but transaction layers are not. All transactions within a host are carried on a single transport layer. The Universal Bus Protocol consists of two layers: the transport layer is responsible for retransmitting lost packets and ensuring reliable transmission, while the transaction layer handles its own distinct transactions. The transport layer receives packets from the network, strips off the transport layer header, and forwards them to the transaction layer.

[0062] The universal bus protocol message format is shown in Figure 3. Specifically, the field definitions in the universal bus protocol message format are shown in Table 1 below:

[0063] Table 1

[0064] Specifically, the interface between the transaction layer of the universal bus protocol and the application is called Jetty. Application messages can be sent to any destination through a Jetty, and messages can also be received from any source through a Jetty. A Jetty that can only send is defined as Jetty For Send (JFS), while a Jetty that can only receive is defined as Jetty For Receive (JFR).

[0065] Figure 4 is a structural diagram of a host provided in an embodiment of the present application. The host (such as host A and host B shown in Figure 4) can be applied to the application scenario of cross-network communication shown in Figure 2. As shown in Figure 4, host A includes several virtual machines (Virtual Machine, VM), and a VM includes several processes and several remote command (Remote Command, RC) tables for receiving remote Read commands. A process includes several communication interfaces (such as Jetty shown in Figure 4), communication interfaces that can only send (such as JFS shown in Figure 4), and communication interfaces that can only send (such as JFR shown in Figure 4). Among them, Jetty is bidirectional and can both receive and send; JFS is unidirectional and can only send; JFR is unidirectional and can only receive.

[0066] Jetty, JFS, JFR, and RC each have their own context (CXT). Jetty, JFS, JFR, and RC belong to the transaction layer. Several transport layer (TP) connections are established between two hosts (e.g., TP connection #0 to TP connection #7 shown in Figure 4, totaling eight TP connections). These eight TP connections form a transport layer group (TPG), through which all traffic between the two hosts passes. These eight TP connections can be distributed across different physical ports, with traffic evenly distributed across the eight TP connections, achieving multi-port multipathing. TP connections and TPGs belong to the transport layer. Packets may be lost across the network between two hosts. TP connections are responsible for retransmitting lost packets to ensure end-to-end reliability. TP connections are responsible for end-to-end congestion control.

[0067] In Figure 4, host B contains several VMs and several processes. The VMs and SSD controller belong to the transaction layer.

[0068] The above text briefly introduces the scenarios in which the present application can be applied and the internal logic units of the host involved in combination with Figures 1 to 4. In order to facilitate understanding of the embodiments of the present application, some basic concepts involved in the present application are briefly explained.

[0069] 1. Packet Sequence Number (PSN): When the sending transport layer sends a packet, it assigns a PSN to each packet, which increases packet by packet. Upon receiving a packet, the receiving transport layer returns a TPACK (carrying the PSN of the received packet), notifying the sending transport layer that the packet has been received correctly. If the receiving transport layer receives a packet but finds that a packet with a smaller PSN than the one it received has not been received, it determines that the packet with the smaller PSN has been lost in the network and returns a TPSACK (carrying the PSN of the received packet and the PSN of the lost packet). The sending transport layer receives the TPSACK and retransmits the lost packet.

[0070] 2. Segment sequence number (SSN): Transaction layer messages can be quite large, for example, 16MB. In the UB protocol, multiple transaction layers share a transport layer. To prevent a single transaction layer message from occupying the transport layer connection for a long time, the transaction layer segments the message into multiple segments before sending it to the transport layer. For example, each segment is 64KB, and each transaction layer sends only one segment to the transport layer at a time.

[0071] 3. Transaction ACK (TAACK): After the receiving side receives a segment (a segment is split into multiple packets at the transport layer) and executes it correctly (for example, correctly reads and writes memory), it returns TAACK to inform the sending side's transaction layer that the segment has been correctly executed, or the receiving side successfully receives the message from the sending side and returns TAACK to inform the sending side's transaction layer that the message has been successfully received.

[0072] 4. Transaction No OK ACK (TANAK): If the receiving side receives a segment and an execution error occurs (for example, a page fault occurs when reading or writing memory), it returns TANAK to inform the sending side's transaction layer to retransmit the segment. Alternatively, if the receiving side fails to successfully receive the message from the sending side, it returns TANAK to inform the sending side's transaction layer to retransmit the message.

[0073] 5. Remote Direct Memory Access (RDMA): This technology transfers data directly to a computer's storage area over a network, rapidly moving data from one system to a remote system's memory without requiring intervention from the operating systems or kernels of either computer. RDMA eliminates the overhead of external memory copies and context switches, freeing up memory bandwidth and CPU cycles for improved application performance.

[0074] 6. Reliable Connect (RC): A Queue Pair (QP) is connected to only one other QP. Messages are reliably transmitted from one QP's send queue to the other QP's receive queue. Packets are delivered in order. RC connections are very similar to TCP connections.

[0075] Specifically, before establishing an RDMA connection, a context is first created. A protection domain (PD) is created to associate a queue pair (QP) with a memory region (MR). Both parties then create a QP. Each QP contains two first-in-first-out (FIFO) work queues: a send queue (SQ) for sending requests and a receive queue (RQ) for receiving requests. Each of these queues is associated with a completion queue (CQ). To allow the RDMA network card to access memory, the memory must be registered. This type of memory, which is freely accessible to both parties, is called RDMA-accessible memory, and the remote address is the starting virtual address of this memory region. After creating the MR, an 8-byte key is generated. Both parties must exchange their keys and the virtual addresses of the registered memory. Each MR contains its own key (lkey) and the remote memory key (rkey). The rkey must be used to access the remote registered memory. Under normal circumstances, it takes about 10 seconds to create 4096 connections through RDMA_CM, the native communication library of RDMA. On average, it takes between 1ms and 5ms to create each connection. When the RDMA payload is 32 bytes, the delay is about 4us each time. Therefore, in order to establish a connection, it is necessary to delay the sending of hundreds of network data packets.

[0076] 7. Page fault: A page fault occurs when reading or writing memory using a virtual address.

[0077] 8. A process is a computer program's execution of a specific set of data. It is the basic unit of system resource allocation and the foundation of operating system architecture. In early process-oriented computer architectures, a process was the primary execution entity of a program; in modern thread-oriented computer architectures, a process is a container for threads. A program is a description of instructions, data, and their organization; a process is the entity that executes the program. Hereinafter, a process may also be referred to as an application (APP).

[0078] In addition, in order to facilitate understanding of the embodiments of the present application, the following explanations are made.

[0079] First, "at least one" shown in the present application refers to one or more, and "a plurality of" refers to two or more. In addition, in the embodiments of the present application, "first", "second" and various digital numbers (for example, "#1", "#2", etc.) are only for the convenience of description and are not used to limit the scope of the embodiments of the present application. The size of the sequence number of each process below does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application. It should be understood that the objects described in this way can be interchanged under appropriate circumstances so as to be able to describe solutions other than the embodiments of the present application. In addition, in the embodiments of the present application, words such as "S310" are only for the convenience of description and are not used to limit the order of execution of steps.

[0080] Second, in the embodiments of this application, words such as "exemplary" or "for example" are used to indicate examples, illustrations, or explanations. Any embodiment or design described in this application as "exemplary" or "for example" should not be construed as being preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary" or "for example" is intended to present the relevant concepts in a concrete manner.

[0081] Third, the term "storage" used in the embodiments of the present application may refer to storage in one or more memories. The one or more memories may be provided separately or integrated into an encoder or decoder, a processor, or a communication device. The one or more memories may also be partially provided separately and partially integrated into a decoder, a processor, or a communication device. The type of memory may be any form of storage medium, and this application is not limited thereto.

[0082] Fourth, the term “comprising” (also referred to as “includes,” “including,” “comprises,” and / or “comprising”) involved in the embodiments of the present application, when used in this specification, specifies the presence of stated features, integers, steps, operations, elements, and / or parts, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, parts, and / or groups thereof.

[0083] Fifth, the phrase “if” used in the embodiments of the present application may be interpreted as meaning “when” or “upon” or “in response to determining” or “in response to detecting.” Similarly, depending on the context, the phrase “if it is determined that…” or “if [the stated condition or event] is detected” may be interpreted as meaning “upon determining…” or “in response to determining…” or “upon detecting [the stated condition or event]” or “in response to detecting [the stated condition or event].”

[0084] Sixth, the terms used in the description of the various examples in the embodiments of the present application are intended only to describe specific examples and are not intended to be limiting. As used in the description of the various examples and in the appended claims, the number forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.

[0085] Seventh, the term "and / or" in this document simply describes an association between related objects, indicating that three possible relationships exist. For example, "A and / or B" can mean: A exists alone, A and B exist simultaneously, or B exists alone. Furthermore, the character " / " in this document generally indicates that the related objects are in an "or" relationship.

[0086] The above, combined with Figure 2, briefly introduces the scenarios in which the message transmission method provided by this application is applicable, as well as the basic concepts involved in this application. RC is introduced in the basic concepts. The larger the network scale, the more connections are required and the greater the resource consumption. For example, if there are N nodes (hosts) in the network, each node has P processes, and they are fully interconnected, then a node needs to establish N*P*P RC connections.

[0087] To address the current problem of increasing resource consumption as the number of RC connections increases in RDMA-based networking, this application proposes an RDMA-based information transmission method that reduces the number of RC connections in the network by adopting the UB protocol. The RDMA-based information transmission method provided by this application will be described in detail below with reference to the accompanying drawings.

[0088] It should be understood that the RDMA-based information transmission method provided in the embodiments of the present application can be applied to a computer system, for example, the cross-network communication system shown in FIG. 2 .

[0089] It should also be understood that the embodiments shown below do not specifically limit the specific structure of the execution subject of the method provided in the embodiments of the present application. As long as the method provided in the embodiments of the present application can be implemented by running a program that records the code of the method provided in the embodiments of the present application, it is sufficient. For example, the execution subject of the method provided in the embodiments of the present application can be a device, or a functional module in the device that can call and execute the program.

[0090] FIG5 is a schematic flow chart of a message transmission method provided by the present application. The method is applied to a scenario in which a message is transmitted between a first device and a second device, such as the scenario shown in FIG2 . In this embodiment, both the first device and the second device support a universal bus protocol, i.e., the first device includes a transaction layer and a transport layer, and the second device includes a transaction layer and a transport layer.

[0091] Specifically, the method shown in FIG5 includes the following steps:

[0092] S510: The transport layer of the first device receives a message from the transaction layer of the first device.

[0093] The message is a message of the first application to be sent to the second device.

[0094] In this embodiment, the first device and the second device can be any two computer devices in a network, and the first device and the second device can communicate across the network. For example, the first device and the second device can be the two servers shown in Figure 2, or two switches, or one server and the other switch. In this embodiment, the specific form of the first device and the second device is not limited, and they can be any computer devices that can communicate across the network.

[0095] Specifically, in this embodiment, the first device and the second device are both computer devices that support the universal bus protocol, so that the first device includes a transaction layer and a transport layer, and the second device also includes a transaction layer and a transport layer. At least one TP connection can be established between the transport layer of the first device and the transport layer of the second device, and the at least one TP connection can constitute a TPG. As shown in Figure 4, the first device can be the host A shown in Figure 4, and the second device can be the host B shown in Figure 4. The TPG established between the transport layer of the first device and the transport layer of the second device can be the TPG shown in Figure 4, which can include 8 TP connections (such as TP connection #0 to TP connection #7 shown in Figure 4, a total of 8 TP connections). All information (including data, signaling, messages, etc.) between the first device and the second device is transmitted through this TPG.

[0096] It should be understood that the establishment of a TPG between the transport layer of the first device and the transport layer of the second device is merely an example and does not limit the scope of protection of this application. A TPG can be established between the transport layers of any two computer devices in the network. For example, as shown in FIG6 , the network includes a first device, a second device #1, a second device #2, and a second device #3. The transport layer of the first device can establish a TPG with the transport layer of the second device #1, the transport layer of the second device #2, and the transport layer of the second device #3, respectively (e.g., TPG#1, TPG#2, and TPG#3 shown in FIG6 ).

[0097] Furthermore, in this embodiment, after the transport layer of the first device receives the message from the transaction layer of the first device, it determines whether at least one first TP connection has been established between the transport layer of the first device and the transport layer of the second device. The method flow shown in FIG5 further includes:

[0098] S520: The transport layer of the first device determines whether a TP connection has been established between the transport layer of the first device and the transport layer of the second device.

[0099] Mode 1: The transport layer of the first device determines that at least one first TP connection has been established between the transport layer of the first device and the transport layer of the second device.

[0100] For example, before the transport layer of the first device receives a message of the first application from the transaction layer of the first device, the transport layer of the first device receives a message of the second application from the transaction layer of the first device, and in order to transmit the message of the second application, at least one first TP connection is established between the transport layer of the second device, and the message of the second application is transmitted through the at least one first TP connection.

[0101] In the case shown in mode 1, the transport layer of the first device may notify the transaction layer of the first device through the first indication information that the message of the first application may be transmitted through at least one first TP connection.

[0102] Specifically, in the case shown in the embodiment 1, the method flow shown in FIG5 further includes:

[0103] S521: The transport layer of the first device sends first indication information to the transaction layer of the first device.

[0104] The first indication information is used to indicate that at least one first TP connection is used to transmit a message of the first application.

[0105] S522: The transport layer of the first device sends a message of the first application to the transport layer of the second device through at least one first TP connection.

[0106] As can be seen from the introduction to the universal bus protocol in the previous basic concepts, the universal bus protocol defines independent transaction layers and transport layers. There is a connection between the transport layers of two devices, but no connection between the transaction layers. All transactions within a device are carried on a single transport layer. Therefore, in this embodiment, messages from different applications can share the TP connection of the transport layer, so that the number of TP connections established between devices is far less than the number of connections that need to be established (such as RC connections established based on the IB protocol), which can reduce the number of connections between devices.

[0107] For example, there are N nodes in the network, and each node has P applications. If interconnection communication is achieved based on RC connection, one node needs to establish N*P*P RC connections; if interconnection communication is achieved based on TP connection, one node only needs to establish N TP connections.

[0108] In addition, TP connections are permanent connections and do not require dynamic disconnection and establishment, thus avoiding resource consumption caused by dynamic disconnection and establishment.

[0109] Mode 2: The transport layer of the first device determines that no TP connection is established between the transport layer of the first device and the transport layer of the second device.

[0110] For example, the message of the first application received by the transport layer of the first device is the first message that needs to be transmitted to the second device. In order to transmit the message of the first application, the transport layer of the first device needs to establish at least one second TP connection between the transport layer of the first device and the transport layer of the second device for transmitting the message of the first application.

[0111] In the case shown in mode 2, at least one second TP connection needs to be established between the transport layer of the first device and the transport layer of the second device. The method flow shown in FIG5 further includes:

[0112] S523: The transport layer of the first device obtains the IP address information of the second device.

[0113] S524 : The transport layer of the first device establishes at least one second TP connection between the transport layer of the first device and the transport layer of the second device according to the IP address information of the second device.

[0114] The at least one second TP connection is used to transmit messages of the first application.

[0115] S525: The transport layer of the first device sends a message of the first application to the transport layer of the second device through at least one second TP connection.

[0116] In the case shown in method 2, the process of establishing at least one second TP connection between the transport layer of the first device and the transport layer of the second device can be understood as the process of establishing a shared connection. After at least one second TP connection is established between the transport layer of the first device and the transport layer of the second device, if the transport layer of the first device receives a message of a third application to be sent to the second device, the message of the third application can be transmitted through the at least one second TP connection, without establishing a different connection for the third application, thereby reducing the number of connections and saving resources required to establish the connection.

[0117] Specifically, the shared connection establishment process can be understood as follows: when an application message needs to be transmitted, the URMA software stack will determine the IP address of the other device based on the target EID (Target EID), and then the transmission channel establishment service within the UMDK and the URMA software stack establishment service of the external node will negotiate with each other, exchange information such as PSN and path, and complete the establishment of the transmission channel between the IP addresses at both ends.

[0118] It should be noted that to reduce resource overhead, the URMA software stack provides multiple levels of transmission channel sharing strategies, including but not limited to:

[0119] Device-granular sharing: All applications and VMs share the transmission channel between two devices;

[0120] VM-granularity sharing: Different applications within each VM share the same transmission channel;

[0121] In-application sharing: Within an application, different Jetty instances share the same transmission channel.

[0122] Jetty exclusive: Within the application, each Jetty uses a separate shared transport channel.

[0123] This application mainly involves device-granular sharing, that is, all applications and VMs share the transmission channel between two devices. For example, in the case shown in mode 2, the establishment of a TP connection between the transport layer of the first device and the transport layer of the second device for communication information exchange includes the following possible implementation methods:

[0124] As a possible implementation method, the first device uses a service channel or an existing IP / TCP connection to exchange communication relationships, for example, to obtain Segment information or Jetty information on the second device side, which is called out-of-band exchange.

[0125] As another possible implementation, the first device uses URMA's publicly known Jetty message semantics to interact with the second device and obtain segment information or Jetty information from the second device. This is called in-band exchange. URMA's publicly known Jetty means that the second device can specify a Jetty number when creating a Jetty. The first device can obtain the publicly known Jetty number through agreement or configuration, and then use its local Jetty to interact with the publicly known Jetty on the second device.

[0126] To facilitate understanding, the following describes a process for establishing a TP connection between the transport layer of a first device and the transport layer of a second device, using a specific example:

[0127] Example 1: Establishing a TP connection between the transport layer of a first device and the transport layer of a second device includes the following steps:

[0128] Step 1: Application #1 on the first device side obtains home_seg information of application #2 on the second device side (eg, the EID of the second device). The acquisition method uses the out-of-band exchange or in-band exchange described above.

[0129] Step 2: When application #1 on the first device side calls a function (eg, calls urma_import_seg()), it falls into the kernel.

[0130] Step 3: The URMA software stack checks the EID of the second device to determine whether a TP is established between the first and second devices. If so, the TP connection number (TP Number, TPN) is directly placed in the target seg data structure.

[0131] Step 4: If no TP is established between the first device and the second device, continue with steps 5 to 9 below.

[0132] Step 5: The first device obtains the IP address of the second device based on the EID of the second device. When using a physical function (PF), the EID and IP address are identical and can be directly converted. When using a multipath device, the EID is equivalent to the host name, and multiple IP addresses can be obtained through table lookup or DNS.

[0133] Step 6: Create a link channel: Use the well-known Jetty of the first and second devices, or use the obtained IP addresses to establish a TCP socket

[0134] Step 7: The first device sends a link establishment request to the second device through the link establishment channel and negotiates the initial information of the transport layer:

[0135] Optionally, the link establishment request message includes: the TPN of the first device, the initial PSN, the IP address, the identity credentials of the first device, the link establishment policy and parameters (for example, src / dst EID), the congestion control policy and parameters, etc.

[0136] Optionally, the link establishment response message includes: TPN, IP address, etc. of the second device.

[0137] Step 8: The first device records the mapping relationship between the second device's EID and TPN, and the second device records the mapping relationship between the first device's EID and TPN. The first device returns the TPN and places it in the target seg data structure.

[0138] Step 9: Chain building completed

[0139] Optionally, if a TPG is to be created, multiple link establishment information is transmitted in a link establishment request message at one time, and multiple TP links are established in batches.

[0140] In addition, in this embodiment, in order to achieve the purpose of saving resources by sharing physical transmission channels between different VMs, the physical transmission channel is maintained in the host (Host). There is no need to establish a physical transmission channel in the VM. The VM notifies the Host link establishment service (TP Service) to complete the establishment of the physical transmission channel. Specifically, when the URMA software stack in the VM establishes a transmission channel, the UBN device is defined as supporting offloading capabilities. In this case, the URMA software stack in the VM no longer performs link establishment. The URMA software stack sends a request to establish a transmission channel to the UBN device driver. The hardware sends this request to establish a transmission channel to the URMA software stack link establishment service on the Host through the mailbox (Mailbox). A virtual transmission channel (virtual TP, vTP) is allocated for this VM, and a mapping relationship between vTP and the physical transmission channel TP or TPG is created. The vTP is then returned to the URMA software stack of the VM through the mailbox. The URMA software stack in the VM can then use vTP for communication.

[0141] It can be seen from the above-mentioned methods 1 and 2 that after the transport layer of the first device in this embodiment receives the message of the first application to be sent to the second device, if it is determined that at least one first TP connection has been established between the transport layers of the first device and the second device, the message can be sent directly to the transport layer of the second device through the at least one first TP connection. If it is determined that no connection is established between the transport layers of the first device and the second device, at least one second TP connection needs to be established for transmitting the message of the first application. For the sake of convenience of description, the following takes the transmission of the message of the first application through at least one first TP connection as an example.

[0142] Specifically, when the transaction layer of a first device needs to send a message from a first application to a second device, the message from the first application is carried by a Send Queue Entry (SQE), and the destination address of the SQE is the address of the second device. For example, the destination address of the SQE is the IP address of the second device. The IP address of the second device can be the Entity ID of a virtual machine in the second device.

[0143] It should be understood that when a TP connection is established between the transport layer of the first device and the transport layers of multiple different devices, an application of the first device can send messages to different devices. For example, an application of the first device needs to send three messages to three different devices respectively (for example, the application of the first device needs to send messages to the second device #1, the second device #2, and the second device #3 shown in Figure 6), and the three messages are carried by SQE#0, SQE#1, and SQE#2 respectively. The destination of SQE#0 is the second device #1, the destination of SQE#1 is the second device #1, and the destination of SQE#2 is the second device #1. Specifically, the application of the first device does not perceive the TP connection of the transport layer and only needs to specify the destination in the corresponding SQE.

[0144] In this embodiment, the application of the first device can write an SQE to the JFS. Alternatively, if the application of the first device needs to send different messages to different devices, multiple SQEs can be written to the same JFS. For example, as shown in Figure 7, the application of the first device writes SQE#0, SQE#1, and SQE#2, destined for second device #1, second device #2, and second device #3, respectively, to the same JFS.

[0145] Specifically, after the application of the first device writes the SQE into the JFS, the SQE can be retrieved from the JFS and sent to the transport layer of the first device. The transport layer of the first device finds the corresponding TPG based on the destination entity ID (DEID) in the SQE and sends the SQE to the corresponding TPG.

[0146] For example, SQE#0, SQE#1, and SQE#2 are written in the JFS, where the DEID in SQE#0 corresponds to TPG#1; the DEID in SQE#1 corresponds to TPG#2; and the DEID in SQE#3 corresponds to TPG#3. After receiving SQE#0, the transport layer of the first device can determine through the DEID in SQE#0 to transmit SQE#0 through the TP connection in TPG#1, and can transmit SQE#0 to the correct destination.

[0147] Optionally, when multiple SQEs are written to a JFS, the multiple SQEs can be called out of the JFS in parallel (eg, multiple TPGs call out SQEs in parallel) and sent to different devices.

[0148] Exemplarily, the transport layer of the first device sends the message of the first application to the transport layer of the second device through at least one first TP connection, including:

[0149] The transport layer of the first device sends a message of the first application to the transport layer of the second device through the TP connection with the lightest load among the at least one first TP connection.

[0150] For example, as shown in Figure 8, eight TP connections are established between the transport layer of the first device and the transport layer of the second device. Each TP connection has its own TP queue and TP context. Application A and application C of the first device each need to send a 1MB message to the second device. Application A and application C are not aware of how many TP connections are contained in the TPG. The JFS of the first device can split the 1MB message into 16 64KB segments and send one segment to the TPG at a time. The TPG selects the TP connection with the lightest load to send this segment. That is, the traffic is load balanced among multiple TP connections within the TPG, making full use of multi-port and multi-path to reduce message transmission time.

[0151] Optionally, when network packet loss occurs, the TP connection of the first device is responsible for retransmission, thereby ensuring that reliable service is provided to the application process of the first device.

[0152] Exemplarily, after the transport layer of the first device sends the SQE to the transport layer of the second device, the transport layer of the second device may feed back a response message to the transport layer of the first device to inform the first device whether the SQE was successfully transmitted. The method flow shown in FIG5 further includes:

[0153] S530: The transport layer of the second device sends a response message to the transport layer of the first device.

[0154] As one possible implementation, the response message is a TAACK, indicating that the message was successfully executed by the transaction layer of the second device. In this implementation, the transport layer of the first device sends a TAACK to the JFS of the first device. After receiving the TAACK, the JFS of the first device reports a Complete Queue Entry (CQE) to the application process, informing the application process that the SQE execution is complete.

[0155] As another possible implementation, the response message is a TANAK, indicating that the message failed to execute at the transaction layer of the second device. In this implementation, the transport layer of the first device sends a TANAK to the JFS of the first device. After receiving the TANAK, the JFS of the first device resends an SQE to the transport layer of the first device. The transport layer of the first device then resends the message of the first application to the transport layer of the second device.

[0156] In the message transmission method shown in Figure 5, a TP connection is established between the sender and receiver, and messages are transmitted through the TP connection. Compared to establishing an RC connection, this reduces the number of connections required, thereby reducing resource consumption. Furthermore, a TPG contains multiple TP connections, and applications are unaware of the number of TP connections within the TPG. The transaction layer sends transactions (such as the aforementioned SQE) to the TPG, and the transactions are evenly transmitted across multiple TP connections within the TPG, achieving multi-port multi-path, improving network utilization, and shortening transaction transmission time.

[0157] Furthermore, network congestion control is implemented based on TP connections. Different applications share TP connections, enabling packet loss retransmission and congestion control. Compared to IB, where each QP operates independently, TP-based congestion control provides a more comprehensive approach, helping to reduce network bursts and queues. Furthermore, the transaction layer and transport layer are separated. Transaction layer anomalies are retransmitted at the transaction layer, without blocking the shared transport layer.

[0158] For ease of understanding, the message transmission process between the first device and the second device is described below with reference to specific examples.

[0159] Example 2: As shown in FIG9 , the information transmission process between the first device and the second device is described using the transmission process of a Send message as an example. The transmission of the Send message includes the following steps:

[0160] S910: The application process of the first device sends a 'Send' transaction to the JFS.

[0161] S920 , the JFS of the first device sends the 'Send' transaction to the TPG, which selects the TP connection with the lightest load and encapsulates the 'Send' transaction into a TPH.

[0162] S930: The Link layer encapsulates a Link header for the 'Send' transaction to obtain a 'Send' transaction packet encapsulated based on the UB protocol, and sends the packet to the transport layer of the second device through the network.

[0163] S940, the transport layer of the second device receives the packet. If the packet verification passes, it returns TPACK (transport layer acknowledgment) to inform the transport layer of the first device that the packet has been received correctly. If it checks the PSN in the TPH and finds that the network has lost packets, it returns a transport layer selective acknowledgment (Transport Selective ACK, TPSACK) to inform the transport layer of the first device that the packet has been received correctly, but there has been packet loss, and the packet corresponding to the lost PSN needs to be retransmitted.

[0164] S950: The transport layer of the second device parses the packet and learns that the destination of the packet is a certain VM.

[0165] For example, the transport layer of the second device determines the destination of the packet by looking up the DEID table. The transport layer of the second device strips the TPH and the preceding portion of the packet and transfers the remaining portion to the VM.

[0166] At step S960, a JFR in the VM of the second device receives the packet and verifies it through the UBMMU. If the memory is written correctly, a TAACK is generated and sent to the first device. If a page fault occurs during the memory write or the JFR has no resources to receive the packet, a TANAK is generated and sent to the first device. From the perspective of the transport layer of the second device, the TAACK and TANAK are considered transactions, and the transport layer of the second device also ensures that they are delivered reliably to the first device.

[0167] The JFS of the first device receives TAACK, knowing that the transaction has been executed correctly, and generates CQE to inform the application process. If it receives TANAK, indicating that a page fault or insufficient resources occurred on the second device side, the JFS of the first device retransmits the transaction.

[0168] It should be understood that the specific examples shown in Figures 5 to 9 of the embodiments of the present application are only intended to help those skilled in the art better understand the embodiments of the present application, and do not limit the scope of the embodiments of the present application. It should also be understood that the order of the sequence numbers of the above-mentioned processes does not necessarily indicate the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0169] It should also be understood that in the various embodiments of the present application, unless otherwise specified or there is a logical conflict, the terms and / or descriptions between different embodiments are consistent and can be referenced to each other, and the technical features in different embodiments can be combined to form new embodiments according to their internal logical relationships.

[0170] The above mainly introduces the solution provided by the embodiment of the present application from the perspective of method. In order to realize the above functions, it includes hardware structures and / or software modules corresponding to the execution of each function. Those skilled in the art should easily appreciate that, in combination with the units and algorithm steps of each example described in the embodiments disclosed herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in a hardware or computer software driven hardware manner depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0171] The following describes in detail the apparatus for message transmission provided by the embodiments of the present application in conjunction with Figures 10 to 12. It should be understood that the description of the apparatus embodiment corresponds to the description of the method embodiment. Therefore, for matters not described in detail, reference can be made to the method embodiment above. For the sake of brevity, some contents will not be repeated.

[0172] In the embodiment of the present application, the functional modules of the transmitting device or the receiving device can be divided according to the above method example. For example, each functional module can be divided according to each function, or two or more functions can be integrated into one processing module. The above integrated modules can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of modules in the embodiment of the present application is schematic and is only a logical functional division. There may be other division methods in actual implementation. The following is an example of dividing each functional module according to each function.

[0173] FIG10 shows a schematic structural diagram of a message transmission apparatus 1000 provided in an embodiment of the present application.

[0174] In one example, the message transmission apparatus 1000 can be applied to a first device and can be used to perform the above-described message transmission method, for example, the method shown in FIG5 . The message transmission apparatus 1000 includes a transaction layer and a transport layer. Specifically, the message transmission apparatus 1000 may include a transceiver unit 1010 and a processing unit 1020.

[0175] The transceiver unit 1010 is used to receive a message from the transaction layer of the first device, where the message is a message of the first application to be sent to the second device; when at least one first transport layer TP connection has been established between the transport layer of the first device and the transport layer of the second device, the transceiver unit 1010 is used to send a first indication message to the transaction layer of the first device, where the first indication message is used to indicate that the at least one first TP connection is used to transmit the message of the first application; the transceiver unit 1010 is used to send the message of the first application to the transport layer of the second device through the at least one first TP connection, wherein the at least one first TP connection is a TP connection established by the transport layer of the first device to transmit the message of the second application.

[0176] As an example, in conjunction with FIG5 , the transceiver unit 1010 may be configured to execute S510 , S521 , S522 , S524 , S525 , and S530 , and the processing unit 1020 may be configured to execute S520 and S523 .

[0177] It should be noted that the device shown in FIG. 10 can also be used to execute the method steps involved in the embodiment variations shown in the aforementioned figures, which will not be described in detail here.

[0178] In another example, the apparatus 1000 for message transmission can be applied to the second device, and can be used to execute the above-mentioned method for message transmission, for example, the method shown in Figure 5. The apparatus 1000 for message transmission includes a transaction layer and a transport layer.

[0179] The transceiver unit 1030 is configured to receive a message of a first application from a transport layer of a first device.

[0180] As an example, in conjunction with FIG5 , the transceiver unit 1010 may be configured to execute S522 , S524 , S525 , and S530 .

[0181] It should be noted that the device shown in FIG. 10 can also be used to execute the method steps involved in the embodiment variations shown in the aforementioned figures, which will not be described in detail here.

[0182] The embodiment of the present application further provides a chip system 1100, as shown in FIG11 , wherein the chip system 1100 includes at least one processor and at least one interface circuit. As an example, when the chip system 1100 includes one processor and one interface circuit, the one processor may be the processor 1110 shown in the solid-line box in FIG11 (or the processor 1110 shown in the dashed-line box), and the one interface circuit may be the interface circuit 1120 shown in the solid-line box in FIG11 (or the interface circuit 1120 shown in the dashed-line box).

[0183] When the chip system 1100 includes two processors and two interface circuits, the two processors include the processor 1110 shown in the solid box in Figure 11 and the processor 1110 shown in the dotted box, and the two interface circuits include the interface circuit 1120 shown in the solid box in Figure 11 and the interface circuit 1120 shown in the dotted box. This is not limited. The processor 1110 and the interface circuit 1120 can be interconnected via a line. For example, the interface circuit 1120 can be used to receive signals (such as instructions stored in a memory, etc.). For another example, the interface circuit 1120 can be used to send signals to other devices (such as the processor 1110).

[0184] For example, the interface circuit 1120 can read instructions stored in the memory and send the instructions to the processor 1110. When the instructions are executed by the processor 1110, the message transmission device can perform the various steps in the above embodiment. Of course, the chip system 1100 can also include other discrete components, which are not specifically limited in this embodiment of the application.

[0185] Another embodiment of the present application further provides a computer-readable storage medium having instructions stored therein. When the instructions are executed on a message transmission device, the message transmission device performs the steps performed by the message transmission device in the method flow shown in the above method embodiment. In some embodiments, the disclosed method can be implemented as computer program instructions encoded in a machine-readable format on a computer-readable storage medium or on other non-transitory media or articles.

[0186] FIG12 schematically shows a conceptual partial view of a computer program product provided by an embodiment of the present application, where the computer program product includes a computer program for executing a computer process on a computer device.

[0187] In one embodiment, a computer program product is provided using a signal-bearing medium 1200. The signal-bearing medium 1200 may include one or more program instructions that, when executed by one or more processors, may provide the functionality or portions of the functionality described above with respect to FIG. 5 and FIG. 9 . Thus, for example, one or more features of S510-S530 in FIG. 5 may be provided by one or more instructions associated with the signal-bearing medium 1200. Furthermore, the program instructions in FIG. 12 also depict example instructions.

[0188] In some examples, the signal-bearing medium 1200 may include a computer-readable medium 1201, such as, but not limited to, a hard drive, a compact disk (CD), a digital video disk (DVD), a digital tape, a memory, a read-only memory (ROM), or a random access memory (RAM), and the like.

[0189] In some implementations, the signal bearing medium 1200 may include a computer recordable medium 1202 such as, but not limited to, a memory, a read / write (R / W) CD, a R / W DVD, or the like.

[0190] In some embodiments, the signal-bearing medium 1200 may include a communication medium 1203, such as, but not limited to, a digital and / or analog communication medium (e.g., a fiber optic cable, a waveguide, a wired communication link, a wireless communication link, etc.). The signal-bearing medium 1200 may be communicated by a wireless form of the communication medium 1203 (e.g., a wireless communication medium that complies with the IEEE 1502.11 standard or other transmission protocols). The one or more program instructions may be, for example, computer-executable instructions or logic-implemented instructions.

[0191] In some examples, an apparatus such as that for message transmission of FIG. 5 may be configured to provide various operations, functions, or actions in response to one or more program instructions via computer-readable medium 1201 , computer-recordable medium 1202 , and / or communication medium 1203 .

[0192] Should be understood that the arrangement described here is only for the purpose of example. Thus, those skilled in the art will understand that other arrangements and other elements (such as, machines, interfaces, functions, sequences, and functional groups, etc.) can be used instead, and some elements can be omitted altogether according to the desired result. In addition, many of the described elements can be implemented as discrete or distributed components or in any appropriate combination and position in conjunction with the functional entities implemented by other components.

[0193] In the above embodiments, all or part of the embodiments may be implemented using software, hardware, firmware, or any combination thereof. When implemented using a software program, all or part of the embodiments may be implemented in the form of a computer program product. The computer program product includes one or more computer instructions. When the instructions are executed on a computer, all or part of the processes or functions according to the embodiments of the present application are generated. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device.

[0194] Computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. 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 or data center that includes one or more available media. Available media can be magnetic media (e.g., floppy disks, hard disks, tapes), optical media (e.g., DVDs), or semiconductor media (e.g., solid-state drives (SSDs)).

[0195] The above description is merely a specific embodiment of the present application, but the scope of protection of the present application is not limited thereto. Any changes or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in this application should be included in the scope of protection of this application. Therefore, the scope of protection of this application should be based on the scope of protection of the claims.

Claims

1. A method for message transmission, characterized in that: Applied to a first device, the first device includes a transaction layer and a transport layer, the method includes: The transport layer of the first device receives a message from the transaction layer of the first device, where the message is a message of the first application to be sent to the second device; When at least one first transport layer TP connection has been established between the transport layer of the first device and the transport layer of the second device, the transport layer of the first device sends first indication information to the transaction layer of the first device, where the first indication information is used to indicate that the at least one first TP connection is used to transmit a message of the first application; The transport layer of the first device sends the message of the first application to the transport layer of the second device through the at least one first TP connection, wherein the at least one first TP connection is a TP connection used by the transport layer of the first device to transmit the message of the second application.

2. The method according to claim 1, characterized in that When a TP connection is not established between the transport layer of the first device and the transport layer of the second device, the method further includes: The transport layer of the first device obtains the Internet Protocol IP address information of the second device; The transport layer of the first device establishes at least one second TP connection between the transport layer of the first device and the transport layer of the second device according to the IP address information of the second device, and the at least one second TP connection is used to transmit the message of the first application.

3. The method according to claim 1 or 2, characterized in that: The transport layer of the first device sends the message of the first application to the transport layer of the second device through the at least one first TP connection, including: The transport layer of the first device sends the message of the first application to the transport layer of the second device through the TP connection with the lightest load among the at least one first TP connection.

4. The method according to any one of claims 1 to 3, characterized in that The method further comprises: The transport layer of the first device receives a response message from the transport layer of the second device, where the response message is used to indicate whether the message of the first application is successfully executed by the transaction layer of the second device.

5. The method according to claim 4, characterized in that If the response message is a transaction response TAACK, indicating that the transaction layer of the second device successfully executes the message of the first application, the method further includes: The transport layer of the first device sends a completion queue entry CQE to the transaction layer of the first device, where the CQE is used to indicate that a message of the first application is successfully transmitted.

6. The method according to claim 4, characterized in that If the first response message is a transaction negative acknowledgment TANAK, indicating that the transaction layer of the second device has not successfully executed the message of the first application, the method further includes: The transport layer of the first device sends the TANAK to the transaction layer of the first device; The transport layer of the first device receives the message of the first application from the transaction layer of the first device, and resends the message of the first application to the transport layer of the second device.

7. The method according to any one of claims 1 to 6, characterized in that The transport layer of the first device receives a message from the transaction layer of the first device, including: The transport layer of the first device receives a send queue entry SQE from the transaction layer of the first device, the destination address of the SQE is the address of the second device, and the SQE carries a message of the first application sent to the second device.

8. The method according to claim 7, characterized in that The transport layer of the first device receives the SQE from the transaction layer of the first device, including: The transport layer of the first device receives the SQE from at least one transmit interface of the first device.

9. The method according to claim 7 or 8, characterized in that: Before the transport layer of the first device sends the message of the first application to the transport layer of the second device through the at least one first TP connection, the method further includes: The transport layer of the first device determines the at least one first TP connection according to the destination entity identifier DEID carried in the SQE.

10. A message transmission device, characterized in that: The device comprises a transaction layer and a transport layer, and the device comprises: A transport layer receiving module, configured to receive a message from the transaction layer, wherein the message is a message of the first application to be sent to the second device; When at least one first transport layer TP connection has been established between the transport layer of the apparatus and the transport layer of the second device, the transport layer sending module is used to send first indication information to the transaction layer, wherein the first indication information is used to indicate that the at least one first TP connection is used for transmission. inputting a message of the first application; The transport layer sending module is further configured to send a message of the first application to the transport layer of the second device through the at least one first TP connection; The at least one first TP connection is a TP connection used by the transport layer of the device to transmit messages of the second application.

11. The device according to claim 10, characterized in that When a TP connection is not established between the transport layer of the apparatus and the transport layer of the second device, the transport layer receiving module is further used to obtain Internet Protocol IP address information of the second device; The device also includes: A transport layer processing module is used to establish at least one second TP connection between the transport layer of the apparatus and the transport layer of the second device according to the IP address information of the second device, and the at least one second TP connection is used to transmit the message of the first application.

12. The device according to claim 10 or 11, characterized in that The transport layer sending module sends the message of the first application to the transport layer of the second device through the at least one first TP connection, including: The transport layer sending module sends the message of the first application to the transport layer of the second device through the TP connection with the lightest load among the at least one TP connection.

13. The device according to any one of claims 10 to 12, characterized in that The transport layer receiving module is further used to receive a response message from the transport layer of the second device, where the response message is used to indicate whether the message of the first application is successfully executed by the transaction layer of the second device.

14. The device according to claim 13, characterized in that If the response message is a transaction response TAACK, indicating that the transaction layer of the second device successfully executes the message of the first application, the transport layer sending module is also used to send a completion queue entry CQE to the transaction layer of the first device, and the CQE is used to indicate that the message of the first application is successfully transmitted.

15. The device according to claim 13, characterized in that If the first response message is a transaction negative acknowledgment TANAK, indicating that the transaction layer of the second device has not successfully executed the message of the first application, the transport layer sending module is further used to send the TANAK to the transaction layer of the first device; The transport layer receiving module is further used to receive a message of the first application from the transaction layer of the first device; The transport layer sending module is further used to resend the message of the first application to the transport layer of the second device.

16. The device according to any one of claims 10 to 15, characterized in that The transport layer receiving module receives the message from the transaction layer, including: The transport layer receiving module is used to receive a send queue entry SQE from the transaction layer, the destination address of the SQE is the address of the second device, and the SQE carries a message of the first application sent to the second device.

17. The device according to claim 16, characterized in that The transport layer receiving module receives the SQE from the transaction layer, including: The transport layer receiving module of the device receives the SQE from at least one sending interface of the device.

18. The device according to claim 16 or 17, characterized in that The device comprises: A transport layer processing module is used to determine the at least one first TP connection according to the destination entity identifier DEID carried in the SQE before the transport layer sending module sends the message of the first application to the transport layer of the second device through the at least one first TP connection.

19. A message transmission device, characterized in that: include: A processor, configured to read instructions stored in a memory, wherein when the processor executes the instructions, the device for accessing the memory implements the method according to any one of claims 1 to 9.

20. A message transmission device, characterized in that: The method comprises means for performing the method as claimed in any one of claims 1 to 9.

21. A chip, characterized in that: include: At least one processing core, configured to execute the method according to any one of claims 1 to 9.

22. A computer device, characterized in that: include: A chip as claimed in claim 21.

23. A computer program product, characterized in that The computer program product comprises a computer program code, and when the computer program code is run on a computer, the method according to any one of claims 1 to 9 is executed.

24. A computer-readable storage medium, characterized in that: The method comprises a computer program which, when executed on a computer device, causes a processing module in the computer device to execute the method according to any one of claims 1 to 9.

25. A message transmission system, characterized in that: The method comprises a first device for executing the method according to any one of claims 1 to 9 and a second device for receiving a message.

Citation Information

Patent Citations

  • Message transmission method and device

    CN118869775A

  • Message transmission method and device and electronic equipment

    CN111756751A

  • Message transmission method and device

    CN114615351A

  • Message transmission method, communication device and communication system

    CN114731557A

  • Data transmission method and device, equipment and storage medium

    CN115514682A