Data transmission method and related equipment

By providing data storage space for the application on the first device and reducing data copying with DPU, the problem of high time delay in traditional data transmission methods is solved, and more efficient data transmission is achieved.

CN120144040APending Publication Date: 2025-06-13HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311702753.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-12-11
Publication Date
2025-06-13

AI Technical Summary

Technical Problem

In traditional data transmission methods, the terminal device needs to copy data from the application buffer to the cache area, and then transmit it through the network, resulting in a large number of data copies and a high delay.

Method used

By providing data storage space for the application on the first device and reading data directly from the storage space of the first device when writing to the second device, the number of data copies is reduced. The first device sends address information to the second device through the DPU, rather than actual data, reducing the transmission amount and delay.

Benefits of technology

It reduces the delay during data transmission, improves transmission efficiency, reduces CPU resource usage, and improves device performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120144040A_ABST
    Figure CN120144040A_ABST
Patent Text Reader

Abstract

The invention provides a data transmission method and related equipment, which are used for reducing time delay in a data transmission process. The data transmission method applied to first equipment comprises the following steps: acquiring a first calling request from an application program, wherein the first calling request indicates the application program running in the first equipment to use a storage space of the first equipment to store data; at least one write request is obtained, each write request comprises first address information, an address indicated by the first address information is contained in the storage space of the first device, and each write request indicates that data corresponding to the first address information in the storage space is written into at least one second device. Second address information is sent to at least one second device, so that the at least one second device reads the first data corresponding to the second address information from the storage space of the first device into the storage space of the second device, and the second address information comprises at least one piece of first address information corresponding to the at least one write request.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of communications, and in particular, to a data transmission method and related devices. Background Art

[0002] In the field of communications, a sending end can transmit various data such as letters, digital symbols, voices, graphics, images, audio, etc. to a receiving end, that is, write the data into the receiving end.

[0003] In a traditional method, an application program running on a terminal device can initiate a data write request to a network device through the terminal device. In this process, the terminal device needs to copy the data to be written into the storage space of the network device from the buffer of the application program to the cache of the terminal device. In the subsequent transmission process, these data also need to be copied twice (including the copy during network transmission and the copy when entering the network device) before being written into the storage space of the network device.

[0004] In this method, the number of data copies during the transmission between the terminal device and the network device is relatively large, and each copy consumes time, resulting in a high latency of data transmission. Summary of the Invention

[0005] This application provides a data transmission method and related devices for reducing the latency during data transmission.

[0006] In a first aspect, this application provides a data transmission method, which is applied to a first device. The method includes:

[0007] An application is running on a first device. The application can initiate a first call request through the memory application interface of the first device. The first call request is used to request to use the storage space of the first device to store the data generated or used during the running of the application. Then, for the first device, the first device obtains the first call request from the application and allocates a data storage space for the application based on the first call request. The data storage space is included in the storage space of the first device. The application initiates a write request for writing data to a second device that has established a communication connection with the first device. The first device obtains at least one write request. Each of the at least one write requests includes first address information. The address indicated by the first address information is included in the storage space of the first device, and each write request indicates writing the data corresponding to the first address information in the storage space of the first device to at least one second device. That is to say, the data to be written to the second device is already located in the storage space of the first device, and there is no need to copy the data from the buffer of the application to the buffer of the first device according to the traditional method, reducing one data copy. The first device sends second address information to at least one second device, so that at least one second device reads the first data corresponding to the second address information from the storage space of the first device into the storage space of the second device, where the second address information includes at least one first address information corresponding to the first write request.

[0008] In this application, the data storage space provided by the first device for the application is included in the storage space of the first device. When writing data to the second device, the second device directly reads the data to be written from the storage space of the first device, eliminating one data copy and reducing the latency of data transmission. In addition, during the process of writing data to the second device, the first device does not send the data to be written to the second device, but the address information of these data, reducing the data transmission volume sent by the first device to the second device and further reducing the transmission latency.

[0009] In some optional implementation manners of the first aspect, the first device can send the second address information to at least one second device through its own data processing unit (DPU). Specifically, in this application, the DPU issues an instruction to the network card, causing the network card to execute the sending task, that is, sending the second address information to at least one second device.

[0010] In this application, the function of controlling the data transmission of the network card is unloaded from the central processing unit (CPU) to the DPU, releasing the CPU resources of the first device. While reducing the CPU resource occupancy of the first device, it also improves the performance of the first device.

[0011] In some alternative implementations of the first aspect, at least one write request may be multiple write requests. For example, at least one write request includes a first write request and a second write request. The data volume corresponding to either the first write request or the second write request is less than the first data volume threshold, and the sum of the data volumes corresponding to the first write request and the second write request is greater than or equal to the first data volume threshold. The first data volume threshold is used to measure whether the data volume corresponding to the write requests obtained by the first device reaches the sending standard. For write requests with a high sending frequency and a small requested data volume, if the first device sends each obtained write request to the second device, it will cause the first device to send a large number of write requests in a short time but the requested data volume is not high, resulting in low transmission efficiency. Therefore, by setting the first data volume threshold, when the first device obtains a write request, it will compare the data volume corresponding to this write request with the first data volume threshold. If it is less than the first data volume threshold, the write request will not be sent to the second device for the time being until the data volumes corresponding to multiple write requests obtained by the first device are greater than or equal to the first data volume threshold, and then multiple write requests are sent to the second device. In other words, for the foregoing example, before the first device sends the second address information to at least one second device, the first device may also call the DPU to aggregate the first write request and the second write request to obtain the second address information. The second address information includes the first address information included in the first write request and the first address information included in the second write request. Among them, the value of the first data volume threshold can be preset by the system or set by the user, and the specific value can be determined according to the actual application needs, and will not be specifically limited here.

[0012] In this application, the first data volume threshold is used to measure whether the data volume corresponding to the write requests obtained by the first device reaches the sending standard. For write requests with a data volume less than the first data volume threshold, they will be aggregated with other write requests, and the second address information sent to the second device includes the address information included in each aggregated write request, thereby improving the transmission efficiency.

[0013] In some alternative implementations of the first aspect, if at least one write request includes a third write request and the data volume corresponding to the third write request is greater than or equal to the first data volume threshold, then the second address information includes the address information corresponding to the third write request.

[0014] In some alternative implementations of the first aspect, after sending the second address information to at least one second device, the first device obtains response information from the second device. The response information indicates whether the data reading of the second device is successful and is used to adjust the value of the counting bit of the DPU included in the first device. When the value of the counting bit of the DPU reaches the counting threshold, it means that the write operation for all the second devices (i.e., the at least one second device mentioned above) to which the second address information has been sent is completed. The first device triggers the service callback logic and sends the response result for at least one write request to the application program.

[0015] In this application, the first device does not need to query the second device to check whether the data writing is successful. Instead, the second device asynchronously sends response information to the first device. An interrupt system is set up. When the value of the counting bit of the DPU in the first device adjusted by the response information reaches the counting threshold, the first device automatically triggers the service callback logic and sends the response result to the application program. Compared with the solution where the first device queries the response result from each second device, the performance overhead of the first device is reduced.

[0016] In some alternative implementations of the first aspect, when the first device sends the second address information to at least one second device, it starts recording the duration. When the recorded duration reaches the first preset duration, the first device triggers the service callback logic and sends the response result for at least one write request to the application program. Alternatively, when the first device receives the response information sent by the second device, it starts recording the duration. When the duration recorded at this time reaches the second preset duration, the first device triggers the service callback logic and sends the response result for at least one write request to the application program.

[0017] In this application, there are multiple solutions for the first device to trigger the service callback logic, which enriches the implementation methods and application scenarios of the technical solutions of this application and improves the flexibility of the technical solutions.

[0018] In the second aspect, this application provides a data transmission method, which is applied to the second device. The method includes:

[0019] The second device obtains the second address information from the first device. The second address information includes at least one first address information, and each first address information indicates an address included in the storage space of the first device. That is to say, the data to be read by the second device is located in the storage space of the first device. The second device reads the first data corresponding to the second address information from the storage space of the first device to the storage space of the second device based on the unilateral reading method, realizing the transmission of the first data between the first device and the second device, that is, writing the first data in the storage space of the first device to the storage space of the first device.

[0020] In this application, the second device obtains the first data through single-sided reading. The transmission speed of single-sided reading is fast, and a large amount of data can be transmitted in the same time, which can make full use of the network bandwidth and improve the network throughput.

[0021] In some alternative implementation manners of the second aspect, the storage space of the second device includes a first storage space corresponding to the non-volatile memory, and the non-volatile memory is included in the second device. In this solution, reading the first data corresponding to the second address information into the storage space of the second device is actually reading the first data into the first storage space.

[0022] In this application, for the solution where the second device includes a non-volatile memory, the first data can be read into the first storage space corresponding to the non-volatile memory, which can not only accelerate the speed of storing the first data in the second device, but also ensure that the stored first data is not lost when the device is powered off, improving the reliability of the technical solution of this application.

[0023] In some alternative implementation manners of the second aspect, the storage space of the second device includes not only the foregoing first storage space, but also a second storage space corresponding to the hard disk, where the hard disk is included in the second device. After reading the first data into the first storage space, the second device can migrate the first data from the first storage space to the second storage space to implement asynchronous disk flushing of the first data.

[0024] In this application, after writing the first data into the first storage space of the non-volatile memory, asynchronous disk flushing is also performed on the first data, and the first data is migrated to the second storage space of the hard disk, thereby releasing the storage resources of the non-volatile memory and reducing the cost.

[0025] In some alternative implementation manners of the second aspect, in the solution where the storage space of the second device includes a second storage space corresponding to the hard disk, writing the first data into the storage space of the second device can also be reading the first data into the second storage space. Wherein, the hard disk is included in the second device.

[0026] In this application, the first data can also be directly read into the second storage space corresponding to the hard disk in the second device, reducing the cost of the second device.

[0027] In some alternative implementations of the second aspect, after the first data is read into the storage space of the second device, the second device stores an index of the first data. The index indicates the mapping relationship between the storage location of the first data in the second device and the first attribute information of the first data, and the first attribute information is used to determine the storage location of the first data in the first device. Among them, the first attribute information can also be understood as the information provided by the communication system to the user through the first device, so that the user can determine the storage location of the first data according to the first attribute information. Among them, in the solution where the second device includes a power-preserving memory, the aforementioned index of the first data is stored in the first storage space corresponding to the power-preserving memory. In the solution where the second device does not include a power-preserving memory, the aforementioned index of the first data is stored in the memory of the second device.

[0028] In this application, the second device saves the index of the first data, which provides an implementation basis for other solutions that need to obtain the first data from the second device, such as data query for the first data, and improves the practicability of the technical solution of this application.

[0029] In some alternative implementations of the second aspect, after the first data is read into the storage space of the second device, the second device sends a response message to the first device. This response message not only indicates that the second device has successfully read the first data, but also is used to adjust the value of the count bit of the DPU included in the first device, so that when the value of the count bit of the DPU reaches the count threshold, the service callback logic of the first device is triggered, and the first device sends a response result for at least one write request to the application.

[0030] In this application, the first device does not need to query the second device to check whether the write data is successful. Instead, the second device asynchronously sends a response message to the first device. An interrupt system is set up. When the value of the count bit of the DPU in the first device adjusted by the response message reaches the count threshold, the first device automatically triggers the service callback logic and sends a response result to the application. Compared with the solution where the first device queries the response result from each second device, the performance overhead of the first device is reduced.

[0031] In a third aspect, this application provides a data transmission method, which is applied to the first device and includes:

[0032] The first device obtains a second call request from an application, the second call request instructs the application to use the storage space of the first device to store data, and the application runs on the first device. The data stored by the application in the storage space of the first device includes data generated or used by the application during operation. The application initiates a read request, which is used to initiate a data read request to the second device that establishes a communication connection with the first device. The first device obtains at least one read request, wherein each read request includes third address information, the address indicated by the third address information is included in the storage space of the first device, and each read request indicates that the data stored in the storage space of the second device is written into the storage space of the first device. In other words, the location where the data requested by the application is written is in the storage space of the first device, which is the final storage location of the data. It is not necessary to copy the data to the buffer stored in the application according to the traditional method, thereby reducing one data copy. The first device sends at least one read request to the second device, so that the second device reads the second data corresponding to the at least one read request from the storage space of the second device according to the at least one read request.

[0033] In the present application, the data storage space provided by the first device for the application is included in the storage space of the first device. When the application initiates a read request, the final location of the second data storage read by the first device from the second device is included in the storage space of the first device. There is no need to copy the data again, thereby eliminating one data copy and reducing the delay in data transmission.

[0034] In some optional implementations of the third aspect, each read request sent by the first device to the second device also includes second attribute information, and the second attribute information is used to determine a storage location of data corresponding to each read request on the second device.

[0035] In the present application, the storage location of the data to be read in the second device is determined by the second attribute information included in the read request, thereby improving the feasibility of the technical solution of the present application.

[0036] In some optional implementations of the third aspect, at least one read request is sent to at least one second device through the first device DPU. Specifically, the DPU calls the network card to send at least one read request to the at least one second device, that is, the DPU sends an instruction to the network card so that the network card executes the sending task and sends at least one read request to the at least one second device.

[0037] In the present application, the function of controlling the network card to perform data transmission is offloaded from the CPU to the DPU, thereby releasing the CPU resources of the first device, reducing the CPU resource occupancy of the first device, and improving the performance of the first device.

[0038] In some alternative implementations of the third aspect, at least one read request may be multiple read requests. For example, at least one read request includes a first read request and a second read request. The data volume corresponding to either the first read request or the second read request is less than the second data volume threshold, and the sum of the data volumes corresponding to the first read request and the second read request is greater than or equal to the second data volume threshold. The second data volume threshold is used to measure whether the data volume corresponding to the read request obtained by the first device reaches the sending standard. For read requests with a high sending frequency and a small requested data volume, if the first device sends each obtained read request to the second device, it will cause the first device to send a large number of read requests in a short time but the requested data volume is not high, resulting in low transmission efficiency. Therefore, the second data volume threshold is set. When the first device obtains a read request, it will compare the data volume corresponding to this read request with the second data volume threshold. If it is less than the second data volume threshold, the read request will not be sent to the second device temporarily until the data volumes corresponding to multiple read requests obtained by the first device are greater than or equal to the second data volume threshold, and then multiple read requests are sent to the second device. In other words, for the foregoing example, the first device obtains at least one read request, including: the first device invokes the DPU to aggregate the first read request and the second read request to obtain at least one read request. Among them, the value of the second data volume threshold can be preset by the system or set by the user, and the specific value can be determined according to the actual application needs, and no specific limitation is made here.

[0039] In this application, the second data volume threshold is used to measure whether the data volume corresponding to the read request obtained by the first device reaches the sending standard. For read requests with a data volume less than the second data volume threshold, they will be aggregated with other read requests and the aggregated read requests will be sent to the second device, thereby improving the transmission efficiency.

[0040] In some alternative implementations of the third aspect, obtaining at least one read request may also be obtaining a third read request, and the data volume corresponding to the third read request is greater than or equal to the second data volume threshold.

[0041] In some alternative implementations of the third aspect, after sending at least one read request to the second device, the first device obtains second data from the second device. The second data is read by the second device from the storage space of the second device. The storage space of the second device includes a first storage space corresponding to the non-volatile memory of the second device or a second storage space corresponding to the hard disk of the second device.

[0042] In some alternative implementations of the third aspect, the DPU of the first device is set with a counting bit. When the value of the counting bit reaches the counting threshold, the first device automatically triggers the service callback logic and sends a response result to the application program. The response result is used to indicate whether the read data is successful.

[0043] Fourthly, the present application provides a data transmission method, which is applied to a second device and includes:

[0044] The second device obtains at least one read request from the first device, where each read request includes third address information, and the address indicated by the third address information is included in the storage space of the first device. Each read request instructs to write the data stored in the storage space of the second device into the storage space of the first device. The second device reads at least one second data corresponding to at least one read request from the storage space of the second device, and sends the second data to the first device based on the unilateral sending method.

[0045] In the present application, the second device sends the second data to the first device by the unilateral sending method. The unilateral sending has a fast transmission speed, can transmit a large amount of data in the same time, can make full use of the network bandwidth, and improves the network throughput.

[0046] In some optional implementation manners of the fourth aspect, each read request obtained by the second device further includes second attribute information, and the second attribute information is used to determine the storage location of the data corresponding to each read request in the storage space of the second device. In addition, a mapping relationship between the second attribute information and the data storage location is stored in the storage space of the second device. In this mapping relationship, the second attribute information and the data storage location are in one-to-one correspondence. Then, the second device reads at least one second data corresponding to at least one read request from the storage space of the second device. Specifically, it determines the target storage location of at least one second data corresponding to at least one read request in the storage space of the second device according to at least one second attribute information included in at least one read request and the mapping relationship. Then, the second data is read from the target storage location.

[0047] In the present application, the second device stores a mapping relationship between the attribute information and the data storage location, so that the second device determines the specific storage location of the data to be read in the second device according to the mapping relationship and the second attribute information included in the read request, which provides technical support for the implementation of the technical solution of the present application and improves the feasibility of the technical solution of the present application.

[0048] In some optional implementation manners of the fourth aspect, there are various possibilities for the storage space of the second device. Optionally, the storage space of the second device includes a first storage space corresponding to the non-volatile memory, the non-volatile memory is included in the second device, and the target storage location is included in the first storage space.

[0049] In the present application, the second device includes a non-volatile memory, and the target storage location of the second data is included in the first storage space corresponding to the non-volatile memory. In this solution, the data reading speed is fast. In addition, when the second device is powered off, it can also ensure that the stored second data is not lost, which improves the reliability of the technical solution of the present application.

[0050] In some alternative implementations of the fourth aspect, the storage space of the second device includes a second storage space corresponding to a hard disk, the hard disk is included in the second device, and the target storage location is included in the second storage space.

[0051] In this application, the second data can be stored in the second storage space corresponding to the hard disk, and the second data can be directly read from the hard disk. Using the hard disk to store data reduces the storage cost.

[0052] In some alternative implementations of the fourth aspect, when the storage space of the second device includes a first storage space corresponding to a non-volatile memory and a second storage space corresponding to a hard disk, and the target storage space is included in the second storage space, reading the second data from the target storage location includes: reading the second data from the target storage location to the first storage space. That is to say, the second data stored in the hard disk is migrated to the non-volatile memory, and then the second data is read from the non-volatile memory and returned to the first device. The second device also updates the mapping relationship, and in the updated mapping relationship, the data storage location corresponding to the second attribute information of the second data is included in the first storage space.

[0053] In this application, the second device writes the second data included in the hard disk into the first storage space corresponding to the non-volatile memory and then returns it to the first device, which improves the transmission efficiency of the second data.

[0054] Fifth aspect, this application provides a communication system, including a first device and a second device. The first device includes modules for implementing the method shown in the above-mentioned first aspect or any possible implementation of the first aspect. The second device includes modules for implementing the method shown in the above-mentioned second aspect or any possible implementation of the second aspect.

[0055] The beneficial effects shown in this aspect are similar to any possible implementation of the foregoing first aspect, second aspect, first aspect or second aspect, and will not be elaborated here.

[0056] Sixth aspect, this application provides a communication system, where the first device includes modules for implementing the method shown in the above-mentioned third aspect or any possible implementation of the third aspect. The second device includes modules for implementing the method shown in the above-mentioned fourth aspect or any possible implementation of the fourth aspect.

[0057] The beneficial effects shown in this aspect are similar to any possible implementation of the foregoing third aspect, fourth aspect, third aspect or fourth aspect, and will not be elaborated here.

[0058] In a seventh aspect, the present application provides a communication device, which includes a module for implementing the method shown in any one of the foregoing first to fourth aspects, or any possible implementation manner of the first to fourth aspects. The beneficial effects are as shown above and will not be elaborated here.

[0059] In an eighth aspect, the present application provides a communication device, including a processor and a memory. The processor stores instructions, and when the instructions stored in the memory run on the processor, the method shown in any one of the foregoing first to fourth aspects, or any possible implementation manner of the first to fourth aspects is implemented.

[0060] In a ninth aspect, the present application provides a computer-readable storage medium, in which instructions are stored. When the instructions run on a processor, the method shown in any one of the foregoing first to fourth aspects, or any possible implementation manner of the first to fourth aspects is implemented.

[0061] In a tenth aspect, the present application provides a computer program product. When the computer program product is executed on a processor, the method shown in any one of the foregoing first to fourth aspects, or any possible implementation manner of the first to fourth aspects is implemented.

[0062] The beneficial effects shown in any one of the seventh to tenth aspects are similar to those of the first aspect or any possible implementation manner of the first aspect, and will not be elaborated here. Description of the Drawings

[0063] Figure 1 It is a schematic diagram of the system architecture provided by an embodiment of the present application;

[0064] Figure 2 It is a flowchart of a data transmission method provided by an embodiment of the present application;

[0065] Figure 3 It is another flowchart of the data transmission method provided by an embodiment of the present application;

[0066] Figure 4 It is another flowchart of the data transmission method provided by an embodiment of the present application;

[0067] Figure 5 It is another flowchart of the data transmission method provided by an embodiment of the present application;

[0068] Figure 6 It is a schematic structural diagram of a communication device provided by an embodiment of the present application;

[0069] Figure 7 It is a schematic structural diagram of a communication device provided by an embodiment of the present application. Specific Embodiments

[0070] The embodiments of the present application provide a data transmission method and related devices, which are used to reduce the latency during data transmission.

[0071] Next, the embodiments of the present application will be described with reference to the accompanying drawings. As is known to those of ordinary skill in the art, with the development of technology and the emergence of new scenarios, the technical solutions provided by the embodiments of the present application are equally applicable to similar technical problems.

[0072] Terms such as "first" and "second" in the specification, claims, and the above-mentioned accompanying drawings of the present application are used to distinguish similar objects, and do not necessarily need to be used to describe a specific order or sequence. It should be understood that such terms can be interchanged under appropriate circumstances, which is only a way of distinguishing when describing objects with the same attributes in the embodiments of the present application. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion, so that a process, method, system, product, or device including a series of units does not necessarily have to be limited to those units, but may include other units not clearly listed or inherent to these processes, methods, products, or devices. Additionally, "at least one" means one or more, and "a plurality" means two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships can exist. For example, A and / or B can represent: A exists alone, A and B exist simultaneously, and B exists alone, where A and B can be singular or plural. The character " / " generally represents an "or" relationship between the associated objects before and after. "At least one (item)" or its similar expression refers to any combination of these items, including any combination of single (item) or plural items (items). For example, at least one (item) of a, b, or c can represent: a, b, c, a - b, a - c, b - c, or a - b - c, where a, b, c can be single or multiple.

[0073] First, please refer to Figure 1 , Figure 1 , which is a schematic diagram of the system architecture provided by the embodiments of the present application.

[0074] As Figure 1 shown, the user establishes a communication connection with the server device through a client device. There are various ways to establish this communication connection. It can be through a wireless network connection or a wired network connection, and specific details are not limited here. If it is through a wireless network connection, the specific connection form can be a cellular wireless network, a wireless fidelity (WiFi) network, or other types of wireless networks, and specific details are not limited here.

[0075] Figure 1 The n server devices shown can be a "one master and multiple backup" architecture. For example, assume that server device 1 is the primary server and the other servers are replica servers. Each server device has a data storage function, and the user initiates a data read / write request to the server device through the client device. Among them, the read request is used to read the data stored in the server device, and the write request is used to write data to the server device.

[0076] It should be noted that Figure 1 The client device shown may also be referred to as a terminal device, a terminal, a user equipment (UE), a mobile station, a mobile terminal, etc. The terminal can be widely used in various scenarios, for example, device-to-device (D2D), vehicle to everything (V2X) communication, machine-type communication (MTC), Internet of Things (IOT), virtual reality, augmented reality, industrial control, autonomous driving, telemedicine, smart grid, smart furniture, smart office, smart wear, smart transportation, smart city, etc. The terminal may be a mobile phone, a tablet computer, a computer with wireless transceiver function, a wearable device, a vehicle, a drone, a helicopter, an airplane, a ship, a robot, a robotic arm, a smart home device, etc. The embodiments of the present application do not limit the device form of the terminal. Figure 1 The server device shown may also be referred to as a server, and can also be widely used in various scenarios, such as distributed file systems, database systems, cloud computing fields, etc., which are not specifically limited here.

[0077] In the following description, the first device represents the client device, and the second device represents the server device. It is understandable that Figure 1 This example is based on the example that the system architecture includes n server devices. In actual applications, the communication system may also include a greater or lesser number of server devices, which is not specifically limited here.

[0078] In addition, it should be noted that in this application, "sending information to... (such as the second device)" can be understood as the destination of the information being the second device, which may include directly or indirectly sending information to the second device. "Receiving information from... (such as the second device)" can be understood as the source of the information being the second device, which may include directly or indirectly receiving information from the second device. Necessary processing may be performed on the information between the source and the destination of the information sending, such as format change, etc., but the destination can understand the valid information from the source. Similar expressions in this application can be understood similarly and will not be elaborated here.

[0079] As mentioned above, between the first device and the second device, both data writing operations and data reading operations can be performed. The following will be described separately.

[0080] 1. The first device initiates a data write request to the second device.

[0081] Next, please refer to Figure 2 , Figure 2 , which is a flowchart of a data transmission method provided by an embodiment of this application, including:

[0082] 201. The first device obtains a first call request from an application. The first call request instructs the application running on the first device to use the storage space of the first device to store data.

[0083] An application runs on the first device. When a user (such as an application developer) connects the application to the first device, the application can apply for storage space from the first device through the memory application interface of the first device. That is to say, the application sends a first call request to the first device, and the first call request is used to request to use the storage space of the first device to store the data generated or used during the operation of the application. Based on the first call request, the first device allocates a data storage space for the application, and the data storage space is included in the storage space of the first device.

[0084] 202. The first device obtains at least one write request. Each write request includes first address information, and the address indicated by the first address information is included in the storage space of the first device. Each write request instructs to write the data corresponding to the first address information in the storage space of the first device to at least one second device.

[0085] During the operation of the application, a write request may be initiated to the first device. The write request is used to request a data writing operation to at least one second device that has established a communication connection with the first device. This process can also be understood as the application requesting to store the data generated or used during its operation in at least one second device.

[0086] Each write request includes first address information. The address indicated by the first address information is included in the storage space of the first device, and each write request indicates writing the data corresponding to the first address information in the storage space of the first device into the storage spaces of at least one second device. That is to say, the data that the application needs to apply for writing into the second device is already located in the storage space of the first device, and the buffer of the application is included in the buffer of the first device. Then, in the embodiment of the present application, for the foregoing write request, there is no need to copy the data from the buffer of the application to the buffer of the first device according to the traditional method, but directly obtain the data from the storage space of the first device, reducing one data copy.

[0087] Optionally, the first address information may include the starting address and length of the data. The address indicated by the first address information mentioned above can be implemented through the starting address and length of the data included in the first address information. The starting address and length of the data are used to locate the specific storage location of the data to be written into the storage space of the second device in the first device.

[0088] 203. The first device sends second address information including at least one first address information to the second device.

[0089] In some alternative embodiments, the first device may transmit the first address information included in each write request to the second device every time a write request is obtained, which has good immediacy. In this solution, the second address information includes one first address information.

[0090] In some alternative embodiments, the first device may set a first data volume threshold, and determine whether it is necessary to converge multiple write requests by comparing the first data volume threshold with the data volume corresponding to each write request. Generally speaking, when the first device obtains a write request, if the data volume corresponding to this write request is less than the first data volume threshold, the first device will obtain other write requests until the sum of the data volumes corresponding to the obtained write requests is greater than or equal to the first data volume threshold, and converge these multiple write requests to obtain the second address information. At this time, the second address information includes the first address information included in each of the multiple converged write requests. If the data volume corresponding to a write request is greater than or equal to the first data volume threshold, the first device may determine the first address information corresponding to this write request as the second address information.

[0091] Exemplarily, if at least one write request includes a first write request and a second write request, the data volume corresponding to either the first write request or the second write request is less than the first data volume threshold, and the sum of the data volumes corresponding to the first write request and the second write request is greater than or equal to the first data volume threshold. Then, before sending the second address information to at least one second device, the first device also invokes the DPU to aggregate the first write request and the second write request to obtain the second address information. At this time, the second address information includes the first address information corresponding to the first write request and the first address information corresponding to the second write request.

[0092] Exemplarily, if at least one write request includes a third write request, and the data volume corresponding to the third write request is greater than or equal to the first data volume threshold, the second address information includes the address information corresponding to the third write request.

[0093] It should be noted that the value of the first data volume threshold can be preset by the system or set by the user. The specific value can be determined according to the actual application needs and is not limited here specifically.

[0094] It can be understood that the foregoing first data volume threshold is used to measure whether the data volume corresponding to the write requests obtained by the first device reaches the sending standard. For write requests with a high sending frequency and a small requested data volume, if the first device sends each obtained write request to at least one second device, it will cause the first device to send a large number of write requests in a short time but the requested data volume is not high, resulting in low transmission efficiency. Therefore, the first data volume threshold is set to improve the transmission efficiency.

[0095] In some alternative embodiments, the first device sends the second address information to each second device among at least one second device through its own DPU. Specifically, the DPU can call the network interface card (NIC) to send the second address information. Among them, NIC is also called network card.

[0096] In this application, the function of controlling the network card for data transmission is unloaded from the CPU to the DPU, releasing the CPU resources of the first device, reducing the CPU resource occupancy of the first device, and at the same time improving the performance of the first device. In addition, in this application, during the process of the first device writing data to the second device, the first device does not send the data to be written to the second device, but the address information of these data, reducing the data transmission volume sent by the first device to the second device and reducing the transmission delay.

[0097] 204. The second device reads the first data corresponding to the second address information from the storage space of the first device into the storage space of the second device based on the unilateral reading method.

[0098] The second device obtains the second address information and reads the first data corresponding to the second address information from the storage space of the first device in a one-sided read manner. Herein, the one-sided read manner means that the second device directly reads the first data from the storage space of the first device without the need for the response of the first device, and this process is not perceived by the first device.

[0099] Herein, the one-sided read manner may be the gather manner of remote direct memory access (RDMA). For the solution where the second address information includes multiple first address information, the second device can perform a batch read.

[0100] In this application, the data storage space provided by the first device for the application program is included in the storage space of the first device. When writing data to the second device, the second device directly reads the data to be written from the storage space of the first device, eliminating one data copy and reducing the data transmission delay. In addition, the second device obtains the first data in a one-sided read manner. The one-sided read has a fast transmission speed, can transmit a large amount of data in the same time, can make full use of the network bandwidth, and improves the network throughput.

[0101] The second device reads the first data from the storage space of the first device into the storage space of the second device, which can be understood as the second device reads the first data from the storage space of the first device and, through the network transmission between the first device and the second device, reads the first data into the storage space of the second device.

[0102] There are various possibilities for the storage medium included in the second device, and there are also various possibilities for the specific storage location of the first data in the second device, which will be described separately below.

[0103] In some alternative embodiments, the second device includes a non-volatile memory, and the storage space of the second device includes a first storage space corresponding to the non-volatile memory. Then, reading the first data into the storage space of the second device may be reading the first data into the first storage space. Herein, the non-volatile memory means that after the device is powered off, the memory can still operate normally to ensure that the memory stored therein is not lost. Then, storing the first data in the first storage space corresponding to the non-volatile memory also improves the reliability of data storage.

[0104] Optionally, the non-volatile memory in this application may be a phase change memory (PCM). PCM is a memory medium that can be persistent and has the advantage of fast disk write speed. Writing the first data into the storage space of PCM can accelerate the speed of storing the first data to the second device and further improve the data transmission rate.

[0105] In some alternative embodiments, the second device includes a hard disk, such as a hard disk drive (HDD) or a solid-state drive (SSD). The storage space of the second device includes a second storage space corresponding to the hard disk. Then, writing the first data into the storage space of the second device may be reading the first data into the second storage space.

[0106] In this application, the first data can also be directly read into the second storage space corresponding to the hard disk in the second device, reducing the cost of the second device.

[0107] In some alternative embodiments, the second device includes a power-preserving memory and a hard disk. The storage space of the second device includes a first storage space corresponding to the power-preserving memory and a second storage space corresponding to the hard disk. After reading the first data into the first storage space, the second device can migrate the first data from the first storage space to the second storage space to achieve asynchronous disk flushing of the first data.

[0108] It should be noted that disk flushing of the first data includes disk flushing of data and metadata. In some alternative embodiments, the metadata can be stored on a dedicated second device, that is, there is a dedicated second device for storing metadata.

[0109] In this application, after writing the first data into the first storage space of the power-preserving memory, asynchronous disk flushing of the first data is also performed to write the first data into the second storage space of the hard disk, thereby releasing the storage resources of the power-preserving memory and reducing the cost.

[0110] In some alternative embodiments, for the solution where the second device includes a power-preserving memory and a hard disk, after writing the first data into the first storage space, the second device can choose to store some or all of the data in the first data in the first storage space. That is to say, this part or all of the first data will not be written into the second storage space. Optionally, the second device can select the data with high heat or high recent access frequency from the first data to stay in the first storage space. The second device can determine the heat value and access frequency of the data according to the historical information of using the data during the operation of the second device.

[0111] In some alternative embodiments, if the amount of data stored in the first storage space of the second device reaches a third data volume threshold, the second device may perform data migration or deletion on the data stored in the first storage space. Data migration includes migrating the data to be migrated from the first storage space to the second storage space. Herein, the third data volume threshold may be used to measure the storage capacity of the first storage space, or rather, the remaining data storage capacity. When the amount of data stored in the first storage space reaches the third data volume threshold, it means that the storage capacity of the first storage space is about to reach the storage limit, and the remaining data storage capacity is limited, thus it is necessary to free up storage space. The value of the third data volume threshold may be preset by the system or set by the user, and the specific value may be determined according to the actual application requirements, which are not specifically limited herein.

[0112] It should be noted that for simplicity of description, Figure 2 the illustrated embodiment takes one second device as an example. In practical applications, there may be more second devices. The first device sends the second address information to each second device, so that each second device reads data from the storage space of the first device into the storage space of the second device. The operation of each second device is similar to that of the Figure 2 illustrated second device, which will not be elaborated herein.

[0113] In some alternative embodiments, the first device is further provided with an interrupt system, which is used to cause the first device to trigger a service callback logic and feedback the response result of at least one write request to the application program.

[0114] Optionally, after the first device sends the second address information to at least one second device, that is, after step 204, the first device may further obtain response information from the second device. The response information indicates whether the data reading of the second device is successful and is used to adjust the value of the count bit of the DPU included in the first device. Herein, the so-called data reading, for the second device, is to read the first data corresponding to the second address information into the storage space of the second device. For the first device, it is to write the first data corresponding to the second address information into the storage space of the second device. When the value of the count bit of the DPU reaches the count threshold, it means that the write operation for at least one second device is completed, and the first device triggers a service callback logic and sends the response result for at least one write request to the application program.

[0115] For the second device, after reading the first data into the storage space of the second device, the second device sends response information to the first device. The response information is used to adjust the value of the count bit of the DPU included in the first device, so that when the value of the count bit of the DPU reaches the count threshold, the first device sends the response result for at least one write request to the application program.

[0116] Among them, the counting threshold and the counting method of the DPU can be set according to the needs of actual applications, and specific limitations are not made here. For a scenario with n second devices, exemplarily, the counting threshold can be set to n or 0. If the counting threshold is n, then the starting value of the counting bit of the DPU is 0, and whenever the first device obtains a response message of a second device, the value of the counting bit of the DPU is incremented by 1. If the counting threshold is 0, then the starting value of the counting bit of the DPU is n, and whenever the first device obtains a response message of a second device, the value of the counting bit of the DPU is decremented by 1.

[0117] It should be noted that there are also many possibilities for the counting threshold, and there are also many possibilities for the operation of the value of the counting bit of the DPU when the first device obtains a response message of a second device each time, which can be determined according to the needs of actual applications, and specific limitations are not made here.

[0118] Exemplarily, if the response message obtained by the first device indicates that the data writing of the second device is successful, then the response result indicates the success of the writing of at least one write request. If the response message obtained by the first device indicates that the data writing of the second device fails, then the response result indicates the failure of the writing of at least one write request. After the data writing fails, the application program can re-initiate a write request to the second device where the data writing fails through the first device, and its specific implementation process is as shown above, and will not be elaborated here.

[0119] Exemplarily, if the response message sent by a certain second device to the first device indicates that the writing of some or all of the data corresponding to at least one write request fails. The application program can still initiate the writing of all the data corresponding to at least one write request to the second device through the first device. For the data that has been successfully written, the second device adopts an overwrite write method to avoid duplicate data writing.

[0120] In this application, the first device does not need to query the second device whether the data writing is successful, but the second device asynchronously sends a response message to the first device. An interrupt system is set. When the value of the counting bit of the DPU in the first device adjusted by the response message reaches the counting threshold, the first device automatically triggers the service callback logic and sends a response result to the application program. Compared with the solution where the first device queries the response result of each second device, the performance overhead of the first device is reduced.

[0121] In some alternative embodiments, the first device may also trigger the service callback logic in other ways. For example, when the first device sends the second address information to at least one second device, the first device starts recording the duration. When the recorded duration reaches the first preset duration, the first device triggers the service callback logic and sends the response result for at least one write request to the application. Alternatively, when the first device receives the response information sent by the second device, the first device starts recording the duration. When the recorded duration reaches the second preset duration at this time, the first device triggers the service callback logic and sends the response result for at least one write request to the application.

[0122] In this application, there are multiple solutions for the first device to trigger the service callback logic, which enriches the implementation methods and application scenarios of the technical solutions in this application and improves the flexibility of the technical solutions.

[0123] In some alternative embodiments, after writing the first data into the storage space of the second device, that is, after step 205. The second device may also store the index of the first data. The index of the first data indicates the mapping relationship between the storage location of the first data in the second device and the first attribute information of the first data, and the first attribute information is used to determine the storage location of the first data in the first device.

[0124] Among them, the first attribute information can also be understood as the information provided by the communication system to the user through the first device, so that the user can determine the storage location of the first data according to the first attribute information. The first attribute information includes object information, offset, and data length, and the object information includes file identification, database identification, etc. for indicating the object characteristics containing the first data.

[0125] Exemplarily, the index may be expressed as: file name + offset + len -> data start address. Wherein, the file name indicates which file the data is contained in, the offset indicates the offset when reading data from the file, the len indicates the length of the data, and the data start address indicates the start address of the data in the second device.

[0126] There are various possibilities for the storage medium included in the second device, and there are also various possibilities for the index of the first data. Exemplarily, if the second device includes a non-volatile memory, the index of the first data is stored in the first storage space corresponding to the non-volatile memory. Exemplarily, if the second device does not include a non-volatile memory, the index of the first data is stored in the memory of the second device.

[0127] In this application, the second device stores the index of the first data, which provides an implementation basis for other solutions that require obtaining the first data from the second device, such as data query for the first data, and improves the practicability of the technical solution of this application. In addition, storing the index of the first data in the first storage space corresponding to the non-volatile memory can also speed up the query of the first data and improve efficiency.

[0128] Based on the relevant descriptions above, an embodiment of this application provides a communication system, which is used to implement the method of "the first device sends a data write request to the second device" introduced above.

[0129] Generally speaking, the communication system includes a first device and at least one second device. The first device is used to implement the functions of the first device in the foregoing method, and the second device is used to implement the functions of the second device in the foregoing method. The following will be described in detail with reference to the schematic diagram.

[0130] Please refer to Figure 3 , Figure 3 which is a schematic flowchart of the data transmission method provided by an embodiment of this application. It should be noted that Figure 3 taking one second device as an example, in practical applications, there may also be a greater number of second devices, and specifically, it is not limited here.

[0131] As Figure 3 shown, the first device includes a DPU and a NIC. The data transmission method includes:

[0132] Step 1. The application program applies for the storage space (including the storage space of the first device) registered by the first device through the memory application interface for writing data. The memory application interface mentioned here is provided by the first device for the application program. By calling this interface, the application program can use the storage space of the first device to store data.

[0133] The first device obtains at least one write request, aggregates the at least one write request through the DPU to obtain the aggregated address information (i.e., the second address information). The DPU calls the NIC to execute Step 2. Send the second address information to the second device. Among them, the second address information is a set of at least one first address information included in the at least one write request, and the address indicated by each first address information is the address of the data to be written to the second device, which is included in the storage space of the first device.

[0134] The second device obtains the second address information, and through the NIC, executes step 3.1 to read data in batches unidirectionally into the PCM. Here, the unidirectional batch reading method is DRMA gather, and the data read is the first data indicated by the second address information. Then the second device executes step 3.2 to update the index, which indicates the mapping relationship between the storage location of the first data in the second device and the first attribute information of the first data. Exemplarily, in a distributed file system, the first attribute information can be expressed as "file name + offset + len".

[0135] After writing the first data into the second device, the second device can, through the CPU, execute step 4. to return a response message to the first device, which is used to indicate whether the data writing is successful and adjust the value of the count bit in the DPU of the first device. Optionally, the CPU can return the response message through the atomic_add_and_interrupt method.

[0136] When the value of the count bit in the DPU reaches the count threshold, the first device executes step 5. to trigger the service callback logic, thereby returning a response result to the application program.

[0137] In some alternative embodiments, the second device can also execute step 6. to asynchronously flush the disk. That is, write the first data from the PCM into the storage space of the hard disk.

[0138] Figure 3 The detailed process of the steps shown has been described in detail above. Referring to the foregoing, it will not be elaborated here.

[0139] It should be noted that Figure 3 taking the second device including the PCM as an example, in actual applications, the second device may not include the PCM. In this solution, the second device stores the first data in the hard disk of the second device and stores the index of the first data in the memory of the second device. Figure 3 Taking the CPU of the second device returning the response message as an example, in actual applications, the second device may also include a DPU, and the DPU returns the response message to the first device. Specifically, it is not limited here. Figure 3 Taking the example that at least one write request includes multiple write requests and the DPU in the first device converges multiple write requests, in actual applications, at least one write request may include one write request. At this time, the second address information is the first address information included in this one write request. Specifically, it is not limited here.

[0140] Second, the first device initiates a data read request to the second device.

[0141] Please refer to Figure 4 , Figure 4A flowchart diagram of the data transmission method provided by the embodiments of the present application, including:

[0142] 401. Obtain a second call request from an application, where the second call request instructs the application running on the first device to use the storage space of the first device to store data.

[0143] An application runs on the first device. When a user (such as an application developer) connects the application to the first device, the application can apply for storage space from the first device through the memory application interface of the first device. That is, the application sends a second call request to the first device, and the second call request is used to request to use the storage space of the first device to store the data generated or used during the operation of the application. Based on the second call request, the first device allocates a data storage space for the application, and the data storage space is included in the storage space of the first device.

[0144] 402. The first device obtains at least one read request. Each read request includes third address information, and the address indicated by the third address information is included in the storage space of the first device. Each read request instructs to write the data stored in the storage space of the second device into the storage space of the first device.

[0145] During the operation of the application, a read request may be sent to the first device, and the read request is used to request to perform a read data operation from a second device that has established a communication connection with the first device. This process can also be understood as the application requesting the second device to store the data required during its operation in the storage space of the first device.

[0146] Each read request includes third address information, and the address indicated by the third address information is included in the storage space of the first device. And each read request instructs to write the data in the storage space of the second device into the storage space of the first device, mainly to the address indicated by the third address information. That is, the storage location of the data that the application wants to apply to write into the first device is included in the storage space of the first device, and the buffer of the application is also included in the buffer of the first device. Then, in the embodiments of the present application, for the foregoing read request, it is not necessary to copy the data from the buffer of the application to the buffer of the first device, but to write it into the storage space of the first device, reducing one data copy. Optionally, the address indicated by the third address information may be the starting address of the data.

[0147] In the present application, the data storage space provided by the first device for the application is included in the storage space of the first device. When the application initiates a read request, the final storage location of the second data read by the first device from the second device is included in the storage space of the first device, and there is no need to copy the data again, eliminating one data copy and reducing the latency of data transmission.

[0148] In some alternative embodiments, each read request further includes second attribute information, which is used to determine the storage location of the data corresponding to each read request in the second device. Among them, the second attribute information can also be understood as the information provided by the communication system to the user through the first device, so that the user can determine the storage location of the data to be read according to the second attribute information. Exemplarily, the second attribute information includes object information, offset, and data length. The object information includes file identifiers, database identifiers, etc., which are used to indicate the object characteristics containing the second data.

[0149] In this application, the storage location of the data to be read is determined by the second attribute information included in the read request, which improves the feasibility of the technical solution of this application.

[0150] 403. The first device sends at least one read request to the second device.

[0151] In some alternative embodiments, the first device can transmit each read request to the second device as soon as it obtains a read request, which has good immediacy.

[0152] In some alternative embodiments, the first device can set a second data volume threshold, and determine whether it is necessary to converge multiple read requests by comparing the first data volume threshold with the data volume corresponding to each read request. Generally speaking, when the first device obtains a read request, if the data volume corresponding to the read request is greater than or equal to the second data volume threshold, the first device sends the read request to the second device. If the data volume corresponding to the read request is less than the second data volume threshold, the first device will obtain other read requests until the sum of the data volumes corresponding to the obtained read requests is greater than or equal to the second data volume threshold, converge these multiple read requests to obtain multiple read requests, and send these multiple read requests to the second device.

[0153] Exemplarily, if at least one read request includes a first read request and a second read request, and the data volume corresponding to the first read request or the second read request is less than the second data volume threshold, and the sum of the data volumes corresponding to the first read request and the second read request is greater than or equal to the second data volume threshold. Then, when the first device obtains at least one read request, it includes: invoking the DPU to converge the first read request and the second read request to obtain at least one read request.

[0154] Exemplarily, obtaining at least one read request can also be obtaining a third read request, and the data volume corresponding to the third read request is greater than or equal to the second data volume threshold.

[0155] It should be noted that the value of the second data volume threshold can be preset by the system or set by the user, and the specific value can be determined according to the actual application needs, and will not be specifically limited here.

[0156] In this application, the second data volume threshold is used to measure whether the data volume corresponding to the read requests obtained by the first device reaches the sending standard. For read requests with a high sending frequency and a small requested data volume, if the first device sends each obtained read request to the second device, it will cause the first device to send a large number of read requests in a short time but the requested data volume is not high, resulting in low transmission efficiency. Therefore, for read requests with a requested data volume less than the second data volume threshold, they will be aggregated with other read requests, and the aggregated read requests will be sent to the second device, thereby improving the transmission efficiency.

[0157] In some alternative embodiments, the first device sends at least one read request to at least one second device through the DPU of the first device. Specifically, the DPU can issue an instruction to the network card to call the network card, so that the network card sends at least one read request to at least one second device.

[0158] In this application, offloading the function of controlling the network card for data transmission from the CPU to the DPU releases the CPU resources of the first device. While reducing the CPU resource occupancy of the first device, it also improves the performance of the first device.

[0159] 404. The second device reads at least one second data corresponding to at least one read request from the storage space of the second device according to at least one read request.

[0160] The second device obtains at least one read request from the first device, where each read request includes third address information, and the address indicated by the third address information is included in the storage space of the first device. Each read request instructs to write the data stored in the storage space of the second device into the storage space of the first device.

[0161] Each read request further includes second attribute information, and the second attribute information is used to determine the storage location of the data corresponding to each read request in the second device. The specific content of the second attribute information has been described in the foregoing step 402 and will not be elaborated here.

[0162] In some alternative embodiments, an index may also be stored in the storage space of the second device, and the index is used to indicate the mapping relationship between the second attribute information and the data storage location. The data storage location mentioned here is a storage location that can be perceived by the communication system or the second device, and this data storage location is included in the storage space of the second device. Among them, the data storage location may be the starting position of the data.

[0163] Then, after the second device obtains at least one read request, according to the mapping relationship indicated by the index and at least one second attribute information included in at least one read request, it determines the target storage location of at least one second data corresponding to at least one read request in the storage space of the second device, and reads the second data from the target storage location.

[0164] Exemplarily, the index may be expressed as: file name + offset + len -> data start address. Among them, the file name indicates under which file the data is included, the offset indicates the offset when reading data from the file, the len indicates the length of the data, and the data start address indicates the start address of the data in the second device.

[0165] In this application, the second device stores the mapping relationship between the attribute information and the data storage location, enabling the second device to determine the specific storage location of the data to be read in the second device according to this mapping relationship and the second attribute information included in the read request, providing technical support for the implementation of the technical solution of this application and enhancing the feasibility of the technical solution of this application.

[0166] There are various possibilities for the storage medium included in the second device, and there are also various possibilities for the target storage location of the second data. The following will be described separately.

[0167] In some alternative embodiments, the second device includes a non-volatile memory, and the storage space of the second device includes a first storage space corresponding to the non-volatile memory. If it is determined through querying the index that the target storage location can be included in the first storage space. Then the second device reads the second data from the target storage location.

[0168] In this application, the second device includes a non-volatile memory, and the target storage location of the second data is included in the first storage space corresponding to the non-volatile memory. In this solution, the data reading speed is fast. In addition, when the second device is powered off, it can also ensure that the stored second data is not lost, enhancing the reliability of the technical solution of this application.

[0169] In some alternative embodiments, the second device includes a hard disk, and the storage space of the second device includes a second storage space corresponding to the hard disk. If the index is queried and it is determined that the target storage location can be included in the second storage space. Then there are various possible operations for the second device:

[0170] Optionally, the second device can directly read the second data from the hard disk.

[0171] In this application, the second data can be stored in the second storage space corresponding to the hard disk, and the second data is directly read from the hard disk. Using the hard disk to store data reduces the storage cost of the second device.

[0172] Optionally, if the storage space of the second device further includes a first storage space corresponding to the non-volatile memory, the second device reads the second data from the target storage location in the second storage space to the first storage space. In this solution, the second device also updates the mapping relationship, and the data storage location corresponding to the second attribute information of the second data in the updated mapping relationship is included in the first storage space. That is to say, the second device reads the second data from the hard disk to the non-volatile memory and updates the mapping relationship to avoid errors in subsequent queries or uses of the second data.

[0173] In this application, the second device writes the second data included in the hard disk to the first storage space corresponding to the non-volatile memory and then returns it to the first device, which improves the transmission efficiency of the second data.

[0174] In some alternative embodiments, in the solution where the second device includes a hard disk and a non-volatile memory, if the target storage location can be included in the second storage space, the second device may not read the second data from the second storage space to the first storage space.

[0175] In some alternative embodiments, in the solution where the second device includes a hard disk and a non-volatile memory, if the target storage location can be included in the second storage space, the second device may read some or all of the second data to the first storage space. Optionally, the second device may select the data with high heat or high recent access frequency from the second data and read it to the first storage space. The second device may determine the heat value and access frequency of the data according to the historical information of using the data during the operation of the second device.

[0176] 405. The second device sends the second data based on the one-way sending method.

[0177] After obtaining the second data, the second device sends the second data to the first device based on the one-way sending method. Among them, the one-way sending method means that the first device does not require the response of the second device and directly sends the second data to the first device.

[0178] Exemplarily, assuming that the first device sends multiple read requests to the second device, the one-way sending method may be the scatter method of RDMA to scatter the second data and transmit it to the address corresponding to each read request respectively.

[0179] For the first device, the first device obtains the second data from the second device. The second data is read by the second device from the storage space of the second device. The storage space of the second device includes a first storage space corresponding to the non-volatile memory of the second device or a second storage space corresponding to the hard disk of the second device.

[0180] In this application, the second device sends the second data to the first device in a unilateral sending manner. The transmission speed of unilateral sending is fast, and a large amount of data can be transmitted in the same time, which can make full use of the network bandwidth and improve the network throughput.

[0181] In some alternative embodiments, the first device is further provided with an interrupt system, which is used to cause the first device to trigger a service callback logic and feedback the response results of at least one read request to the application program.

[0182] Optionally, the second device may send a target instruction to the first device to adjust the value of the count bit of the DPU included in the first device. When the value of the count bit of the DPU reaches the count threshold, it means that the read operation on the second device is completed, and the first device triggers the service callback logic and sends the response results for at least one read request to the application program. Exemplarily, the second device may return the target instruction through the atomic_add_and_interrupt method.

[0183] Among them, the count threshold and the counting method of the DPU can be set according to the actual application needs, and specific limitations are not made here. For a scenario with m read requests, exemplarily, the count threshold can be set to m or 0. If the count threshold is m, then the starting value of the count bit of the DPU is 0, and whenever the first device obtains a target instruction from the second device, the value of the count bit of the DPU is incremented by 1. If the count threshold is 0, then the starting value of the count bit of the DPU is m, and whenever the first device obtains a target instruction from the second device, the value of the count bit of the DPU is decremented by 1.

[0184] It should be noted that there are also various possibilities for the count threshold, and there are also various possibilities for the operation of the value of the count bit of the DPU when the first device obtains each response information from the second device, which can be determined according to the actual application needs, and specific limitations are not made here.

[0185] In this application, the first device does not need to query the second device whether the read data is successful, but the second device asynchronously sends an instruction to the first device. An interrupt system is set up. When the value of the count bit of the DPU in the first device adjusted by the instruction reaches the count threshold, the first device automatically triggers the service callback logic and sends the response results to the application program. Compared with the solution that the first device queries the response results of read requests from the second device one by one, the performance overhead of the first device is reduced.

[0186] In some alternative embodiments, the first device may also trigger the service callback logic in other ways. For example, when the first device sends at least one read request to the second device, the first device starts to record the duration. When the recorded duration reaches the third preset duration, the first device triggers the service callback logic and sends the response results for at least one read request to the application program.

[0187] In this application, there are multiple solutions for the first device to trigger the service callback logic, which enriches the implementation methods and application scenarios of the technical solutions of this application and improves the flexibility of the technical solutions.

[0188] Based on the relevant descriptions above, an embodiment of this application provides a communication system, which is used to implement the method of "the first device initiates a data read request to the second device" introduced above.

[0189] Generally speaking, the communication system includes a first device and at least one second device. The first device is used to implement the functions of the first device in the foregoing method, and the second device is used to implement the functions of the second device in the foregoing method. The following will be described in detail with reference to the schematic diagram.

[0190] Please refer to Figure 5 , Figure 5 which is a schematic flowchart of the data transmission method provided by an embodiment of this application. It should be noted that Figure 5 taking one second device as an example, in actual applications, there may also be a greater number of second devices, and the specific number is not limited here.

[0191] As Figure 5 shown, the first device includes a DPU and a NIC. The data transmission method includes:

[0192] Step 1. The application program applies for the storage space (including the storage space of the first device) registered by the first device through the memory application interface for writing data. The memory application interface mentioned here is provided by the first device for the application program. By calling this interface, the application program can use the storage space of the first device to store data.

[0193] The first device obtains at least one read request and aggregates at least one read request through the DPU. The DPU calls the NIC to execute Step 2. Send at least one read request to the second device. Each read request includes third address information and may also include second attribute information. The address indicated by the third address information is included in the storage space of the first device.

[0194] The second device obtains at least one read request and executes Step 3.1 Query the index to obtain the target storage location of the second data corresponding to at least one read request. If the target storage location is included in the second storage space of the hard disk, then execute Step 3.2 Data reading, and read the second data into the first storage space. The second device will also update the index, which indicates the mapping relationship between the storage location of the second data in the second device and the second attribute information of the second data.

[0195] After obtaining the second data, the second device calls the NIC to execute Step 3.3 Unilateral transmission of the second data.

[0196] The second device can also execute step 4 through the CPU to return a target instruction to the first device. This instruction is used to adjust the value of the count bit of the DPU in the first device. Optionally, the CPU can return the target instruction through the atomic_add_and_interrupt method.

[0197] When the value of the count bit in the DPU reaches the count threshold, the first device executes step 5 to trigger the service callback logic, thereby returning a response result to the application program.

[0198] Figure 5 The detailed process of the steps shown has been described in detail above. Referring to the above, it will not be repeated here.

[0199] It should be noted that Figure 5 taking the second device including PCM as an example, in actual applications, the second device may not include PCM. In this solution, the second device stores the index of the first data in the memory of the second device. Figure 5 Taking the CPU of the second device returning the target instruction as an example, in actual applications, the second device may also include a DPU, and the DPU returns the target instruction to the first device. Specifically, it is not limited here. Figure 5 Taking at least one read request including multiple read requests as an example, and the DPU in the first device aggregating multiple read requests as an example, in actual applications, at least one read request may only include one write request. Specifically, it is not limited here.

[0200] In addition, Figure 3 and Figure 5 In the embodiments shown, taking the communication system capable of implementing the method of the first device initiating a data write request or a data read request to the second device provided in the embodiments of the present application as an example. In actual applications, the communication system provided in the embodiments of the present application can also implement the method of the first device initiating a data write request and a data read request to the second device provided in the embodiments of the present application. It is not limited here.

[0201] The relevant devices provided in the embodiments of the present application will be described below. Please refer to Figure 6 and Figure 7 , Figure 6 and Figure 7 Both are schematic structural diagrams of the communication device provided in the embodiments of the present application.

[0202] Generally speaking, the communication device includes corresponding units or modules for performing the foregoing method. The units or modules included in the communication device can be implemented in software and / or hardware. As the first device, the communication device can be, for example, a terminal device, or a module of the terminal device (such as a chip, etc.), or a logical node, logical module, or software that can implement all or part of the functions of the terminal device. As the second device, the communication device can be, for example, a network device, or a module of the network device (such as a chip, etc.), or a logical node, logical module, or software that can implement all or part of the functions of the network device.

[0203] As Figure 6 shown, the communication device 600, as the first device, includes a transceiver unit 601.

[0204] The transceiver unit 601 is configured to: obtain a first call request from an application, where the first call request instructs the application to use the storage space of the first device to store data, and the application runs on the first device. Obtain at least one write request, where each write request includes first address information, and the address indicated by the first address information is included in the storage space of the first device, and each write request instructs to write the data corresponding to the first address information in the storage space to at least one second device. Send second address information to at least one second device, so that at least one second device reads the first data corresponding to the second address information from the storage space of the first device and writes the first data to the storage space of the second device, where the second address information includes at least one first address information.

[0205] In some optional embodiments, the transceiver unit 601 is specifically configured to send the second address information to at least one second device through the DPU of the first device.

[0206] In some optional embodiments, at least one write request includes a first write request and a second write request, the data volume corresponding to the first write request or the second write request is less than the first data volume threshold, and the sum of the data volumes corresponding to the first write request and the second write request is greater than or equal to the first data volume threshold. The communication device 600 further includes a processing unit 602, configured to call the DPU to aggregate the first write request and the second write request to obtain the second address information.

[0207] In some optional embodiments, if at least one write request includes a third write request, and the data volume corresponding to the third write request is greater than or equal to the first data volume threshold, then the second address information includes the address information corresponding to the third write request.

[0208] In some alternative embodiments, the transceiver unit 601 is further configured to obtain response information from the second device, where the response information indicates whether the data writing of the second device is successful, and is configured to adjust the value of the count bit of the DPU included in the first device. When the value of the count bit of the DPU reaches the count threshold, a response result for at least one write request is sent to the application program.

[0209] The communication device 600 is configured to perform the relevant operations of the first device in the scenario of "1. The first device initiates a data write request to the second device" in the foregoing embodiments, which will not be elaborated herein.

[0210] As Figure 6 shown, the communication device 600, as the second device, includes a transceiver unit 601 and a processing unit 602.

[0211] In some alternative embodiments, the transceiver unit 601 is configured to obtain second address information from the first device, where the second address information includes at least one first address information, and each first address information indicates an address included in the storage space of the first device.

[0212] The processing unit 602 is configured to read first data corresponding to the second address information from the storage space of the first device based on the unilateral reading method according to the second address information. The first data is written into the storage space of the second device.

[0213] In some alternative embodiments, the storage space of the second device includes a first storage space corresponding to the non-volatile memory, and the non-volatile memory is included in the second device. The processing unit 602 is specifically configured to write the first data into the first storage space.

[0214] In some alternative embodiments, the storage space of the second device further includes a second storage space corresponding to the hard disk, and the hard disk is included in the second device. The processing unit 602 is further configured to write the first data from the first storage space into the second storage space.

[0215] In some alternative embodiments, the storage space of the second device includes a second storage space corresponding to the hard disk, and the hard disk is included in the second device. The processing unit 602 is specifically configured to write the first data into the second storage space.

[0216] In some alternative embodiments, the processing unit is further configured to, if the second device includes a non-volatile memory, store an index of the first data in the first storage space corresponding to the non-volatile memory, where the index of the first data indicates the mapping relationship between the storage location of the first data in the second device and the first attribute information of the first data, and the first attribute information is used to determine the storage location of the first data in the first device. If the second device does not include a non-volatile memory, store the index of the first data in the memory of the second device.

[0217] In some alternative embodiments, a transceiver unit 601 is configured to send response information to a first device, where the response information is used to adjust the value of a count bit of a DPU included in the first device, so that when the value of the count bit of the DPU reaches a count threshold, the first device sends a response result for at least one write request to an application program.

[0218] The communication device 600 is configured to perform the relevant operations of the second device in the scenario of "I. The first device initiates a data write request to the second device" in the foregoing embodiments, which will not be elaborated here.

[0219] As Figure 6 shown, the communication device 600, as the first device, includes a transceiver unit 601.

[0220] The transceiver unit 601 is configured to obtain a second call request from an application program, where the second call request instructs the application program to store data using the storage space of the first device, and the application program runs on the first device. Obtain at least one read request, where each read request includes third address information, and the address indicated by the third address information is included in the storage space of the first device, and each read request instructs to write the data stored in the storage space of the second device into the storage space of the first device. Send at least one read request to the second device, so that the second device reads second data corresponding to at least one read request from the storage space of the second device according to at least one read request.

[0221] In some alternative embodiments, each read request further includes second attribute information, where the second attribute information is used to determine the storage location of the data corresponding to each read request in the second device.

[0222] In some alternative embodiments, the transceiver unit 601 is specifically configured to send at least one read request to at least one second device through the DPU of the first device.

[0223] In some alternative embodiments, at least one read request includes a first read request and a second read request, where the data volume corresponding to the first read request or the second read request is less than a second data volume threshold, and the sum of the data volumes corresponding to the first read request and the second read request is greater than or equal to the second data volume threshold. The communication device 600 further includes a processing unit 602, which is specifically configured to call the DPU to converge the first read request and the second read request to obtain at least one read request.

[0224] In some alternative embodiments, the transceiver unit 601 is specifically configured to obtain a third read request, where the data volume corresponding to the third read request is greater than or equal to the second data volume threshold.

[0225] In some alternative embodiments, the transceiver unit 601 is specifically configured to obtain second data from a second device, where the second data is read by the second device from the storage space of the second device. The storage space of the second device includes a first storage space corresponding to the non-volatile memory of the second device, or a second storage space corresponding to the hard disk of the second device.

[0226] The communication device 600 is configured to perform the relevant operations of the first device in the scenario of "II. The first device sends a data read request to the second device" in the foregoing embodiments, which will not be elaborated herein.

[0227] As Figure 6 shown, the communication device 600, as the second device, includes a transceiver unit 601 and a processing unit 602.

[0228] The transceiver unit 601 is configured to obtain at least one read request from the first device, where each read request includes third address information, and the address indicated by the third address information is included in the storage space of the first device. Each read request indicates that the data stored in the storage space of the second device is written into the storage space of the first device.

[0229] The processing unit 602 is configured to read at least one second data corresponding to at least one read request from the storage space of the second device according to the at least one read request.

[0230] The transceiver unit 601 is further configured to send the second data to the first device based on a unidirectional transmission method.

[0231] In some alternative embodiments, each read request further includes second attribute information, and the second attribute information is used to determine the storage location of the data corresponding to each read request in the second device. The mapping relationship between the second attribute information and the data storage location is stored in the storage space of the second device.

[0232] The processing unit 602 is specifically configured to determine the target storage location of at least one second data corresponding to at least one read request in the storage space of the second device according to at least one second attribute information included in the at least one read request and the mapping relationship. Read the second data from the target storage location.

[0233] In some alternative embodiments, the storage space of the second device includes a first storage space corresponding to the non-volatile memory, the non-volatile memory is included in the second device, and the target storage location is included in the first storage space.

[0234] In some alternative embodiments, the storage space of the second device includes a second storage space corresponding to the hard disk, the hard disk is included in the second device, and the target storage location is included in the second storage space.

[0235] In some alternative embodiments, if the storage space of the second device includes a first storage space corresponding to the power-preserving memory and a second storage space corresponding to the hard disk, and the target storage location is included in the second storage space. The processing unit 602 is specifically configured to read the second data from the target storage location to the first storage space. The processing unit 602 is further configured to update the mapping relationship, and in the updated mapping relationship, the data storage location corresponding to the second attribute information of the second data is included in the first storage space.

[0236] The communication device 600 is used to perform the related operations of the second device in the scenario of "II. The first device sends a data read request to the second device" in the foregoing embodiments, which will not be elaborated here.

[0237] Next, please refer to Figure 7 , Figure 7 which is a schematic structural diagram of a communication device provided by an embodiment of the present application. The communication device 700 includes a processor 701, a memory 702, a communication interface 703, and a bus 704. Among them, the processor 701, the memory 702, and the communication interface 703 communicate through the bus 704, and can also communicate through other means such as wireless transmission. The memory 702 stores program codes, and the processor 701 can call the program codes stored in the memory 702 to execute the operations performed by the first device or the second device in the foregoing, so as to implement any data transmission method provided by the embodiments of the present application, which will not be elaborated here.

[0238] It should be understood that in the embodiments of the present application, the processor 701 may be a CPU, and the processor 701 may also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor, etc.

[0239] The memory 702 may include a read-only memory and a random access memory, and provide instructions and data to the processor 701. The memory 702 may also include a non-volatile random access memory. For example, the memory 702 may also store information about the device type.

[0240] The memory 702 can be a volatile memory, a non-volatile memory, or can include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM), or a flash memory. The volatile memory can be a random access memory (RAM), which is used as an external cache. By way of example but not limitation, many forms of RAM are available, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchlink DRAM (SLDRAM), and direct rambus RAM (DR RAM).

[0241] In addition to including a data bus, the bus 704 can also include a power bus, a control bus, a status signal bus, etc. However, for the sake of clarity, all kinds of buses are labeled as bus 704 in the figure. The bus 740 can be a Peripheral Component Interconnect Express (PCIe) bus, or an extended industry standard architecture (EISA) bus, a unified bus (Ubus or UB), a compute express link (CXL), a cache coherent interconnect for accelerators (CCIX), etc. The bus 740 can be divided into an address bus, a data bus, a control bus, etc.

[0242] The communication device 700 can also include one or more communication interfaces, one or more operating systems, such as Windows Server TM , Mac OS X TM , UnixTM , Linux TM , FreeBSD TM and so on.

[0243] Those skilled in the art can clearly understand that for the convenience and conciseness of description, the specific working processes of the systems, devices, and units described above can refer to the corresponding processes in the foregoing method embodiments, and will not be elaborated herein.

[0244] In the several embodiments provided in this application, it should be understood that the disclosed systems, devices, and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the units is only a logical function division, and there can be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed couplings or direct couplings or communication connections to each other can be through some interfaces, and the indirect couplings or communication connections of the devices or units can be in electrical, mechanical, or other forms.

[0245] The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they can be located in one place, or can be distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0246] In addition, the functional units in each embodiment of this application can be integrated into one processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.

[0247] If the above-mentioned integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of this technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in each embodiment of this application. The foregoing storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical discs that can store program codes.

Claims

1. A data transmission method, characterized in that, the method is applied to a first device, and the method includes: obtaining a first call request from an application, where the first call request instructs the application to use the storage space of the first device to store data, and the application runs on the first device; obtaining at least one write request, where each write request includes first address information, and the address indicated by the first address information is included in the storage space of the first device, and each write request instructs to write the data corresponding to the first address information in the storage space to at least one second device; sending second address information to the at least one second device, so that the at least one second device reads the first data corresponding to the second address information from the storage space of the first device into the storage space of the second device, where the second address information includes at least one first address information corresponding to the at least one write request.

2. The method according to claim 1, characterized in that, the sending the second address information to the at least one second device includes: sending the second address information to the at least one second device through the data processor DPU of the first device.

3. The method according to claim 1 or 2, characterized in that, the at least one write request includes a first write request and a second write request, the data volume corresponding to the first write request or the second write request is less than a first data volume threshold, and the sum of the data volumes corresponding to the first write request and the second write request is greater than or equal to the first data volume threshold; before the sending the second address information to the at least one second device, the method further includes: invoking the DPU to converge the first write request and the second write request to obtain the second address information.

4. The method according to claim 1 or 2, characterized in that, if the at least one write request includes a third write request, and the data volume corresponding to the third write request is greater than or equal to the first data volume threshold, then the second address information includes the address information corresponding to the third write request.

5. The method according to any one of claims 1 to 4, characterized in that, after the sending the second address information to the at least one second device, the method further includes: obtaining response information from the second device, where the response information indicates whether the data reading of the second device is successful and is used to adjust the value of the count bit of the DPU included in the first device; when the value of the count bit of the DPU reaches a count threshold, then sending a response result for the at least one write request to the application.

6. A data transmission method, characterized in that, the method is applied to a second device, and the method includes: obtaining second address information from a first device, where the second address information includes at least one first address information, and the address indicated by each first address information is included in the storage space of the first device; based on a unilateral reading method, reading the first data corresponding to the second address information from the storage space of the first device into the storage space of the second device.

7. The method according to claim 6, wherein, the storage space of the second device includes a first storage space corresponding to the non-volatile memory, and the non-volatile memory is included in the second device; the step of reading the first data corresponding to the second address information from the storage space of the first device into the storage space of the second device includes: reading the first data corresponding to the second address information into the first storage space.

8. The method according to claim 7, wherein, the storage space of the second device further includes a second storage space corresponding to the hard disk, and the hard disk is included in the second device; after reading the first data corresponding to the second address information into the first storage space, the method further includes: transferring the first data from the first storage space to the second storage space.

9. The method according to claim 6, wherein, the storage space of the second device includes a second storage space corresponding to the hard disk, and the hard disk is included in the second device; the step of reading the first data corresponding to the second address information from the storage space of the first device into the storage space of the second device includes: reading the first data corresponding to the second address information into the second storage space.

10. The method according to any one of claims 7 to 9, wherein, after reading the first data corresponding to the second address information from the storage space of the first device into the storage space of the second device, the method further includes: if the second device includes a non-volatile memory, storing an index of the first data in the first storage space corresponding to the non-volatile memory, the index of the first data indicating a mapping relationship between the storage location of the first data in the second device and first attribute information of the first data, and the first attribute information being used to determine the storage location of the first data in the first device; if the second device does not include the non-volatile memory, storing the index of the first data in the memory of the second device.

11. The method according to any one of claims 6 to 10, wherein, after reading the first data corresponding to the second address information from the storage space of the first device into the storage space of the second device, the method further includes: sending response information to the first device, the response information being used to adjust the value of a count bit included in a DPU of the first device, so that when the value of the count bit of the DPU reaches a count threshold, the first device sends a response result for the at least one write request to the application program.

12. A data transmission method, wherein, the method is applied to a first device, and the method includes: obtaining a second call request from an application program, the second call request indicating that the application program uses the storage space of the first device to store data, and the application program runs on the first device; Obtain at least one read request, where each read request includes third address information, and the address indicated by the third address information is included in the storage space of the first device, and each read request indicates that the data stored in the storage space of the second device is written into the storage space of the first device; Send the at least one read request to the second device, so that the second device reads the second data corresponding to the at least one read request from the storage space of the second device according to the at least one read request.

13. The method according to claim 12, wherein, each read request further includes second attribute information, and the second attribute information is used to determine the storage location of the data corresponding to each read request in the second device.

14. The method according to claim 12 or 13, wherein, the sending the at least one read request to the second device includes: Sending the at least one read request to the at least one second device through the DPU of the first device.

15. The method according to any one of claims 12 to 14, wherein, the at least one read request includes a first read request and a second read request, the data volume corresponding to the first read request or the second read request is less than the second data volume threshold, and the sum of the data volumes corresponding to the first read request and the second read request is greater than or equal to the second data volume threshold; the obtaining at least one read request includes: Invoking the DPU to converge the first read request and the second read request to obtain the at least one read request.

16. The method according to any one of claims 12 to 14, wherein, the obtaining at least one read request includes: Obtaining a third read request, and the data volume corresponding to the third read request is greater than or equal to the second data volume threshold.

17. The method according to any one of claims 12 to 16, wherein, after the sending the at least one read request to the second device, the method further includes: Obtaining the second data from the second device, where the second data is read by the second device from the storage space of the second device, and the storage space of the second device includes a first storage space corresponding to the non-volatile memory of the second device or a second storage space corresponding to the hard disk of the second device.

18. A data transmission method, wherein, the method is applied to a second device, and the method includes: Obtaining at least one read request from a first device, where each read request includes third address information, and the address indicated by the third address information is included in the storage space of the first device, and each read request indicates that the data stored in the storage space of the second device is written into the storage space of the first device; Reading the second data corresponding to the at least one read request from the storage space of the second device according to the at least one read request; Sending the second data to the first device based on a unilateral sending method.

19. The method according to claim 18, wherein, Each of the read requests further includes second attribute information for determining a storage location of data corresponding to each of the read requests in the storage space of the second device; The storage space of the second device stores a mapping relationship between the second attribute information and the data storage location; The reading of the at least one second data corresponding to the at least one read request from the storage space of the second device according to the at least one read request includes: Determining a target storage location of the at least one second data corresponding to the at least one read request in the storage space of the second device according to at least one piece of second attribute information included in the at least one read request and the mapping relationship; Reading the second data from the target storage location.

20. The method according to claim 19, wherein, The storage space of the second device includes a first storage space corresponding to a non-volatile memory, the non-volatile memory is included in the second device, and the target storage location is included in the first storage space.

21. The method according to claim 19, wherein, The storage space of the second device includes a second storage space corresponding to a hard disk, the hard disk is included in the second device, and the target storage location is included in the second storage space.

22. The method according to claim 21, wherein, If the storage space of the second device further includes a first storage space corresponding to a non-volatile memory, then the reading of the second data from the target storage location includes: Reading the second data from the target storage location to the first storage space; The method further includes: updating the mapping relationship, and in the updated mapping relationship, the data storage location corresponding to the second attribute information of the second data is included in the first storage space.

23. A communication device, wherein, It includes a module for implementing the method according to any one of the foregoing claims 1 to 5, 6 to 11, 12 to 17, 18 to 22.

24. A communication device, wherein, It includes a processor, and the processor is coupled to a memory; Instructions are stored in the memory, and when the instructions run on the processor, the communication device implements the method according to any one of claims 1 to 5, 6 to 11, 12 to 17, 18 to 22.

25. A computer-readable storage medium, wherein, The computer-readable storage medium stores instructions, and when the instructions run on a processor, the method according to any one of claims 1 to 5, 6 to 11, 12 to 17, 18 to 22 is implemented.

26. A computer program product, wherein, When the computer program product is executed on a computer, the method according to any one of claims 1 to 5, 6 to 11, 12 to 17, 18 to 22 is implemented.